From aa555614c0ba6cebdf38a15f13569ce93da5adab Mon Sep 17 00:00:00 2001 From: MalteHerrmann <42640438+MalteHerrmann@users.noreply.github.com> Date: Wed, 27 Nov 2024 16:28:51 +0100 Subject: [PATCH] imp(all): Bump to latest state on Evmos main (b72a32d76) (#60) --- .clconfig.json | 5 +- .github/workflows/bsr-push.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/proto.yml | 4 +- .github/workflows/super-linter.yml | 1 + .github/workflows/test.yml | 3 +- .golangci.yml | 3 +- .mergify.yml | 26 +- CHANGELOG.md | 7 +- Makefile | 6 +- ante/cosmos/authz_test.go | 31 +- ante/cosmos/min_gas_price.go | 12 +- ante/evm/01_setup_ctx.go | 15 +- ante/evm/01_setup_ctx_test.go | 2 +- ante/evm/02_mempool_fee.go | 6 +- ante/evm/04_validate.go | 24 +- ante/evm/04_validate_test.go | 88 +- ante/evm/05_signature_verification.go | 6 +- ante/evm/06_account_verification.go | 2 +- ante/evm/06_account_verification_test.go | 2 +- ante/evm/07_can_transfer_test.go | 4 +- ante/evm/08_gas_consume.go | 15 - ante/evm/08_gas_consume_test.go | 6 +- ante/evm/10_gas_wanted.go | 5 +- ante/evm/ante_test.go | 34 +- ante/evm/eth_benchmark_test.go | 4 +- ante/evm/fee_checker.go | 56 +- ante/evm/fee_checker_test.go | 98 +- ante/evm/fee_market_test.go | 4 +- ante/evm/mono_decorator.go | 60 +- ante/evm/signverify_test.go | 5 +- ante/evm/sigs_test.go | 2 +- ante/evm/utils.go | 33 +- ante/evm/utils_test.go | 35 +- ante/interfaces/evm.go | 17 +- ante/testutils/testutil.go | 55 +- api/os/evm/v1/evm.pulsar.go | 424 +- api/os/evm/v1/msg.go | 14 +- api/os/evm/v1/query.pulsar.go | 8890 ++++++++++------- api/os/evm/v1/query_grpc.pb.go | 108 +- api/os/feemarket/v1/feemarket.pulsar.go | 62 +- api/os/feemarket/v1/query.pulsar.go | 84 +- api/os/types/v1/dynamic_fee.pulsar.go | 32 +- contracts/hardhat.config.js | 18 +- contracts/package-lock.json | 39 +- ethereum/eip712/eip712_fuzzer_test.go | 4 +- ethereum/eip712/eip712_test.go | 3 +- ethereum/eip712/preprocess_test.go | 7 +- example_chain/ante/evm_benchmark_test.go | 4 +- example_chain/ante/handler_options_test.go | 2 +- example_chain/ante/integration_test.go | 29 +- example_chain/app.go | 19 +- example_chain/config.go | 84 + example_chain/config_testing.go | 93 + example_chain/constants.go | 9 + example_chain/eips/README.md | 258 + example_chain/eips/eips.go | 36 + example_chain/eips/eips_test.go | 441 + example_chain/eips/testdata/Counter.json | 38 + example_chain/eips/testdata/Counter.sol | 15 + .../eips/testdata/CounterFactory.json | 56 + .../eips/testdata/CounterFactory.sol | 25 + example_chain/eips/testdata/contracts.go | 17 + example_chain/genesis.go | 1 - example_chain/go.mod | 102 +- example_chain/go.sum | 214 +- example_chain/local_node.sh | 12 +- example_chain/osd/cmd/root.go | 1 + example_chain/osd/config/config.go | 12 - example_chain/osd/main.go | 1 - example_chain/precompiles.go | 18 + example_chain/testutil/abci.go | 6 +- example_chain/testutil/contract.go | 12 +- go.mod | 104 +- go.sum | 216 +- go.work | 8 - go.work.sum | 2689 ----- ibc/module_test.go | 5 +- ibc/testing/app.go | 2 +- ibc/testing/chain.go | 2 +- ibc/utils_test.go | 22 +- precompiles/bank/IBank.sol | 39 +- precompiles/bank/bank.go | 17 +- precompiles/bank/integration_test.go | 13 +- precompiles/bank/query.go | 23 +- precompiles/bank/query_test.go | 6 - precompiles/bank/types.go | 2 +- precompiles/common/precompile.go | 4 +- precompiles/distribution/distribution.go | 7 +- precompiles/distribution/distribution_test.go | 24 +- precompiles/distribution/integration_test.go | 186 +- precompiles/distribution/setup_test.go | 6 +- precompiles/distribution/tx.go | 37 +- precompiles/erc20/approve_test.go | 2 - precompiles/erc20/erc20.go | 21 +- precompiles/erc20/erc20_test.go | 32 +- precompiles/erc20/errors.go | 1 + precompiles/erc20/events_test.go | 2 - precompiles/erc20/integration_test.go | 74 +- precompiles/erc20/query.go | 10 +- precompiles/erc20/query_test.go | 10 - precompiles/erc20/tx.go | 14 +- precompiles/erc20/tx_test.go | 2 - precompiles/erc20/types_test.go | 5 - precompiles/erc20/utils_test.go | 7 +- precompiles/gov/IGov.sol | 192 + precompiles/gov/abi.json | 803 ++ precompiles/gov/errors.go | 28 + precompiles/gov/events.go | 85 + precompiles/gov/events_test.go | 167 + precompiles/gov/gov.go | 158 + precompiles/gov/gov_test.go | 138 + precompiles/gov/integration_test.go | 662 ++ precompiles/gov/query.go | 184 + precompiles/gov/query_test.go | 585 ++ precompiles/gov/setup_test.go | 137 + precompiles/gov/tx.go | 89 + precompiles/gov/tx_test.go | 278 + precompiles/gov/types.go | 571 ++ precompiles/ics20/ics20.go | 7 +- precompiles/ics20/tx.go | 3 +- precompiles/slashing/ISlashing.sol | 77 + precompiles/slashing/abi.json | 229 + precompiles/slashing/events.go | 46 + precompiles/slashing/events_test.go | 104 + precompiles/slashing/query.go | 78 + precompiles/slashing/query_test.go | 261 + precompiles/slashing/setup_test.go | 61 + precompiles/slashing/slashing.go | 145 + precompiles/slashing/tx.go | 57 + precompiles/slashing/tx_test.go | 141 + precompiles/slashing/types.go | 137 + precompiles/staking/StakingI.sol | 25 +- precompiles/staking/approve_test.go | 1 - precompiles/staking/integration_test.go | 45 +- precompiles/staking/staking.go | 6 +- precompiles/staking/staking_test.go | 34 +- precompiles/staking/tx.go | 11 +- .../testutil/contracts/InterchainSender.json | 4 +- .../testutil/contracts/InterchainSender.sol | 10 +- .../contracts/InterchainSenderCaller.json | 4 +- precompiles/testutil/contracts/contracts.go | 9 +- precompiles/werc20/IWERC20.sol | 36 + precompiles/werc20/abi.json | 347 + precompiles/werc20/events.go | 81 + precompiles/werc20/events_test.go | 207 + precompiles/werc20/integration_test.go | 607 ++ precompiles/werc20/testdata/WEVMOS9.json | 288 + .../werc20/testdata/WEVMOS9TestCaller.json | 79 + .../werc20/testdata/WEVMOS9TestCaller.sol | 34 + precompiles/werc20/testdata/wevmos9.go | 15 + .../werc20/testdata/wevmos9_test_caller.go | 13 + precompiles/werc20/tx.go | 88 + precompiles/werc20/utils_test.go | 70 + precompiles/werc20/werc20.go | 162 + proto/os/evm/v1/evm.proto | 6 + proto/os/evm/v1/query.proto | 41 + proto/os/feemarket/v1/feemarket.proto | 2 +- proto/os/feemarket/v1/query.proto | 3 +- proto/os/types/v1/dynamic_fee.proto | 2 +- rpc/backend/backend.go | 27 +- rpc/backend/backend_suite_test.go | 10 +- rpc/backend/blocks.go | 60 +- rpc/backend/blocks_test.go | 37 +- rpc/backend/call_tx.go | 48 +- rpc/backend/call_tx_test.go | 29 +- rpc/backend/chain_info.go | 29 +- rpc/backend/chain_info_test.go | 20 +- rpc/backend/client_test.go | 31 + rpc/backend/evm_query_client_test.go | 13 +- rpc/backend/filters.go | 2 +- rpc/backend/mocks/evm_query_client.go | 187 +- rpc/backend/node_info.go | 44 +- rpc/backend/node_info_test.go | 61 +- rpc/backend/sign_tx.go | 9 +- rpc/backend/sign_tx_test.go | 9 +- rpc/backend/tracing_test.go | 12 +- rpc/backend/tx_info.go | 38 +- rpc/backend/tx_info_test.go | 1 - rpc/namespaces/ethereum/eth/api.go | 31 +- rpc/types/utils.go | 27 +- .../compile_smart_contracts.py | 2 + server/config/migration/migration.go | 1 - server/indexer_cmd.go | 1 + server/start.go | 27 + server/util.go | 11 + tests/integration/ledger/ledger_test.go | 11 +- tests/solidity/init-node.sh | 2 +- .../suites/precompiles/hardhat.config.js | 28 +- tests/solidity/yarn.lock | 6 +- testutil/constants/constants.go | 33 +- testutil/fund.go | 9 +- testutil/integration/common/factory/helper.go | 4 +- testutil/integration/common/grpc/bank.go | 4 +- testutil/integration/common/grpc/grpc.go | 2 +- .../integration/common/network/network.go | 2 +- testutil/integration/os/factory/factory.go | 4 +- testutil/integration/os/grpc/evm.go | 34 +- testutil/integration/os/grpc/grpc.go | 3 + .../os/network/chain_id_modifiers.go | 76 + testutil/integration/os/network/coins.go | 83 + testutil/integration/os/network/config.go | 56 +- .../integration/os/network/config_test.go | 63 +- .../os/network/example_contracts.go | 30 + testutil/integration/os/network/network.go | 39 +- testutil/integration/os/network/setup.go | 31 +- testutil/integration/os/utils/bank.go | 2 +- testutil/integration/os/utils/bank_test.go | 27 +- testutil/integration/os/utils/gov.go | 4 +- testutil/integration/os/utils/staking.go | 8 +- testutil/network/network.go | 4 +- testutil/network/util.go | 3 - testutil/tx/eth.go | 21 +- types/dynamic_fee.go | 4 +- types/dynamic_fee.pb.go | 24 +- utils/utils_test.go | 2 +- wallets/ledger/ledger.go | 1 + x/erc20/keeper/dynamic_precompiles.go | 13 +- x/erc20/keeper/dynamic_precompiles_test.go | 2 +- x/erc20/keeper/ibc_callbacks_test.go | 16 +- x/erc20/keeper/integration_test.go | 2 +- x/erc20/keeper/params.go | 62 +- x/erc20/keeper/precompiles.go | 49 +- x/erc20/keeper/setup_test.go | 6 +- x/erc20/keeper/token_pairs_test.go | 21 +- x/erc20/types/codec.go | 3 + x/erc20/types/genesis_test.go | 1 - x/erc20/types/utils.go | 17 - x/evm/client/cli/query.go | 29 + x/evm/client/cli/tx.go | 8 +- x/evm/client/cli/utils_test.go | 1 - x/evm/core/vm/custom_eip_testing.go | 33 + x/evm/genesis.go | 2 - x/evm/genesis_test.go | 24 +- x/evm/keeper/abci.go | 22 +- x/evm/keeper/benchmark_test.go | 19 +- x/evm/keeper/call_evm.go | 4 +- x/evm/keeper/call_evm_test.go | 8 +- x/evm/keeper/config.go | 10 +- x/evm/keeper/fees.go | 11 +- x/evm/keeper/fees_test.go | 13 +- x/evm/keeper/gas.go | 3 +- x/evm/keeper/grpc_query.go | 71 +- x/evm/keeper/grpc_query_test.go | 90 +- x/evm/keeper/integration_test.go | 47 +- x/evm/keeper/keeper.go | 116 +- x/evm/keeper/keeper_test.go | 53 +- x/evm/keeper/msg_server_test.go | 5 +- x/evm/keeper/params_benchmark_test.go | 3 +- x/evm/keeper/params_test.go | 30 - x/evm/keeper/precompiles.go | 4 + x/evm/keeper/setup_test.go | 39 +- x/evm/keeper/state_transition.go | 14 +- .../keeper/state_transition_benchmark_test.go | 23 +- x/evm/keeper/state_transition_test.go | 38 +- x/evm/keeper/statedb.go | 20 +- x/evm/keeper/statedb_test.go | 8 +- x/evm/keeper/utils_test.go | 34 +- x/evm/module.go | 4 +- x/evm/statedb/state_object.go | 2 + x/evm/types/chain_config.go | 57 +- x/evm/types/chain_config_test.go | 51 +- x/evm/types/codec.go | 8 +- x/evm/types/config.go | 62 + x/evm/types/config_testing.go | 84 + x/evm/{config => types}/configurator.go | 43 +- x/evm/{config => types}/configurator_test.go | 52 +- x/evm/types/denom.go | 62 + x/evm/types/denom_config.go | 66 + x/evm/types/denom_config_testing.go | 74 + x/evm/types/dynamic_fee_tx.go | 4 +- x/evm/types/events.go | 3 + x/evm/types/evm.pb.go | 375 +- x/evm/types/genesis_test.go | 70 +- x/evm/types/interfaces.go | 18 +- x/evm/types/logs_test.go | 2 - x/evm/types/msg.go | 3 +- x/evm/types/msg_test.go | 50 +- x/evm/types/params.go | 45 - x/evm/types/params_legacy.go | 2 - x/evm/types/params_test.go | 61 +- x/evm/types/permissions_test.go | 27 +- x/evm/types/precompiles.go | 4 + x/evm/types/query.go | 5 + x/evm/types/query.pb.go | 1060 +- x/evm/types/query.pb.gw.go | 130 + x/evm/types/scaling.go | 104 + x/evm/types/scaling_test.go | 327 + x/evm/types/storage_test.go | 2 - x/evm/types/tx_data.go | 14 +- x/evm/types/utils.go | 8 +- x/evm/wrappers/README.md | 33 + x/evm/wrappers/bank.go | 114 + x/evm/wrappers/feemarket.go | 58 + x/feemarket/keeper/abci.go | 10 +- x/feemarket/keeper/eip1559.go | 61 +- x/feemarket/keeper/eip1559_test.go | 21 +- x/feemarket/keeper/grpc_query.go | 6 +- x/feemarket/keeper/grpc_query_test.go | 10 +- x/feemarket/keeper/integration_test.go | 16 +- x/feemarket/keeper/keeper.go | 13 +- x/feemarket/keeper/keeper_test.go | 7 +- x/feemarket/keeper/params.go | 20 +- x/feemarket/module.go | 2 +- x/feemarket/types/feemarket.pb.go | 58 +- x/feemarket/types/genesis_test.go | 1 - x/feemarket/types/params.go | 8 +- x/feemarket/types/params_test.go | 30 +- x/feemarket/types/query.pb.go | 62 +- x/ibc/transfer/keeper/msg_server_test.go | 3 +- 310 files changed, 19915 insertions(+), 8973 deletions(-) create mode 100644 example_chain/config.go create mode 100644 example_chain/config_testing.go create mode 100644 example_chain/eips/README.md create mode 100644 example_chain/eips/eips.go create mode 100644 example_chain/eips/eips_test.go create mode 100644 example_chain/eips/testdata/Counter.json create mode 100644 example_chain/eips/testdata/Counter.sol create mode 100644 example_chain/eips/testdata/CounterFactory.json create mode 100644 example_chain/eips/testdata/CounterFactory.sol create mode 100644 example_chain/eips/testdata/contracts.go delete mode 100644 go.work delete mode 100644 go.work.sum create mode 100644 precompiles/gov/IGov.sol create mode 100644 precompiles/gov/abi.json create mode 100644 precompiles/gov/errors.go create mode 100644 precompiles/gov/events.go create mode 100644 precompiles/gov/events_test.go create mode 100644 precompiles/gov/gov.go create mode 100644 precompiles/gov/gov_test.go create mode 100644 precompiles/gov/integration_test.go create mode 100644 precompiles/gov/query.go create mode 100644 precompiles/gov/query_test.go create mode 100644 precompiles/gov/setup_test.go create mode 100644 precompiles/gov/tx.go create mode 100644 precompiles/gov/tx_test.go create mode 100644 precompiles/gov/types.go create mode 100644 precompiles/slashing/ISlashing.sol create mode 100644 precompiles/slashing/abi.json create mode 100644 precompiles/slashing/events.go create mode 100644 precompiles/slashing/events_test.go create mode 100644 precompiles/slashing/query.go create mode 100644 precompiles/slashing/query_test.go create mode 100644 precompiles/slashing/setup_test.go create mode 100644 precompiles/slashing/slashing.go create mode 100644 precompiles/slashing/tx.go create mode 100644 precompiles/slashing/tx_test.go create mode 100644 precompiles/slashing/types.go create mode 100644 precompiles/werc20/IWERC20.sol create mode 100644 precompiles/werc20/abi.json create mode 100644 precompiles/werc20/events.go create mode 100644 precompiles/werc20/events_test.go create mode 100644 precompiles/werc20/integration_test.go create mode 100644 precompiles/werc20/testdata/WEVMOS9.json create mode 100644 precompiles/werc20/testdata/WEVMOS9TestCaller.json create mode 100644 precompiles/werc20/testdata/WEVMOS9TestCaller.sol create mode 100644 precompiles/werc20/testdata/wevmos9.go create mode 100644 precompiles/werc20/testdata/wevmos9_test_caller.go create mode 100644 precompiles/werc20/tx.go create mode 100644 precompiles/werc20/utils_test.go create mode 100644 precompiles/werc20/werc20.go create mode 100644 testutil/integration/os/network/chain_id_modifiers.go create mode 100644 testutil/integration/os/network/coins.go create mode 100644 testutil/integration/os/network/example_contracts.go create mode 100644 x/evm/core/vm/custom_eip_testing.go create mode 100644 x/evm/types/config.go create mode 100644 x/evm/types/config_testing.go rename x/evm/{config => types}/configurator.go (64%) rename x/evm/{config => types}/configurator_test.go (65%) create mode 100644 x/evm/types/denom.go create mode 100644 x/evm/types/denom_config.go create mode 100644 x/evm/types/denom_config_testing.go create mode 100644 x/evm/types/scaling.go create mode 100644 x/evm/types/scaling_test.go create mode 100644 x/evm/wrappers/README.md create mode 100644 x/evm/wrappers/bank.go create mode 100644 x/evm/wrappers/feemarket.go diff --git a/.clconfig.json b/.clconfig.json index ddfadb3d..513e7d6f 100644 --- a/.clconfig.json +++ b/.clconfig.json @@ -44,9 +44,8 @@ "OS": "os", "PR": "pr", "RPC": "rpc", - "SDK": "sdk", - "evmOS": "evmos" + "SDK": "sdk" }, "legacy_version": null, "target_repo": "https://github.com/evmos/os" -} \ No newline at end of file +} diff --git a/.github/workflows/bsr-push.yml b/.github/workflows/bsr-push.yml index d42294f8..0711446b 100644 --- a/.github/workflows/bsr-push.yml +++ b/.github/workflows/bsr-push.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: bufbuild/buf-setup-action@v1.41.0 + - uses: bufbuild/buf-setup-action@v1.47.2 # Push evmOS protos to the Buf Schema Registry - uses: bufbuild/buf-push-action@v1.2.0 with: diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 8d1b8dea..7f2c5ad3 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -26,7 +26,7 @@ jobs: go.mod go.sum *.toml - - uses: golangci/golangci-lint-action@v6.1.0 + - uses: golangci/golangci-lint-action@v6.1.1 with: # Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version. version: latest diff --git a/.github/workflows/proto.yml b/.github/workflows/proto.yml index 6adaf486..b87c8e18 100644 --- a/.github/workflows/proto.yml +++ b/.github/workflows/proto.yml @@ -32,7 +32,7 @@ jobs: timeout-minutes: 5 steps: - uses: actions/checkout@v4 - - uses: bufbuild/buf-setup-action@v1.41.0 + - uses: bufbuild/buf-setup-action@v1.47.2 - uses: bufbuild/buf-lint-action@v1 with: input: "proto" @@ -41,7 +41,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: bufbuild/buf-setup-action@v1.41.0 + - uses: bufbuild/buf-setup-action@v1.47.2 - uses: bufbuild/buf-breaking-action@v1 with: input: "proto" diff --git a/.github/workflows/super-linter.yml b/.github/workflows/super-linter.yml index 24d6f1e4..c7c93f94 100644 --- a/.github/workflows/super-linter.yml +++ b/.github/workflows/super-linter.yml @@ -30,6 +30,7 @@ jobs: PROTOBUF_CONFIG_FILE: .protolint.yml VALIDATE_NATURAL_LANGUAGE: false VALIDATE_OPENAPI: false + VALIDATE_JAVASCRIPT_STANDARD: false VALIDATE_JSCPD: false VALIDATE_GO: false VALIDATE_GO_MODULES: false diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 7d1644d7..2cafba57 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -37,7 +37,7 @@ jobs: run: | make test-unit-cover if: env.GIT_DIFF - - uses: codecov/codecov-action@v4 + - uses: codecov/codecov-action@v5 with: file: ./coverage.txt # We were getting a 500 error on codecov servers @@ -60,7 +60,6 @@ jobs: uses: actions/setup-python@v5 with: python-version: "3.11" - cache: "pip" # caching pip dependencies if: env.GIT_DIFF - name: Install Pytest run: | diff --git a/.golangci.yml b/.golangci.yml index 2b7c5059..51d0695f 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -24,7 +24,7 @@ linters: - misspell - nakedret - prealloc - - exportloopref + - copyloopvar - staticcheck - stylecheck - typecheck @@ -33,7 +33,6 @@ linters: - unused - nolintlint - asciicheck - - exportloopref - gofumpt - gomodguard diff --git a/.mergify.yml b/.mergify.yml index 40847617..7bb3b196 100644 --- a/.mergify.yml +++ b/.mergify.yml @@ -1,21 +1,17 @@ queue_rules: - name: default - conditions: - - "#approved-reviews-by>1" - -pull_request_rules: - - name: automerge to main with label "automerge" and branch protection passing - conditions: + queue_conditions: - "#approved-reviews-by>1" - base=main - label=automerge - actions: - queue: - name: default - method: squash - commit_message_template: | - {{ title }} (#{{ number }}) - {{ body }} + merge_conditions: + - "#approved-reviews-by>1" + merge_method: squash + commit_message_template: | + {{ title }} (#{{ number }}) + {{ body }} + +pull_request_rules: - name: backport patches to v6.0.x branch conditions: - base=main @@ -48,3 +44,7 @@ pull_request_rules: backport: branches: - release/v3.0.x + - name: refactored queue action rule + conditions: [] + actions: + queue: diff --git a/CHANGELOG.md b/CHANGELOG.md index 501d127d..03eac414 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,14 +8,15 @@ This changelog was created using the `clu` binary ### Improvements +- (all) [#60](https://github.com/evmos/os/pull/60) Apply latest changes from Evmos repo (f943af3b to b72a32d76). - (cli) [#55](https://github.com/evmos/os/pull/55) Add missing list key types subcommand. - (cli) [#54](https://github.com/evmos/os/pull/54) Align debug CLI commands with Cosmos SDK plus other minor clean up. - (cli) [#53](https://github.com/evmos/os/pull/53) Enable specifying default key type for adding keys. - (ante) [#52](https://github.com/evmos/os/pull/52) Refactor ante handlers to be easier to use in partner chains. -- (all) [#48](https://github.com/evmos/os/pull/48) Move latest changes from evmOS main (f943af3b incl. SDK v50). -- (all) [#43](https://github.com/evmos/os/pull/43) Update with latest evmOS main changes (2b7a8e2). +- (all) [#48](https://github.com/evmos/os/pull/48) Move latest changes from Evmos main (f943af3b incl. SDK v50). +- (all) [#43](https://github.com/evmos/os/pull/43) Update with latest Evmos main changes (2b7a8e2). - (tests) [#41](https://github.com/evmos/os/pull/41) Add Solidity and Ledger tests. -- (all) [#37](https://github.com/evmos/os/pull/37) Add EVM, feemarket and precompiles from evmOS. +- (all) [#37](https://github.com/evmos/os/pull/37) Add EVM, feemarket and precompiles from Evmos. - (all) [#38](https://github.com/evmos/os/pull/38) Add readme. - (all) [#30](https://github.com/evmos/os/pull/30) Add example chain implementation and ante handlers. - (ci) [#35](https://github.com/evmos/os/pull/35) Disable dependabot temporarily. diff --git a/Makefile b/Makefile index d424766a..2bc49f69 100644 --- a/Makefile +++ b/Makefile @@ -54,9 +54,9 @@ test-unit-cover: TEST_PACKAGES=$(PACKAGES_UNIT) run-tests: ifneq (,$(shell which tparse 2>/dev/null)) - go test -mod=readonly -json $(ARGS) $(EXTRA_ARGS) $(TEST_PACKAGES) | tparse + go test -tags=test -mod=readonly -json $(ARGS) $(EXTRA_ARGS) $(TEST_PACKAGES) | tparse else - go test -mod=readonly $(ARGS) $(EXTRA_ARGS) $(TEST_PACKAGES) + go test -tags=test -mod=readonly $(ARGS) $(EXTRA_ARGS) $(TEST_PACKAGES) endif test-scripts: @@ -70,7 +70,7 @@ test-solidity: .PHONY: run-tests test test-all $(TEST_TARGETS) benchmark: - @go test -mod=readonly -bench=. $(PACKAGES_NOSIMULATION) + @go test -tags=test -mod=readonly -bench=. $(PACKAGES_NOSIMULATION) .PHONY: benchmark diff --git a/ante/cosmos/authz_test.go b/ante/cosmos/authz_test.go index 4178fcbf..de27e74c 100644 --- a/ante/cosmos/authz_test.go +++ b/ante/cosmos/authz_test.go @@ -17,7 +17,6 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" cosmosante "github.com/evmos/os/ante/cosmos" "github.com/evmos/os/testutil" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/common/factory" "github.com/evmos/os/testutil/integration/os/network" utiltx "github.com/evmos/os/testutil/tx" @@ -31,6 +30,7 @@ func TestAuthzLimiterDecorator(t *testing.T) { testPrivKeys, testAddresses, err := generatePrivKeyAddressPairs(5) require.NoError(t, err) + evmDenom := evmtypes.GetEVMCoinDenom() distantFuture := time.Date(9000, 1, 1, 0, 0, 0, 0, time.UTC) validator := sdk.ValAddress(testAddresses[4]) @@ -57,7 +57,7 @@ func TestAuthzLimiterDecorator(t *testing.T) { banktypes.NewMsgSend( testAddresses[0], testAddresses[1], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), }, false, @@ -139,7 +139,7 @@ func TestAuthzLimiterDecorator(t *testing.T) { []sdk.Msg{banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), )}), }, false, @@ -173,7 +173,7 @@ func TestAuthzLimiterDecorator(t *testing.T) { banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), &evmtypes.MsgEthereumTx{}, }, @@ -224,7 +224,7 @@ func TestAuthzLimiterDecorator(t *testing.T) { banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), }, ), @@ -242,7 +242,7 @@ func TestAuthzLimiterDecorator(t *testing.T) { banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), }, ), @@ -253,7 +253,7 @@ func TestAuthzLimiterDecorator(t *testing.T) { banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), }, ), @@ -288,13 +288,18 @@ func (suite *AnteTestSuite) TestRejectMsgsInAuthz() { distantFuture := time.Date(9000, 1, 1, 0, 0, 0, 0, time.UTC) nw := suite.GetNetwork() + evmDenom := evmtypes.GetEVMCoinDenom() + + baseFeeRes, err := nw.GetEvmClient().BaseFee(nw.GetContext(), &evmtypes.QueryBaseFeeRequest{}) + suite.Require().NoError(err, "failed to get base fee") + // create a dummy MsgEthereumTx for the test // otherwise throws error that cannot unpack tx data msgEthereumTx := evmtypes.NewTx(&evmtypes.EvmTxArgs{ ChainID: nw.GetEIP155ChainID(), Nonce: 0, GasLimit: gasLimit, - GasFeeCap: nw.App.FeeMarketKeeper.GetBaseFee(nw.GetContext()), + GasFeeCap: baseFeeRes.BaseFee.BigInt(), GasTipCap: big.NewInt(1), Input: nil, Accesses: ðtypes.AccessList{}, @@ -344,7 +349,7 @@ func (suite *AnteTestSuite) TestRejectMsgsInAuthz() { banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), msgEthereumTx, }, @@ -375,7 +380,7 @@ func (suite *AnteTestSuite) TestRejectMsgsInAuthz() { banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), }, ), @@ -392,7 +397,7 @@ func (suite *AnteTestSuite) TestRejectMsgsInAuthz() { banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), }, ), @@ -403,7 +408,7 @@ func (suite *AnteTestSuite) TestRejectMsgsInAuthz() { banktypes.NewMsgSend( testAddresses[0], testAddresses[3], - sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100e6)), + sdk.NewCoins(sdk.NewInt64Coin(evmDenom, 100e6)), ), }, ), @@ -424,7 +429,7 @@ func (suite *AnteTestSuite) TestRejectMsgsInAuthz() { priv := suite.GetKeyring().GetPrivKey(0) if tc.isEIP712 { - coinAmount := sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(20)) + coinAmount := sdk.NewCoin(evmDenom, math.NewInt(20)) fees := sdk.NewCoins(coinAmount) cosmosTxArgs := utiltx.CosmosTxArgs{ TxCfg: suite.GetClientCtx().TxConfig, diff --git a/ante/cosmos/min_gas_price.go b/ante/cosmos/min_gas_price.go index 8a2784be..c65ad5ca 100644 --- a/ante/cosmos/min_gas_price.go +++ b/ante/cosmos/min_gas_price.go @@ -14,6 +14,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" errortypes "github.com/cosmos/cosmos-sdk/types/errors" anteinterfaces "github.com/evmos/os/ante/interfaces" + evmtypes "github.com/evmos/os/x/evm/types" ) // MinGasPriceDecorator will check if the transaction's fee is at least as large @@ -22,14 +23,14 @@ import ( // If fee is high enough, then call next AnteHandler // CONTRACT: Tx must implement FeeTx to use MinGasPriceDecorator type MinGasPriceDecorator struct { - feesKeeper anteinterfaces.FeeMarketKeeper - evmKeeper anteinterfaces.EVMKeeper + feemarketKeeper anteinterfaces.FeeMarketKeeper + evmKeeper anteinterfaces.EVMKeeper } // NewMinGasPriceDecorator creates a new MinGasPriceDecorator instance used only for // Cosmos transactions. func NewMinGasPriceDecorator(fk anteinterfaces.FeeMarketKeeper, ek anteinterfaces.EVMKeeper) MinGasPriceDecorator { - return MinGasPriceDecorator{feesKeeper: fk, evmKeeper: ek} + return MinGasPriceDecorator{feemarketKeeper: fk, evmKeeper: ek} } func (mpd MinGasPriceDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler) (newCtx sdk.Context, err error) { @@ -38,11 +39,10 @@ func (mpd MinGasPriceDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate return ctx, errorsmod.Wrapf(errortypes.ErrInvalidType, "invalid transaction type %T, expected sdk.FeeTx", tx) } - minGasPrice := mpd.feesKeeper.GetParams(ctx).MinGasPrice + minGasPrice := mpd.feemarketKeeper.GetParams(ctx).MinGasPrice feeCoins := feeTx.GetFee() - evmParams := mpd.evmKeeper.GetParams(ctx) - evmDenom := evmParams.GetEvmDenom() + evmDenom := evmtypes.GetEVMCoinDenom() // only allow user to pass in aevmos and stake native token as transaction fees // allow use stake native tokens for fees is just for unit tests to pass diff --git a/ante/evm/01_setup_ctx.go b/ante/evm/01_setup_ctx.go index c63d2412..12355635 100644 --- a/ante/evm/01_setup_ctx.go +++ b/ante/evm/01_setup_ctx.go @@ -28,25 +28,34 @@ func NewEthSetUpContextDecorator(evmKeeper anteinterfaces.EVMKeeper) EthSetupCon } func (esc EthSetupContextDecorator) AnteHandle(ctx sdktypes.Context, tx sdktypes.Tx, simulate bool, next sdktypes.AnteHandler) (newCtx sdktypes.Context, err error) { - newCtx, err = SetupContext(ctx, tx, esc.evmKeeper) + newCtx, err = SetupContextAndResetTransientGas(ctx, tx, esc.evmKeeper) if err != nil { return ctx, err } return next(newCtx, tx, simulate) } -func SetupContext(ctx sdktypes.Context, tx sdktypes.Tx, evmKeeper anteinterfaces.EVMKeeper) (sdktypes.Context, error) { +// SetupContextAndResetTransientGas modifies the context to be used in the +// execution of the ante handler associated with an EVM transaction. Previous +// gas consumed is reset in the transient store. +func SetupContextAndResetTransientGas(ctx sdktypes.Context, tx sdktypes.Tx, evmKeeper anteinterfaces.EVMKeeper) (sdktypes.Context, error) { // all transactions must implement GasTx _, ok := tx.(authante.GasTx) if !ok { return ctx, errorsmod.Wrapf(errortypes.ErrInvalidType, "invalid transaction type %T, expected GasTx", tx) } - // We need to set up an empty gas config so that the gas is consistent with Ethereum. + // To have gas consumption consistent with Ethereum, we need to: + // 1. Set an empty gas config for both KV and transient store. + // 2. Set an infinite gas meter. newCtx := evmante.BuildEvmExecutionCtx(ctx). WithGasMeter(storetypes.NewInfiniteGasMeter()) + // Reset transient gas used to prepare the execution of current cosmos tx. // Transient gas-used is necessary to sum the gas-used of cosmos tx, when it contains multiple eth msgs. + // + // TODO: add more context here to explain why gas used is reset. Not clear + // from docstring. evmKeeper.ResetTransientGasUsed(ctx) return newCtx, nil diff --git a/ante/evm/01_setup_ctx_test.go b/ante/evm/01_setup_ctx_test.go index ad52ec84..048adc00 100644 --- a/ante/evm/01_setup_ctx_test.go +++ b/ante/evm/01_setup_ctx_test.go @@ -15,7 +15,7 @@ import ( func (suite *AnteTestSuite) TestEthSetupContextDecorator() { dec := evmante.NewEthSetUpContextDecorator(suite.GetNetwork().App.EVMKeeper) ethContractCreationTxParams := &evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: evmtypes.GetEthChainConfig().ChainID, Nonce: 1, Amount: big.NewInt(10), GasLimit: 1000, diff --git a/ante/evm/02_mempool_fee.go b/ante/evm/02_mempool_fee.go index 43e7a3b2..7fe4e58e 100644 --- a/ante/evm/02_mempool_fee.go +++ b/ante/evm/02_mempool_fee.go @@ -9,7 +9,9 @@ import ( errortypes "github.com/cosmos/cosmos-sdk/types/errors" ) -// CheckMempoolFee checks if the provided fee is at least as large as the local validator's +// CheckMempoolFee checks if the provided fee is at least as large as the local +// validator's configured value. The fee computation assumes that both price and fee are +// represented in 18 decimals. func CheckMempoolFee(fee, mempoolMinGasPrice, gasLimit sdkmath.LegacyDec, isLondon bool) error { if isLondon { return nil @@ -20,7 +22,7 @@ func CheckMempoolFee(fee, mempoolMinGasPrice, gasLimit sdkmath.LegacyDec, isLond if fee.LT(requiredFee) { return errorsmod.Wrapf( errortypes.ErrInsufficientFee, - "insufficient fee; got: %s required: %s", + "got: %s, minimum required: %s", fee, requiredFee, ) } diff --git a/ante/evm/04_validate.go b/ante/evm/04_validate.go index 51f7737f..38168203 100644 --- a/ante/evm/04_validate.go +++ b/ante/evm/04_validate.go @@ -4,8 +4,10 @@ package evm import ( "errors" + "math/big" errorsmod "cosmossdk.io/errors" + sdkmath "cosmossdk.io/math" sdktypes "github.com/cosmos/cosmos-sdk/types" errortypes "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/tx" @@ -13,9 +15,8 @@ import ( evmtypes "github.com/evmos/os/x/evm/types" ) -// ValidateMsg validates an Ethereum specific message type and returns an error if invalid -// -// It checks the following requirements: +// ValidateMsg validates an Ethereum specific message type and returns an error +// if invalid. It checks the following requirements: // - nil MUST be passed as the from address // - If the transaction is a contract creation or call, the corresponding operation must be enabled in the EVM parameters func ValidateMsg( @@ -43,8 +44,8 @@ func checkDisabledCreateCall( blockCreate := permissions.Create.AccessType == evmtypes.AccessTypeRestricted blockCall := permissions.Call.AccessType == evmtypes.AccessTypeRestricted - // return error if contract creation or call are disabled through governance - // and the transaction is trying to create a contract or call a contract + // return error if contract creation or call are disabled + // and the transaction is trying to create a contract or call a contract. if blockCreate && to == nil { return errorsmod.Wrap(evmtypes.ErrCreateDisabled, "failed to create new contract") } else if blockCall && to != nil { @@ -100,13 +101,20 @@ func ValidateTx(tx sdktypes.Tx) (*tx.Fee, error) { return authInfo.Fee, nil } -func CheckTxFee(txFeeInfo *tx.Fee, txFee sdktypes.Coins, txGasLimit uint64) error { +// CheckTxFee checks if the Amount and GasLimit fields of the txFeeInfo input +// are equal to the txFee coins and the txGasLimit value. +// The function expects txFeeInfo to contains coins in the original decimal +// representation. +func CheckTxFee(txFeeInfo *tx.Fee, txFee *big.Int, txGasLimit uint64) error { if txFeeInfo == nil { return nil } - if !txFeeInfo.Amount.Equal(txFee) { - return errorsmod.Wrapf(errortypes.ErrInvalidRequest, "invalid AuthInfo Fee Amount (%s != %s)", txFeeInfo.Amount, txFee) + convertedAmount := sdkmath.NewIntFromBigInt(evmtypes.ConvertAmountFrom18DecimalsBigInt(txFee)) + + baseDenom := evmtypes.GetEVMCoinDenom() + if !txFeeInfo.Amount.AmountOf(baseDenom).Equal(convertedAmount) { + return errorsmod.Wrapf(errortypes.ErrInvalidRequest, "invalid AuthInfo Fee Amount (%s != %s)", txFeeInfo.Amount, convertedAmount) } if txFeeInfo.GasLimit != txGasLimit { diff --git a/ante/evm/04_validate_test.go b/ante/evm/04_validate_test.go index de4589be..571bc394 100644 --- a/ante/evm/04_validate_test.go +++ b/ante/evm/04_validate_test.go @@ -3,13 +3,16 @@ package evm_test import ( + "fmt" "math/big" + "cosmossdk.io/math" sdktypes "github.com/cosmos/cosmos-sdk/types" errortypes "github.com/cosmos/cosmos-sdk/types/errors" + "github.com/cosmos/cosmos-sdk/types/tx" "github.com/ethereum/go-ethereum/common" "github.com/evmos/os/ante/evm" - "github.com/evmos/os/testutil/constants" + testconstants "github.com/evmos/os/testutil/constants" testkeyring "github.com/evmos/os/testutil/integration/os/keyring" evmtypes "github.com/evmos/os/x/evm/types" ) @@ -33,7 +36,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { expectedError: errortypes.ErrInvalidRequest, getFunctionParams: func() validateMsgParams { return validateMsgParams{ - evmParams: evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom), + evmParams: evmtypes.DefaultParams(), txData: nil, from: keyring.GetAccAddr(0), } @@ -47,7 +50,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { txData, err := txArgs.ToTxData() suite.Require().NoError(err) return validateMsgParams{ - evmParams: evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom), + evmParams: evmtypes.DefaultParams(), txData: txData, from: nil, } @@ -61,7 +64,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { txData, err := txArgs.ToTxData() suite.Require().NoError(err) - params := evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom) + params := evmtypes.DefaultParams() params.AccessControl.Call.AccessType = evmtypes.AccessTypeRestricted params.AccessControl.Create.AccessType = evmtypes.AccessTypeRestricted @@ -80,7 +83,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { txData, err := txArgs.ToTxData() suite.Require().NoError(err) return validateMsgParams{ - evmParams: evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom), + evmParams: evmtypes.DefaultParams(), txData: txData, from: nil, } @@ -94,7 +97,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { txData, err := txArgs.ToTxData() suite.Require().NoError(err) - params := evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom) + params := evmtypes.DefaultParams() params.AccessControl.Create.AccessType = evmtypes.AccessTypeRestricted return validateMsgParams{ @@ -112,7 +115,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { txData, err := txArgs.ToTxData() suite.Require().NoError(err) - params := evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom) + params := evmtypes.DefaultParams() params.AccessControl.Call.AccessType = evmtypes.AccessTypeRestricted return validateMsgParams{ @@ -130,7 +133,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { txData, err := txArgs.ToTxData() suite.Require().NoError(err) return validateMsgParams{ - evmParams: evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom), + evmParams: evmtypes.DefaultParams(), txData: txData, from: nil, } @@ -144,7 +147,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { txData, err := txArgs.ToTxData() suite.Require().NoError(err) - params := evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom) + params := evmtypes.DefaultParams() params.AccessControl.Call.AccessType = evmtypes.AccessTypeRestricted return validateMsgParams{ @@ -162,7 +165,7 @@ func (suite *EvmAnteTestSuite) TestValidateMsg() { txData, err := txArgs.ToTxData() suite.Require().NoError(err) - params := evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom) + params := evmtypes.DefaultParams() params.AccessControl.Create.AccessType = evmtypes.AccessTypeRestricted return validateMsgParams{ @@ -215,3 +218,68 @@ func getTxByType(typeTx string, recipient common.Address) evmtypes.EvmTxArgs { panic("invalid type") } } + +func (suite *EvmAnteTestSuite) TestCheckTxFee() { + // amount represents 1 token in the 18 decimals representation. + amount := math.NewInt(1e18) + gasLimit := uint64(1e6) + + testCases := []struct { + name string + txFee *big.Int + txGasLimit uint64 + expError error + }{ + { + name: "pass", + txFee: big.NewInt(amount.Int64()), + txGasLimit: gasLimit, + expError: nil, + }, + { + name: "fail: not enough tx fees", + txFee: big.NewInt(amount.Int64() - 1), + txGasLimit: gasLimit, + expError: errortypes.ErrInvalidRequest, + }, + } + + for _, decimals := range []evmtypes.Decimals{ + evmtypes.SixDecimals, + evmtypes.EighteenDecimals, + } { + for _, tc := range testCases { + suite.Run(fmt.Sprintf("%d decimals, %s", decimals, tc.name), func() { + // Call the configurator to set the EVM coin required for the + // function to be tested. + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + suite.Require().NoError(configurator.WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(decimals)).Configure()) + + // If decimals is not 18 decimals, we have to convert txFeeInfo to original + // decimals representation. + originalAmount := amount + evmCoinDecimal := evmtypes.GetEVMCoinDecimals() + originalAmount = originalAmount.Quo(evmCoinDecimal.ConversionFactor()) + + coins := sdktypes.Coins{sdktypes.Coin{Denom: "aevmos", Amount: originalAmount}} + + // This struct should hold values in the original representation + txFeeInfo := &tx.Fee{ + Amount: coins, + GasLimit: gasLimit, + } + + // Function under test + err := evm.CheckTxFee(txFeeInfo, tc.txFee, tc.txGasLimit) + + if tc.expError != nil { + suite.Require().Error(err) + suite.Contains(err.Error(), tc.expError.Error()) + } else { + suite.Require().NoError(err) + } + }) + } + } +} diff --git a/ante/evm/05_signature_verification.go b/ante/evm/05_signature_verification.go index 068df4e4..e1339913 100644 --- a/ante/evm/05_signature_verification.go +++ b/ante/evm/05_signature_verification.go @@ -32,10 +32,8 @@ func NewEthSigVerificationDecorator(ek anteinterfaces.EVMKeeper) EthSigVerificat // Failure in RecheckTx will prevent tx to be included into block, especially when CheckTx succeed, in which case user // won't see the error message. func (esvd EthSigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler) (newCtx sdk.Context, err error) { - chainID := esvd.evmKeeper.ChainID() evmParams := esvd.evmKeeper.GetParams(ctx) - chainCfg := evmParams.GetChainConfig() - ethCfg := chainCfg.EthereumConfig(chainID) + ethCfg := evmtypes.GetEthChainConfig() blockNum := big.NewInt(ctx.BlockHeight()) signer := ethtypes.MakeSigner(ethCfg, blockNum) allowUnprotectedTxs := evmParams.GetAllowUnprotectedTxs() @@ -62,6 +60,8 @@ func (esvd EthSigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, s // SignatureVerification checks that the registered chain id is the same as the one on the message, and // that the signer address matches the one defined on the message. +// The function set the field from of the given message equal to the sender +// computed from the signature of the Ethereum transaction. func SignatureVerification( msg *evmtypes.MsgEthereumTx, signer ethtypes.Signer, diff --git a/ante/evm/06_account_verification.go b/ante/evm/06_account_verification.go index c77e7513..3d5fcde2 100644 --- a/ante/evm/06_account_verification.go +++ b/ante/evm/06_account_verification.go @@ -27,7 +27,7 @@ func VerifyAccountBalance( from common.Address, txData evmtypes.TxData, ) error { - // check whether the sender address is EOA + // Only EOA are allowed to send transactions. if account != nil && account.IsContract() { return errorsmod.Wrapf( errortypes.ErrInvalidType, diff --git a/ante/evm/06_account_verification_test.go b/ante/evm/06_account_verification_test.go index e5aef619..77a16d75 100644 --- a/ante/evm/06_account_verification_test.go +++ b/ante/evm/06_account_verification_test.go @@ -53,7 +53,7 @@ func (suite *EvmAnteTestSuite) TestVerifyAccountBalance() { suite.Require().NoError(err) // Make tx cost greater than balance - balanceResp, err := grpcHandler.GetBalance(senderKey.AccAddr, unitNetwork.GetDenom()) + balanceResp, err := grpcHandler.GetBalanceFromBank(senderKey.AccAddr, unitNetwork.GetBaseDenom()) suite.Require().NoError(err) invalidAmount := balanceResp.Balance.Amount.Add(math.NewInt(100)) diff --git a/ante/evm/07_can_transfer_test.go b/ante/evm/07_can_transfer_test.go index 94ea7190..188de1a0 100644 --- a/ante/evm/07_can_transfer_test.go +++ b/ante/evm/07_can_transfer_test.go @@ -45,7 +45,7 @@ func (suite *EvmAnteTestSuite) TestCanTransfer() { expectedError: errortypes.ErrInsufficientFunds, isLondon: true, malleate: func(txArgs *evmtypes.EvmTxArgs) { - balanceResp, err := grpcHandler.GetBalance(senderKey.AccAddr, unitNetwork.GetDenom()) + balanceResp, err := grpcHandler.GetBalanceFromBank(senderKey.AccAddr, unitNetwork.GetBaseDenom()) suite.Require().NoError(err) invalidAmount := balanceResp.Balance.Amount.Add(math.NewInt(1)).BigInt() txArgs.Amount = invalidAmount @@ -62,7 +62,7 @@ func (suite *EvmAnteTestSuite) TestCanTransfer() { for _, tc := range testCases { suite.Run(fmt.Sprintf("%v_%v", evmtypes.GetTxTypeName(suite.ethTxType), tc.name), func() { - baseFeeResp, err := grpcHandler.GetBaseFee() + baseFeeResp, err := grpcHandler.GetEvmBaseFee() suite.Require().NoError(err) ethCfg := unitNetwork.GetEVMChainConfig() evmParams, err := grpcHandler.GetEvmParams() diff --git a/ante/evm/08_gas_consume.go b/ante/evm/08_gas_consume.go index ff6d8747..8ea93b61 100644 --- a/ante/evm/08_gas_consume.go +++ b/ante/evm/08_gas_consume.go @@ -7,7 +7,6 @@ import ( "math/big" errorsmod "cosmossdk.io/errors" - sdkmath "cosmossdk.io/math" sdktypes "github.com/cosmos/cosmos-sdk/types" errortypes "github.com/cosmos/cosmos-sdk/types/errors" "github.com/ethereum/go-ethereum/common" @@ -127,17 +126,3 @@ func CheckBlockGasLimit(ctx sdktypes.Context, gasWanted uint64, minPriority int6 return ctx, nil } - -// UpdateCumulativeTxFee updates the cumulative transaction fee -func UpdateCumulativeTxFee( - cumulativeTxFee sdktypes.Coins, - msgFee *big.Int, - denom string, -) sdktypes.Coins { - return cumulativeTxFee.Add( - sdktypes.Coin{ - Denom: denom, - Amount: sdkmath.NewIntFromBigInt(msgFee), - }, - ) -} diff --git a/ante/evm/08_gas_consume_test.go b/ante/evm/08_gas_consume_test.go index 3165de37..b7c55376 100644 --- a/ante/evm/08_gas_consume_test.go +++ b/ante/evm/08_gas_consume_test.go @@ -111,7 +111,7 @@ func (suite *EvmAnteTestSuite) TestConsumeGasAndEmitEvent() { { name: "success: there are non zero fees, user has sufficient bank balances and event emitted", fees: sdktypes.Coins{ - sdktypes.NewCoin(unitNetwork.GetDenom(), sdkmath.NewInt(1000)), + sdktypes.NewCoin(unitNetwork.GetBaseDenom(), sdkmath.NewInt(1000)), }, getSender: func() sdktypes.AccAddress { // Return prefunded sender @@ -122,7 +122,7 @@ func (suite *EvmAnteTestSuite) TestConsumeGasAndEmitEvent() { name: "fail: insufficient user balance, event is NOT emitted", expectedError: "failed to deduct transaction costs from user balance", fees: sdktypes.Coins{ - sdktypes.NewCoin(unitNetwork.GetDenom(), sdkmath.NewInt(1000)), + sdktypes.NewCoin(unitNetwork.GetBaseDenom(), sdkmath.NewInt(1000)), }, getSender: func() sdktypes.AccAddress { // Set up account with too little balance (but not zero) @@ -134,7 +134,7 @@ func (suite *EvmAnteTestSuite) TestConsumeGasAndEmitEvent() { Msgs: []sdktypes.Msg{&banktypes.MsgSend{ FromAddress: sender.AccAddr.String(), ToAddress: acc.AccAddr.String(), - Amount: sdktypes.Coins{sdktypes.NewCoin(unitNetwork.GetDenom(), sdkmath.NewInt(500))}, + Amount: sdktypes.Coins{sdktypes.NewCoin(unitNetwork.GetBaseDenom(), sdkmath.NewInt(500))}, }}, }) suite.Require().NoError(err, "failed to send funds to new key") diff --git a/ante/evm/10_gas_wanted.go b/ante/evm/10_gas_wanted.go index 7710ad22..aba3da7e 100644 --- a/ante/evm/10_gas_wanted.go +++ b/ante/evm/10_gas_wanted.go @@ -11,6 +11,7 @@ import ( errortypes "github.com/cosmos/cosmos-sdk/types/errors" anteinterfaces "github.com/evmos/os/ante/interfaces" "github.com/evmos/os/types" + evmtypes "github.com/evmos/os/x/evm/types" ) // GasWantedDecorator keeps track of the gasWanted amount on the current block in transient store @@ -33,9 +34,7 @@ func NewGasWantedDecorator( } func (gwd GasWantedDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler) (newCtx sdk.Context, err error) { - evmParams := gwd.evmKeeper.GetParams(ctx) - chainCfg := evmParams.GetChainConfig() - ethCfg := chainCfg.EthereumConfig(gwd.evmKeeper.ChainID()) + ethCfg := evmtypes.GetEthChainConfig() blockHeight := big.NewInt(ctx.BlockHeight()) isLondon := ethCfg.IsLondon(blockHeight) diff --git a/ante/evm/ante_test.go b/ante/evm/ante_test.go index b5e1f3a4..22689e12 100644 --- a/ante/evm/ante_test.go +++ b/ante/evm/ante_test.go @@ -32,7 +32,7 @@ func (suite *AnteTestSuite) TestAnteHandler() { setup := func() { suite.WithFeemarketEnabled(false) - baseFee := sdkmath.NewInt(100) + baseFee := sdkmath.LegacyNewDec(100) suite.WithBaseFee(&baseFee) suite.SetupTest() // reset @@ -42,8 +42,9 @@ func (suite *AnteTestSuite) TestAnteHandler() { ctx = suite.GetNetwork().GetContext() } + ethCfg := evmtypes.GetEthChainConfig() ethContractCreationTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, Nonce: 0, Amount: big.NewInt(10), GasLimit: 100000, @@ -52,7 +53,7 @@ func (suite *AnteTestSuite) TestAnteHandler() { } ethTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, To: &to, Nonce: 0, Amount: big.NewInt(10), @@ -163,7 +164,7 @@ func (suite *AnteTestSuite) TestAnteHandler() { nonce, err := suite.GetNetwork().App.AccountKeeper.GetSequence(ctx, suite.GetKeyring().GetAccAddr(0)) suite.Require().NoError(err) ethTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, To: &to, Nonce: nonce, Amount: big.NewInt(10), @@ -182,7 +183,7 @@ func (suite *AnteTestSuite) TestAnteHandler() { nonce, err := suite.GetNetwork().App.AccountKeeper.GetSequence(ctx, suite.GetKeyring().GetAccAddr(0)) suite.Require().NoError(err) ethTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, To: &to, Nonce: nonce, Amount: big.NewInt(10), @@ -200,7 +201,7 @@ func (suite *AnteTestSuite) TestAnteHandler() { nonce, err := suite.GetNetwork().App.AccountKeeper.GetSequence(ctx, suite.GetKeyring().GetAccAddr(0)) suite.Require().NoError(err) ethTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, To: &to, Nonce: nonce, Amount: big.NewInt(10), @@ -218,7 +219,7 @@ func (suite *AnteTestSuite) TestAnteHandler() { nonce, err := suite.GetNetwork().App.AccountKeeper.GetSequence(ctx, suite.GetKeyring().GetAccAddr(0)) suite.Require().NoError(err) ethTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, To: &to, Nonce: nonce, Amount: big.NewInt(10), @@ -228,7 +229,7 @@ func (suite *AnteTestSuite) TestAnteHandler() { txBuilder := suite.CreateTxBuilder(privKey, ethTxParams) expFee := txBuilder.GetTx().GetFee() - oneCoin := sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(1)) + oneCoin := sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(1)) invalidFee := expFee.Add(oneCoin) txBuilder.SetFeeAmount(invalidFee) return txBuilder.GetTx() @@ -240,7 +241,7 @@ func (suite *AnteTestSuite) TestAnteHandler() { nonce, err := suite.GetNetwork().App.AccountKeeper.GetSequence(ctx, suite.GetKeyring().GetAccAddr(0)) suite.Require().NoError(err) ethTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, To: &to, Nonce: nonce, Amount: big.NewInt(10), @@ -599,12 +600,13 @@ func (suite *AnteTestSuite) TestAnteHandler() { { "passes - Single-signer EIP-712", func() sdk.Tx { + evmDenom := evmtypes.GetEVMCoinDenom() msg := banktypes.NewMsgSend( sdk.AccAddress(privKey.PubKey().Address()), addr[:], sdk.NewCoins( sdk.NewCoin( - "evmos", + evmDenom, sdkmath.NewInt(1), ), ), @@ -917,8 +919,10 @@ func (suite *AnteTestSuite) TestAnteHandlerWithDynamicTxFee() { addr, privKey := utiltx.NewAddrKey() to := utiltx.GenerateAddress() + evmChainID := evmtypes.GetEthChainConfig().ChainID + ethContractCreationTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: evmChainID, Nonce: 0, Amount: big.NewInt(10), GasLimit: 100000, @@ -928,7 +932,7 @@ func (suite *AnteTestSuite) TestAnteHandlerWithDynamicTxFee() { } ethTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: evmChainID, Nonce: 0, Amount: big.NewInt(10), GasLimit: 100000, @@ -1080,8 +1084,10 @@ func (suite *AnteTestSuite) TestAnteHandlerWithParams() { addr, privKey := utiltx.NewAddrKey() to := utiltx.GenerateAddress() + ethCfg := evmtypes.GetEthChainConfig() + ethContractCreationTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, Nonce: 0, Amount: big.NewInt(10), GasLimit: 100000, @@ -1092,7 +1098,7 @@ func (suite *AnteTestSuite) TestAnteHandlerWithParams() { } ethTxParams := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, Nonce: 0, Amount: big.NewInt(10), GasLimit: 100000, diff --git a/ante/evm/eth_benchmark_test.go b/ante/evm/eth_benchmark_test.go index a3a55d68..790b54af 100644 --- a/ante/evm/eth_benchmark_test.go +++ b/ante/evm/eth_benchmark_test.go @@ -28,7 +28,7 @@ func BenchmarkEthGasConsumeDecorator(b *testing.B) { ctx := s.GetNetwork().GetContext() args := &evmtypes.EvmTxArgs{ - ChainID: s.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: evmtypes.GetEthChainConfig().ChainID, Nonce: 1, Amount: big.NewInt(10), GasLimit: uint64(1_000_000), @@ -68,7 +68,7 @@ func BenchmarkEthGasConsumeDecorator(b *testing.B) { baseFee := s.GetNetwork().App.FeeMarketKeeper.GetParams(ctx).BaseFee fee := tx.GetEffectiveFee(baseFee.BigInt()) - denom := s.GetNetwork().App.EVMKeeper.GetParams(ctx).EvmDenom + denom := evmtypes.GetEVMCoinDenom() fees := sdk.NewCoins(sdk.NewCoin(denom, sdkmath.NewIntFromBigInt(fee))) bechAddr := sdk.AccAddress(addr.Bytes()) diff --git a/ante/evm/fee_checker.go b/ante/evm/fee_checker.go index 2943c822..1b120b57 100644 --- a/ante/evm/fee_checker.go +++ b/ante/evm/fee_checker.go @@ -26,7 +26,7 @@ import ( // - when `ExtensionOptionDynamicFeeTx` is omitted, `tipFeeCap` defaults to `MaxInt64`. // - when london hardfork is not enabled, it falls back to SDK default behavior (validator min-gas-prices). // - Tx priority is set to `effectiveGasPrice / DefaultPriorityReduction`. -func NewDynamicFeeChecker(k anteinterfaces.DynamicFeeEVMKeeper) authante.TxFeeChecker { +func NewDynamicFeeChecker(k anteinterfaces.FeeMarketKeeper) authante.TxFeeChecker { return func(ctx sdk.Context, tx sdk.Tx) (sdk.Coins, int64, error) { feeTx, ok := tx.(sdk.FeeTx) if !ok { @@ -38,9 +38,8 @@ func NewDynamicFeeChecker(k anteinterfaces.DynamicFeeEVMKeeper) authante.TxFeeCh // genesis transactions: fallback to min-gas-price logic return checkTxFeeWithValidatorMinGasPrices(ctx, feeTx) } - params := k.GetParams(ctx) - denom := params.EvmDenom - ethCfg := params.ChainConfig.EthereumConfig(k.ChainID()) + denom := evmtypes.GetEVMCoinDenom() + ethCfg := evmtypes.GetEthChainConfig() return FeeChecker(ctx, k, denom, ethCfg, feeTx) } @@ -49,25 +48,35 @@ func NewDynamicFeeChecker(k anteinterfaces.DynamicFeeEVMKeeper) authante.TxFeeCh // FeeChecker returns the effective fee and priority for a given transaction. func FeeChecker( ctx sdk.Context, - k anteinterfaces.DynamicFeeEVMKeeper, + k anteinterfaces.FeeMarketKeeper, denom string, ethConfig *params.ChainConfig, feeTx sdk.FeeTx, ) (sdk.Coins, int64, error) { - baseFee := k.GetBaseFee(ctx, ethConfig) - if baseFee == nil { + if !evmtypes.IsLondon(ethConfig, ctx.BlockHeight()) { // london hardfork is not enabled: fallback to min-gas-prices logic return checkTxFeeWithValidatorMinGasPrices(ctx, feeTx) } + baseFee := k.GetBaseFee(ctx) + // if baseFee is nil because it is disabled + // or not found, consider it as 0 + // so the DynamicFeeTx logic can be applied + if baseFee.IsNil() { + baseFee = sdkmath.LegacyZeroDec() + } + // default to `MaxInt64` when there's no extension option. - maxPriorityPrice := sdkmath.NewInt(math.MaxInt64) + maxPriorityPrice := sdkmath.LegacyNewDec(math.MaxInt64) // get the priority tip cap from the extension option. if hasExtOptsTx, ok := feeTx.(authante.HasExtensionOptionsTx); ok { for _, opt := range hasExtOptsTx.GetExtensionOptions() { if extOpt, ok := opt.GetCachedValue().(*evmostypes.ExtensionOptionDynamicFeeTx); ok { maxPriorityPrice = extOpt.MaxPriorityPrice + if maxPriorityPrice.IsNil() { + maxPriorityPrice = sdkmath.LegacyZeroDec() + } break } } @@ -78,33 +87,36 @@ func FeeChecker( return nil, 0, errorsmod.Wrapf(errortypes.ErrInsufficientFee, "max priority price cannot be negative") } - gas := feeTx.GetGas() + gas := sdkmath.NewIntFromUint64(feeTx.GetGas()) + if gas.IsZero() { + return nil, 0, errorsmod.Wrap(errortypes.ErrInvalidRequest, "gas cannot be zero") + } + feeCoins := feeTx.GetFee() - fee := feeCoins.AmountOfNoDenomValidation(denom) + feeAmtDec := sdkmath.LegacyNewDecFromInt(feeCoins.AmountOfNoDenomValidation(denom)) - feeCap := fee.Quo(sdkmath.NewIntFromUint64(gas)) - baseFeeInt := sdkmath.NewIntFromBigInt(baseFee) + feeCap := feeAmtDec.QuoInt(gas) - if feeCap.LT(baseFeeInt) { - return nil, 0, errorsmod.Wrapf(errortypes.ErrInsufficientFee, "gas prices too low, got: %s%s required: %s%s. Please retry using a higher gas price or a higher fee", feeCap, denom, baseFeeInt, denom) + if feeCap.LT(baseFee) { + return nil, 0, errorsmod.Wrapf(errortypes.ErrInsufficientFee, "gas prices too low, got: %s%s required: %s%s. Please retry using a higher gas price or a higher fee", feeCap, denom, baseFee, denom) } // calculate the effective gas price using the EIP-1559 logic. - effectivePrice := sdkmath.NewIntFromBigInt(evmtypes.EffectiveGasPrice(baseFeeInt.BigInt(), feeCap.BigInt(), maxPriorityPrice.BigInt())) + effectivePrice := effectiveGasPriceLegacyDec(baseFee, feeCap, maxPriorityPrice) // NOTE: create a new coins slice without having to validate the denom effectiveFee := sdk.Coins{ { Denom: denom, - Amount: effectivePrice.Mul(sdkmath.NewIntFromUint64(gas)), + Amount: effectivePrice.MulInt(gas).Ceil().RoundInt(), }, } - bigPriority := effectivePrice.Sub(baseFeeInt).Quo(evmtypes.DefaultPriorityReduction) + priorityInt := effectivePrice.Sub(baseFee).QuoInt(evmtypes.DefaultPriorityReduction).TruncateInt() priority := int64(math.MaxInt64) - if bigPriority.IsInt64() { - priority = bigPriority.Int64() + if priorityInt.IsInt64() { + priority = priorityInt.Int64() } return effectiveFee, priority, nil @@ -161,3 +173,9 @@ func getTxPriority(fees sdk.Coins, gas int64) int64 { return priority } + +// effectiveGasPriceLegacyDec computes the effective gas price based on eip-1559 rules +// `effectiveGasPrice = min(baseFee + tipCap, feeCap)` using decimals +func effectiveGasPriceLegacyDec(baseFee, feeCap, tipCap sdkmath.LegacyDec) sdkmath.LegacyDec { + return sdkmath.LegacyMinDec(tipCap.Add(baseFee), feeCap) +} diff --git a/ante/evm/fee_checker_test.go b/ante/evm/fee_checker_test.go index 40bf24c3..bf4ca604 100644 --- a/ante/evm/fee_checker_test.go +++ b/ante/evm/fee_checker_test.go @@ -10,36 +10,36 @@ import ( codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" - "github.com/ethereum/go-ethereum/params" "github.com/evmos/os/ante/evm" anteinterfaces "github.com/evmos/os/ante/interfaces" testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/os/network" "github.com/evmos/os/types" evmtypes "github.com/evmos/os/x/evm/types" + feemarkettypes "github.com/evmos/os/x/feemarket/types" "github.com/stretchr/testify/require" ) -var _ anteinterfaces.DynamicFeeEVMKeeper = MockEVMKeeper{} +var _ anteinterfaces.FeeMarketKeeper = MockFeemarketKeeper{} -type MockEVMKeeper struct { - BaseFee *big.Int - EnableLondonHF bool +type MockFeemarketKeeper struct { + BaseFee math.LegacyDec } -func (m MockEVMKeeper) GetBaseFee(_ sdk.Context, _ *params.ChainConfig) *big.Int { - if m.EnableLondonHF { - return m.BaseFee - } - return nil +func (m MockFeemarketKeeper) GetBaseFee(_ sdk.Context) math.LegacyDec { + return m.BaseFee +} + +func (m MockFeemarketKeeper) GetBaseFeeEnabled(_ sdk.Context) bool { + return true } -func (m MockEVMKeeper) GetParams(_ sdk.Context) evmtypes.Params { - return evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) +func (m MockFeemarketKeeper) AddTransientGasWanted(_ sdk.Context, _ uint64) (uint64, error) { + return 0, nil } -func (m MockEVMKeeper) ChainID() *big.Int { - return big.NewInt(9000) +func (m MockFeemarketKeeper) GetParams(_ sdk.Context) (params feemarkettypes.Params) { + return feemarkettypes.DefaultParams() } func TestSDKTxFeeChecker(t *testing.T) { @@ -54,28 +54,31 @@ func TestSDKTxFeeChecker(t *testing.T) { // london hardfork enableness nw := network.New() encodingConfig := nw.GetEncodingConfig() - minGasPrices := sdk.NewDecCoins(sdk.NewDecCoin(testconstants.ExampleAttoDenom, math.NewInt(10))) + evmDenom := evmtypes.GetEVMCoinDenom() + minGasPrices := sdk.NewDecCoins(sdk.NewDecCoin(evmDenom, math.NewInt(10))) genesisCtx := sdk.NewContext(nil, tmproto.Header{}, false, log.NewNopLogger()) checkTxCtx := sdk.NewContext(nil, tmproto.Header{Height: 1}, true, log.NewNopLogger()).WithMinGasPrices(minGasPrices) deliverTxCtx := sdk.NewContext(nil, tmproto.Header{Height: 1}, false, log.NewNopLogger()) testCases := []struct { - name string - ctx sdk.Context - keeper anteinterfaces.DynamicFeeEVMKeeper - buildTx func() sdk.FeeTx - expFees string - expPriority int64 - expSuccess bool + name string + ctx sdk.Context + keeper anteinterfaces.FeeMarketKeeper + buildTx func() sdk.FeeTx + londonEnabled bool + expFees string + expPriority int64 + expSuccess bool }{ { "success, genesis tx", genesisCtx, - MockEVMKeeper{}, + MockFeemarketKeeper{}, func() sdk.FeeTx { return encodingConfig.TxConfig.NewTxBuilder().GetTx() }, + false, "", 0, true, @@ -83,10 +86,11 @@ func TestSDKTxFeeChecker(t *testing.T) { { "fail, min-gas-prices", checkTxCtx, - MockEVMKeeper{}, + MockFeemarketKeeper{}, func() sdk.FeeTx { return encodingConfig.TxConfig.NewTxBuilder().GetTx() }, + false, "", 0, false, @@ -94,13 +98,14 @@ func TestSDKTxFeeChecker(t *testing.T) { { "success, min-gas-prices", checkTxCtx, - MockEVMKeeper{}, + MockFeemarketKeeper{}, func() sdk.FeeTx { txBuilder := encodingConfig.TxConfig.NewTxBuilder() txBuilder.SetGasLimit(1) txBuilder.SetFeeAmount(sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(10)))) return txBuilder.GetTx() }, + false, "10aevmos", 0, true, @@ -108,10 +113,11 @@ func TestSDKTxFeeChecker(t *testing.T) { { "success, min-gas-prices deliverTx", deliverTxCtx, - MockEVMKeeper{}, + MockFeemarketKeeper{}, func() sdk.FeeTx { return encodingConfig.TxConfig.NewTxBuilder().GetTx() }, + false, "", 0, true, @@ -119,14 +125,15 @@ func TestSDKTxFeeChecker(t *testing.T) { { "fail, dynamic fee", deliverTxCtx, - MockEVMKeeper{ - EnableLondonHF: true, BaseFee: big.NewInt(1), + MockFeemarketKeeper{ + BaseFee: math.LegacyNewDec(1), }, func() sdk.FeeTx { txBuilder := encodingConfig.TxConfig.NewTxBuilder() txBuilder.SetGasLimit(1) return txBuilder.GetTx() }, + true, "", 0, false, @@ -134,8 +141,8 @@ func TestSDKTxFeeChecker(t *testing.T) { { "success, dynamic fee", deliverTxCtx, - MockEVMKeeper{ - EnableLondonHF: true, BaseFee: big.NewInt(10), + MockFeemarketKeeper{ + BaseFee: math.LegacyNewDec(10), }, func() sdk.FeeTx { txBuilder := encodingConfig.TxConfig.NewTxBuilder() @@ -143,6 +150,7 @@ func TestSDKTxFeeChecker(t *testing.T) { txBuilder.SetFeeAmount(sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(10)))) return txBuilder.GetTx() }, + true, "10aevmos", 0, true, @@ -150,8 +158,8 @@ func TestSDKTxFeeChecker(t *testing.T) { { "success, dynamic fee priority", deliverTxCtx, - MockEVMKeeper{ - EnableLondonHF: true, BaseFee: big.NewInt(10), + MockFeemarketKeeper{ + BaseFee: math.LegacyNewDec(10), }, func() sdk.FeeTx { txBuilder := encodingConfig.TxConfig.NewTxBuilder() @@ -159,6 +167,7 @@ func TestSDKTxFeeChecker(t *testing.T) { txBuilder.SetFeeAmount(sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(10).Mul(evmtypes.DefaultPriorityReduction).Add(math.NewInt(10))))) return txBuilder.GetTx() }, + true, "10000010aevmos", 10, true, @@ -166,8 +175,8 @@ func TestSDKTxFeeChecker(t *testing.T) { { "success, dynamic fee empty tipFeeCap", deliverTxCtx, - MockEVMKeeper{ - EnableLondonHF: true, BaseFee: big.NewInt(10), + MockFeemarketKeeper{ + BaseFee: math.LegacyNewDec(10), }, func() sdk.FeeTx { txBuilder := encodingConfig.TxConfig.NewTxBuilder().(authtx.ExtensionOptionsTxBuilder) @@ -179,6 +188,7 @@ func TestSDKTxFeeChecker(t *testing.T) { txBuilder.SetExtensionOptions(option) return txBuilder.GetTx() }, + true, "10aevmos", 0, true, @@ -186,8 +196,8 @@ func TestSDKTxFeeChecker(t *testing.T) { { "success, dynamic fee tipFeeCap", deliverTxCtx, - MockEVMKeeper{ - EnableLondonHF: true, BaseFee: big.NewInt(10), + MockFeemarketKeeper{ + BaseFee: math.LegacyNewDec(10), }, func() sdk.FeeTx { txBuilder := encodingConfig.TxConfig.NewTxBuilder().(authtx.ExtensionOptionsTxBuilder) @@ -195,12 +205,13 @@ func TestSDKTxFeeChecker(t *testing.T) { txBuilder.SetFeeAmount(sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(10).Mul(evmtypes.DefaultPriorityReduction).Add(math.NewInt(10))))) option, err := codectypes.NewAnyWithValue(&types.ExtensionOptionDynamicFeeTx{ - MaxPriorityPrice: math.NewInt(5).Mul(evmtypes.DefaultPriorityReduction), + MaxPriorityPrice: math.LegacyNewDec(5).MulInt(evmtypes.DefaultPriorityReduction), }) require.NoError(t, err) txBuilder.SetExtensionOptions(option) return txBuilder.GetTx() }, + true, "5000010aevmos", 5, true, @@ -208,8 +219,8 @@ func TestSDKTxFeeChecker(t *testing.T) { { "fail, negative dynamic fee tipFeeCap", deliverTxCtx, - MockEVMKeeper{ - EnableLondonHF: true, BaseFee: big.NewInt(10), + MockFeemarketKeeper{ + BaseFee: math.LegacyNewDec(10), }, func() sdk.FeeTx { txBuilder := encodingConfig.TxConfig.NewTxBuilder().(authtx.ExtensionOptionsTxBuilder) @@ -218,12 +229,13 @@ func TestSDKTxFeeChecker(t *testing.T) { // set negative priority fee option, err := codectypes.NewAnyWithValue(&types.ExtensionOptionDynamicFeeTx{ - MaxPriorityPrice: math.NewInt(-5).Mul(evmtypes.DefaultPriorityReduction), + MaxPriorityPrice: math.LegacyNewDec(-5).MulInt(evmtypes.DefaultPriorityReduction), }) require.NoError(t, err) txBuilder.SetExtensionOptions(option) return txBuilder.GetTx() }, + true, "", 0, false, @@ -232,6 +244,12 @@ func TestSDKTxFeeChecker(t *testing.T) { for _, tc := range testCases { t.Run(tc.name, func(t *testing.T) { + cfg := evmtypes.GetEthChainConfig() + if !tc.londonEnabled { + cfg.LondonBlock = big.NewInt(10000) + } else { + cfg.LondonBlock = big.NewInt(0) + } fees, priority, err := evm.NewDynamicFeeChecker(tc.keeper)(tc.ctx, tc.buildTx()) if tc.expSuccess { require.Equal(t, tc.expFees, fees.String()) diff --git a/ante/evm/fee_market_test.go b/ante/evm/fee_market_test.go index eeff5bcc..4ce9e776 100644 --- a/ante/evm/fee_market_test.go +++ b/ante/evm/fee_market_test.go @@ -23,6 +23,7 @@ func (suite *AnteTestSuite) TestGasWantedDecorator() { dec := evm.NewGasWantedDecorator(suite.GetNetwork().App.EVMKeeper, suite.GetNetwork().App.FeeMarketKeeper) from, fromPrivKey := utiltx.NewAddrKey() to := utiltx.GenerateAddress() + denom := evmtypes.GetEVMCoinDenom() testCases := []struct { name string @@ -34,13 +35,12 @@ func (suite *AnteTestSuite) TestGasWantedDecorator() { "Cosmos Tx", testutils.TestGasLimit, func() sdk.Tx { - denom := testconstants.ExampleAttoDenom testMsg := banktypes.MsgSend{ FromAddress: "evmos1x8fhpj9nmhqk8z9kpgjt95ck2xwyue0ptzkucp", ToAddress: "evmos1dx67l23hz9l0k9hcher8xz04uj7wf3yu26l2yn", Amount: sdk.Coins{sdk.Coin{Amount: sdkmath.NewInt(10), Denom: denom}}, } - txBuilder := suite.CreateTestCosmosTxBuilder(sdkmath.NewInt(10), testconstants.ExampleAttoDenom, &testMsg) + txBuilder := suite.CreateTestCosmosTxBuilder(sdkmath.NewInt(10), denom, &testMsg) return txBuilder.GetTx() }, true, diff --git a/ante/evm/mono_decorator.go b/ante/evm/mono_decorator.go index 678e0cd1..dacfdfab 100644 --- a/ante/evm/mono_decorator.go +++ b/ante/evm/mono_decorator.go @@ -52,27 +52,34 @@ func (md MonoDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, ne // 0. Basic validation of the transaction var txFeeInfo *txtypes.Fee if !ctx.IsReCheckTx() { + // NOTE: txFeeInfo is associated with the Cosmos stack, not the EVM. For + // this reason, the fee is represented in the original decimals and + // should be converted later when used. txFeeInfo, err = ValidateTx(tx) if err != nil { return ctx, err } } + ethCfg := evmtypes.GetEthChainConfig() + evmDenom := evmtypes.GetEVMCoinDenom() + // 1. setup ctx - ctx, err = SetupContext(ctx, tx, md.evmKeeper) + ctx, err = SetupContextAndResetTransientGas(ctx, tx, md.evmKeeper) if err != nil { return ctx, err } // 2. get utils - decUtils, err := NewMonoDecoratorUtils(ctx, md.evmKeeper, md.feeMarketKeeper) + decUtils, err := NewMonoDecoratorUtils(ctx, md.evmKeeper) if err != nil { return ctx, err } - // Use the lowest priority of all the messages as the final one. + // NOTE: the protocol does not support multiple EVM messages currently so + // this loop will complete after the first message. for i, msg := range tx.GetMsgs() { - ethMsg, txData, from, err := evmtypes.UnpackEthMsg(msg) + ethMsg, txData, err := evmtypes.UnpackEthMsg(msg) if err != nil { return ctx, err } @@ -82,30 +89,38 @@ func (md MonoDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, ne fee := sdkmath.LegacyNewDecFromBigInt(feeAmt) gasLimit := sdkmath.LegacyNewDecFromBigInt(new(big.Int).SetUint64(gas)) + // TODO: computation for mempool and global fee can be made using only + // the price instead of the fee. This would save some computation. + // // 2. mempool inclusion fee if ctx.IsCheckTx() && !simulate { + // FIX: Mempool dec should be converted if err := CheckMempoolFee(fee, decUtils.MempoolMinGasPrice, gasLimit, decUtils.Rules.IsLondon); err != nil { return ctx, err } } - // 3. min gas price (global min fee) if txData.TxType() == ethtypes.DynamicFeeTxType && decUtils.BaseFee != nil { + // If the base fee is not empty, we compute the effective gas price + // according to current base fee price. The gas limit is specified + // by the user, while the price is given by the minimum between the + // max price paid for the entire tx, and the sum between the price + // for the tip and the base fee. feeAmt = txData.EffectiveFee(decUtils.BaseFee) fee = sdkmath.LegacyNewDecFromBigInt(feeAmt) } + // 3. min gas price (global min fee) if err := CheckGlobalFee(fee, decUtils.GlobalMinGasPrice, gasLimit); err != nil { return ctx, err } // 4. validate msg contents - err = ValidateMsg( + if err := ValidateMsg( decUtils.EvmParams, txData, - from, - ) - if err != nil { + ethMsg.GetFrom(), + ); err != nil { return ctx, err } @@ -118,12 +133,13 @@ func (md MonoDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, ne return ctx, err } - // NOTE: sender address has been verified and cached - from = ethMsg.GetFrom() + from := ethMsg.GetFrom() + fromAddr := common.BytesToAddress(from) // 6. account balance verification - fromAddr := common.HexToAddress(ethMsg.From) - // TODO: Use account from AccountKeeper instead + // We get the account with the balance from the EVM keeper because it is + // using a wrapper of the bank keeper as a dependency to scale all + // balances to 18 decimals. account := md.evmKeeper.GetAccount(ctx, fromAddr) if err := VerifyAccountBalance( ctx, @@ -149,7 +165,7 @@ func (md MonoDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, ne md.evmKeeper, coreMsg, decUtils.BaseFee, - decUtils.EthConfig, + ethCfg, decUtils.EvmParams, decUtils.Rules.IsLondon, ); err != nil { @@ -159,7 +175,7 @@ func (md MonoDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, ne // 8. gas consumption msgFees, err := evmkeeper.VerifyFee( txData, - decUtils.EvmDenom, + evmDenom, decUtils.BaseFee, decUtils.Rules.IsHomestead, decUtils.Rules.IsIstanbul, @@ -181,7 +197,7 @@ func (md MonoDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, ne gasWanted := UpdateCumulativeGasWanted( ctx, - txData.GetGas(), + gas, md.maxGasWanted, decUtils.GasWanted, ) @@ -194,12 +210,12 @@ func (md MonoDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, ne ) decUtils.MinPriority = minPriority - txFee := UpdateCumulativeTxFee( - decUtils.TxFee, - txData.Fee(), - decUtils.EvmDenom, - ) - decUtils.TxFee = txFee + // Update the fee to be paid for the tx adding the fee specified for the + // current message. + decUtils.TxFee.Add(decUtils.TxFee, txData.Fee()) + + // Update the transaction gas limit adding the gas specified in the + // current message. decUtils.TxGasLimit += gas // 9. increment sequence diff --git a/ante/evm/signverify_test.go b/ante/evm/signverify_test.go index fc752829..e9ab7466 100644 --- a/ante/evm/signverify_test.go +++ b/ante/evm/signverify_test.go @@ -13,10 +13,11 @@ import ( func (suite *AnteTestSuite) TestEthSigVerificationDecorator() { addr, privKey := testutiltx.NewAddrKey() - ethSigner := ethtypes.LatestSignerForChainID(suite.GetNetwork().App.EVMKeeper.ChainID()) + ethCfg := evmtypes.GetEthChainConfig() + ethSigner := ethtypes.LatestSignerForChainID(ethCfg.ChainID) ethContractCreationTxParams := &evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, Nonce: 1, Amount: big.NewInt(10), GasLimit: 1000, diff --git a/ante/evm/sigs_test.go b/ante/evm/sigs_test.go index de7d8e26..ccf99f86 100644 --- a/ante/evm/sigs_test.go +++ b/ante/evm/sigs_test.go @@ -15,7 +15,7 @@ func (suite *AnteTestSuite) TestSignatures() { to := utiltx.GenerateAddress() txArgs := evmtypes.EvmTxArgs{ - ChainID: suite.GetNetwork().App.EVMKeeper.ChainID(), + ChainID: evmtypes.GetEthChainConfig().ChainID, Nonce: 0, To: &to, Amount: big.NewInt(10), diff --git a/ante/evm/utils.go b/ante/evm/utils.go index 7058ddb4..143566e0 100644 --- a/ante/evm/utils.go +++ b/ante/evm/utils.go @@ -20,18 +20,16 @@ import ( // throughout the verification of an Ethereum transaction. type DecoratorUtils struct { EvmParams evmtypes.Params - EthConfig *params.ChainConfig Rules params.Rules Signer ethtypes.Signer BaseFee *big.Int - EvmDenom string MempoolMinGasPrice sdkmath.LegacyDec GlobalMinGasPrice sdkmath.LegacyDec BlockTxIndex uint64 TxGasLimit uint64 GasWanted uint64 MinPriority int64 - TxFee sdk.Coins + TxFee *big.Int } // NewMonoDecoratorUtils returns a new DecoratorUtils instance. @@ -39,18 +37,19 @@ type DecoratorUtils struct { // These utilities are extracted once at the beginning of the ante handle process, // and are used throughout the entire decorator chain. // This avoids redundant calls to the keeper and thus improves speed of transaction processing. +// +// All prices, fees and balances are converted into 18 decimals here +// to be correctly used in the EVM. func NewMonoDecoratorUtils( ctx sdk.Context, ek anteinterfaces.EVMKeeper, - fmk anteinterfaces.FeeMarketKeeper, ) (*DecoratorUtils, error) { evmParams := ek.GetParams(ctx) - chainCfg := evmParams.GetChainConfig() - ethCfg := chainCfg.EthereumConfig(ek.ChainID()) + ethCfg := evmtypes.GetEthChainConfig() + evmDenom := evmtypes.GetEVMCoinDenom() blockHeight := big.NewInt(ctx.BlockHeight()) rules := ethCfg.Rules(blockHeight, true) - baseFee := ek.GetBaseFee(ctx, ethCfg) - feeMarketParams := fmk.GetParams(ctx) + baseFee := ek.GetBaseFee(ctx) if rules.IsLondon && baseFee == nil { return nil, errorsmod.Wrap( @@ -59,19 +58,25 @@ func NewMonoDecoratorUtils( ) } + globalMinGasPrice := ek.GetMinGasPrice(ctx) + + // Mempool gas price should be scaled to the 18 decimals representation. + // If it is already a 18 decimal token, this is a no-op. + mempoolMinGasPrice := evmtypes.ConvertAmountTo18DecimalsLegacy(ctx.MinGasPrices().AmountOf(evmDenom)) + return &DecoratorUtils{ EvmParams: evmParams, - EthConfig: ethCfg, Rules: rules, Signer: ethtypes.MakeSigner(ethCfg, blockHeight), BaseFee: baseFee, - MempoolMinGasPrice: ctx.MinGasPrices().AmountOf(evmParams.EvmDenom), - GlobalMinGasPrice: feeMarketParams.MinGasPrice, - EvmDenom: evmParams.EvmDenom, + MempoolMinGasPrice: mempoolMinGasPrice, + GlobalMinGasPrice: globalMinGasPrice, BlockTxIndex: ek.GetTxIndexTransient(ctx), - TxGasLimit: 0, GasWanted: 0, MinPriority: int64(math.MaxInt64), - TxFee: sdk.Coins{}, + // TxGasLimit and TxFee are set to zero because they are updated + // summing up the values of all messages contained in a tx. + TxGasLimit: 0, + TxFee: big.NewInt(0), }, nil } diff --git a/ante/evm/utils_test.go b/ante/evm/utils_test.go index 800df225..f1831d6e 100644 --- a/ante/evm/utils_test.go +++ b/ante/evm/utils_test.go @@ -35,7 +35,6 @@ import ( "github.com/evmos/os/crypto/ethsecp256k1" "github.com/evmos/os/ethereum/eip712" "github.com/evmos/os/testutil" - testconstants "github.com/evmos/os/testutil/constants" utiltx "github.com/evmos/os/testutil/tx" evmtypes "github.com/evmos/os/x/evm/types" ) @@ -68,7 +67,7 @@ func (suite *AnteTestSuite) CreateTxBuilder(privKey cryptotypes.PrivKey, txArgs txData, err := evmtypes.UnpackTxData(signedMsg.Data) suite.Require().NoError(err) - fees := sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewIntFromBigInt(txData.Fee()))) + fees := sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewIntFromBigInt(txData.Fee()))) builder.SetFeeAmount(fees) builder.SetGasLimit(signedMsg.GetGas()) return builder @@ -107,14 +106,14 @@ func (suite *AnteTestSuite) CreateTestCosmosTxBuilder(gasPrice sdkmath.Int, deno func (suite *AnteTestSuite) CreateTestEIP712TxBuilderMsgSend(from sdk.AccAddress, priv cryptotypes.PrivKey, chainID string, gas uint64, gasAmount sdk.Coins) (client.TxBuilder, error) { // Build MsgSend recipient := sdk.AccAddress(common.Address{}.Bytes()) - msgSend := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(1)))) + msgSend := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(1)))) return suite.CreateTestEIP712SingleMessageTxBuilder(priv, chainID, gas, gasAmount, msgSend) } func (suite *AnteTestSuite) CreateTestEIP712TxBuilderMsgDelegate(from sdk.AccAddress, priv cryptotypes.PrivKey, chainID string, gas uint64, gasAmount sdk.Coins) (client.TxBuilder, error) { // Build MsgDelegate val := suite.GetNetwork().GetValidators()[0] - msgDelegate := stakingtypes.NewMsgDelegate(from.String(), val.OperatorAddress, sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(20))) + msgDelegate := stakingtypes.NewMsgDelegate(from.String(), val.OperatorAddress, sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(20))) return suite.CreateTestEIP712SingleMessageTxBuilder(priv, chainID, gas, gasAmount, msgDelegate) } @@ -122,10 +121,11 @@ func (suite *AnteTestSuite) CreateTestEIP712MsgCreateValidator(from sdk.AccAddre // Build MsgCreateValidator valAddr := sdk.ValAddress(from.Bytes()) privEd := ed25519.GenPrivKey() + evmDenom := evmtypes.GetEVMCoinDenom() msgCreate, err := stakingtypes.NewMsgCreateValidator( valAddr.String(), privEd.PubKey(), - sdk.NewCoin(testconstants.ExampleAttoDenom, sdkmath.NewInt(20)), + sdk.NewCoin(evmDenom, sdkmath.NewInt(20)), stakingtypes.NewDescription("moniker", "identity", "website", "security_contract", "details"), stakingtypes.NewCommissionRates(sdkmath.LegacyOneDec(), sdkmath.LegacyOneDec(), sdkmath.LegacyOneDec()), sdkmath.OneInt(), @@ -141,7 +141,7 @@ func (suite *AnteTestSuite) CreateTestEIP712MsgCreateValidator2(from sdk.AccAddr msgCreate, err := stakingtypes.NewMsgCreateValidator( valAddr.String(), privEd.PubKey(), - sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(20)), + sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(20)), // Ensure optional fields can be left blank stakingtypes.NewDescription("moniker", "identity", "", "", ""), stakingtypes.NewCommissionRates(sdkmath.LegacyOneDec(), sdkmath.LegacyOneDec(), sdkmath.LegacyOneDec()), @@ -160,7 +160,7 @@ func (suite *AnteTestSuite) CreateTestEIP712SubmitProposal(from sdk.AccAddress, } func (suite *AnteTestSuite) CreateTestEIP712GrantAllowance(from sdk.AccAddress, priv cryptotypes.PrivKey, chainID string, gas uint64, gasAmount sdk.Coins) (client.TxBuilder, error) { - spendLimit := sdk.NewCoins(sdk.NewInt64Coin(suite.GetNetwork().GetDenom(), 10)) + spendLimit := sdk.NewCoins(sdk.NewInt64Coin(suite.GetNetwork().GetBaseDenom(), 10)) threeHours := time.Now().Add(3 * time.Hour) basic := &feegrant.BasicAllowance{ SpendLimit: spendLimit, @@ -231,7 +231,7 @@ func (suite *AnteTestSuite) CreateTestEIP712SubmitProposalV1(from sdk.AccAddress // Build V1 proposal msgProposal, err := govtypesv1.NewMsgSubmitProposal( proposalMsgs, - sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(100))), + sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(100))), sdk.MustBech32ifyAddressBytes(sdk.GetConfig().GetBech32AccountAddrPrefix(), from.Bytes()), "Metadata", "title", "summary", false, @@ -244,26 +244,26 @@ func (suite *AnteTestSuite) CreateTestEIP712SubmitProposalV1(from sdk.AccAddress func (suite *AnteTestSuite) CreateTestEIP712MsgExec(from sdk.AccAddress, priv cryptotypes.PrivKey, chainID string, gas uint64, gasAmount sdk.Coins) (client.TxBuilder, error) { recipient := sdk.AccAddress(common.Address{}.Bytes()) - msgSend := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(1)))) + msgSend := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(1)))) msgExec := authz.NewMsgExec(from, []sdk.Msg{msgSend}) return suite.CreateTestEIP712SingleMessageTxBuilder(priv, chainID, gas, gasAmount, &msgExec) } func (suite *AnteTestSuite) CreateTestEIP712MultipleMsgSend(from sdk.AccAddress, priv cryptotypes.PrivKey, chainID string, gas uint64, gasAmount sdk.Coins) (client.TxBuilder, error) { recipient := sdk.AccAddress(common.Address{}.Bytes()) - msgSend := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(1)))) + msgSend := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(1)))) return suite.CreateTestEIP712CosmosTxBuilder(priv, chainID, gas, gasAmount, []sdk.Msg{msgSend, msgSend, msgSend}) } func (suite *AnteTestSuite) CreateTestEIP712MultipleDifferentMsgs(from sdk.AccAddress, priv cryptotypes.PrivKey, chainID string, gas uint64, gasAmount sdk.Coins) (client.TxBuilder, error) { recipient := sdk.AccAddress(common.Address{}.Bytes()) - msgSend := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(1)))) + msgSend := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(1)))) msgVote := govtypesv1.NewMsgVote(from, 1, govtypesv1.VoteOption_VOTE_OPTION_YES, "") valEthAddr := utiltx.GenerateAddress() valAddr := sdk.ValAddress(valEthAddr.Bytes()) - msgDelegate := stakingtypes.NewMsgDelegate(from.String(), valAddr.String(), sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(20))) + msgDelegate := stakingtypes.NewMsgDelegate(from.String(), valAddr.String(), sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(20))) return suite.CreateTestEIP712CosmosTxBuilder(priv, chainID, gas, gasAmount, []sdk.Msg{msgSend, msgVote, msgDelegate}) } @@ -299,14 +299,14 @@ func (suite *AnteTestSuite) CreateTestEIP712MsgTransferWithoutMemo(from sdk.AccA func (suite *AnteTestSuite) createMsgTransfer(from sdk.AccAddress, memo string) *ibctypes.MsgTransfer { recipient := sdk.AccAddress(common.Address{}.Bytes()) - msgTransfer := ibctypes.NewMsgTransfer("transfer", "channel-25", sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(100000)), from.String(), recipient.String(), ibcclienttypes.NewHeight(1000, 1000), 1000, memo) + msgTransfer := ibctypes.NewMsgTransfer("transfer", "channel-25", sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(100000)), from.String(), recipient.String(), ibcclienttypes.NewHeight(1000, 1000), 1000, memo) return msgTransfer } func (suite *AnteTestSuite) CreateTestEIP712MultipleSignerMsgs(from sdk.AccAddress, priv cryptotypes.PrivKey, chainID string, gas uint64, gasAmount sdk.Coins) (client.TxBuilder, error) { recipient := sdk.AccAddress(common.Address{}.Bytes()) - msgSend1 := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(1)))) - msgSend2 := banktypes.NewMsgSend(recipient, from, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(1)))) + msgSend1 := banktypes.NewMsgSend(from, recipient, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(1)))) + msgSend2 := banktypes.NewMsgSend(recipient, from, sdk.NewCoins(sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(1)))) return suite.CreateTestEIP712CosmosTxBuilder(priv, chainID, gas, gasAmount, []sdk.Msg{msgSend1, msgSend2}) } @@ -445,6 +445,7 @@ func (suite *AnteTestSuite) generateMultikeySignatures(signMode signing.SignMode // RegisterAccount creates an account with the keeper and populates the initial balance func (suite *AnteTestSuite) RegisterAccount(pubKey cryptotypes.PubKey, balance *big.Int) { ctx := suite.GetNetwork().GetContext() + acc := suite.GetNetwork().App.AccountKeeper.NewAccountWithAddress(ctx, sdk.AccAddress(pubKey.Address())) suite.GetNetwork().App.AccountKeeper.SetAccount(ctx, acc) @@ -484,7 +485,7 @@ func (suite *AnteTestSuite) createBaseTxBuilder(msg sdk.Msg, gas uint64) client. txBuilder.SetGasLimit(gas) txBuilder.SetFeeAmount(sdk.NewCoins( - sdk.NewCoin(suite.GetNetwork().GetDenom(), sdkmath.NewInt(10000)), + sdk.NewCoin(suite.GetNetwork().GetBaseDenom(), sdkmath.NewInt(10000)), )) err := txBuilder.SetMsgs(msg) @@ -540,7 +541,7 @@ func (suite *AnteTestSuite) CreateTestSignedMultisigTx(privKeys []cryptotypes.Pr func (suite *AnteTestSuite) CreateTestSingleSignedTx(privKey cryptotypes.PrivKey, signMode signing.SignMode, msg sdk.Msg, chainID string, gas uint64, signType string) client.TxBuilder { pubKey := privKey.PubKey() - suite.RegisterAccount(pubKey, big.NewInt(10000000000)) + suite.RegisterAccount(pubKey, big.NewInt(10_000_000_000)) txBuilder := suite.createBaseTxBuilder(msg, gas) diff --git a/ante/interfaces/evm.go b/ante/interfaces/evm.go index 658f21c2..d7adcb24 100644 --- a/ante/interfaces/evm.go +++ b/ante/interfaces/evm.go @@ -6,11 +6,11 @@ package interfaces import ( "math/big" + "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/tx" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core" - "github.com/ethereum/go-ethereum/params" "github.com/evmos/os/x/evm/core/vm" "github.com/evmos/os/x/evm/statedb" evmtypes "github.com/evmos/os/x/evm/types" @@ -20,7 +20,6 @@ import ( // EVMKeeper exposes the required EVM keeper interface required for ante handlers type EVMKeeper interface { statedb.Keeper - DynamicFeeEVMKeeper NewEVM(ctx sdk.Context, msg core.Message, cfg *statedb.EVMConfig, tracer vm.EVMLogger, stateDB vm.StateDB) *vm.EVM DeductTxCostsFromUserBalance(ctx sdk.Context, fees sdk.Coins, from common.Address) error @@ -28,6 +27,12 @@ type EVMKeeper interface { ResetTransientGasUsed(ctx sdk.Context) GetTxIndexTransient(ctx sdk.Context) uint64 GetParams(ctx sdk.Context) evmtypes.Params + // GetBaseFee returns the BaseFee param from the fee market module + // adapted according to the evm denom decimals + GetBaseFee(ctx sdk.Context) *big.Int + // GetMinGasPrice returns the MinGasPrice param from the fee market module + // adapted according to the evm denom decimals + GetMinGasPrice(ctx sdk.Context) math.LegacyDec } // FeeMarketKeeper exposes the required feemarket keeper interface required for ante handlers @@ -35,13 +40,7 @@ type FeeMarketKeeper interface { GetParams(ctx sdk.Context) (params feemarkettypes.Params) AddTransientGasWanted(ctx sdk.Context, gasWanted uint64) (uint64, error) GetBaseFeeEnabled(ctx sdk.Context) bool -} - -// DynamicFeeEVMKeeper is a subset of EVMKeeper interface that supports dynamic fee checker -type DynamicFeeEVMKeeper interface { - ChainID() *big.Int - GetParams(ctx sdk.Context) evmtypes.Params - GetBaseFee(ctx sdk.Context, ethCfg *params.ChainConfig) *big.Int + GetBaseFee(ctx sdk.Context) math.LegacyDec } type ProtoTxProvider interface { diff --git a/ante/testutils/testutil.go b/ante/testutils/testutil.go index 43a9ff9c..e90fed48 100644 --- a/ante/testutils/testutil.go +++ b/ante/testutils/testutil.go @@ -1,20 +1,21 @@ // Copyright Tharsis Labs Ltd.(Evmos) // SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) - package testutils import ( "math" + "github.com/stretchr/testify/suite" + sdkmath "cosmossdk.io/math" "github.com/cosmos/cosmos-sdk/client" sdk "github.com/cosmos/cosmos-sdk/types" consensustypes "github.com/cosmos/cosmos-sdk/x/consensus/types" + "github.com/evmos/os/ante" evmante "github.com/evmos/os/ante/evm" chainante "github.com/evmos/os/example_chain/ante" chainutil "github.com/evmos/os/example_chain/testutil" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/os/factory" "github.com/evmos/os/testutil/integration/os/grpc" "github.com/evmos/os/testutil/integration/os/keyring" @@ -22,7 +23,6 @@ import ( "github.com/evmos/os/types" evmtypes "github.com/evmos/os/x/evm/types" feemarkettypes "github.com/evmos/os/x/feemarket/types" - "github.com/stretchr/testify/suite" ) type AnteTestSuite struct { @@ -36,7 +36,7 @@ type AnteTestSuite struct { anteHandler sdk.AnteHandler enableFeemarket bool - baseFee *sdkmath.Int + baseFee *sdkmath.LegacyDec enableLondonHF bool evmParamsOption func(*evmtypes.Params) } @@ -60,16 +60,7 @@ func (suite *AnteTestSuite) SetupTest() { customGenesis[feemarkettypes.ModuleName] = feemarketGenesis evmGenesis := evmtypes.DefaultGenesisState() - evmGenesis.Params.EvmDenom = testconstants.ExampleAttoDenom - if !suite.enableLondonHF { - maxInt := sdkmath.NewInt(math.MaxInt64) - evmGenesis.Params.ChainConfig.LondonBlock = &maxInt - evmGenesis.Params.ChainConfig.ArrowGlacierBlock = &maxInt - evmGenesis.Params.ChainConfig.GrayGlacierBlock = &maxInt - evmGenesis.Params.ChainConfig.MergeNetsplitBlock = &maxInt - evmGenesis.Params.ChainConfig.ShanghaiBlock = &maxInt - evmGenesis.Params.ChainConfig.CancunBlock = &maxInt - } + if suite.evmParamsOption != nil { suite.evmParamsOption(&evmGenesis.Params) } @@ -84,6 +75,7 @@ func (suite *AnteTestSuite) SetupTest() { network.WithPreFundedAccounts(keys.GetAllAccAddrs()...), network.WithCustomGenesis(customGenesis), ) + gh := grpc.NewIntegrationHandler(nw) tf := factory.New(nw, gh) @@ -98,7 +90,31 @@ func (suite *AnteTestSuite) SetupTest() { suite.Require().NotNil(suite.network.App.AppCodec()) - options := chainante.HandlerOptions{ + chainConfig := evmtypes.DefaultChainConfig(suite.network.GetChainID()) + if !suite.enableLondonHF { + maxInt := sdkmath.NewInt(math.MaxInt64) + chainConfig.LondonBlock = &maxInt + chainConfig.ArrowGlacierBlock = &maxInt + chainConfig.GrayGlacierBlock = &maxInt + chainConfig.MergeNetsplitBlock = &maxInt + chainConfig.ShanghaiBlock = &maxInt + chainConfig.CancunBlock = &maxInt + } + + // get the denom and decimals set when initialized the chain + // to set them again + // when resetting the chain config + denom := evmtypes.GetEVMCoinDenom() //nolint:staticcheck + decimals := evmtypes.GetEVMCoinDecimals() //nolint:staticcheck + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + err := configurator. + WithChainConfig(chainConfig). + WithEVMCoinInfo(denom, uint8(decimals)). + Configure() + suite.Require().NoError(err) + + anteHandler := chainante.NewAnteHandler(chainante.HandlerOptions{ Cdc: suite.network.App.AppCodec(), AccountKeeper: suite.network.App.AccountKeeper, BankKeeper: suite.network.App.BankKeeper, @@ -109,11 +125,10 @@ func (suite *AnteTestSuite) SetupTest() { SignModeHandler: encodingConfig.TxConfig.SignModeHandler(), SigGasConsumer: ante.SigVerificationGasConsumer, ExtensionOptionChecker: types.HasDynamicFeeExtensionOption, - TxFeeChecker: evmante.NewDynamicFeeChecker(suite.network.App.EVMKeeper), - } - suite.Require().NoError(options.Validate(), "invalid ante handler options") + TxFeeChecker: evmante.NewDynamicFeeChecker(suite.network.App.FeeMarketKeeper), + }) - suite.anteHandler = chainante.NewAnteHandler(options) + suite.anteHandler = anteHandler } func (suite *AnteTestSuite) WithFeemarketEnabled(enabled bool) { @@ -124,7 +139,7 @@ func (suite *AnteTestSuite) WithLondonHardForkEnabled(enabled bool) { suite.enableLondonHF = enabled } -func (suite *AnteTestSuite) WithBaseFee(baseFee *sdkmath.Int) { +func (suite *AnteTestSuite) WithBaseFee(baseFee *sdkmath.LegacyDec) { suite.baseFee = baseFee } diff --git a/api/os/evm/v1/evm.pulsar.go b/api/os/evm/v1/evm.pulsar.go index 21a390cb..c2f21476 100644 --- a/api/os/evm/v1/evm.pulsar.go +++ b/api/os/evm/v1/evm.pulsar.go @@ -2081,6 +2081,9 @@ var ( fd_ChainConfig_merge_netsplit_block protoreflect.FieldDescriptor fd_ChainConfig_shanghai_block protoreflect.FieldDescriptor fd_ChainConfig_cancun_block protoreflect.FieldDescriptor + fd_ChainConfig_chain_id protoreflect.FieldDescriptor + fd_ChainConfig_denom protoreflect.FieldDescriptor + fd_ChainConfig_decimals protoreflect.FieldDescriptor ) func init() { @@ -2105,6 +2108,9 @@ func init() { fd_ChainConfig_merge_netsplit_block = md_ChainConfig.Fields().ByName("merge_netsplit_block") fd_ChainConfig_shanghai_block = md_ChainConfig.Fields().ByName("shanghai_block") fd_ChainConfig_cancun_block = md_ChainConfig.Fields().ByName("cancun_block") + fd_ChainConfig_chain_id = md_ChainConfig.Fields().ByName("chain_id") + fd_ChainConfig_denom = md_ChainConfig.Fields().ByName("denom") + fd_ChainConfig_decimals = md_ChainConfig.Fields().ByName("decimals") } var _ protoreflect.Message = (*fastReflection_ChainConfig)(nil) @@ -2286,6 +2292,24 @@ func (x *fastReflection_ChainConfig) Range(f func(protoreflect.FieldDescriptor, return } } + if x.ChainId != uint64(0) { + value := protoreflect.ValueOfUint64(x.ChainId) + if !f(fd_ChainConfig_chain_id, value) { + return + } + } + if x.Denom != "" { + value := protoreflect.ValueOfString(x.Denom) + if !f(fd_ChainConfig_denom, value) { + return + } + } + if x.Decimals != uint64(0) { + value := protoreflect.ValueOfUint64(x.Decimals) + if !f(fd_ChainConfig_decimals, value) { + return + } + } } // Has reports whether a field is populated. @@ -2339,6 +2363,12 @@ func (x *fastReflection_ChainConfig) Has(fd protoreflect.FieldDescriptor) bool { return x.ShanghaiBlock != "" case "os.evm.v1.ChainConfig.cancun_block": return x.CancunBlock != "" + case "os.evm.v1.ChainConfig.chain_id": + return x.ChainId != uint64(0) + case "os.evm.v1.ChainConfig.denom": + return x.Denom != "" + case "os.evm.v1.ChainConfig.decimals": + return x.Decimals != uint64(0) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.ChainConfig")) @@ -2393,6 +2423,12 @@ func (x *fastReflection_ChainConfig) Clear(fd protoreflect.FieldDescriptor) { x.ShanghaiBlock = "" case "os.evm.v1.ChainConfig.cancun_block": x.CancunBlock = "" + case "os.evm.v1.ChainConfig.chain_id": + x.ChainId = uint64(0) + case "os.evm.v1.ChainConfig.denom": + x.Denom = "" + case "os.evm.v1.ChainConfig.decimals": + x.Decimals = uint64(0) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.ChainConfig")) @@ -2466,6 +2502,15 @@ func (x *fastReflection_ChainConfig) Get(descriptor protoreflect.FieldDescriptor case "os.evm.v1.ChainConfig.cancun_block": value := x.CancunBlock return protoreflect.ValueOfString(value) + case "os.evm.v1.ChainConfig.chain_id": + value := x.ChainId + return protoreflect.ValueOfUint64(value) + case "os.evm.v1.ChainConfig.denom": + value := x.Denom + return protoreflect.ValueOfString(value) + case "os.evm.v1.ChainConfig.decimals": + value := x.Decimals + return protoreflect.ValueOfUint64(value) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.ChainConfig")) @@ -2524,6 +2569,12 @@ func (x *fastReflection_ChainConfig) Set(fd protoreflect.FieldDescriptor, value x.ShanghaiBlock = value.Interface().(string) case "os.evm.v1.ChainConfig.cancun_block": x.CancunBlock = value.Interface().(string) + case "os.evm.v1.ChainConfig.chain_id": + x.ChainId = value.Uint() + case "os.evm.v1.ChainConfig.denom": + x.Denom = value.Interface().(string) + case "os.evm.v1.ChainConfig.decimals": + x.Decimals = value.Uint() default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.ChainConfig")) @@ -2582,6 +2633,12 @@ func (x *fastReflection_ChainConfig) Mutable(fd protoreflect.FieldDescriptor) pr panic(fmt.Errorf("field shanghai_block of message os.evm.v1.ChainConfig is not mutable")) case "os.evm.v1.ChainConfig.cancun_block": panic(fmt.Errorf("field cancun_block of message os.evm.v1.ChainConfig is not mutable")) + case "os.evm.v1.ChainConfig.chain_id": + panic(fmt.Errorf("field chain_id of message os.evm.v1.ChainConfig is not mutable")) + case "os.evm.v1.ChainConfig.denom": + panic(fmt.Errorf("field denom of message os.evm.v1.ChainConfig is not mutable")) + case "os.evm.v1.ChainConfig.decimals": + panic(fmt.Errorf("field decimals of message os.evm.v1.ChainConfig is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.ChainConfig")) @@ -2633,6 +2690,12 @@ func (x *fastReflection_ChainConfig) NewField(fd protoreflect.FieldDescriptor) p return protoreflect.ValueOfString("") case "os.evm.v1.ChainConfig.cancun_block": return protoreflect.ValueOfString("") + case "os.evm.v1.ChainConfig.chain_id": + return protoreflect.ValueOfUint64(uint64(0)) + case "os.evm.v1.ChainConfig.denom": + return protoreflect.ValueOfString("") + case "os.evm.v1.ChainConfig.decimals": + return protoreflect.ValueOfUint64(uint64(0)) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.ChainConfig")) @@ -2777,6 +2840,16 @@ func (x *fastReflection_ChainConfig) ProtoMethods() *protoiface.Methods { if l > 0 { n += 2 + l + runtime.Sov(uint64(l)) } + if x.ChainId != 0 { + n += 2 + runtime.Sov(uint64(x.ChainId)) + } + l = len(x.Denom) + if l > 0 { + n += 2 + l + runtime.Sov(uint64(l)) + } + if x.Decimals != 0 { + n += 2 + runtime.Sov(uint64(x.Decimals)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -2806,6 +2879,29 @@ func (x *fastReflection_ChainConfig) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if x.Decimals != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Decimals)) + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0xd0 + } + if len(x.Denom) > 0 { + i -= len(x.Denom) + copy(dAtA[i:], x.Denom) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Denom))) + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0xca + } + if x.ChainId != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ChainId)) + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0xc0 + } if len(x.CancunBlock) > 0 { i -= len(x.CancunBlock) copy(dAtA[i:], x.CancunBlock) @@ -3599,6 +3695,76 @@ func (x *fastReflection_ChainConfig) ProtoMethods() *protoiface.Methods { } x.CancunBlock = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 24: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType) + } + x.ChainId = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ChainId |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 25: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Denom = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 26: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Decimals", wireType) + } + x.Decimals = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Decimals |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -8199,6 +8365,12 @@ type ChainConfig struct { ShanghaiBlock string `protobuf:"bytes,22,opt,name=shanghai_block,json=shanghaiBlock,proto3" json:"shanghai_block,omitempty"` // cancun_block switch block (nil = no fork, 0 = already on cancun) CancunBlock string `protobuf:"bytes,23,opt,name=cancun_block,json=cancunBlock,proto3" json:"cancun_block,omitempty"` + // chain_id is the id of the chain (EIP-155) + ChainId uint64 `protobuf:"varint,24,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"` + // denom is the denomination used on the EVM + Denom string `protobuf:"bytes,25,opt,name=denom,proto3" json:"denom,omitempty"` + // decimals is the real decimal precision of the denomination used on the EVM + Decimals uint64 `protobuf:"varint,26,opt,name=decimals,proto3" json:"decimals,omitempty"` } func (x *ChainConfig) Reset() { @@ -8354,6 +8526,27 @@ func (x *ChainConfig) GetCancunBlock() string { return "" } +func (x *ChainConfig) GetChainId() uint64 { + if x != nil { + return x.ChainId + } + return 0 +} + +func (x *ChainConfig) GetDenom() string { + if x != nil { + return x.Denom + } + return "" +} + +func (x *ChainConfig) GetDecimals() uint64 { + if x != nil { + return x.Decimals + } + return 0 +} + // State represents a single Storage key value pair item. type State struct { state protoimpl.MessageState @@ -8884,7 +9077,7 @@ var file_os_evm_v1_evm_proto_rawDesc = []byte{ 0x73, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x6f, 0x6c, 0x4c, 0x69, 0x73, 0x74, 0xf2, 0xde, 0x1f, 0x1a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x6f, 0x6c, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x22, 0x52, 0x11, 0x61, 0x63, 0x63, 0x65, - 0x73, 0x73, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x6f, 0x6c, 0x4c, 0x69, 0x73, 0x74, 0x22, 0xfd, 0x0e, + 0x73, 0x73, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x6f, 0x6c, 0x4c, 0x69, 0x73, 0x74, 0x22, 0xca, 0x0f, 0x0a, 0x0b, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x5c, 0x0a, 0x0f, 0x68, 0x6f, 0x6d, 0x65, 0x73, 0x74, 0x65, 0x61, 0x64, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x33, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, @@ -8999,118 +9192,123 @@ var file_os_evm_v1_evm_proto_rawDesc = []byte{ 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x13, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x61, 0x6e, 0x63, 0x75, 0x6e, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x22, 0x52, 0x0b, 0x63, 0x61, 0x6e, 0x63, - 0x75, 0x6e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4a, 0x04, 0x08, 0x0e, 0x10, 0x0f, 0x4a, 0x04, 0x08, - 0x0f, 0x10, 0x10, 0x4a, 0x04, 0x08, 0x10, 0x10, 0x11, 0x4a, 0x04, 0x08, 0x13, 0x10, 0x14, 0x52, - 0x0d, 0x79, 0x6f, 0x6c, 0x6f, 0x5f, 0x76, 0x33, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x0b, - 0x65, 0x77, 0x61, 0x73, 0x6d, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x0e, 0x63, 0x61, 0x74, - 0x61, 0x6c, 0x79, 0x73, 0x74, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x10, 0x6d, 0x65, 0x72, - 0x67, 0x65, 0x5f, 0x66, 0x6f, 0x72, 0x6b, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x22, 0x2f, 0x0a, - 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, - 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x49, - 0x0a, 0x0f, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x6f, 0x67, - 0x73, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x68, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x02, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x6f, 0x67, 0x52, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x22, 0xca, 0x02, 0x0a, 0x03, 0x4c, 0x6f, - 0x67, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x74, - 0x6f, 0x70, 0x69, 0x63, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x74, 0x6f, 0x70, - 0x69, 0x63, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x32, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, - 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x42, 0x0f, 0xea, - 0xde, 0x1f, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x52, 0x0b, - 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x2c, 0x0a, 0x07, 0x74, - 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, 0x13, 0xea, 0xde, - 0x1f, 0x0f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x61, 0x73, - 0x68, 0x52, 0x06, 0x74, 0x78, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x08, 0x74, 0x78, 0x5f, - 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, 0x42, 0x14, 0xea, 0xde, 0x1f, - 0x10, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, - 0x78, 0x52, 0x07, 0x74, 0x78, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x2c, 0x0a, 0x0a, 0x62, 0x6c, - 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0d, - 0xea, 0xde, 0x1f, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x52, 0x09, 0x62, - 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x05, 0x69, 0x6e, 0x64, 0x65, - 0x78, 0x18, 0x08, 0x20, 0x01, 0x28, 0x04, 0x42, 0x0c, 0xea, 0xde, 0x1f, 0x08, 0x6c, 0x6f, 0x67, - 0x49, 0x6e, 0x64, 0x65, 0x78, 0x52, 0x05, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x18, 0x0a, 0x07, - 0x72, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x72, - 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x64, 0x22, 0x89, 0x02, 0x0a, 0x08, 0x54, 0x78, 0x52, 0x65, 0x73, - 0x75, 0x6c, 0x74, 0x12, 0x46, 0x0a, 0x10, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, - 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1b, 0xf2, - 0xde, 0x1f, 0x17, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, - 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x52, 0x0f, 0x63, 0x6f, 0x6e, 0x74, - 0x72, 0x61, 0x63, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x62, - 0x6c, 0x6f, 0x6f, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x62, 0x6c, 0x6f, 0x6f, - 0x6d, 0x12, 0x50, 0x0a, 0x07, 0x74, 0x78, 0x5f, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x54, - 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x6f, 0x67, 0x73, 0x42, 0x1b, - 0xc8, 0xde, 0x1f, 0x00, 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x74, 0x78, - 0x5f, 0x6c, 0x6f, 0x67, 0x73, 0x22, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x74, 0x78, 0x4c, - 0x6f, 0x67, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x72, 0x65, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, - 0x52, 0x03, 0x72, 0x65, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x65, - 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x65, - 0x64, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x61, 0x73, 0x5f, 0x75, 0x73, 0x65, 0x64, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x61, 0x73, 0x55, 0x73, 0x65, 0x64, 0x3a, 0x04, 0x88, 0xa0, - 0x1f, 0x00, 0x22, 0x61, 0x0a, 0x0b, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x75, 0x70, 0x6c, - 0x65, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x32, 0x0a, 0x0c, 0x73, - 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, - 0x09, 0x42, 0x0f, 0xea, 0xde, 0x1f, 0x0b, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x4b, 0x65, - 0x79, 0x73, 0x52, 0x0b, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x4b, 0x65, 0x79, 0x73, 0x3a, - 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x22, 0x99, 0x04, 0x0a, 0x0b, 0x54, 0x72, 0x61, 0x63, 0x65, 0x43, - 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x72, 0x61, 0x63, 0x65, 0x72, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x72, 0x61, 0x63, 0x65, 0x72, 0x12, 0x18, 0x0a, - 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, - 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x65, 0x78, 0x65, - 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x72, 0x65, 0x65, 0x78, 0x65, 0x63, 0x12, - 0x35, 0x0a, 0x0d, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x73, 0x74, 0x61, 0x63, 0x6b, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x42, 0x10, 0xea, 0xde, 0x1f, 0x0c, 0x64, 0x69, 0x73, 0x61, - 0x62, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x52, 0x0c, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, - 0x65, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x12, 0x3b, 0x0a, 0x0f, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, - 0x65, 0x5f, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x42, - 0x12, 0xea, 0xde, 0x1f, 0x0e, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, - 0x61, 0x67, 0x65, 0x52, 0x0e, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, - 0x61, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x64, 0x65, 0x62, 0x75, 0x67, 0x18, 0x08, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x05, 0x64, 0x65, 0x62, 0x75, 0x67, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, - 0x69, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, - 0x34, 0x0a, 0x09, 0x6f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64, 0x65, 0x73, 0x18, 0x0a, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x68, 0x61, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x09, 0x6f, 0x76, 0x65, 0x72, - 0x72, 0x69, 0x64, 0x65, 0x73, 0x12, 0x35, 0x0a, 0x0d, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x5f, - 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x08, 0x42, 0x10, 0xea, 0xde, - 0x1f, 0x0c, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x52, 0x0c, - 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x12, 0x42, 0x0a, 0x12, - 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x5f, 0x64, 0x61, - 0x74, 0x61, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x42, 0x14, 0xea, 0xde, 0x1f, 0x10, 0x65, 0x6e, - 0x61, 0x62, 0x6c, 0x65, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x44, 0x61, 0x74, 0x61, 0x52, 0x10, - 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x44, 0x61, 0x74, 0x61, - 0x12, 0x3e, 0x0a, 0x12, 0x74, 0x72, 0x61, 0x63, 0x65, 0x72, 0x5f, 0x6a, 0x73, 0x6f, 0x6e, 0x5f, - 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x42, 0x10, 0xea, 0xde, - 0x1f, 0x0c, 0x74, 0x72, 0x61, 0x63, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x10, - 0x74, 0x72, 0x61, 0x63, 0x65, 0x72, 0x4a, 0x73, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, - 0x4a, 0x04, 0x08, 0x04, 0x10, 0x05, 0x4a, 0x04, 0x08, 0x07, 0x10, 0x08, 0x52, 0x0e, 0x64, 0x69, - 0x73, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x52, 0x13, 0x64, 0x69, - 0x73, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x5f, 0x64, 0x61, 0x74, - 0x61, 0x2a, 0xc0, 0x01, 0x0a, 0x0a, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x79, 0x70, 0x65, - 0x12, 0x3c, 0x0a, 0x1a, 0x41, 0x43, 0x43, 0x45, 0x53, 0x53, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, - 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x4c, 0x45, 0x53, 0x53, 0x10, 0x00, - 0x1a, 0x1c, 0x8a, 0x9d, 0x20, 0x18, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x79, 0x70, 0x65, - 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x6c, 0x65, 0x73, 0x73, 0x12, 0x34, - 0x0a, 0x16, 0x41, 0x43, 0x43, 0x45, 0x53, 0x53, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, - 0x53, 0x54, 0x52, 0x49, 0x43, 0x54, 0x45, 0x44, 0x10, 0x01, 0x1a, 0x18, 0x8a, 0x9d, 0x20, 0x14, - 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x74, 0x72, 0x69, - 0x63, 0x74, 0x65, 0x64, 0x12, 0x38, 0x0a, 0x18, 0x41, 0x43, 0x43, 0x45, 0x53, 0x53, 0x5f, 0x54, - 0x59, 0x50, 0x45, 0x5f, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x45, 0x44, - 0x10, 0x02, 0x1a, 0x1a, 0x8a, 0x9d, 0x20, 0x16, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x79, - 0x70, 0x65, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x65, 0x64, 0x1a, 0x04, - 0x88, 0xa3, 0x1e, 0x00, 0x42, 0x81, 0x01, 0x0a, 0x0d, 0x63, 0x6f, 0x6d, 0x2e, 0x6f, 0x73, 0x2e, - 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x42, 0x08, 0x45, 0x76, 0x6d, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x50, 0x01, 0x5a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, - 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6f, 0x73, 0x2f, 0x65, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x3b, 0x65, - 0x76, 0x6d, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4f, 0x45, 0x58, 0xaa, 0x02, 0x09, 0x4f, 0x73, 0x2e, - 0x45, 0x76, 0x6d, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x09, 0x4f, 0x73, 0x5c, 0x45, 0x76, 0x6d, 0x5c, - 0x56, 0x31, 0xe2, 0x02, 0x15, 0x4f, 0x73, 0x5c, 0x45, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x5c, 0x47, - 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0b, 0x4f, 0x73, 0x3a, - 0x3a, 0x45, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x75, 0x6e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x12, 0x19, 0x0a, 0x08, 0x63, 0x68, 0x61, 0x69, 0x6e, + 0x5f, 0x69, 0x64, 0x18, 0x18, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x63, 0x68, 0x61, 0x69, 0x6e, + 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x18, 0x19, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x05, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x12, 0x1a, 0x0a, 0x08, 0x64, 0x65, 0x63, 0x69, + 0x6d, 0x61, 0x6c, 0x73, 0x18, 0x1a, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x64, 0x65, 0x63, 0x69, + 0x6d, 0x61, 0x6c, 0x73, 0x4a, 0x04, 0x08, 0x0e, 0x10, 0x0f, 0x4a, 0x04, 0x08, 0x0f, 0x10, 0x10, + 0x4a, 0x04, 0x08, 0x10, 0x10, 0x11, 0x4a, 0x04, 0x08, 0x13, 0x10, 0x14, 0x52, 0x0d, 0x79, 0x6f, + 0x6c, 0x6f, 0x5f, 0x76, 0x33, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x0b, 0x65, 0x77, 0x61, + 0x73, 0x6d, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x0e, 0x63, 0x61, 0x74, 0x61, 0x6c, 0x79, + 0x73, 0x74, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x10, 0x6d, 0x65, 0x72, 0x67, 0x65, 0x5f, + 0x66, 0x6f, 0x72, 0x6b, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x22, 0x2f, 0x0a, 0x05, 0x53, 0x74, + 0x61, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x49, 0x0a, 0x0f, 0x54, + 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x6f, 0x67, 0x73, 0x12, 0x12, + 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x68, 0x61, + 0x73, 0x68, 0x12, 0x22, 0x0a, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x0e, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, + 0x52, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x22, 0xca, 0x02, 0x0a, 0x03, 0x4c, 0x6f, 0x67, 0x12, 0x18, + 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x6f, 0x70, 0x69, + 0x63, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x74, 0x6f, 0x70, 0x69, 0x63, 0x73, + 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, + 0x64, 0x61, 0x74, 0x61, 0x12, 0x32, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, + 0x6d, 0x62, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x42, 0x0f, 0xea, 0xde, 0x1f, 0x0b, + 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x52, 0x0b, 0x62, 0x6c, 0x6f, + 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x2c, 0x0a, 0x07, 0x74, 0x78, 0x5f, 0x68, + 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, 0x13, 0xea, 0xde, 0x1f, 0x0f, 0x74, + 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x61, 0x73, 0x68, 0x52, 0x06, + 0x74, 0x78, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x08, 0x74, 0x78, 0x5f, 0x69, 0x6e, 0x64, + 0x65, 0x78, 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, 0x42, 0x14, 0xea, 0xde, 0x1f, 0x10, 0x74, 0x72, + 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x52, 0x07, + 0x74, 0x78, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x2c, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0d, 0xea, 0xde, 0x1f, + 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, + 0x6b, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x05, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x04, 0x42, 0x0c, 0xea, 0xde, 0x1f, 0x08, 0x6c, 0x6f, 0x67, 0x49, 0x6e, 0x64, + 0x65, 0x78, 0x52, 0x05, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x65, 0x6d, + 0x6f, 0x76, 0x65, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x72, 0x65, 0x6d, 0x6f, + 0x76, 0x65, 0x64, 0x22, 0x89, 0x02, 0x0a, 0x08, 0x54, 0x78, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, + 0x12, 0x46, 0x0a, 0x10, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x61, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1b, 0xf2, 0xde, 0x1f, 0x17, + 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x61, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x52, 0x0f, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, + 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x62, 0x6c, 0x6f, 0x6f, + 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x62, 0x6c, 0x6f, 0x6f, 0x6d, 0x12, 0x50, + 0x0a, 0x07, 0x74, 0x78, 0x5f, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1a, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x72, 0x61, 0x6e, + 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x6f, 0x67, 0x73, 0x42, 0x1b, 0xc8, 0xde, 0x1f, + 0x00, 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x74, 0x78, 0x5f, 0x6c, 0x6f, + 0x67, 0x73, 0x22, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x74, 0x78, 0x4c, 0x6f, 0x67, 0x73, + 0x12, 0x10, 0x0a, 0x03, 0x72, 0x65, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x72, + 0x65, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x65, 0x64, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x65, 0x64, 0x12, 0x19, + 0x0a, 0x08, 0x67, 0x61, 0x73, 0x5f, 0x75, 0x73, 0x65, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, + 0x52, 0x07, 0x67, 0x61, 0x73, 0x55, 0x73, 0x65, 0x64, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x22, + 0x61, 0x0a, 0x0b, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x75, 0x70, 0x6c, 0x65, 0x12, 0x18, + 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x32, 0x0a, 0x0c, 0x73, 0x74, 0x6f, 0x72, + 0x61, 0x67, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x42, 0x0f, + 0xea, 0xde, 0x1f, 0x0b, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x4b, 0x65, 0x79, 0x73, 0x52, + 0x0b, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x4b, 0x65, 0x79, 0x73, 0x3a, 0x04, 0x88, 0xa0, + 0x1f, 0x00, 0x22, 0x99, 0x04, 0x0a, 0x0b, 0x54, 0x72, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, + 0x69, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x72, 0x61, 0x63, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x06, 0x74, 0x72, 0x61, 0x63, 0x65, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x74, 0x69, + 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x74, 0x69, 0x6d, + 0x65, 0x6f, 0x75, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x65, 0x78, 0x65, 0x63, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x72, 0x65, 0x65, 0x78, 0x65, 0x63, 0x12, 0x35, 0x0a, 0x0d, + 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x08, 0x42, 0x10, 0xea, 0xde, 0x1f, 0x0c, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, + 0x53, 0x74, 0x61, 0x63, 0x6b, 0x52, 0x0c, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x53, 0x74, + 0x61, 0x63, 0x6b, 0x12, 0x3b, 0x0a, 0x0f, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x73, + 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x42, 0x12, 0xea, 0xde, + 0x1f, 0x0e, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, + 0x52, 0x0e, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, + 0x12, 0x14, 0x0a, 0x05, 0x64, 0x65, 0x62, 0x75, 0x67, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x05, 0x64, 0x65, 0x62, 0x75, 0x67, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x34, 0x0a, 0x09, + 0x6f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64, 0x65, 0x73, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x16, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x68, 0x61, 0x69, + 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x09, 0x6f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64, + 0x65, 0x73, 0x12, 0x35, 0x0a, 0x0d, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x6d, 0x65, 0x6d, + 0x6f, 0x72, 0x79, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x08, 0x42, 0x10, 0xea, 0xde, 0x1f, 0x0c, 0x65, + 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x52, 0x0c, 0x65, 0x6e, 0x61, + 0x62, 0x6c, 0x65, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x12, 0x42, 0x0a, 0x12, 0x65, 0x6e, 0x61, + 0x62, 0x6c, 0x65, 0x5f, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, + 0x0c, 0x20, 0x01, 0x28, 0x08, 0x42, 0x14, 0xea, 0xde, 0x1f, 0x10, 0x65, 0x6e, 0x61, 0x62, 0x6c, + 0x65, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x44, 0x61, 0x74, 0x61, 0x52, 0x10, 0x65, 0x6e, 0x61, + 0x62, 0x6c, 0x65, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x44, 0x61, 0x74, 0x61, 0x12, 0x3e, 0x0a, + 0x12, 0x74, 0x72, 0x61, 0x63, 0x65, 0x72, 0x5f, 0x6a, 0x73, 0x6f, 0x6e, 0x5f, 0x63, 0x6f, 0x6e, + 0x66, 0x69, 0x67, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x42, 0x10, 0xea, 0xde, 0x1f, 0x0c, 0x74, + 0x72, 0x61, 0x63, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x10, 0x74, 0x72, 0x61, + 0x63, 0x65, 0x72, 0x4a, 0x73, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x4a, 0x04, 0x08, + 0x04, 0x10, 0x05, 0x4a, 0x04, 0x08, 0x07, 0x10, 0x08, 0x52, 0x0e, 0x64, 0x69, 0x73, 0x61, 0x62, + 0x6c, 0x65, 0x5f, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x52, 0x13, 0x64, 0x69, 0x73, 0x61, 0x62, + 0x6c, 0x65, 0x5f, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x2a, 0xc0, + 0x01, 0x0a, 0x0a, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x79, 0x70, 0x65, 0x12, 0x3c, 0x0a, + 0x1a, 0x41, 0x43, 0x43, 0x45, 0x53, 0x53, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x50, 0x45, 0x52, + 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x4c, 0x45, 0x53, 0x53, 0x10, 0x00, 0x1a, 0x1c, 0x8a, + 0x9d, 0x20, 0x18, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x79, 0x70, 0x65, 0x50, 0x65, 0x72, + 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x6c, 0x65, 0x73, 0x73, 0x12, 0x34, 0x0a, 0x16, 0x41, + 0x43, 0x43, 0x45, 0x53, 0x53, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, 0x53, 0x54, 0x52, + 0x49, 0x43, 0x54, 0x45, 0x44, 0x10, 0x01, 0x1a, 0x18, 0x8a, 0x9d, 0x20, 0x14, 0x41, 0x63, 0x63, + 0x65, 0x73, 0x73, 0x54, 0x79, 0x70, 0x65, 0x52, 0x65, 0x73, 0x74, 0x72, 0x69, 0x63, 0x74, 0x65, + 0x64, 0x12, 0x38, 0x0a, 0x18, 0x41, 0x43, 0x43, 0x45, 0x53, 0x53, 0x5f, 0x54, 0x59, 0x50, 0x45, + 0x5f, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x45, 0x44, 0x10, 0x02, 0x1a, + 0x1a, 0x8a, 0x9d, 0x20, 0x16, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x79, 0x70, 0x65, 0x50, + 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x65, 0x64, 0x1a, 0x04, 0x88, 0xa3, 0x1e, + 0x00, 0x42, 0x81, 0x01, 0x0a, 0x0d, 0x63, 0x6f, 0x6d, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, + 0x2e, 0x76, 0x31, 0x42, 0x08, 0x45, 0x76, 0x6d, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, + 0x69, 0x2f, 0x6f, 0x73, 0x2f, 0x65, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x3b, 0x65, 0x76, 0x6d, 0x76, + 0x31, 0xa2, 0x02, 0x03, 0x4f, 0x45, 0x58, 0xaa, 0x02, 0x09, 0x4f, 0x73, 0x2e, 0x45, 0x76, 0x6d, + 0x2e, 0x56, 0x31, 0xca, 0x02, 0x09, 0x4f, 0x73, 0x5c, 0x45, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0xe2, + 0x02, 0x15, 0x4f, 0x73, 0x5c, 0x45, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, + 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0b, 0x4f, 0x73, 0x3a, 0x3a, 0x45, 0x76, + 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/api/os/evm/v1/msg.go b/api/os/evm/v1/msg.go index 4fb830cb..f81e401b 100644 --- a/api/os/evm/v1/msg.go +++ b/api/os/evm/v1/msg.go @@ -13,10 +13,13 @@ import ( // supportedTxs holds the Ethereum transaction types // supported by Evmos -var supportedTxs = map[string]TxDataV2{ - "/os.evm.v1.DynamicFeeTx": &DynamicFeeTx{}, - "/os.evm.v1.AccessListTx": &AccessListTx{}, - "/os.evm.v1.LegacyTx": &LegacyTx{}, +// +// Use a function to return a new pointer and avoid +// possible reuse or racing conditions when using the same pointer +var supportedTxs = map[string]func() TxDataV2{ + "/os.evm.v1.DynamicFeeTx": func() TxDataV2 { return &DynamicFeeTx{} }, + "/os.evm.v1.AccessListTx": func() TxDataV2 { return &AccessListTx{} }, + "/os.evm.v1.LegacyTx": func() TxDataV2 { return &LegacyTx{} }, } // getSender extracts the sender address from the signature values using the latest signer for the given chainID. @@ -37,10 +40,11 @@ func GetSigners(msg protov2.Message) ([][]byte, error) { return nil, fmt.Errorf("invalid type, expected MsgEthereumTx and got %T", msg) } - txData, found := supportedTxs[msgEthTx.Data.TypeUrl] + txDataFn, found := supportedTxs[msgEthTx.Data.TypeUrl] if !found { return nil, fmt.Errorf("invalid TypeUrl %s", msgEthTx.Data.TypeUrl) } + txData := txDataFn() // msgEthTx.Data is a message (DynamicFeeTx, LegacyTx or AccessListTx) if err := msgEthTx.Data.UnmarshalTo(txData); err != nil { diff --git a/api/os/evm/v1/query.pulsar.go b/api/os/evm/v1/query.pulsar.go index df7335da..5049c23c 100644 --- a/api/os/evm/v1/query.pulsar.go +++ b/api/os/evm/v1/query.pulsar.go @@ -18,25 +18,23 @@ import ( ) var ( - md_QueryAccountRequest protoreflect.MessageDescriptor - fd_QueryAccountRequest_address protoreflect.FieldDescriptor + md_QueryConfigRequest protoreflect.MessageDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryAccountRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryAccountRequest") - fd_QueryAccountRequest_address = md_QueryAccountRequest.Fields().ByName("address") + md_QueryConfigRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryConfigRequest") } -var _ protoreflect.Message = (*fastReflection_QueryAccountRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryConfigRequest)(nil) -type fastReflection_QueryAccountRequest QueryAccountRequest +type fastReflection_QueryConfigRequest QueryConfigRequest -func (x *QueryAccountRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryAccountRequest)(x) +func (x *QueryConfigRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryConfigRequest)(x) } -func (x *QueryAccountRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryConfigRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[0] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -48,43 +46,43 @@ func (x *QueryAccountRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryAccountRequest_messageType fastReflection_QueryAccountRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryAccountRequest_messageType{} +var _fastReflection_QueryConfigRequest_messageType fastReflection_QueryConfigRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryConfigRequest_messageType{} -type fastReflection_QueryAccountRequest_messageType struct{} +type fastReflection_QueryConfigRequest_messageType struct{} -func (x fastReflection_QueryAccountRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryAccountRequest)(nil) +func (x fastReflection_QueryConfigRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryConfigRequest)(nil) } -func (x fastReflection_QueryAccountRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryAccountRequest) +func (x fastReflection_QueryConfigRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryConfigRequest) } -func (x fastReflection_QueryAccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryAccountRequest +func (x fastReflection_QueryConfigRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryConfigRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryAccountRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryAccountRequest +func (x *fastReflection_QueryConfigRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryConfigRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryAccountRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryAccountRequest_messageType +func (x *fastReflection_QueryConfigRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryConfigRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryAccountRequest) New() protoreflect.Message { - return new(fastReflection_QueryAccountRequest) +func (x *fastReflection_QueryConfigRequest) New() protoreflect.Message { + return new(fastReflection_QueryConfigRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryAccountRequest) Interface() protoreflect.ProtoMessage { - return (*QueryAccountRequest)(x) +func (x *fastReflection_QueryConfigRequest) Interface() protoreflect.ProtoMessage { + return (*QueryConfigRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -92,13 +90,7 @@ func (x *fastReflection_QueryAccountRequest) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryAccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Address != "" { - value := protoreflect.ValueOfString(x.Address) - if !f(fd_QueryAccountRequest_address, value) { - return - } - } +func (x *fastReflection_QueryConfigRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { } // Has reports whether a field is populated. @@ -112,15 +104,13 @@ func (x *fastReflection_QueryAccountRequest) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryAccountRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryConfigRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryAccountRequest.address": - return x.Address != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigRequest does not contain field %s", fd.FullName())) } } @@ -130,15 +120,13 @@ func (x *fastReflection_QueryAccountRequest) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryAccountRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryConfigRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryAccountRequest.address": - x.Address = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigRequest does not contain field %s", fd.FullName())) } } @@ -148,16 +136,13 @@ func (x *fastReflection_QueryAccountRequest) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryAccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryConfigRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryAccountRequest.address": - value := x.Address - return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigRequest does not contain field %s", descriptor.FullName())) } } @@ -171,15 +156,13 @@ func (x *fastReflection_QueryAccountRequest) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryAccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryConfigRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryAccountRequest.address": - x.Address = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigRequest does not contain field %s", fd.FullName())) } } @@ -193,40 +176,36 @@ func (x *fastReflection_QueryAccountRequest) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryAccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryConfigRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryAccountRequest.address": - panic(fmt.Errorf("field address of message os.evm.v1.QueryAccountRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryAccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryConfigRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryAccountRequest.address": - return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryAccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryConfigRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryAccountRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryConfigRequest", d.FullName())) } panic("unreachable") } @@ -234,7 +213,7 @@ func (x *fastReflection_QueryAccountRequest) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryAccountRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryConfigRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -245,7 +224,7 @@ func (x *fastReflection_QueryAccountRequest) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryAccountRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryConfigRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -257,7 +236,7 @@ func (x *fastReflection_QueryAccountRequest) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryAccountRequest) IsValid() bool { +func (x *fastReflection_QueryConfigRequest) IsValid() bool { return x != nil } @@ -267,9 +246,9 @@ func (x *fastReflection_QueryAccountRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryAccountRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryConfigRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryAccountRequest) + x := input.Message.Interface().(*QueryConfigRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -281,10 +260,6 @@ func (x *fastReflection_QueryAccountRequest) ProtoMethods() *protoiface.Methods var n int var l int _ = l - l = len(x.Address) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -295,7 +270,7 @@ func (x *fastReflection_QueryAccountRequest) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryAccountRequest) + x := input.Message.Interface().(*QueryConfigRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -314,13 +289,6 @@ func (x *fastReflection_QueryAccountRequest) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Address) > 0 { - i -= len(x.Address) - copy(dAtA[i:], x.Address) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) - i-- - dAtA[i] = 0xa - } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) } else { @@ -332,7 +300,7 @@ func (x *fastReflection_QueryAccountRequest) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryAccountRequest) + x := input.Message.Interface().(*QueryConfigRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -364,44 +332,12 @@ func (x *fastReflection_QueryAccountRequest) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryAccountRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryConfigRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryAccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryConfigRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 1: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.Address = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -438,29 +374,25 @@ func (x *fastReflection_QueryAccountRequest) ProtoMethods() *protoiface.Methods } var ( - md_QueryAccountResponse protoreflect.MessageDescriptor - fd_QueryAccountResponse_balance protoreflect.FieldDescriptor - fd_QueryAccountResponse_code_hash protoreflect.FieldDescriptor - fd_QueryAccountResponse_nonce protoreflect.FieldDescriptor + md_QueryConfigResponse protoreflect.MessageDescriptor + fd_QueryConfigResponse_config protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryAccountResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryAccountResponse") - fd_QueryAccountResponse_balance = md_QueryAccountResponse.Fields().ByName("balance") - fd_QueryAccountResponse_code_hash = md_QueryAccountResponse.Fields().ByName("code_hash") - fd_QueryAccountResponse_nonce = md_QueryAccountResponse.Fields().ByName("nonce") + md_QueryConfigResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryConfigResponse") + fd_QueryConfigResponse_config = md_QueryConfigResponse.Fields().ByName("config") } -var _ protoreflect.Message = (*fastReflection_QueryAccountResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryConfigResponse)(nil) -type fastReflection_QueryAccountResponse QueryAccountResponse +type fastReflection_QueryConfigResponse QueryConfigResponse -func (x *QueryAccountResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryAccountResponse)(x) +func (x *QueryConfigResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryConfigResponse)(x) } -func (x *QueryAccountResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryConfigResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[1] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -472,43 +404,43 @@ func (x *QueryAccountResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryAccountResponse_messageType fastReflection_QueryAccountResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryAccountResponse_messageType{} +var _fastReflection_QueryConfigResponse_messageType fastReflection_QueryConfigResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryConfigResponse_messageType{} -type fastReflection_QueryAccountResponse_messageType struct{} +type fastReflection_QueryConfigResponse_messageType struct{} -func (x fastReflection_QueryAccountResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryAccountResponse)(nil) +func (x fastReflection_QueryConfigResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryConfigResponse)(nil) } -func (x fastReflection_QueryAccountResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryAccountResponse) +func (x fastReflection_QueryConfigResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryConfigResponse) } -func (x fastReflection_QueryAccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryAccountResponse +func (x fastReflection_QueryConfigResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryConfigResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryAccountResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryAccountResponse +func (x *fastReflection_QueryConfigResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryConfigResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryAccountResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryAccountResponse_messageType +func (x *fastReflection_QueryConfigResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryConfigResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryAccountResponse) New() protoreflect.Message { - return new(fastReflection_QueryAccountResponse) +func (x *fastReflection_QueryConfigResponse) New() protoreflect.Message { + return new(fastReflection_QueryConfigResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryAccountResponse) Interface() protoreflect.ProtoMessage { - return (*QueryAccountResponse)(x) +func (x *fastReflection_QueryConfigResponse) Interface() protoreflect.ProtoMessage { + return (*QueryConfigResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -516,22 +448,10 @@ func (x *fastReflection_QueryAccountResponse) Interface() protoreflect.ProtoMess // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryAccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Balance != "" { - value := protoreflect.ValueOfString(x.Balance) - if !f(fd_QueryAccountResponse_balance, value) { - return - } - } - if x.CodeHash != "" { - value := protoreflect.ValueOfString(x.CodeHash) - if !f(fd_QueryAccountResponse_code_hash, value) { - return - } - } - if x.Nonce != uint64(0) { - value := protoreflect.ValueOfUint64(x.Nonce) - if !f(fd_QueryAccountResponse_nonce, value) { +func (x *fastReflection_QueryConfigResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Config != nil { + value := protoreflect.ValueOfMessage(x.Config.ProtoReflect()) + if !f(fd_QueryConfigResponse_config, value) { return } } @@ -548,19 +468,15 @@ func (x *fastReflection_QueryAccountResponse) Range(f func(protoreflect.FieldDes // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryAccountResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryConfigResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryAccountResponse.balance": - return x.Balance != "" - case "os.evm.v1.QueryAccountResponse.code_hash": - return x.CodeHash != "" - case "os.evm.v1.QueryAccountResponse.nonce": - return x.Nonce != uint64(0) + case "os.evm.v1.QueryConfigResponse.config": + return x.Config != nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigResponse does not contain field %s", fd.FullName())) } } @@ -570,19 +486,15 @@ func (x *fastReflection_QueryAccountResponse) Has(fd protoreflect.FieldDescripto // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryAccountResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryConfigResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryAccountResponse.balance": - x.Balance = "" - case "os.evm.v1.QueryAccountResponse.code_hash": - x.CodeHash = "" - case "os.evm.v1.QueryAccountResponse.nonce": - x.Nonce = uint64(0) + case "os.evm.v1.QueryConfigResponse.config": + x.Config = nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigResponse does not contain field %s", fd.FullName())) } } @@ -592,22 +504,16 @@ func (x *fastReflection_QueryAccountResponse) Clear(fd protoreflect.FieldDescrip // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryAccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryConfigResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryAccountResponse.balance": - value := x.Balance - return protoreflect.ValueOfString(value) - case "os.evm.v1.QueryAccountResponse.code_hash": - value := x.CodeHash - return protoreflect.ValueOfString(value) - case "os.evm.v1.QueryAccountResponse.nonce": - value := x.Nonce - return protoreflect.ValueOfUint64(value) + case "os.evm.v1.QueryConfigResponse.config": + value := x.Config + return protoreflect.ValueOfMessage(value.ProtoReflect()) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigResponse does not contain field %s", descriptor.FullName())) } } @@ -621,19 +527,15 @@ func (x *fastReflection_QueryAccountResponse) Get(descriptor protoreflect.FieldD // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryAccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryConfigResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryAccountResponse.balance": - x.Balance = value.Interface().(string) - case "os.evm.v1.QueryAccountResponse.code_hash": - x.CodeHash = value.Interface().(string) - case "os.evm.v1.QueryAccountResponse.nonce": - x.Nonce = value.Uint() + case "os.evm.v1.QueryConfigResponse.config": + x.Config = value.Message().Interface().(*ChainConfig) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigResponse does not contain field %s", fd.FullName())) } } @@ -647,48 +549,44 @@ func (x *fastReflection_QueryAccountResponse) Set(fd protoreflect.FieldDescripto // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryAccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryConfigResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryAccountResponse.balance": - panic(fmt.Errorf("field balance of message os.evm.v1.QueryAccountResponse is not mutable")) - case "os.evm.v1.QueryAccountResponse.code_hash": - panic(fmt.Errorf("field code_hash of message os.evm.v1.QueryAccountResponse is not mutable")) - case "os.evm.v1.QueryAccountResponse.nonce": - panic(fmt.Errorf("field nonce of message os.evm.v1.QueryAccountResponse is not mutable")) + case "os.evm.v1.QueryConfigResponse.config": + if x.Config == nil { + x.Config = new(ChainConfig) + } + return protoreflect.ValueOfMessage(x.Config.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryAccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryConfigResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryAccountResponse.balance": - return protoreflect.ValueOfString("") - case "os.evm.v1.QueryAccountResponse.code_hash": - return protoreflect.ValueOfString("") - case "os.evm.v1.QueryAccountResponse.nonce": - return protoreflect.ValueOfUint64(uint64(0)) + case "os.evm.v1.QueryConfigResponse.config": + m := new(ChainConfig) + return protoreflect.ValueOfMessage(m.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryConfigResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryConfigResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryAccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryConfigResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryAccountResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryConfigResponse", d.FullName())) } panic("unreachable") } @@ -696,7 +594,7 @@ func (x *fastReflection_QueryAccountResponse) WhichOneof(d protoreflect.OneofDes // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryAccountResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryConfigResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -707,7 +605,7 @@ func (x *fastReflection_QueryAccountResponse) GetUnknown() protoreflect.RawField // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryAccountResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryConfigResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -719,7 +617,7 @@ func (x *fastReflection_QueryAccountResponse) SetUnknown(fields protoreflect.Raw // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryAccountResponse) IsValid() bool { +func (x *fastReflection_QueryConfigResponse) IsValid() bool { return x != nil } @@ -729,9 +627,9 @@ func (x *fastReflection_QueryAccountResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryConfigResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryAccountResponse) + x := input.Message.Interface().(*QueryConfigResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -743,17 +641,10 @@ func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - l = len(x.Balance) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } - l = len(x.CodeHash) - if l > 0 { + if x.Config != nil { + l = options.Size(x.Config) n += 1 + l + runtime.Sov(uint64(l)) } - if x.Nonce != 0 { - n += 1 + runtime.Sov(uint64(x.Nonce)) - } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -764,7 +655,7 @@ func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryAccountResponse) + x := input.Message.Interface().(*QueryConfigResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -783,24 +674,19 @@ func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if x.Nonce != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.Nonce)) + if x.Config != nil { + encoded, err := options.Marshal(x.Config) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) i-- - dAtA[i] = 0x18 - } - if len(x.CodeHash) > 0 { - i -= len(x.CodeHash) - copy(dAtA[i:], x.CodeHash) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CodeHash))) - i-- - dAtA[i] = 0x12 - } - if len(x.Balance) > 0 { - i -= len(x.Balance) - copy(dAtA[i:], x.Balance) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Balance))) - i-- - dAtA[i] = 0xa + dAtA[i] = 0xa } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) @@ -813,7 +699,7 @@ func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryAccountResponse) + x := input.Message.Interface().(*QueryConfigResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -845,17 +731,17 @@ func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryAccountResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryConfigResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryAccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryConfigResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Balance", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -865,75 +751,28 @@ func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Balance = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CodeHash", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + if x.Config == nil { + x.Config = &ChainConfig{} } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Config); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } - x.CodeHash = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: - if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Nonce", wireType) - } - x.Nonce = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - x.Nonce |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -970,25 +809,25 @@ func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods } var ( - md_QueryCosmosAccountRequest protoreflect.MessageDescriptor - fd_QueryCosmosAccountRequest_address protoreflect.FieldDescriptor + md_QueryAccountRequest protoreflect.MessageDescriptor + fd_QueryAccountRequest_address protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryCosmosAccountRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryCosmosAccountRequest") - fd_QueryCosmosAccountRequest_address = md_QueryCosmosAccountRequest.Fields().ByName("address") + md_QueryAccountRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryAccountRequest") + fd_QueryAccountRequest_address = md_QueryAccountRequest.Fields().ByName("address") } -var _ protoreflect.Message = (*fastReflection_QueryCosmosAccountRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryAccountRequest)(nil) -type fastReflection_QueryCosmosAccountRequest QueryCosmosAccountRequest +type fastReflection_QueryAccountRequest QueryAccountRequest -func (x *QueryCosmosAccountRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryCosmosAccountRequest)(x) +func (x *QueryAccountRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryAccountRequest)(x) } -func (x *QueryCosmosAccountRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryAccountRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1000,43 +839,43 @@ func (x *QueryCosmosAccountRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryCosmosAccountRequest_messageType fastReflection_QueryCosmosAccountRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryCosmosAccountRequest_messageType{} +var _fastReflection_QueryAccountRequest_messageType fastReflection_QueryAccountRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryAccountRequest_messageType{} -type fastReflection_QueryCosmosAccountRequest_messageType struct{} +type fastReflection_QueryAccountRequest_messageType struct{} -func (x fastReflection_QueryCosmosAccountRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryCosmosAccountRequest)(nil) +func (x fastReflection_QueryAccountRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryAccountRequest)(nil) } -func (x fastReflection_QueryCosmosAccountRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryCosmosAccountRequest) +func (x fastReflection_QueryAccountRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryAccountRequest) } -func (x fastReflection_QueryCosmosAccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryCosmosAccountRequest +func (x fastReflection_QueryAccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryAccountRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryCosmosAccountRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryCosmosAccountRequest +func (x *fastReflection_QueryAccountRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryAccountRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryCosmosAccountRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryCosmosAccountRequest_messageType +func (x *fastReflection_QueryAccountRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryAccountRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryCosmosAccountRequest) New() protoreflect.Message { - return new(fastReflection_QueryCosmosAccountRequest) +func (x *fastReflection_QueryAccountRequest) New() protoreflect.Message { + return new(fastReflection_QueryAccountRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryCosmosAccountRequest) Interface() protoreflect.ProtoMessage { - return (*QueryCosmosAccountRequest)(x) +func (x *fastReflection_QueryAccountRequest) Interface() protoreflect.ProtoMessage { + return (*QueryAccountRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -1044,10 +883,10 @@ func (x *fastReflection_QueryCosmosAccountRequest) Interface() protoreflect.Prot // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryCosmosAccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +func (x *fastReflection_QueryAccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { if x.Address != "" { value := protoreflect.ValueOfString(x.Address) - if !f(fd_QueryCosmosAccountRequest_address, value) { + if !f(fd_QueryAccountRequest_address, value) { return } } @@ -1064,15 +903,15 @@ func (x *fastReflection_QueryCosmosAccountRequest) Range(f func(protoreflect.Fie // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryCosmosAccountRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryAccountRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountRequest.address": + case "os.evm.v1.QueryAccountRequest.address": return x.Address != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) } } @@ -1082,15 +921,15 @@ func (x *fastReflection_QueryCosmosAccountRequest) Has(fd protoreflect.FieldDesc // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCosmosAccountRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryAccountRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountRequest.address": + case "os.evm.v1.QueryAccountRequest.address": x.Address = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) } } @@ -1100,16 +939,16 @@ func (x *fastReflection_QueryCosmosAccountRequest) Clear(fd protoreflect.FieldDe // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryCosmosAccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryAccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryCosmosAccountRequest.address": + case "os.evm.v1.QueryAccountRequest.address": value := x.Address return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", descriptor.FullName())) } } @@ -1123,15 +962,15 @@ func (x *fastReflection_QueryCosmosAccountRequest) Get(descriptor protoreflect.F // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCosmosAccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryAccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountRequest.address": + case "os.evm.v1.QueryAccountRequest.address": x.Address = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) } } @@ -1145,40 +984,40 @@ func (x *fastReflection_QueryCosmosAccountRequest) Set(fd protoreflect.FieldDesc // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCosmosAccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryAccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountRequest.address": - panic(fmt.Errorf("field address of message os.evm.v1.QueryCosmosAccountRequest is not mutable")) + case "os.evm.v1.QueryAccountRequest.address": + panic(fmt.Errorf("field address of message os.evm.v1.QueryAccountRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryCosmosAccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryAccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountRequest.address": + case "os.evm.v1.QueryAccountRequest.address": return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryCosmosAccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryAccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryCosmosAccountRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryAccountRequest", d.FullName())) } panic("unreachable") } @@ -1186,7 +1025,7 @@ func (x *fastReflection_QueryCosmosAccountRequest) WhichOneof(d protoreflect.One // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryCosmosAccountRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryAccountRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -1197,7 +1036,7 @@ func (x *fastReflection_QueryCosmosAccountRequest) GetUnknown() protoreflect.Raw // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCosmosAccountRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryAccountRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -1209,7 +1048,7 @@ func (x *fastReflection_QueryCosmosAccountRequest) SetUnknown(fields protoreflec // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryCosmosAccountRequest) IsValid() bool { +func (x *fastReflection_QueryAccountRequest) IsValid() bool { return x != nil } @@ -1219,9 +1058,9 @@ func (x *fastReflection_QueryCosmosAccountRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryCosmosAccountRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryAccountRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryCosmosAccountRequest) + x := input.Message.Interface().(*QueryAccountRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -1247,7 +1086,7 @@ func (x *fastReflection_QueryCosmosAccountRequest) ProtoMethods() *protoiface.Me } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryCosmosAccountRequest) + x := input.Message.Interface().(*QueryAccountRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -1284,7 +1123,7 @@ func (x *fastReflection_QueryCosmosAccountRequest) ProtoMethods() *protoiface.Me }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryCosmosAccountRequest) + x := input.Message.Interface().(*QueryAccountRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -1316,10 +1155,10 @@ func (x *fastReflection_QueryCosmosAccountRequest) ProtoMethods() *protoiface.Me fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCosmosAccountRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryAccountRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCosmosAccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryAccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -1390,29 +1229,29 @@ func (x *fastReflection_QueryCosmosAccountRequest) ProtoMethods() *protoiface.Me } var ( - md_QueryCosmosAccountResponse protoreflect.MessageDescriptor - fd_QueryCosmosAccountResponse_cosmos_address protoreflect.FieldDescriptor - fd_QueryCosmosAccountResponse_sequence protoreflect.FieldDescriptor - fd_QueryCosmosAccountResponse_account_number protoreflect.FieldDescriptor + md_QueryAccountResponse protoreflect.MessageDescriptor + fd_QueryAccountResponse_balance protoreflect.FieldDescriptor + fd_QueryAccountResponse_code_hash protoreflect.FieldDescriptor + fd_QueryAccountResponse_nonce protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryCosmosAccountResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryCosmosAccountResponse") - fd_QueryCosmosAccountResponse_cosmos_address = md_QueryCosmosAccountResponse.Fields().ByName("cosmos_address") - fd_QueryCosmosAccountResponse_sequence = md_QueryCosmosAccountResponse.Fields().ByName("sequence") - fd_QueryCosmosAccountResponse_account_number = md_QueryCosmosAccountResponse.Fields().ByName("account_number") + md_QueryAccountResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryAccountResponse") + fd_QueryAccountResponse_balance = md_QueryAccountResponse.Fields().ByName("balance") + fd_QueryAccountResponse_code_hash = md_QueryAccountResponse.Fields().ByName("code_hash") + fd_QueryAccountResponse_nonce = md_QueryAccountResponse.Fields().ByName("nonce") } -var _ protoreflect.Message = (*fastReflection_QueryCosmosAccountResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryAccountResponse)(nil) -type fastReflection_QueryCosmosAccountResponse QueryCosmosAccountResponse +type fastReflection_QueryAccountResponse QueryAccountResponse -func (x *QueryCosmosAccountResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryCosmosAccountResponse)(x) +func (x *QueryAccountResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryAccountResponse)(x) } -func (x *QueryCosmosAccountResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryAccountResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1424,43 +1263,43 @@ func (x *QueryCosmosAccountResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryCosmosAccountResponse_messageType fastReflection_QueryCosmosAccountResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryCosmosAccountResponse_messageType{} +var _fastReflection_QueryAccountResponse_messageType fastReflection_QueryAccountResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryAccountResponse_messageType{} -type fastReflection_QueryCosmosAccountResponse_messageType struct{} +type fastReflection_QueryAccountResponse_messageType struct{} -func (x fastReflection_QueryCosmosAccountResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryCosmosAccountResponse)(nil) +func (x fastReflection_QueryAccountResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryAccountResponse)(nil) } -func (x fastReflection_QueryCosmosAccountResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryCosmosAccountResponse) +func (x fastReflection_QueryAccountResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryAccountResponse) } -func (x fastReflection_QueryCosmosAccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryCosmosAccountResponse +func (x fastReflection_QueryAccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryAccountResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryCosmosAccountResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryCosmosAccountResponse +func (x *fastReflection_QueryAccountResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryAccountResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryCosmosAccountResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryCosmosAccountResponse_messageType +func (x *fastReflection_QueryAccountResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryAccountResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryCosmosAccountResponse) New() protoreflect.Message { - return new(fastReflection_QueryCosmosAccountResponse) +func (x *fastReflection_QueryAccountResponse) New() protoreflect.Message { + return new(fastReflection_QueryAccountResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryCosmosAccountResponse) Interface() protoreflect.ProtoMessage { - return (*QueryCosmosAccountResponse)(x) +func (x *fastReflection_QueryAccountResponse) Interface() protoreflect.ProtoMessage { + return (*QueryAccountResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -1468,22 +1307,22 @@ func (x *fastReflection_QueryCosmosAccountResponse) Interface() protoreflect.Pro // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryCosmosAccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.CosmosAddress != "" { - value := protoreflect.ValueOfString(x.CosmosAddress) - if !f(fd_QueryCosmosAccountResponse_cosmos_address, value) { +func (x *fastReflection_QueryAccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Balance != "" { + value := protoreflect.ValueOfString(x.Balance) + if !f(fd_QueryAccountResponse_balance, value) { return } } - if x.Sequence != uint64(0) { - value := protoreflect.ValueOfUint64(x.Sequence) - if !f(fd_QueryCosmosAccountResponse_sequence, value) { + if x.CodeHash != "" { + value := protoreflect.ValueOfString(x.CodeHash) + if !f(fd_QueryAccountResponse_code_hash, value) { return } } - if x.AccountNumber != uint64(0) { - value := protoreflect.ValueOfUint64(x.AccountNumber) - if !f(fd_QueryCosmosAccountResponse_account_number, value) { + if x.Nonce != uint64(0) { + value := protoreflect.ValueOfUint64(x.Nonce) + if !f(fd_QueryAccountResponse_nonce, value) { return } } @@ -1500,19 +1339,19 @@ func (x *fastReflection_QueryCosmosAccountResponse) Range(f func(protoreflect.Fi // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryCosmosAccountResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryAccountResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": - return x.CosmosAddress != "" - case "os.evm.v1.QueryCosmosAccountResponse.sequence": - return x.Sequence != uint64(0) - case "os.evm.v1.QueryCosmosAccountResponse.account_number": - return x.AccountNumber != uint64(0) + case "os.evm.v1.QueryAccountResponse.balance": + return x.Balance != "" + case "os.evm.v1.QueryAccountResponse.code_hash": + return x.CodeHash != "" + case "os.evm.v1.QueryAccountResponse.nonce": + return x.Nonce != uint64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) } } @@ -1522,19 +1361,19 @@ func (x *fastReflection_QueryCosmosAccountResponse) Has(fd protoreflect.FieldDes // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCosmosAccountResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryAccountResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": - x.CosmosAddress = "" - case "os.evm.v1.QueryCosmosAccountResponse.sequence": - x.Sequence = uint64(0) - case "os.evm.v1.QueryCosmosAccountResponse.account_number": - x.AccountNumber = uint64(0) + case "os.evm.v1.QueryAccountResponse.balance": + x.Balance = "" + case "os.evm.v1.QueryAccountResponse.code_hash": + x.CodeHash = "" + case "os.evm.v1.QueryAccountResponse.nonce": + x.Nonce = uint64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) } } @@ -1544,22 +1383,22 @@ func (x *fastReflection_QueryCosmosAccountResponse) Clear(fd protoreflect.FieldD // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryCosmosAccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryAccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": - value := x.CosmosAddress + case "os.evm.v1.QueryAccountResponse.balance": + value := x.Balance return protoreflect.ValueOfString(value) - case "os.evm.v1.QueryCosmosAccountResponse.sequence": - value := x.Sequence - return protoreflect.ValueOfUint64(value) - case "os.evm.v1.QueryCosmosAccountResponse.account_number": - value := x.AccountNumber + case "os.evm.v1.QueryAccountResponse.code_hash": + value := x.CodeHash + return protoreflect.ValueOfString(value) + case "os.evm.v1.QueryAccountResponse.nonce": + value := x.Nonce return protoreflect.ValueOfUint64(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", descriptor.FullName())) } } @@ -1573,19 +1412,19 @@ func (x *fastReflection_QueryCosmosAccountResponse) Get(descriptor protoreflect. // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCosmosAccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryAccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": - x.CosmosAddress = value.Interface().(string) - case "os.evm.v1.QueryCosmosAccountResponse.sequence": - x.Sequence = value.Uint() - case "os.evm.v1.QueryCosmosAccountResponse.account_number": - x.AccountNumber = value.Uint() + case "os.evm.v1.QueryAccountResponse.balance": + x.Balance = value.Interface().(string) + case "os.evm.v1.QueryAccountResponse.code_hash": + x.CodeHash = value.Interface().(string) + case "os.evm.v1.QueryAccountResponse.nonce": + x.Nonce = value.Uint() default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) } } @@ -1599,48 +1438,48 @@ func (x *fastReflection_QueryCosmosAccountResponse) Set(fd protoreflect.FieldDes // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCosmosAccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryAccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": - panic(fmt.Errorf("field cosmos_address of message os.evm.v1.QueryCosmosAccountResponse is not mutable")) - case "os.evm.v1.QueryCosmosAccountResponse.sequence": - panic(fmt.Errorf("field sequence of message os.evm.v1.QueryCosmosAccountResponse is not mutable")) - case "os.evm.v1.QueryCosmosAccountResponse.account_number": - panic(fmt.Errorf("field account_number of message os.evm.v1.QueryCosmosAccountResponse is not mutable")) + case "os.evm.v1.QueryAccountResponse.balance": + panic(fmt.Errorf("field balance of message os.evm.v1.QueryAccountResponse is not mutable")) + case "os.evm.v1.QueryAccountResponse.code_hash": + panic(fmt.Errorf("field code_hash of message os.evm.v1.QueryAccountResponse is not mutable")) + case "os.evm.v1.QueryAccountResponse.nonce": + panic(fmt.Errorf("field nonce of message os.evm.v1.QueryAccountResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryCosmosAccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryAccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": + case "os.evm.v1.QueryAccountResponse.balance": return protoreflect.ValueOfString("") - case "os.evm.v1.QueryCosmosAccountResponse.sequence": - return protoreflect.ValueOfUint64(uint64(0)) - case "os.evm.v1.QueryCosmosAccountResponse.account_number": + case "os.evm.v1.QueryAccountResponse.code_hash": + return protoreflect.ValueOfString("") + case "os.evm.v1.QueryAccountResponse.nonce": return protoreflect.ValueOfUint64(uint64(0)) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryAccountResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryCosmosAccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryAccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryCosmosAccountResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryAccountResponse", d.FullName())) } panic("unreachable") } @@ -1648,7 +1487,7 @@ func (x *fastReflection_QueryCosmosAccountResponse) WhichOneof(d protoreflect.On // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryCosmosAccountResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryAccountResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -1659,7 +1498,7 @@ func (x *fastReflection_QueryCosmosAccountResponse) GetUnknown() protoreflect.Ra // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCosmosAccountResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryAccountResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -1671,7 +1510,7 @@ func (x *fastReflection_QueryCosmosAccountResponse) SetUnknown(fields protorefle // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryCosmosAccountResponse) IsValid() bool { +func (x *fastReflection_QueryAccountResponse) IsValid() bool { return x != nil } @@ -1681,9 +1520,9 @@ func (x *fastReflection_QueryCosmosAccountResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryAccountResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryCosmosAccountResponse) + x := input.Message.Interface().(*QueryAccountResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -1695,15 +1534,16 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M var n int var l int _ = l - l = len(x.CosmosAddress) + l = len(x.Balance) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - if x.Sequence != 0 { - n += 1 + runtime.Sov(uint64(x.Sequence)) + l = len(x.CodeHash) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) } - if x.AccountNumber != 0 { - n += 1 + runtime.Sov(uint64(x.AccountNumber)) + if x.Nonce != 0 { + n += 1 + runtime.Sov(uint64(x.Nonce)) } if x.unknownFields != nil { n += len(x.unknownFields) @@ -1715,7 +1555,7 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryCosmosAccountResponse) + x := input.Message.Interface().(*QueryAccountResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -1734,20 +1574,22 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if x.AccountNumber != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.AccountNumber)) + if x.Nonce != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Nonce)) i-- dAtA[i] = 0x18 } - if x.Sequence != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.Sequence)) + if len(x.CodeHash) > 0 { + i -= len(x.CodeHash) + copy(dAtA[i:], x.CodeHash) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CodeHash))) i-- - dAtA[i] = 0x10 + dAtA[i] = 0x12 } - if len(x.CosmosAddress) > 0 { - i -= len(x.CosmosAddress) - copy(dAtA[i:], x.CosmosAddress) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CosmosAddress))) + if len(x.Balance) > 0 { + i -= len(x.Balance) + copy(dAtA[i:], x.Balance) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Balance))) i-- dAtA[i] = 0xa } @@ -1762,7 +1604,7 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryCosmosAccountResponse) + x := input.Message.Interface().(*QueryAccountResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -1794,15 +1636,15 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCosmosAccountResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryAccountResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCosmosAccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryAccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CosmosAddress", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Balance", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -1830,13 +1672,13 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.CosmosAddress = string(dAtA[iNdEx:postIndex]) + x.Balance = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: - if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Sequence", wireType) + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CodeHash", wireType) } - x.Sequence = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -1846,16 +1688,29 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M } b := dAtA[iNdEx] iNdEx++ - x.Sequence |= uint64(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CodeHash = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 3: if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AccountNumber", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Nonce", wireType) } - x.AccountNumber = 0 + x.Nonce = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -1865,7 +1720,7 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M } b := dAtA[iNdEx] iNdEx++ - x.AccountNumber |= uint64(b&0x7F) << shift + x.Nonce |= uint64(b&0x7F) << shift if b < 0x80 { break } @@ -1906,25 +1761,25 @@ func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.M } var ( - md_QueryValidatorAccountRequest protoreflect.MessageDescriptor - fd_QueryValidatorAccountRequest_cons_address protoreflect.FieldDescriptor + md_QueryCosmosAccountRequest protoreflect.MessageDescriptor + fd_QueryCosmosAccountRequest_address protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryValidatorAccountRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryValidatorAccountRequest") - fd_QueryValidatorAccountRequest_cons_address = md_QueryValidatorAccountRequest.Fields().ByName("cons_address") + md_QueryCosmosAccountRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryCosmosAccountRequest") + fd_QueryCosmosAccountRequest_address = md_QueryCosmosAccountRequest.Fields().ByName("address") } -var _ protoreflect.Message = (*fastReflection_QueryValidatorAccountRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryCosmosAccountRequest)(nil) -type fastReflection_QueryValidatorAccountRequest QueryValidatorAccountRequest +type fastReflection_QueryCosmosAccountRequest QueryCosmosAccountRequest -func (x *QueryValidatorAccountRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryValidatorAccountRequest)(x) +func (x *QueryCosmosAccountRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryCosmosAccountRequest)(x) } -func (x *QueryValidatorAccountRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryCosmosAccountRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1936,43 +1791,43 @@ func (x *QueryValidatorAccountRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryValidatorAccountRequest_messageType fastReflection_QueryValidatorAccountRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryValidatorAccountRequest_messageType{} +var _fastReflection_QueryCosmosAccountRequest_messageType fastReflection_QueryCosmosAccountRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryCosmosAccountRequest_messageType{} -type fastReflection_QueryValidatorAccountRequest_messageType struct{} +type fastReflection_QueryCosmosAccountRequest_messageType struct{} -func (x fastReflection_QueryValidatorAccountRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryValidatorAccountRequest)(nil) +func (x fastReflection_QueryCosmosAccountRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryCosmosAccountRequest)(nil) } -func (x fastReflection_QueryValidatorAccountRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryValidatorAccountRequest) +func (x fastReflection_QueryCosmosAccountRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryCosmosAccountRequest) } -func (x fastReflection_QueryValidatorAccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryValidatorAccountRequest +func (x fastReflection_QueryCosmosAccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCosmosAccountRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryValidatorAccountRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryValidatorAccountRequest +func (x *fastReflection_QueryCosmosAccountRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCosmosAccountRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryValidatorAccountRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryValidatorAccountRequest_messageType +func (x *fastReflection_QueryCosmosAccountRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryCosmosAccountRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryValidatorAccountRequest) New() protoreflect.Message { - return new(fastReflection_QueryValidatorAccountRequest) +func (x *fastReflection_QueryCosmosAccountRequest) New() protoreflect.Message { + return new(fastReflection_QueryCosmosAccountRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryValidatorAccountRequest) Interface() protoreflect.ProtoMessage { - return (*QueryValidatorAccountRequest)(x) +func (x *fastReflection_QueryCosmosAccountRequest) Interface() protoreflect.ProtoMessage { + return (*QueryCosmosAccountRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -1980,10 +1835,10 @@ func (x *fastReflection_QueryValidatorAccountRequest) Interface() protoreflect.P // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryValidatorAccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.ConsAddress != "" { - value := protoreflect.ValueOfString(x.ConsAddress) - if !f(fd_QueryValidatorAccountRequest_cons_address, value) { +func (x *fastReflection_QueryCosmosAccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_QueryCosmosAccountRequest_address, value) { return } } @@ -2000,15 +1855,15 @@ func (x *fastReflection_QueryValidatorAccountRequest) Range(f func(protoreflect. // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryValidatorAccountRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryCosmosAccountRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountRequest.cons_address": - return x.ConsAddress != "" + case "os.evm.v1.QueryCosmosAccountRequest.address": + return x.Address != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) } } @@ -2018,15 +1873,15 @@ func (x *fastReflection_QueryValidatorAccountRequest) Has(fd protoreflect.FieldD // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryValidatorAccountRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryCosmosAccountRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountRequest.cons_address": - x.ConsAddress = "" + case "os.evm.v1.QueryCosmosAccountRequest.address": + x.Address = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) } } @@ -2036,16 +1891,16 @@ func (x *fastReflection_QueryValidatorAccountRequest) Clear(fd protoreflect.Fiel // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryValidatorAccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCosmosAccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryValidatorAccountRequest.cons_address": - value := x.ConsAddress + case "os.evm.v1.QueryCosmosAccountRequest.address": + value := x.Address return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", descriptor.FullName())) } } @@ -2059,15 +1914,15 @@ func (x *fastReflection_QueryValidatorAccountRequest) Get(descriptor protoreflec // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryValidatorAccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryCosmosAccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountRequest.cons_address": - x.ConsAddress = value.Interface().(string) + case "os.evm.v1.QueryCosmosAccountRequest.address": + x.Address = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) } } @@ -2081,40 +1936,40 @@ func (x *fastReflection_QueryValidatorAccountRequest) Set(fd protoreflect.FieldD // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryValidatorAccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCosmosAccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountRequest.cons_address": - panic(fmt.Errorf("field cons_address of message os.evm.v1.QueryValidatorAccountRequest is not mutable")) + case "os.evm.v1.QueryCosmosAccountRequest.address": + panic(fmt.Errorf("field address of message os.evm.v1.QueryCosmosAccountRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryValidatorAccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCosmosAccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountRequest.cons_address": + case "os.evm.v1.QueryCosmosAccountRequest.address": return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryValidatorAccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryCosmosAccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryValidatorAccountRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryCosmosAccountRequest", d.FullName())) } panic("unreachable") } @@ -2122,7 +1977,7 @@ func (x *fastReflection_QueryValidatorAccountRequest) WhichOneof(d protoreflect. // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryValidatorAccountRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryCosmosAccountRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -2133,7 +1988,7 @@ func (x *fastReflection_QueryValidatorAccountRequest) GetUnknown() protoreflect. // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryValidatorAccountRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryCosmosAccountRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -2145,7 +2000,7 @@ func (x *fastReflection_QueryValidatorAccountRequest) SetUnknown(fields protoref // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryValidatorAccountRequest) IsValid() bool { +func (x *fastReflection_QueryCosmosAccountRequest) IsValid() bool { return x != nil } @@ -2155,9 +2010,9 @@ func (x *fastReflection_QueryValidatorAccountRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryCosmosAccountRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryValidatorAccountRequest) + x := input.Message.Interface().(*QueryCosmosAccountRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2169,7 +2024,7 @@ func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface var n int var l int _ = l - l = len(x.ConsAddress) + l = len(x.Address) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -2183,7 +2038,7 @@ func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryValidatorAccountRequest) + x := input.Message.Interface().(*QueryCosmosAccountRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2202,10 +2057,10 @@ func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.ConsAddress) > 0 { - i -= len(x.ConsAddress) - copy(dAtA[i:], x.ConsAddress) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ConsAddress))) + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) i-- dAtA[i] = 0xa } @@ -2220,7 +2075,7 @@ func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryValidatorAccountRequest) + x := input.Message.Interface().(*QueryCosmosAccountRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2252,15 +2107,15 @@ func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryValidatorAccountRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCosmosAccountRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryValidatorAccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCosmosAccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ConsAddress", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -2288,7 +2143,7 @@ func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.ConsAddress = string(dAtA[iNdEx:postIndex]) + x.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -2326,29 +2181,29 @@ func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface } var ( - md_QueryValidatorAccountResponse protoreflect.MessageDescriptor - fd_QueryValidatorAccountResponse_account_address protoreflect.FieldDescriptor - fd_QueryValidatorAccountResponse_sequence protoreflect.FieldDescriptor - fd_QueryValidatorAccountResponse_account_number protoreflect.FieldDescriptor + md_QueryCosmosAccountResponse protoreflect.MessageDescriptor + fd_QueryCosmosAccountResponse_cosmos_address protoreflect.FieldDescriptor + fd_QueryCosmosAccountResponse_sequence protoreflect.FieldDescriptor + fd_QueryCosmosAccountResponse_account_number protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryValidatorAccountResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryValidatorAccountResponse") - fd_QueryValidatorAccountResponse_account_address = md_QueryValidatorAccountResponse.Fields().ByName("account_address") - fd_QueryValidatorAccountResponse_sequence = md_QueryValidatorAccountResponse.Fields().ByName("sequence") - fd_QueryValidatorAccountResponse_account_number = md_QueryValidatorAccountResponse.Fields().ByName("account_number") + md_QueryCosmosAccountResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryCosmosAccountResponse") + fd_QueryCosmosAccountResponse_cosmos_address = md_QueryCosmosAccountResponse.Fields().ByName("cosmos_address") + fd_QueryCosmosAccountResponse_sequence = md_QueryCosmosAccountResponse.Fields().ByName("sequence") + fd_QueryCosmosAccountResponse_account_number = md_QueryCosmosAccountResponse.Fields().ByName("account_number") } -var _ protoreflect.Message = (*fastReflection_QueryValidatorAccountResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryCosmosAccountResponse)(nil) -type fastReflection_QueryValidatorAccountResponse QueryValidatorAccountResponse +type fastReflection_QueryCosmosAccountResponse QueryCosmosAccountResponse -func (x *QueryValidatorAccountResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryValidatorAccountResponse)(x) +func (x *QueryCosmosAccountResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryCosmosAccountResponse)(x) } -func (x *QueryValidatorAccountResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryCosmosAccountResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -2360,43 +2215,43 @@ func (x *QueryValidatorAccountResponse) slowProtoReflect() protoreflect.Message return mi.MessageOf(x) } -var _fastReflection_QueryValidatorAccountResponse_messageType fastReflection_QueryValidatorAccountResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryValidatorAccountResponse_messageType{} +var _fastReflection_QueryCosmosAccountResponse_messageType fastReflection_QueryCosmosAccountResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryCosmosAccountResponse_messageType{} -type fastReflection_QueryValidatorAccountResponse_messageType struct{} +type fastReflection_QueryCosmosAccountResponse_messageType struct{} -func (x fastReflection_QueryValidatorAccountResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryValidatorAccountResponse)(nil) +func (x fastReflection_QueryCosmosAccountResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryCosmosAccountResponse)(nil) } -func (x fastReflection_QueryValidatorAccountResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryValidatorAccountResponse) +func (x fastReflection_QueryCosmosAccountResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryCosmosAccountResponse) } -func (x fastReflection_QueryValidatorAccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryValidatorAccountResponse +func (x fastReflection_QueryCosmosAccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCosmosAccountResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryValidatorAccountResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryValidatorAccountResponse +func (x *fastReflection_QueryCosmosAccountResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCosmosAccountResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryValidatorAccountResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryValidatorAccountResponse_messageType +func (x *fastReflection_QueryCosmosAccountResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryCosmosAccountResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryValidatorAccountResponse) New() protoreflect.Message { - return new(fastReflection_QueryValidatorAccountResponse) +func (x *fastReflection_QueryCosmosAccountResponse) New() protoreflect.Message { + return new(fastReflection_QueryCosmosAccountResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryValidatorAccountResponse) Interface() protoreflect.ProtoMessage { - return (*QueryValidatorAccountResponse)(x) +func (x *fastReflection_QueryCosmosAccountResponse) Interface() protoreflect.ProtoMessage { + return (*QueryCosmosAccountResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -2404,22 +2259,22 @@ func (x *fastReflection_QueryValidatorAccountResponse) Interface() protoreflect. // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryValidatorAccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.AccountAddress != "" { - value := protoreflect.ValueOfString(x.AccountAddress) - if !f(fd_QueryValidatorAccountResponse_account_address, value) { +func (x *fastReflection_QueryCosmosAccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.CosmosAddress != "" { + value := protoreflect.ValueOfString(x.CosmosAddress) + if !f(fd_QueryCosmosAccountResponse_cosmos_address, value) { return } } if x.Sequence != uint64(0) { value := protoreflect.ValueOfUint64(x.Sequence) - if !f(fd_QueryValidatorAccountResponse_sequence, value) { + if !f(fd_QueryCosmosAccountResponse_sequence, value) { return } } if x.AccountNumber != uint64(0) { value := protoreflect.ValueOfUint64(x.AccountNumber) - if !f(fd_QueryValidatorAccountResponse_account_number, value) { + if !f(fd_QueryCosmosAccountResponse_account_number, value) { return } } @@ -2436,19 +2291,19 @@ func (x *fastReflection_QueryValidatorAccountResponse) Range(f func(protoreflect // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryValidatorAccountResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryCosmosAccountResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountResponse.account_address": - return x.AccountAddress != "" - case "os.evm.v1.QueryValidatorAccountResponse.sequence": + case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": + return x.CosmosAddress != "" + case "os.evm.v1.QueryCosmosAccountResponse.sequence": return x.Sequence != uint64(0) - case "os.evm.v1.QueryValidatorAccountResponse.account_number": + case "os.evm.v1.QueryCosmosAccountResponse.account_number": return x.AccountNumber != uint64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) } } @@ -2458,19 +2313,19 @@ func (x *fastReflection_QueryValidatorAccountResponse) Has(fd protoreflect.Field // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryValidatorAccountResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryCosmosAccountResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountResponse.account_address": - x.AccountAddress = "" - case "os.evm.v1.QueryValidatorAccountResponse.sequence": + case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": + x.CosmosAddress = "" + case "os.evm.v1.QueryCosmosAccountResponse.sequence": x.Sequence = uint64(0) - case "os.evm.v1.QueryValidatorAccountResponse.account_number": + case "os.evm.v1.QueryCosmosAccountResponse.account_number": x.AccountNumber = uint64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) } } @@ -2480,22 +2335,22 @@ func (x *fastReflection_QueryValidatorAccountResponse) Clear(fd protoreflect.Fie // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryValidatorAccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCosmosAccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryValidatorAccountResponse.account_address": - value := x.AccountAddress + case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": + value := x.CosmosAddress return protoreflect.ValueOfString(value) - case "os.evm.v1.QueryValidatorAccountResponse.sequence": + case "os.evm.v1.QueryCosmosAccountResponse.sequence": value := x.Sequence return protoreflect.ValueOfUint64(value) - case "os.evm.v1.QueryValidatorAccountResponse.account_number": + case "os.evm.v1.QueryCosmosAccountResponse.account_number": value := x.AccountNumber return protoreflect.ValueOfUint64(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", descriptor.FullName())) } } @@ -2509,19 +2364,19 @@ func (x *fastReflection_QueryValidatorAccountResponse) Get(descriptor protorefle // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryValidatorAccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryCosmosAccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountResponse.account_address": - x.AccountAddress = value.Interface().(string) - case "os.evm.v1.QueryValidatorAccountResponse.sequence": + case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": + x.CosmosAddress = value.Interface().(string) + case "os.evm.v1.QueryCosmosAccountResponse.sequence": x.Sequence = value.Uint() - case "os.evm.v1.QueryValidatorAccountResponse.account_number": + case "os.evm.v1.QueryCosmosAccountResponse.account_number": x.AccountNumber = value.Uint() default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) } } @@ -2535,48 +2390,48 @@ func (x *fastReflection_QueryValidatorAccountResponse) Set(fd protoreflect.Field // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryValidatorAccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCosmosAccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountResponse.account_address": - panic(fmt.Errorf("field account_address of message os.evm.v1.QueryValidatorAccountResponse is not mutable")) - case "os.evm.v1.QueryValidatorAccountResponse.sequence": - panic(fmt.Errorf("field sequence of message os.evm.v1.QueryValidatorAccountResponse is not mutable")) - case "os.evm.v1.QueryValidatorAccountResponse.account_number": - panic(fmt.Errorf("field account_number of message os.evm.v1.QueryValidatorAccountResponse is not mutable")) - default: - if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) - } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) + case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": + panic(fmt.Errorf("field cosmos_address of message os.evm.v1.QueryCosmosAccountResponse is not mutable")) + case "os.evm.v1.QueryCosmosAccountResponse.sequence": + panic(fmt.Errorf("field sequence of message os.evm.v1.QueryCosmosAccountResponse is not mutable")) + case "os.evm.v1.QueryCosmosAccountResponse.account_number": + panic(fmt.Errorf("field account_number of message os.evm.v1.QueryCosmosAccountResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryValidatorAccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCosmosAccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryValidatorAccountResponse.account_address": + case "os.evm.v1.QueryCosmosAccountResponse.cosmos_address": return protoreflect.ValueOfString("") - case "os.evm.v1.QueryValidatorAccountResponse.sequence": + case "os.evm.v1.QueryCosmosAccountResponse.sequence": return protoreflect.ValueOfUint64(uint64(0)) - case "os.evm.v1.QueryValidatorAccountResponse.account_number": + case "os.evm.v1.QueryCosmosAccountResponse.account_number": return protoreflect.ValueOfUint64(uint64(0)) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCosmosAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCosmosAccountResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryValidatorAccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryCosmosAccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryValidatorAccountResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryCosmosAccountResponse", d.FullName())) } panic("unreachable") } @@ -2584,7 +2439,7 @@ func (x *fastReflection_QueryValidatorAccountResponse) WhichOneof(d protoreflect // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryValidatorAccountResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryCosmosAccountResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -2595,7 +2450,7 @@ func (x *fastReflection_QueryValidatorAccountResponse) GetUnknown() protoreflect // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryValidatorAccountResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryCosmosAccountResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -2607,7 +2462,7 @@ func (x *fastReflection_QueryValidatorAccountResponse) SetUnknown(fields protore // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryValidatorAccountResponse) IsValid() bool { +func (x *fastReflection_QueryCosmosAccountResponse) IsValid() bool { return x != nil } @@ -2617,9 +2472,9 @@ func (x *fastReflection_QueryValidatorAccountResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryCosmosAccountResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryValidatorAccountResponse) + x := input.Message.Interface().(*QueryCosmosAccountResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2631,7 +2486,7 @@ func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoifac var n int var l int _ = l - l = len(x.AccountAddress) + l = len(x.CosmosAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -2651,7 +2506,7 @@ func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoifac } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryValidatorAccountResponse) + x := input.Message.Interface().(*QueryCosmosAccountResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2680,10 +2535,10 @@ func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoifac i-- dAtA[i] = 0x10 } - if len(x.AccountAddress) > 0 { - i -= len(x.AccountAddress) - copy(dAtA[i:], x.AccountAddress) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.AccountAddress))) + if len(x.CosmosAddress) > 0 { + i -= len(x.CosmosAddress) + copy(dAtA[i:], x.CosmosAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CosmosAddress))) i-- dAtA[i] = 0xa } @@ -2698,7 +2553,7 @@ func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoifac }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryValidatorAccountResponse) + x := input.Message.Interface().(*QueryCosmosAccountResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -2730,15 +2585,15 @@ func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoifac fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryValidatorAccountResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCosmosAccountResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryValidatorAccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCosmosAccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AccountAddress", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CosmosAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -2766,7 +2621,7 @@ func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoifac if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.AccountAddress = string(dAtA[iNdEx:postIndex]) + x.CosmosAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { @@ -2842,25 +2697,25 @@ func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoifac } var ( - md_QueryBalanceRequest protoreflect.MessageDescriptor - fd_QueryBalanceRequest_address protoreflect.FieldDescriptor + md_QueryValidatorAccountRequest protoreflect.MessageDescriptor + fd_QueryValidatorAccountRequest_cons_address protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryBalanceRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryBalanceRequest") - fd_QueryBalanceRequest_address = md_QueryBalanceRequest.Fields().ByName("address") + md_QueryValidatorAccountRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryValidatorAccountRequest") + fd_QueryValidatorAccountRequest_cons_address = md_QueryValidatorAccountRequest.Fields().ByName("cons_address") } -var _ protoreflect.Message = (*fastReflection_QueryBalanceRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryValidatorAccountRequest)(nil) -type fastReflection_QueryBalanceRequest QueryBalanceRequest +type fastReflection_QueryValidatorAccountRequest QueryValidatorAccountRequest -func (x *QueryBalanceRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryBalanceRequest)(x) +func (x *QueryValidatorAccountRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryValidatorAccountRequest)(x) } -func (x *QueryBalanceRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryValidatorAccountRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -2872,43 +2727,43 @@ func (x *QueryBalanceRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryBalanceRequest_messageType fastReflection_QueryBalanceRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryBalanceRequest_messageType{} +var _fastReflection_QueryValidatorAccountRequest_messageType fastReflection_QueryValidatorAccountRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryValidatorAccountRequest_messageType{} -type fastReflection_QueryBalanceRequest_messageType struct{} +type fastReflection_QueryValidatorAccountRequest_messageType struct{} -func (x fastReflection_QueryBalanceRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryBalanceRequest)(nil) +func (x fastReflection_QueryValidatorAccountRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryValidatorAccountRequest)(nil) } -func (x fastReflection_QueryBalanceRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryBalanceRequest) +func (x fastReflection_QueryValidatorAccountRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryValidatorAccountRequest) } -func (x fastReflection_QueryBalanceRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryBalanceRequest +func (x fastReflection_QueryValidatorAccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryValidatorAccountRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryBalanceRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryBalanceRequest +func (x *fastReflection_QueryValidatorAccountRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryValidatorAccountRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryBalanceRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryBalanceRequest_messageType +func (x *fastReflection_QueryValidatorAccountRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryValidatorAccountRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryBalanceRequest) New() protoreflect.Message { - return new(fastReflection_QueryBalanceRequest) +func (x *fastReflection_QueryValidatorAccountRequest) New() protoreflect.Message { + return new(fastReflection_QueryValidatorAccountRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryBalanceRequest) Interface() protoreflect.ProtoMessage { - return (*QueryBalanceRequest)(x) +func (x *fastReflection_QueryValidatorAccountRequest) Interface() protoreflect.ProtoMessage { + return (*QueryValidatorAccountRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -2916,10 +2771,10 @@ func (x *fastReflection_QueryBalanceRequest) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryBalanceRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Address != "" { - value := protoreflect.ValueOfString(x.Address) - if !f(fd_QueryBalanceRequest_address, value) { +func (x *fastReflection_QueryValidatorAccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.ConsAddress != "" { + value := protoreflect.ValueOfString(x.ConsAddress) + if !f(fd_QueryValidatorAccountRequest_cons_address, value) { return } } @@ -2936,15 +2791,15 @@ func (x *fastReflection_QueryBalanceRequest) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryBalanceRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryValidatorAccountRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryBalanceRequest.address": - return x.Address != "" + case "os.evm.v1.QueryValidatorAccountRequest.cons_address": + return x.ConsAddress != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) } } @@ -2954,15 +2809,15 @@ func (x *fastReflection_QueryBalanceRequest) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBalanceRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryValidatorAccountRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryBalanceRequest.address": - x.Address = "" + case "os.evm.v1.QueryValidatorAccountRequest.cons_address": + x.ConsAddress = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) } } @@ -2972,16 +2827,16 @@ func (x *fastReflection_QueryBalanceRequest) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryBalanceRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryValidatorAccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryBalanceRequest.address": - value := x.Address + case "os.evm.v1.QueryValidatorAccountRequest.cons_address": + value := x.ConsAddress return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", descriptor.FullName())) } } @@ -2995,15 +2850,15 @@ func (x *fastReflection_QueryBalanceRequest) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBalanceRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryValidatorAccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryBalanceRequest.address": - x.Address = value.Interface().(string) + case "os.evm.v1.QueryValidatorAccountRequest.cons_address": + x.ConsAddress = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) } } @@ -3017,40 +2872,40 @@ func (x *fastReflection_QueryBalanceRequest) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBalanceRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryValidatorAccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryBalanceRequest.address": - panic(fmt.Errorf("field address of message os.evm.v1.QueryBalanceRequest is not mutable")) + case "os.evm.v1.QueryValidatorAccountRequest.cons_address": + panic(fmt.Errorf("field cons_address of message os.evm.v1.QueryValidatorAccountRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryBalanceRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryValidatorAccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryBalanceRequest.address": + case "os.evm.v1.QueryValidatorAccountRequest.cons_address": return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryBalanceRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryValidatorAccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryBalanceRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryValidatorAccountRequest", d.FullName())) } panic("unreachable") } @@ -3058,7 +2913,7 @@ func (x *fastReflection_QueryBalanceRequest) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryBalanceRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryValidatorAccountRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -3069,7 +2924,7 @@ func (x *fastReflection_QueryBalanceRequest) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBalanceRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryValidatorAccountRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -3081,7 +2936,7 @@ func (x *fastReflection_QueryBalanceRequest) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryBalanceRequest) IsValid() bool { +func (x *fastReflection_QueryValidatorAccountRequest) IsValid() bool { return x != nil } @@ -3091,9 +2946,9 @@ func (x *fastReflection_QueryBalanceRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryValidatorAccountRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryBalanceRequest) + x := input.Message.Interface().(*QueryValidatorAccountRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3105,7 +2960,7 @@ func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods var n int var l int _ = l - l = len(x.Address) + l = len(x.ConsAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -3119,7 +2974,7 @@ func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryBalanceRequest) + x := input.Message.Interface().(*QueryValidatorAccountRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3138,10 +2993,10 @@ func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Address) > 0 { - i -= len(x.Address) - copy(dAtA[i:], x.Address) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + if len(x.ConsAddress) > 0 { + i -= len(x.ConsAddress) + copy(dAtA[i:], x.ConsAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ConsAddress))) i-- dAtA[i] = 0xa } @@ -3156,7 +3011,7 @@ func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryBalanceRequest) + x := input.Message.Interface().(*QueryValidatorAccountRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3188,15 +3043,15 @@ func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBalanceRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryValidatorAccountRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBalanceRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryValidatorAccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ConsAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -3224,7 +3079,7 @@ func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Address = string(dAtA[iNdEx:postIndex]) + x.ConsAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -3262,25 +3117,29 @@ func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods } var ( - md_QueryBalanceResponse protoreflect.MessageDescriptor - fd_QueryBalanceResponse_balance protoreflect.FieldDescriptor + md_QueryValidatorAccountResponse protoreflect.MessageDescriptor + fd_QueryValidatorAccountResponse_account_address protoreflect.FieldDescriptor + fd_QueryValidatorAccountResponse_sequence protoreflect.FieldDescriptor + fd_QueryValidatorAccountResponse_account_number protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryBalanceResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryBalanceResponse") - fd_QueryBalanceResponse_balance = md_QueryBalanceResponse.Fields().ByName("balance") + md_QueryValidatorAccountResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryValidatorAccountResponse") + fd_QueryValidatorAccountResponse_account_address = md_QueryValidatorAccountResponse.Fields().ByName("account_address") + fd_QueryValidatorAccountResponse_sequence = md_QueryValidatorAccountResponse.Fields().ByName("sequence") + fd_QueryValidatorAccountResponse_account_number = md_QueryValidatorAccountResponse.Fields().ByName("account_number") } -var _ protoreflect.Message = (*fastReflection_QueryBalanceResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryValidatorAccountResponse)(nil) -type fastReflection_QueryBalanceResponse QueryBalanceResponse +type fastReflection_QueryValidatorAccountResponse QueryValidatorAccountResponse -func (x *QueryBalanceResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryBalanceResponse)(x) +func (x *QueryValidatorAccountResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryValidatorAccountResponse)(x) } -func (x *QueryBalanceResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryValidatorAccountResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -3292,43 +3151,43 @@ func (x *QueryBalanceResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryBalanceResponse_messageType fastReflection_QueryBalanceResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryBalanceResponse_messageType{} +var _fastReflection_QueryValidatorAccountResponse_messageType fastReflection_QueryValidatorAccountResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryValidatorAccountResponse_messageType{} -type fastReflection_QueryBalanceResponse_messageType struct{} +type fastReflection_QueryValidatorAccountResponse_messageType struct{} -func (x fastReflection_QueryBalanceResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryBalanceResponse)(nil) +func (x fastReflection_QueryValidatorAccountResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryValidatorAccountResponse)(nil) } -func (x fastReflection_QueryBalanceResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryBalanceResponse) +func (x fastReflection_QueryValidatorAccountResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryValidatorAccountResponse) } -func (x fastReflection_QueryBalanceResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryBalanceResponse +func (x fastReflection_QueryValidatorAccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryValidatorAccountResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryBalanceResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryBalanceResponse +func (x *fastReflection_QueryValidatorAccountResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryValidatorAccountResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryBalanceResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryBalanceResponse_messageType +func (x *fastReflection_QueryValidatorAccountResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryValidatorAccountResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryBalanceResponse) New() protoreflect.Message { - return new(fastReflection_QueryBalanceResponse) +func (x *fastReflection_QueryValidatorAccountResponse) New() protoreflect.Message { + return new(fastReflection_QueryValidatorAccountResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryBalanceResponse) Interface() protoreflect.ProtoMessage { - return (*QueryBalanceResponse)(x) +func (x *fastReflection_QueryValidatorAccountResponse) Interface() protoreflect.ProtoMessage { + return (*QueryValidatorAccountResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -3336,10 +3195,22 @@ func (x *fastReflection_QueryBalanceResponse) Interface() protoreflect.ProtoMess // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryBalanceResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Balance != "" { - value := protoreflect.ValueOfString(x.Balance) - if !f(fd_QueryBalanceResponse_balance, value) { +func (x *fastReflection_QueryValidatorAccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.AccountAddress != "" { + value := protoreflect.ValueOfString(x.AccountAddress) + if !f(fd_QueryValidatorAccountResponse_account_address, value) { + return + } + } + if x.Sequence != uint64(0) { + value := protoreflect.ValueOfUint64(x.Sequence) + if !f(fd_QueryValidatorAccountResponse_sequence, value) { + return + } + } + if x.AccountNumber != uint64(0) { + value := protoreflect.ValueOfUint64(x.AccountNumber) + if !f(fd_QueryValidatorAccountResponse_account_number, value) { return } } @@ -3356,15 +3227,19 @@ func (x *fastReflection_QueryBalanceResponse) Range(f func(protoreflect.FieldDes // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryBalanceResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryValidatorAccountResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryBalanceResponse.balance": - return x.Balance != "" + case "os.evm.v1.QueryValidatorAccountResponse.account_address": + return x.AccountAddress != "" + case "os.evm.v1.QueryValidatorAccountResponse.sequence": + return x.Sequence != uint64(0) + case "os.evm.v1.QueryValidatorAccountResponse.account_number": + return x.AccountNumber != uint64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) } } @@ -3374,15 +3249,19 @@ func (x *fastReflection_QueryBalanceResponse) Has(fd protoreflect.FieldDescripto // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBalanceResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryValidatorAccountResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryBalanceResponse.balance": - x.Balance = "" + case "os.evm.v1.QueryValidatorAccountResponse.account_address": + x.AccountAddress = "" + case "os.evm.v1.QueryValidatorAccountResponse.sequence": + x.Sequence = uint64(0) + case "os.evm.v1.QueryValidatorAccountResponse.account_number": + x.AccountNumber = uint64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) } } @@ -3392,16 +3271,22 @@ func (x *fastReflection_QueryBalanceResponse) Clear(fd protoreflect.FieldDescrip // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryBalanceResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryValidatorAccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryBalanceResponse.balance": - value := x.Balance + case "os.evm.v1.QueryValidatorAccountResponse.account_address": + value := x.AccountAddress return protoreflect.ValueOfString(value) + case "os.evm.v1.QueryValidatorAccountResponse.sequence": + value := x.Sequence + return protoreflect.ValueOfUint64(value) + case "os.evm.v1.QueryValidatorAccountResponse.account_number": + value := x.AccountNumber + return protoreflect.ValueOfUint64(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", descriptor.FullName())) } } @@ -3415,15 +3300,19 @@ func (x *fastReflection_QueryBalanceResponse) Get(descriptor protoreflect.FieldD // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBalanceResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryValidatorAccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryBalanceResponse.balance": - x.Balance = value.Interface().(string) + case "os.evm.v1.QueryValidatorAccountResponse.account_address": + x.AccountAddress = value.Interface().(string) + case "os.evm.v1.QueryValidatorAccountResponse.sequence": + x.Sequence = value.Uint() + case "os.evm.v1.QueryValidatorAccountResponse.account_number": + x.AccountNumber = value.Uint() default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) } } @@ -3437,40 +3326,48 @@ func (x *fastReflection_QueryBalanceResponse) Set(fd protoreflect.FieldDescripto // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBalanceResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryValidatorAccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryBalanceResponse.balance": - panic(fmt.Errorf("field balance of message os.evm.v1.QueryBalanceResponse is not mutable")) + case "os.evm.v1.QueryValidatorAccountResponse.account_address": + panic(fmt.Errorf("field account_address of message os.evm.v1.QueryValidatorAccountResponse is not mutable")) + case "os.evm.v1.QueryValidatorAccountResponse.sequence": + panic(fmt.Errorf("field sequence of message os.evm.v1.QueryValidatorAccountResponse is not mutable")) + case "os.evm.v1.QueryValidatorAccountResponse.account_number": + panic(fmt.Errorf("field account_number of message os.evm.v1.QueryValidatorAccountResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryBalanceResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryValidatorAccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryBalanceResponse.balance": + case "os.evm.v1.QueryValidatorAccountResponse.account_address": return protoreflect.ValueOfString("") + case "os.evm.v1.QueryValidatorAccountResponse.sequence": + return protoreflect.ValueOfUint64(uint64(0)) + case "os.evm.v1.QueryValidatorAccountResponse.account_number": + return protoreflect.ValueOfUint64(uint64(0)) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryValidatorAccountResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryValidatorAccountResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryBalanceResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryValidatorAccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryBalanceResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryValidatorAccountResponse", d.FullName())) } panic("unreachable") } @@ -3478,7 +3375,7 @@ func (x *fastReflection_QueryBalanceResponse) WhichOneof(d protoreflect.OneofDes // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryBalanceResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryValidatorAccountResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -3489,7 +3386,7 @@ func (x *fastReflection_QueryBalanceResponse) GetUnknown() protoreflect.RawField // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBalanceResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryValidatorAccountResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -3501,7 +3398,7 @@ func (x *fastReflection_QueryBalanceResponse) SetUnknown(fields protoreflect.Raw // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryBalanceResponse) IsValid() bool { +func (x *fastReflection_QueryValidatorAccountResponse) IsValid() bool { return x != nil } @@ -3511,9 +3408,9 @@ func (x *fastReflection_QueryBalanceResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryValidatorAccountResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryBalanceResponse) + x := input.Message.Interface().(*QueryValidatorAccountResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3525,10 +3422,16 @@ func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - l = len(x.Balance) + l = len(x.AccountAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } + if x.Sequence != 0 { + n += 1 + runtime.Sov(uint64(x.Sequence)) + } + if x.AccountNumber != 0 { + n += 1 + runtime.Sov(uint64(x.AccountNumber)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -3539,7 +3442,7 @@ func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryBalanceResponse) + x := input.Message.Interface().(*QueryValidatorAccountResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3558,10 +3461,20 @@ func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Balance) > 0 { - i -= len(x.Balance) - copy(dAtA[i:], x.Balance) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Balance))) + if x.AccountNumber != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.AccountNumber)) + i-- + dAtA[i] = 0x18 + } + if x.Sequence != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Sequence)) + i-- + dAtA[i] = 0x10 + } + if len(x.AccountAddress) > 0 { + i -= len(x.AccountAddress) + copy(dAtA[i:], x.AccountAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.AccountAddress))) i-- dAtA[i] = 0xa } @@ -3576,7 +3489,7 @@ func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryBalanceResponse) + x := input.Message.Interface().(*QueryValidatorAccountResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3608,15 +3521,15 @@ func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBalanceResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryValidatorAccountResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBalanceResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryValidatorAccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Balance", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AccountAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -3644,8 +3557,46 @@ func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Balance = string(dAtA[iNdEx:postIndex]) + x.AccountAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Sequence", wireType) + } + x.Sequence = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Sequence |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AccountNumber", wireType) + } + x.AccountNumber = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.AccountNumber |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -3682,27 +3633,25 @@ func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods } var ( - md_QueryStorageRequest protoreflect.MessageDescriptor - fd_QueryStorageRequest_address protoreflect.FieldDescriptor - fd_QueryStorageRequest_key protoreflect.FieldDescriptor + md_QueryBalanceRequest protoreflect.MessageDescriptor + fd_QueryBalanceRequest_address protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryStorageRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryStorageRequest") - fd_QueryStorageRequest_address = md_QueryStorageRequest.Fields().ByName("address") - fd_QueryStorageRequest_key = md_QueryStorageRequest.Fields().ByName("key") + md_QueryBalanceRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryBalanceRequest") + fd_QueryBalanceRequest_address = md_QueryBalanceRequest.Fields().ByName("address") } -var _ protoreflect.Message = (*fastReflection_QueryStorageRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryBalanceRequest)(nil) -type fastReflection_QueryStorageRequest QueryStorageRequest +type fastReflection_QueryBalanceRequest QueryBalanceRequest -func (x *QueryStorageRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryStorageRequest)(x) +func (x *QueryBalanceRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBalanceRequest)(x) } -func (x *QueryStorageRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryBalanceRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -3714,43 +3663,43 @@ func (x *QueryStorageRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryStorageRequest_messageType fastReflection_QueryStorageRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryStorageRequest_messageType{} +var _fastReflection_QueryBalanceRequest_messageType fastReflection_QueryBalanceRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryBalanceRequest_messageType{} -type fastReflection_QueryStorageRequest_messageType struct{} +type fastReflection_QueryBalanceRequest_messageType struct{} -func (x fastReflection_QueryStorageRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryStorageRequest)(nil) +func (x fastReflection_QueryBalanceRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBalanceRequest)(nil) } -func (x fastReflection_QueryStorageRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryStorageRequest) +func (x fastReflection_QueryBalanceRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBalanceRequest) } -func (x fastReflection_QueryStorageRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryStorageRequest +func (x fastReflection_QueryBalanceRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBalanceRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryStorageRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryStorageRequest +func (x *fastReflection_QueryBalanceRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBalanceRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryStorageRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryStorageRequest_messageType +func (x *fastReflection_QueryBalanceRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryBalanceRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryStorageRequest) New() protoreflect.Message { - return new(fastReflection_QueryStorageRequest) +func (x *fastReflection_QueryBalanceRequest) New() protoreflect.Message { + return new(fastReflection_QueryBalanceRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryStorageRequest) Interface() protoreflect.ProtoMessage { - return (*QueryStorageRequest)(x) +func (x *fastReflection_QueryBalanceRequest) Interface() protoreflect.ProtoMessage { + return (*QueryBalanceRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -3758,16 +3707,10 @@ func (x *fastReflection_QueryStorageRequest) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryStorageRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +func (x *fastReflection_QueryBalanceRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { if x.Address != "" { value := protoreflect.ValueOfString(x.Address) - if !f(fd_QueryStorageRequest_address, value) { - return - } - } - if x.Key != "" { - value := protoreflect.ValueOfString(x.Key) - if !f(fd_QueryStorageRequest_key, value) { + if !f(fd_QueryBalanceRequest_address, value) { return } } @@ -3784,17 +3727,15 @@ func (x *fastReflection_QueryStorageRequest) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryStorageRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryBalanceRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryStorageRequest.address": + case "os.evm.v1.QueryBalanceRequest.address": return x.Address != "" - case "os.evm.v1.QueryStorageRequest.key": - return x.Key != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) } } @@ -3804,17 +3745,15 @@ func (x *fastReflection_QueryStorageRequest) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryStorageRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryBalanceRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryStorageRequest.address": + case "os.evm.v1.QueryBalanceRequest.address": x.Address = "" - case "os.evm.v1.QueryStorageRequest.key": - x.Key = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) } } @@ -3824,19 +3763,16 @@ func (x *fastReflection_QueryStorageRequest) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryStorageRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryBalanceRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryStorageRequest.address": + case "os.evm.v1.QueryBalanceRequest.address": value := x.Address return protoreflect.ValueOfString(value) - case "os.evm.v1.QueryStorageRequest.key": - value := x.Key - return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", descriptor.FullName())) } } @@ -3850,17 +3786,15 @@ func (x *fastReflection_QueryStorageRequest) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryStorageRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryBalanceRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryStorageRequest.address": + case "os.evm.v1.QueryBalanceRequest.address": x.Address = value.Interface().(string) - case "os.evm.v1.QueryStorageRequest.key": - x.Key = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) } } @@ -3874,44 +3808,40 @@ func (x *fastReflection_QueryStorageRequest) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryStorageRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryBalanceRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryStorageRequest.address": - panic(fmt.Errorf("field address of message os.evm.v1.QueryStorageRequest is not mutable")) - case "os.evm.v1.QueryStorageRequest.key": - panic(fmt.Errorf("field key of message os.evm.v1.QueryStorageRequest is not mutable")) + case "os.evm.v1.QueryBalanceRequest.address": + panic(fmt.Errorf("field address of message os.evm.v1.QueryBalanceRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryStorageRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryBalanceRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryStorageRequest.address": - return protoreflect.ValueOfString("") - case "os.evm.v1.QueryStorageRequest.key": + case "os.evm.v1.QueryBalanceRequest.address": return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryStorageRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryBalanceRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryStorageRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryBalanceRequest", d.FullName())) } panic("unreachable") } @@ -3919,7 +3849,7 @@ func (x *fastReflection_QueryStorageRequest) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryStorageRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryBalanceRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -3930,7 +3860,7 @@ func (x *fastReflection_QueryStorageRequest) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryStorageRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryBalanceRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -3942,7 +3872,7 @@ func (x *fastReflection_QueryStorageRequest) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryStorageRequest) IsValid() bool { +func (x *fastReflection_QueryBalanceRequest) IsValid() bool { return x != nil } @@ -3952,9 +3882,9 @@ func (x *fastReflection_QueryStorageRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryBalanceRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryStorageRequest) + x := input.Message.Interface().(*QueryBalanceRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -3970,10 +3900,6 @@ func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - l = len(x.Key) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -3984,7 +3910,7 @@ func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryStorageRequest) + x := input.Message.Interface().(*QueryBalanceRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -4003,13 +3929,6 @@ func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Key) > 0 { - i -= len(x.Key) - copy(dAtA[i:], x.Key) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Key))) - i-- - dAtA[i] = 0x12 - } if len(x.Address) > 0 { i -= len(x.Address) copy(dAtA[i:], x.Address) @@ -4028,7 +3947,7 @@ func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryStorageRequest) + x := input.Message.Interface().(*QueryBalanceRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -4060,10 +3979,10 @@ func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryStorageRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBalanceRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryStorageRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBalanceRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -4098,38 +4017,6 @@ func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods } x.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.Key = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -4166,25 +4053,25 @@ func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods } var ( - md_QueryStorageResponse protoreflect.MessageDescriptor - fd_QueryStorageResponse_value protoreflect.FieldDescriptor + md_QueryBalanceResponse protoreflect.MessageDescriptor + fd_QueryBalanceResponse_balance protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryStorageResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryStorageResponse") - fd_QueryStorageResponse_value = md_QueryStorageResponse.Fields().ByName("value") + md_QueryBalanceResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryBalanceResponse") + fd_QueryBalanceResponse_balance = md_QueryBalanceResponse.Fields().ByName("balance") } -var _ protoreflect.Message = (*fastReflection_QueryStorageResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryBalanceResponse)(nil) -type fastReflection_QueryStorageResponse QueryStorageResponse +type fastReflection_QueryBalanceResponse QueryBalanceResponse -func (x *QueryStorageResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryStorageResponse)(x) +func (x *QueryBalanceResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBalanceResponse)(x) } -func (x *QueryStorageResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryBalanceResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -4196,43 +4083,43 @@ func (x *QueryStorageResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryStorageResponse_messageType fastReflection_QueryStorageResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryStorageResponse_messageType{} +var _fastReflection_QueryBalanceResponse_messageType fastReflection_QueryBalanceResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryBalanceResponse_messageType{} -type fastReflection_QueryStorageResponse_messageType struct{} +type fastReflection_QueryBalanceResponse_messageType struct{} -func (x fastReflection_QueryStorageResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryStorageResponse)(nil) +func (x fastReflection_QueryBalanceResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBalanceResponse)(nil) } -func (x fastReflection_QueryStorageResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryStorageResponse) +func (x fastReflection_QueryBalanceResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBalanceResponse) } -func (x fastReflection_QueryStorageResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryStorageResponse +func (x fastReflection_QueryBalanceResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBalanceResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryStorageResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryStorageResponse +func (x *fastReflection_QueryBalanceResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBalanceResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryStorageResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryStorageResponse_messageType +func (x *fastReflection_QueryBalanceResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryBalanceResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryStorageResponse) New() protoreflect.Message { - return new(fastReflection_QueryStorageResponse) +func (x *fastReflection_QueryBalanceResponse) New() protoreflect.Message { + return new(fastReflection_QueryBalanceResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryStorageResponse) Interface() protoreflect.ProtoMessage { - return (*QueryStorageResponse)(x) +func (x *fastReflection_QueryBalanceResponse) Interface() protoreflect.ProtoMessage { + return (*QueryBalanceResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -4240,10 +4127,10 @@ func (x *fastReflection_QueryStorageResponse) Interface() protoreflect.ProtoMess // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryStorageResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Value != "" { - value := protoreflect.ValueOfString(x.Value) - if !f(fd_QueryStorageResponse_value, value) { +func (x *fastReflection_QueryBalanceResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Balance != "" { + value := protoreflect.ValueOfString(x.Balance) + if !f(fd_QueryBalanceResponse_balance, value) { return } } @@ -4260,15 +4147,15 @@ func (x *fastReflection_QueryStorageResponse) Range(f func(protoreflect.FieldDes // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryStorageResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryBalanceResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryStorageResponse.value": - return x.Value != "" + case "os.evm.v1.QueryBalanceResponse.balance": + return x.Balance != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) } } @@ -4278,15 +4165,15 @@ func (x *fastReflection_QueryStorageResponse) Has(fd protoreflect.FieldDescripto // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryStorageResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryBalanceResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryStorageResponse.value": - x.Value = "" + case "os.evm.v1.QueryBalanceResponse.balance": + x.Balance = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) } } @@ -4296,16 +4183,16 @@ func (x *fastReflection_QueryStorageResponse) Clear(fd protoreflect.FieldDescrip // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryStorageResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryBalanceResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryStorageResponse.value": - value := x.Value + case "os.evm.v1.QueryBalanceResponse.balance": + value := x.Balance return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", descriptor.FullName())) } } @@ -4319,15 +4206,15 @@ func (x *fastReflection_QueryStorageResponse) Get(descriptor protoreflect.FieldD // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryStorageResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryBalanceResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryStorageResponse.value": - x.Value = value.Interface().(string) + case "os.evm.v1.QueryBalanceResponse.balance": + x.Balance = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) } } @@ -4341,40 +4228,40 @@ func (x *fastReflection_QueryStorageResponse) Set(fd protoreflect.FieldDescripto // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryStorageResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryBalanceResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryStorageResponse.value": - panic(fmt.Errorf("field value of message os.evm.v1.QueryStorageResponse is not mutable")) + case "os.evm.v1.QueryBalanceResponse.balance": + panic(fmt.Errorf("field balance of message os.evm.v1.QueryBalanceResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryStorageResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryBalanceResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryStorageResponse.value": + case "os.evm.v1.QueryBalanceResponse.balance": return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBalanceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBalanceResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryStorageResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryBalanceResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryStorageResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryBalanceResponse", d.FullName())) } panic("unreachable") } @@ -4382,7 +4269,7 @@ func (x *fastReflection_QueryStorageResponse) WhichOneof(d protoreflect.OneofDes // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryStorageResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryBalanceResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -4393,7 +4280,7 @@ func (x *fastReflection_QueryStorageResponse) GetUnknown() protoreflect.RawField // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryStorageResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryBalanceResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -4405,7 +4292,7 @@ func (x *fastReflection_QueryStorageResponse) SetUnknown(fields protoreflect.Raw // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryStorageResponse) IsValid() bool { +func (x *fastReflection_QueryBalanceResponse) IsValid() bool { return x != nil } @@ -4415,9 +4302,9 @@ func (x *fastReflection_QueryStorageResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryBalanceResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryStorageResponse) + x := input.Message.Interface().(*QueryBalanceResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -4429,7 +4316,7 @@ func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - l = len(x.Value) + l = len(x.Balance) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -4443,7 +4330,7 @@ func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryStorageResponse) + x := input.Message.Interface().(*QueryBalanceResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -4462,10 +4349,10 @@ func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Value) > 0 { - i -= len(x.Value) - copy(dAtA[i:], x.Value) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Value))) + if len(x.Balance) > 0 { + i -= len(x.Balance) + copy(dAtA[i:], x.Balance) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Balance))) i-- dAtA[i] = 0xa } @@ -4480,7 +4367,7 @@ func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryStorageResponse) + x := input.Message.Interface().(*QueryBalanceResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -4512,15 +4399,15 @@ func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryStorageResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBalanceResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryStorageResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBalanceResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Balance", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -4548,7 +4435,7 @@ func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Value = string(dAtA[iNdEx:postIndex]) + x.Balance = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -4586,25 +4473,27 @@ func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods } var ( - md_QueryCodeRequest protoreflect.MessageDescriptor - fd_QueryCodeRequest_address protoreflect.FieldDescriptor + md_QueryStorageRequest protoreflect.MessageDescriptor + fd_QueryStorageRequest_address protoreflect.FieldDescriptor + fd_QueryStorageRequest_key protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryCodeRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryCodeRequest") - fd_QueryCodeRequest_address = md_QueryCodeRequest.Fields().ByName("address") + md_QueryStorageRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryStorageRequest") + fd_QueryStorageRequest_address = md_QueryStorageRequest.Fields().ByName("address") + fd_QueryStorageRequest_key = md_QueryStorageRequest.Fields().ByName("key") } -var _ protoreflect.Message = (*fastReflection_QueryCodeRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryStorageRequest)(nil) -type fastReflection_QueryCodeRequest QueryCodeRequest +type fastReflection_QueryStorageRequest QueryStorageRequest -func (x *QueryCodeRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryCodeRequest)(x) +func (x *QueryStorageRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryStorageRequest)(x) } -func (x *QueryCodeRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryStorageRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -4616,43 +4505,43 @@ func (x *QueryCodeRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryCodeRequest_messageType fastReflection_QueryCodeRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryCodeRequest_messageType{} +var _fastReflection_QueryStorageRequest_messageType fastReflection_QueryStorageRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryStorageRequest_messageType{} -type fastReflection_QueryCodeRequest_messageType struct{} +type fastReflection_QueryStorageRequest_messageType struct{} -func (x fastReflection_QueryCodeRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryCodeRequest)(nil) +func (x fastReflection_QueryStorageRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryStorageRequest)(nil) } -func (x fastReflection_QueryCodeRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryCodeRequest) +func (x fastReflection_QueryStorageRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryStorageRequest) } -func (x fastReflection_QueryCodeRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryCodeRequest +func (x fastReflection_QueryStorageRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryStorageRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryCodeRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryCodeRequest +func (x *fastReflection_QueryStorageRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryStorageRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryCodeRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryCodeRequest_messageType +func (x *fastReflection_QueryStorageRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryStorageRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryCodeRequest) New() protoreflect.Message { - return new(fastReflection_QueryCodeRequest) +func (x *fastReflection_QueryStorageRequest) New() protoreflect.Message { + return new(fastReflection_QueryStorageRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryCodeRequest) Interface() protoreflect.ProtoMessage { - return (*QueryCodeRequest)(x) +func (x *fastReflection_QueryStorageRequest) Interface() protoreflect.ProtoMessage { + return (*QueryStorageRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -4660,10 +4549,16 @@ func (x *fastReflection_QueryCodeRequest) Interface() protoreflect.ProtoMessage // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryCodeRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +func (x *fastReflection_QueryStorageRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { if x.Address != "" { value := protoreflect.ValueOfString(x.Address) - if !f(fd_QueryCodeRequest_address, value) { + if !f(fd_QueryStorageRequest_address, value) { + return + } + } + if x.Key != "" { + value := protoreflect.ValueOfString(x.Key) + if !f(fd_QueryStorageRequest_key, value) { return } } @@ -4680,15 +4575,17 @@ func (x *fastReflection_QueryCodeRequest) Range(f func(protoreflect.FieldDescrip // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryCodeRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryStorageRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryCodeRequest.address": + case "os.evm.v1.QueryStorageRequest.address": return x.Address != "" + case "os.evm.v1.QueryStorageRequest.key": + return x.Key != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) } } @@ -4698,15 +4595,17 @@ func (x *fastReflection_QueryCodeRequest) Has(fd protoreflect.FieldDescriptor) b // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCodeRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryStorageRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryCodeRequest.address": + case "os.evm.v1.QueryStorageRequest.address": x.Address = "" + case "os.evm.v1.QueryStorageRequest.key": + x.Key = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) } } @@ -4716,16 +4615,19 @@ func (x *fastReflection_QueryCodeRequest) Clear(fd protoreflect.FieldDescriptor) // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryCodeRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryStorageRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryCodeRequest.address": + case "os.evm.v1.QueryStorageRequest.address": value := x.Address return protoreflect.ValueOfString(value) + case "os.evm.v1.QueryStorageRequest.key": + value := x.Key + return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", descriptor.FullName())) } } @@ -4739,15 +4641,17 @@ func (x *fastReflection_QueryCodeRequest) Get(descriptor protoreflect.FieldDescr // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCodeRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryStorageRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryCodeRequest.address": + case "os.evm.v1.QueryStorageRequest.address": x.Address = value.Interface().(string) + case "os.evm.v1.QueryStorageRequest.key": + x.Key = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) } } @@ -4761,40 +4665,44 @@ func (x *fastReflection_QueryCodeRequest) Set(fd protoreflect.FieldDescriptor, v // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCodeRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryStorageRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryCodeRequest.address": - panic(fmt.Errorf("field address of message os.evm.v1.QueryCodeRequest is not mutable")) + case "os.evm.v1.QueryStorageRequest.address": + panic(fmt.Errorf("field address of message os.evm.v1.QueryStorageRequest is not mutable")) + case "os.evm.v1.QueryStorageRequest.key": + panic(fmt.Errorf("field key of message os.evm.v1.QueryStorageRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryCodeRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryStorageRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryCodeRequest.address": + case "os.evm.v1.QueryStorageRequest.address": + return protoreflect.ValueOfString("") + case "os.evm.v1.QueryStorageRequest.key": return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryCodeRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryStorageRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryCodeRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryStorageRequest", d.FullName())) } panic("unreachable") } @@ -4802,7 +4710,7 @@ func (x *fastReflection_QueryCodeRequest) WhichOneof(d protoreflect.OneofDescrip // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryCodeRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryStorageRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -4813,7 +4721,7 @@ func (x *fastReflection_QueryCodeRequest) GetUnknown() protoreflect.RawFields { // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCodeRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryStorageRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -4825,7 +4733,7 @@ func (x *fastReflection_QueryCodeRequest) SetUnknown(fields protoreflect.RawFiel // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryCodeRequest) IsValid() bool { +func (x *fastReflection_QueryStorageRequest) IsValid() bool { return x != nil } @@ -4835,9 +4743,9 @@ func (x *fastReflection_QueryCodeRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryStorageRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryCodeRequest) + x := input.Message.Interface().(*QueryStorageRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -4853,6 +4761,10 @@ func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } + l = len(x.Key) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -4863,7 +4775,7 @@ func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryCodeRequest) + x := input.Message.Interface().(*QueryStorageRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -4882,6 +4794,13 @@ func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if len(x.Key) > 0 { + i -= len(x.Key) + copy(dAtA[i:], x.Key) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Key))) + i-- + dAtA[i] = 0x12 + } if len(x.Address) > 0 { i -= len(x.Address) copy(dAtA[i:], x.Address) @@ -4900,7 +4819,7 @@ func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryCodeRequest) + x := input.Message.Interface().(*QueryStorageRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -4932,10 +4851,10 @@ func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCodeRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryStorageRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCodeRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryStorageRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -4970,6 +4889,38 @@ func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { } x.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Key = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -5006,25 +4957,25 @@ func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { } var ( - md_QueryCodeResponse protoreflect.MessageDescriptor - fd_QueryCodeResponse_code protoreflect.FieldDescriptor + md_QueryStorageResponse protoreflect.MessageDescriptor + fd_QueryStorageResponse_value protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryCodeResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryCodeResponse") - fd_QueryCodeResponse_code = md_QueryCodeResponse.Fields().ByName("code") + md_QueryStorageResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryStorageResponse") + fd_QueryStorageResponse_value = md_QueryStorageResponse.Fields().ByName("value") } -var _ protoreflect.Message = (*fastReflection_QueryCodeResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryStorageResponse)(nil) -type fastReflection_QueryCodeResponse QueryCodeResponse +type fastReflection_QueryStorageResponse QueryStorageResponse -func (x *QueryCodeResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryCodeResponse)(x) +func (x *QueryStorageResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryStorageResponse)(x) } -func (x *QueryCodeResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryStorageResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -5036,43 +4987,43 @@ func (x *QueryCodeResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryCodeResponse_messageType fastReflection_QueryCodeResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryCodeResponse_messageType{} +var _fastReflection_QueryStorageResponse_messageType fastReflection_QueryStorageResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryStorageResponse_messageType{} -type fastReflection_QueryCodeResponse_messageType struct{} +type fastReflection_QueryStorageResponse_messageType struct{} -func (x fastReflection_QueryCodeResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryCodeResponse)(nil) +func (x fastReflection_QueryStorageResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryStorageResponse)(nil) } -func (x fastReflection_QueryCodeResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryCodeResponse) +func (x fastReflection_QueryStorageResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryStorageResponse) } -func (x fastReflection_QueryCodeResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryCodeResponse +func (x fastReflection_QueryStorageResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryStorageResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryCodeResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryCodeResponse +func (x *fastReflection_QueryStorageResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryStorageResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryCodeResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryCodeResponse_messageType +func (x *fastReflection_QueryStorageResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryStorageResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryCodeResponse) New() protoreflect.Message { - return new(fastReflection_QueryCodeResponse) +func (x *fastReflection_QueryStorageResponse) New() protoreflect.Message { + return new(fastReflection_QueryStorageResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryCodeResponse) Interface() protoreflect.ProtoMessage { - return (*QueryCodeResponse)(x) +func (x *fastReflection_QueryStorageResponse) Interface() protoreflect.ProtoMessage { + return (*QueryStorageResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -5080,10 +5031,10 @@ func (x *fastReflection_QueryCodeResponse) Interface() protoreflect.ProtoMessage // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryCodeResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if len(x.Code) != 0 { - value := protoreflect.ValueOfBytes(x.Code) - if !f(fd_QueryCodeResponse_code, value) { +func (x *fastReflection_QueryStorageResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Value != "" { + value := protoreflect.ValueOfString(x.Value) + if !f(fd_QueryStorageResponse_value, value) { return } } @@ -5100,15 +5051,15 @@ func (x *fastReflection_QueryCodeResponse) Range(f func(protoreflect.FieldDescri // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryCodeResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryStorageResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryCodeResponse.code": - return len(x.Code) != 0 + case "os.evm.v1.QueryStorageResponse.value": + return x.Value != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) } } @@ -5118,15 +5069,15 @@ func (x *fastReflection_QueryCodeResponse) Has(fd protoreflect.FieldDescriptor) // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCodeResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryStorageResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryCodeResponse.code": - x.Code = nil + case "os.evm.v1.QueryStorageResponse.value": + x.Value = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) } } @@ -5136,16 +5087,16 @@ func (x *fastReflection_QueryCodeResponse) Clear(fd protoreflect.FieldDescriptor // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryCodeResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryStorageResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryCodeResponse.code": - value := x.Code - return protoreflect.ValueOfBytes(value) + case "os.evm.v1.QueryStorageResponse.value": + value := x.Value + return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", descriptor.FullName())) } } @@ -5159,15 +5110,15 @@ func (x *fastReflection_QueryCodeResponse) Get(descriptor protoreflect.FieldDesc // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCodeResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryStorageResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryCodeResponse.code": - x.Code = value.Bytes() + case "os.evm.v1.QueryStorageResponse.value": + x.Value = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) } } @@ -5181,40 +5132,40 @@ func (x *fastReflection_QueryCodeResponse) Set(fd protoreflect.FieldDescriptor, // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCodeResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryStorageResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryCodeResponse.code": - panic(fmt.Errorf("field code of message os.evm.v1.QueryCodeResponse is not mutable")) + case "os.evm.v1.QueryStorageResponse.value": + panic(fmt.Errorf("field value of message os.evm.v1.QueryStorageResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryCodeResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryStorageResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryCodeResponse.code": - return protoreflect.ValueOfBytes(nil) + case "os.evm.v1.QueryStorageResponse.value": + return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryStorageResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryStorageResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryCodeResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryStorageResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryCodeResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryStorageResponse", d.FullName())) } panic("unreachable") } @@ -5222,7 +5173,7 @@ func (x *fastReflection_QueryCodeResponse) WhichOneof(d protoreflect.OneofDescri // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryCodeResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryStorageResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -5233,7 +5184,7 @@ func (x *fastReflection_QueryCodeResponse) GetUnknown() protoreflect.RawFields { // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryCodeResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryStorageResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -5245,7 +5196,7 @@ func (x *fastReflection_QueryCodeResponse) SetUnknown(fields protoreflect.RawFie // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryCodeResponse) IsValid() bool { +func (x *fastReflection_QueryStorageResponse) IsValid() bool { return x != nil } @@ -5255,9 +5206,9 @@ func (x *fastReflection_QueryCodeResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryStorageResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryCodeResponse) + x := input.Message.Interface().(*QueryStorageResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -5269,7 +5220,7 @@ func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { var n int var l int _ = l - l = len(x.Code) + l = len(x.Value) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -5283,7 +5234,7 @@ func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryCodeResponse) + x := input.Message.Interface().(*QueryStorageResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -5302,10 +5253,10 @@ func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Code) > 0 { - i -= len(x.Code) - copy(dAtA[i:], x.Code) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Code))) + if len(x.Value) > 0 { + i -= len(x.Value) + copy(dAtA[i:], x.Value) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Value))) i-- dAtA[i] = 0xa } @@ -5320,7 +5271,7 @@ func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryCodeResponse) + x := input.Message.Interface().(*QueryStorageResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -5352,17 +5303,17 @@ func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCodeResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryStorageResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCodeResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryStorageResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Code", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } - var byteLen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -5372,25 +5323,23 @@ func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { } b := dAtA[iNdEx] iNdEx++ - byteLen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if byteLen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } - postIndex := iNdEx + byteLen + postIndex := iNdEx + intStringLen if postIndex < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Code = append(x.Code[:0], dAtA[iNdEx:postIndex]...) - if x.Code == nil { - x.Code = []byte{} - } + x.Value = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -5428,27 +5377,25 @@ func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { } var ( - md_QueryTxLogsRequest protoreflect.MessageDescriptor - fd_QueryTxLogsRequest_hash protoreflect.FieldDescriptor - fd_QueryTxLogsRequest_pagination protoreflect.FieldDescriptor + md_QueryCodeRequest protoreflect.MessageDescriptor + fd_QueryCodeRequest_address protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryTxLogsRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryTxLogsRequest") - fd_QueryTxLogsRequest_hash = md_QueryTxLogsRequest.Fields().ByName("hash") - fd_QueryTxLogsRequest_pagination = md_QueryTxLogsRequest.Fields().ByName("pagination") + md_QueryCodeRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryCodeRequest") + fd_QueryCodeRequest_address = md_QueryCodeRequest.Fields().ByName("address") } -var _ protoreflect.Message = (*fastReflection_QueryTxLogsRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryCodeRequest)(nil) -type fastReflection_QueryTxLogsRequest QueryTxLogsRequest +type fastReflection_QueryCodeRequest QueryCodeRequest -func (x *QueryTxLogsRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryTxLogsRequest)(x) +func (x *QueryCodeRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryCodeRequest)(x) } -func (x *QueryTxLogsRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryCodeRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -5460,43 +5407,43 @@ func (x *QueryTxLogsRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryTxLogsRequest_messageType fastReflection_QueryTxLogsRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryTxLogsRequest_messageType{} +var _fastReflection_QueryCodeRequest_messageType fastReflection_QueryCodeRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryCodeRequest_messageType{} -type fastReflection_QueryTxLogsRequest_messageType struct{} +type fastReflection_QueryCodeRequest_messageType struct{} -func (x fastReflection_QueryTxLogsRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryTxLogsRequest)(nil) +func (x fastReflection_QueryCodeRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryCodeRequest)(nil) } -func (x fastReflection_QueryTxLogsRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryTxLogsRequest) +func (x fastReflection_QueryCodeRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryCodeRequest) } -func (x fastReflection_QueryTxLogsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTxLogsRequest +func (x fastReflection_QueryCodeRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCodeRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryTxLogsRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTxLogsRequest +func (x *fastReflection_QueryCodeRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCodeRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryTxLogsRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryTxLogsRequest_messageType +func (x *fastReflection_QueryCodeRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryCodeRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryTxLogsRequest) New() protoreflect.Message { - return new(fastReflection_QueryTxLogsRequest) +func (x *fastReflection_QueryCodeRequest) New() protoreflect.Message { + return new(fastReflection_QueryCodeRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryTxLogsRequest) Interface() protoreflect.ProtoMessage { - return (*QueryTxLogsRequest)(x) +func (x *fastReflection_QueryCodeRequest) Interface() protoreflect.ProtoMessage { + return (*QueryCodeRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -5504,16 +5451,10 @@ func (x *fastReflection_QueryTxLogsRequest) Interface() protoreflect.ProtoMessag // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryTxLogsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Hash != "" { - value := protoreflect.ValueOfString(x.Hash) - if !f(fd_QueryTxLogsRequest_hash, value) { - return - } - } - if x.Pagination != nil { - value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) - if !f(fd_QueryTxLogsRequest_pagination, value) { +func (x *fastReflection_QueryCodeRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_QueryCodeRequest_address, value) { return } } @@ -5530,17 +5471,15 @@ func (x *fastReflection_QueryTxLogsRequest) Range(f func(protoreflect.FieldDescr // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryTxLogsRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryCodeRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsRequest.hash": - return x.Hash != "" - case "os.evm.v1.QueryTxLogsRequest.pagination": - return x.Pagination != nil + case "os.evm.v1.QueryCodeRequest.address": + return x.Address != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) } } @@ -5550,17 +5489,15 @@ func (x *fastReflection_QueryTxLogsRequest) Has(fd protoreflect.FieldDescriptor) // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTxLogsRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryCodeRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsRequest.hash": - x.Hash = "" - case "os.evm.v1.QueryTxLogsRequest.pagination": - x.Pagination = nil + case "os.evm.v1.QueryCodeRequest.address": + x.Address = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) } } @@ -5570,19 +5507,16 @@ func (x *fastReflection_QueryTxLogsRequest) Clear(fd protoreflect.FieldDescripto // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryTxLogsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCodeRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryTxLogsRequest.hash": - value := x.Hash + case "os.evm.v1.QueryCodeRequest.address": + value := x.Address return protoreflect.ValueOfString(value) - case "os.evm.v1.QueryTxLogsRequest.pagination": - value := x.Pagination - return protoreflect.ValueOfMessage(value.ProtoReflect()) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", descriptor.FullName())) } } @@ -5596,17 +5530,15 @@ func (x *fastReflection_QueryTxLogsRequest) Get(descriptor protoreflect.FieldDes // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTxLogsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryCodeRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsRequest.hash": - x.Hash = value.Interface().(string) - case "os.evm.v1.QueryTxLogsRequest.pagination": - x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "os.evm.v1.QueryCodeRequest.address": + x.Address = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) } } @@ -5620,48 +5552,40 @@ func (x *fastReflection_QueryTxLogsRequest) Set(fd protoreflect.FieldDescriptor, // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTxLogsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCodeRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsRequest.pagination": - if x.Pagination == nil { - x.Pagination = new(v1beta1.PageRequest) - } - return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) - case "os.evm.v1.QueryTxLogsRequest.hash": - panic(fmt.Errorf("field hash of message os.evm.v1.QueryTxLogsRequest is not mutable")) + case "os.evm.v1.QueryCodeRequest.address": + panic(fmt.Errorf("field address of message os.evm.v1.QueryCodeRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryTxLogsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCodeRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsRequest.hash": + case "os.evm.v1.QueryCodeRequest.address": return protoreflect.ValueOfString("") - case "os.evm.v1.QueryTxLogsRequest.pagination": - m := new(v1beta1.PageRequest) - return protoreflect.ValueOfMessage(m.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryTxLogsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryCodeRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTxLogsRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryCodeRequest", d.FullName())) } panic("unreachable") } @@ -5669,7 +5593,7 @@ func (x *fastReflection_QueryTxLogsRequest) WhichOneof(d protoreflect.OneofDescr // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryTxLogsRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryCodeRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -5680,7 +5604,7 @@ func (x *fastReflection_QueryTxLogsRequest) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTxLogsRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryCodeRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -5692,7 +5616,7 @@ func (x *fastReflection_QueryTxLogsRequest) SetUnknown(fields protoreflect.RawFi // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryTxLogsRequest) IsValid() bool { +func (x *fastReflection_QueryCodeRequest) IsValid() bool { return x != nil } @@ -5702,9 +5626,9 @@ func (x *fastReflection_QueryTxLogsRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryCodeRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryTxLogsRequest) + x := input.Message.Interface().(*QueryCodeRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -5716,14 +5640,10 @@ func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { var n int var l int _ = l - l = len(x.Hash) + l = len(x.Address) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - if x.Pagination != nil { - l = options.Size(x.Pagination) - n += 1 + l + runtime.Sov(uint64(l)) - } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -5734,7 +5654,7 @@ func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryTxLogsRequest) + x := input.Message.Interface().(*QueryCodeRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -5753,24 +5673,10 @@ func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if x.Pagination != nil { - encoded, err := options.Marshal(x.Pagination) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) - i-- - dAtA[i] = 0x12 - } - if len(x.Hash) > 0 { - i -= len(x.Hash) - copy(dAtA[i:], x.Hash) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Hash))) + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) i-- dAtA[i] = 0xa } @@ -5785,7 +5691,7 @@ func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryTxLogsRequest) + x := input.Message.Interface().(*QueryCodeRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -5817,15 +5723,15 @@ func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTxLogsRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCodeRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTxLogsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCodeRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Hash", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -5853,43 +5759,7 @@ func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Hash = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - if x.Pagination == nil { - x.Pagination = &v1beta1.PageRequest{} - } - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err - } + x.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -5926,79 +5796,26 @@ func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { } } -var _ protoreflect.List = (*_QueryTxLogsResponse_1_list)(nil) - -type _QueryTxLogsResponse_1_list struct { - list *[]*Log -} - -func (x *_QueryTxLogsResponse_1_list) Len() int { - if x.list == nil { - return 0 - } - return len(*x.list) -} - -func (x *_QueryTxLogsResponse_1_list) Get(i int) protoreflect.Value { - return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) -} - -func (x *_QueryTxLogsResponse_1_list) Set(i int, value protoreflect.Value) { - valueUnwrapped := value.Message() - concreteValue := valueUnwrapped.Interface().(*Log) - (*x.list)[i] = concreteValue -} - -func (x *_QueryTxLogsResponse_1_list) Append(value protoreflect.Value) { - valueUnwrapped := value.Message() - concreteValue := valueUnwrapped.Interface().(*Log) - *x.list = append(*x.list, concreteValue) -} - -func (x *_QueryTxLogsResponse_1_list) AppendMutable() protoreflect.Value { - v := new(Log) - *x.list = append(*x.list, v) - return protoreflect.ValueOfMessage(v.ProtoReflect()) -} - -func (x *_QueryTxLogsResponse_1_list) Truncate(n int) { - for i := n; i < len(*x.list); i++ { - (*x.list)[i] = nil - } - *x.list = (*x.list)[:n] -} - -func (x *_QueryTxLogsResponse_1_list) NewElement() protoreflect.Value { - v := new(Log) - return protoreflect.ValueOfMessage(v.ProtoReflect()) -} - -func (x *_QueryTxLogsResponse_1_list) IsValid() bool { - return x.list != nil -} - var ( - md_QueryTxLogsResponse protoreflect.MessageDescriptor - fd_QueryTxLogsResponse_logs protoreflect.FieldDescriptor - fd_QueryTxLogsResponse_pagination protoreflect.FieldDescriptor + md_QueryCodeResponse protoreflect.MessageDescriptor + fd_QueryCodeResponse_code protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryTxLogsResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryTxLogsResponse") - fd_QueryTxLogsResponse_logs = md_QueryTxLogsResponse.Fields().ByName("logs") - fd_QueryTxLogsResponse_pagination = md_QueryTxLogsResponse.Fields().ByName("pagination") + md_QueryCodeResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryCodeResponse") + fd_QueryCodeResponse_code = md_QueryCodeResponse.Fields().ByName("code") } -var _ protoreflect.Message = (*fastReflection_QueryTxLogsResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryCodeResponse)(nil) -type fastReflection_QueryTxLogsResponse QueryTxLogsResponse +type fastReflection_QueryCodeResponse QueryCodeResponse -func (x *QueryTxLogsResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryTxLogsResponse)(x) +func (x *QueryCodeResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryCodeResponse)(x) } -func (x *QueryTxLogsResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryCodeResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -6010,43 +5827,43 @@ func (x *QueryTxLogsResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryTxLogsResponse_messageType fastReflection_QueryTxLogsResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryTxLogsResponse_messageType{} +var _fastReflection_QueryCodeResponse_messageType fastReflection_QueryCodeResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryCodeResponse_messageType{} -type fastReflection_QueryTxLogsResponse_messageType struct{} +type fastReflection_QueryCodeResponse_messageType struct{} -func (x fastReflection_QueryTxLogsResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryTxLogsResponse)(nil) +func (x fastReflection_QueryCodeResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryCodeResponse)(nil) } -func (x fastReflection_QueryTxLogsResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryTxLogsResponse) +func (x fastReflection_QueryCodeResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryCodeResponse) } -func (x fastReflection_QueryTxLogsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTxLogsResponse +func (x fastReflection_QueryCodeResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCodeResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryTxLogsResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTxLogsResponse +func (x *fastReflection_QueryCodeResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCodeResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryTxLogsResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryTxLogsResponse_messageType +func (x *fastReflection_QueryCodeResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryCodeResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryTxLogsResponse) New() protoreflect.Message { - return new(fastReflection_QueryTxLogsResponse) +func (x *fastReflection_QueryCodeResponse) New() protoreflect.Message { + return new(fastReflection_QueryCodeResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryTxLogsResponse) Interface() protoreflect.ProtoMessage { - return (*QueryTxLogsResponse)(x) +func (x *fastReflection_QueryCodeResponse) Interface() protoreflect.ProtoMessage { + return (*QueryCodeResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -6054,16 +5871,10 @@ func (x *fastReflection_QueryTxLogsResponse) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryTxLogsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if len(x.Logs) != 0 { - value := protoreflect.ValueOfList(&_QueryTxLogsResponse_1_list{list: &x.Logs}) - if !f(fd_QueryTxLogsResponse_logs, value) { - return - } - } - if x.Pagination != nil { - value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) - if !f(fd_QueryTxLogsResponse_pagination, value) { +func (x *fastReflection_QueryCodeResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Code) != 0 { + value := protoreflect.ValueOfBytes(x.Code) + if !f(fd_QueryCodeResponse_code, value) { return } } @@ -6080,17 +5891,15 @@ func (x *fastReflection_QueryTxLogsResponse) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryTxLogsResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryCodeResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsResponse.logs": - return len(x.Logs) != 0 - case "os.evm.v1.QueryTxLogsResponse.pagination": - return x.Pagination != nil + case "os.evm.v1.QueryCodeResponse.code": + return len(x.Code) != 0 default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) } } @@ -6100,17 +5909,15 @@ func (x *fastReflection_QueryTxLogsResponse) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTxLogsResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryCodeResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsResponse.logs": - x.Logs = nil - case "os.evm.v1.QueryTxLogsResponse.pagination": - x.Pagination = nil + case "os.evm.v1.QueryCodeResponse.code": + x.Code = nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) } } @@ -6120,22 +5927,16 @@ func (x *fastReflection_QueryTxLogsResponse) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryTxLogsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCodeResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryTxLogsResponse.logs": - if len(x.Logs) == 0 { - return protoreflect.ValueOfList(&_QueryTxLogsResponse_1_list{}) - } - listValue := &_QueryTxLogsResponse_1_list{list: &x.Logs} - return protoreflect.ValueOfList(listValue) - case "os.evm.v1.QueryTxLogsResponse.pagination": - value := x.Pagination - return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "os.evm.v1.QueryCodeResponse.code": + value := x.Code + return protoreflect.ValueOfBytes(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", descriptor.FullName())) } } @@ -6149,19 +5950,15 @@ func (x *fastReflection_QueryTxLogsResponse) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTxLogsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryCodeResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsResponse.logs": - lv := value.List() - clv := lv.(*_QueryTxLogsResponse_1_list) - x.Logs = *clv.list - case "os.evm.v1.QueryTxLogsResponse.pagination": - x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + case "os.evm.v1.QueryCodeResponse.code": + x.Code = value.Bytes() default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) } } @@ -6175,53 +5972,40 @@ func (x *fastReflection_QueryTxLogsResponse) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTxLogsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCodeResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsResponse.logs": - if x.Logs == nil { - x.Logs = []*Log{} - } - value := &_QueryTxLogsResponse_1_list{list: &x.Logs} - return protoreflect.ValueOfList(value) - case "os.evm.v1.QueryTxLogsResponse.pagination": - if x.Pagination == nil { - x.Pagination = new(v1beta1.PageResponse) - } - return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "os.evm.v1.QueryCodeResponse.code": + panic(fmt.Errorf("field code of message os.evm.v1.QueryCodeResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryTxLogsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryCodeResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTxLogsResponse.logs": - list := []*Log{} - return protoreflect.ValueOfList(&_QueryTxLogsResponse_1_list{list: &list}) - case "os.evm.v1.QueryTxLogsResponse.pagination": - m := new(v1beta1.PageResponse) - return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "os.evm.v1.QueryCodeResponse.code": + return protoreflect.ValueOfBytes(nil) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryCodeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryCodeResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryTxLogsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryCodeResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTxLogsResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryCodeResponse", d.FullName())) } panic("unreachable") } @@ -6229,7 +6013,7 @@ func (x *fastReflection_QueryTxLogsResponse) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryTxLogsResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryCodeResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -6240,7 +6024,7 @@ func (x *fastReflection_QueryTxLogsResponse) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTxLogsResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryCodeResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -6252,7 +6036,7 @@ func (x *fastReflection_QueryTxLogsResponse) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryTxLogsResponse) IsValid() bool { +func (x *fastReflection_QueryCodeResponse) IsValid() bool { return x != nil } @@ -6262,9 +6046,9 @@ func (x *fastReflection_QueryTxLogsResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryCodeResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryTxLogsResponse) + x := input.Message.Interface().(*QueryCodeResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -6276,14 +6060,8 @@ func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - if len(x.Logs) > 0 { - for _, e := range x.Logs { - l = options.Size(e) - n += 1 + l + runtime.Sov(uint64(l)) - } - } - if x.Pagination != nil { - l = options.Size(x.Pagination) + l = len(x.Code) + if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } if x.unknownFields != nil { @@ -6296,7 +6074,7 @@ func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryTxLogsResponse) + x := input.Message.Interface().(*QueryCodeResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -6315,35 +6093,12 @@ func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if x.Pagination != nil { - encoded, err := options.Marshal(x.Pagination) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + if len(x.Code) > 0 { + i -= len(x.Code) + copy(dAtA[i:], x.Code) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Code))) i-- - dAtA[i] = 0x12 - } - if len(x.Logs) > 0 { - for iNdEx := len(x.Logs) - 1; iNdEx >= 0; iNdEx-- { - encoded, err := options.Marshal(x.Logs[iNdEx]) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) - i-- - dAtA[i] = 0xa - } + dAtA[i] = 0xa } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) @@ -6356,7 +6111,7 @@ func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryTxLogsResponse) + x := input.Message.Interface().(*QueryCodeResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -6388,51 +6143,17 @@ func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTxLogsResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCodeResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTxLogsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCodeResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Logs", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.Logs = append(x.Logs, &Log{}) - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Logs[len(x.Logs)-1]); err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Code", wireType) } - var msglen int + var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -6442,26 +6163,24 @@ func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + byteLen |= int(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + if byteLen < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } - postIndex := iNdEx + msglen + postIndex := iNdEx + byteLen if postIndex < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - if x.Pagination == nil { - x.Pagination = &v1beta1.PageResponse{} - } - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + x.Code = append(x.Code[:0], dAtA[iNdEx:postIndex]...) + if x.Code == nil { + x.Code = []byte{} } iNdEx = postIndex default: @@ -6500,23 +6219,27 @@ func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods } var ( - md_QueryParamsRequest protoreflect.MessageDescriptor + md_QueryTxLogsRequest protoreflect.MessageDescriptor + fd_QueryTxLogsRequest_hash protoreflect.FieldDescriptor + fd_QueryTxLogsRequest_pagination protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryParamsRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryParamsRequest") + md_QueryTxLogsRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryTxLogsRequest") + fd_QueryTxLogsRequest_hash = md_QueryTxLogsRequest.Fields().ByName("hash") + fd_QueryTxLogsRequest_pagination = md_QueryTxLogsRequest.Fields().ByName("pagination") } -var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryTxLogsRequest)(nil) -type fastReflection_QueryParamsRequest QueryParamsRequest +type fastReflection_QueryTxLogsRequest QueryTxLogsRequest -func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryParamsRequest)(x) +func (x *QueryTxLogsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryTxLogsRequest)(x) } -func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryTxLogsRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -6528,43 +6251,43 @@ func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} +var _fastReflection_QueryTxLogsRequest_messageType fastReflection_QueryTxLogsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryTxLogsRequest_messageType{} -type fastReflection_QueryParamsRequest_messageType struct{} +type fastReflection_QueryTxLogsRequest_messageType struct{} -func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryParamsRequest)(nil) +func (x fastReflection_QueryTxLogsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryTxLogsRequest)(nil) } -func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryParamsRequest) +func (x fastReflection_QueryTxLogsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryTxLogsRequest) } -func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryParamsRequest +func (x fastReflection_QueryTxLogsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTxLogsRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryParamsRequest +func (x *fastReflection_QueryTxLogsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTxLogsRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryParamsRequest_messageType +func (x *fastReflection_QueryTxLogsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryTxLogsRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { - return new(fastReflection_QueryParamsRequest) +func (x *fastReflection_QueryTxLogsRequest) New() protoreflect.Message { + return new(fastReflection_QueryTxLogsRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { - return (*QueryParamsRequest)(x) +func (x *fastReflection_QueryTxLogsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryTxLogsRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -6572,27 +6295,43 @@ func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessag // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { -} - -// Has reports whether a field is populated. -// -// Some fields have the property of nullability where it is possible to -// distinguish between the default value of a field and whether the field -// was explicitly populated with the default value. Singular message fields, -// member fields of a oneof, and proto2 scalar fields are nullable. Such -// fields are populated only if explicitly set. +func (x *fastReflection_QueryTxLogsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Hash != "" { + value := protoreflect.ValueOfString(x.Hash) + if !f(fd_QueryTxLogsRequest_hash, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryTxLogsRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. // // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryTxLogsRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { + case "os.evm.v1.QueryTxLogsRequest.hash": + return x.Hash != "" + case "os.evm.v1.QueryTxLogsRequest.pagination": + return x.Pagination != nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) } } @@ -6602,13 +6341,17 @@ func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryTxLogsRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { + case "os.evm.v1.QueryTxLogsRequest.hash": + x.Hash = "" + case "os.evm.v1.QueryTxLogsRequest.pagination": + x.Pagination = nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) } } @@ -6618,13 +6361,19 @@ func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescripto // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTxLogsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { + case "os.evm.v1.QueryTxLogsRequest.hash": + value := x.Hash + return protoreflect.ValueOfString(value) + case "os.evm.v1.QueryTxLogsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", descriptor.FullName())) } } @@ -6638,13 +6387,17 @@ func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDes // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryTxLogsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { + case "os.evm.v1.QueryTxLogsRequest.hash": + x.Hash = value.Interface().(string) + case "os.evm.v1.QueryTxLogsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) } } @@ -6658,36 +6411,48 @@ func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTxLogsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { + case "os.evm.v1.QueryTxLogsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "os.evm.v1.QueryTxLogsRequest.hash": + panic(fmt.Errorf("field hash of message os.evm.v1.QueryTxLogsRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTxLogsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { + case "os.evm.v1.QueryTxLogsRequest.hash": + return protoreflect.ValueOfString("") + case "os.evm.v1.QueryTxLogsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryTxLogsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryParamsRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTxLogsRequest", d.FullName())) } panic("unreachable") } @@ -6695,7 +6460,7 @@ func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescr // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryTxLogsRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -6706,7 +6471,7 @@ func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryTxLogsRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -6718,7 +6483,7 @@ func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFi // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryParamsRequest) IsValid() bool { +func (x *fastReflection_QueryTxLogsRequest) IsValid() bool { return x != nil } @@ -6728,9 +6493,9 @@ func (x *fastReflection_QueryParamsRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryTxLogsRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryParamsRequest) + x := input.Message.Interface().(*QueryTxLogsRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -6742,6 +6507,14 @@ func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { var n int var l int _ = l + l = len(x.Hash) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -6752,7 +6525,7 @@ func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryParamsRequest) + x := input.Message.Interface().(*QueryTxLogsRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -6771,6 +6544,27 @@ func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Hash) > 0 { + i -= len(x.Hash) + copy(dAtA[i:], x.Hash) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Hash))) + i-- + dAtA[i] = 0xa + } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) } else { @@ -6782,7 +6576,7 @@ func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryParamsRequest) + x := input.Message.Interface().(*QueryTxLogsRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -6814,12 +6608,80 @@ func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTxLogsRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTxLogsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Hash", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Hash = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -6855,74 +6717,127 @@ func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { } } -var ( - md_QueryParamsResponse protoreflect.MessageDescriptor - fd_QueryParamsResponse_params protoreflect.FieldDescriptor -) +var _ protoreflect.List = (*_QueryTxLogsResponse_1_list)(nil) -func init() { - file_os_evm_v1_query_proto_init() - md_QueryParamsResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryParamsResponse") - fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +type _QueryTxLogsResponse_1_list struct { + list *[]*Log } -var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) +func (x *_QueryTxLogsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} -type fastReflection_QueryParamsResponse QueryParamsResponse +func (x *_QueryTxLogsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} -func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryParamsResponse)(x) +func (x *_QueryTxLogsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Log) + (*x.list)[i] = concreteValue } -func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { - mi := &file_os_evm_v1_query_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) +func (x *_QueryTxLogsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Log) + *x.list = append(*x.list, concreteValue) } -var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} +func (x *_QueryTxLogsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Log) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} -type fastReflection_QueryParamsResponse_messageType struct{} +func (x *_QueryTxLogsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} -func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryParamsResponse)(nil) +func (x *_QueryTxLogsResponse_1_list) NewElement() protoreflect.Value { + v := new(Log) + return protoreflect.ValueOfMessage(v.ProtoReflect()) } -func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryParamsResponse) + +func (x *_QueryTxLogsResponse_1_list) IsValid() bool { + return x.list != nil } -func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryParamsResponse + +var ( + md_QueryTxLogsResponse protoreflect.MessageDescriptor + fd_QueryTxLogsResponse_logs protoreflect.FieldDescriptor + fd_QueryTxLogsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_os_evm_v1_query_proto_init() + md_QueryTxLogsResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryTxLogsResponse") + fd_QueryTxLogsResponse_logs = md_QueryTxLogsResponse.Fields().ByName("logs") + fd_QueryTxLogsResponse_pagination = md_QueryTxLogsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryTxLogsResponse)(nil) + +type fastReflection_QueryTxLogsResponse QueryTxLogsResponse + +func (x *QueryTxLogsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryTxLogsResponse)(x) +} + +func (x *QueryTxLogsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_os_evm_v1_query_proto_msgTypes[15] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryTxLogsResponse_messageType fastReflection_QueryTxLogsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryTxLogsResponse_messageType{} + +type fastReflection_QueryTxLogsResponse_messageType struct{} + +func (x fastReflection_QueryTxLogsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryTxLogsResponse)(nil) +} +func (x fastReflection_QueryTxLogsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryTxLogsResponse) +} +func (x fastReflection_QueryTxLogsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTxLogsResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryParamsResponse +func (x *fastReflection_QueryTxLogsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTxLogsResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryParamsResponse_messageType +func (x *fastReflection_QueryTxLogsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryTxLogsResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { - return new(fastReflection_QueryParamsResponse) +func (x *fastReflection_QueryTxLogsResponse) New() protoreflect.Message { + return new(fastReflection_QueryTxLogsResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { - return (*QueryParamsResponse)(x) +func (x *fastReflection_QueryTxLogsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryTxLogsResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -6930,10 +6845,16 @@ func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Params != nil { - value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) - if !f(fd_QueryParamsResponse_params, value) { +func (x *fastReflection_QueryTxLogsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Logs) != 0 { + value := protoreflect.ValueOfList(&_QueryTxLogsResponse_1_list{list: &x.Logs}) + if !f(fd_QueryTxLogsResponse_logs, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryTxLogsResponse_pagination, value) { return } } @@ -6950,15 +6871,17 @@ func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryTxLogsResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryParamsResponse.params": - return x.Params != nil + case "os.evm.v1.QueryTxLogsResponse.logs": + return len(x.Logs) != 0 + case "os.evm.v1.QueryTxLogsResponse.pagination": + return x.Pagination != nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) } } @@ -6968,15 +6891,17 @@ func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryTxLogsResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryParamsResponse.params": - x.Params = nil + case "os.evm.v1.QueryTxLogsResponse.logs": + x.Logs = nil + case "os.evm.v1.QueryTxLogsResponse.pagination": + x.Pagination = nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) } } @@ -6986,16 +6911,22 @@ func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTxLogsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryParamsResponse.params": - value := x.Params + case "os.evm.v1.QueryTxLogsResponse.logs": + if len(x.Logs) == 0 { + return protoreflect.ValueOfList(&_QueryTxLogsResponse_1_list{}) + } + listValue := &_QueryTxLogsResponse_1_list{list: &x.Logs} + return protoreflect.ValueOfList(listValue) + case "os.evm.v1.QueryTxLogsResponse.pagination": + value := x.Pagination return protoreflect.ValueOfMessage(value.ProtoReflect()) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", descriptor.FullName())) } } @@ -7009,15 +6940,19 @@ func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryTxLogsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryParamsResponse.params": - x.Params = value.Message().Interface().(*Params) + case "os.evm.v1.QueryTxLogsResponse.logs": + lv := value.List() + clv := lv.(*_QueryTxLogsResponse_1_list) + x.Logs = *clv.list + case "os.evm.v1.QueryTxLogsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) } } @@ -7031,44 +6966,53 @@ func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTxLogsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryParamsResponse.params": - if x.Params == nil { - x.Params = new(Params) + case "os.evm.v1.QueryTxLogsResponse.logs": + if x.Logs == nil { + x.Logs = []*Log{} } - return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + value := &_QueryTxLogsResponse_1_list{list: &x.Logs} + return protoreflect.ValueOfList(value) + case "os.evm.v1.QueryTxLogsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTxLogsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryParamsResponse.params": - m := new(Params) + case "os.evm.v1.QueryTxLogsResponse.logs": + list := []*Log{} + return protoreflect.ValueOfList(&_QueryTxLogsResponse_1_list{list: &list}) + case "os.evm.v1.QueryTxLogsResponse.pagination": + m := new(v1beta1.PageResponse) return protoreflect.ValueOfMessage(m.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTxLogsResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTxLogsResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryTxLogsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryParamsResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTxLogsResponse", d.FullName())) } panic("unreachable") } @@ -7076,7 +7020,7 @@ func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryTxLogsResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -7087,7 +7031,7 @@ func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryTxLogsResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -7099,7 +7043,7 @@ func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryParamsResponse) IsValid() bool { +func (x *fastReflection_QueryTxLogsResponse) IsValid() bool { return x != nil } @@ -7109,9 +7053,9 @@ func (x *fastReflection_QueryParamsResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryTxLogsResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryParamsResponse) + x := input.Message.Interface().(*QueryTxLogsResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -7123,8 +7067,14 @@ func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - if x.Params != nil { - l = options.Size(x.Params) + if len(x.Logs) > 0 { + for _, e := range x.Logs { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) n += 1 + l + runtime.Sov(uint64(l)) } if x.unknownFields != nil { @@ -7137,7 +7087,7 @@ func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryParamsResponse) + x := input.Message.Interface().(*QueryTxLogsResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -7156,8 +7106,8 @@ func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if x.Params != nil { - encoded, err := options.Marshal(x.Params) + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) if err != nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -7168,7 +7118,23 @@ func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods copy(dAtA[i:], encoded) i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) i-- - dAtA[i] = 0xa + dAtA[i] = 0x12 + } + if len(x.Logs) > 0 { + for iNdEx := len(x.Logs) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Logs[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) @@ -7181,7 +7147,7 @@ func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryParamsResponse) + x := input.Message.Interface().(*QueryTxLogsResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -7213,15 +7179,15 @@ func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTxLogsResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTxLogsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Logs", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7248,21 +7214,55 @@ func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - if x.Params == nil { - x.Params = &Params{} - } - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + x.Logs = append(x.Logs, &Log{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Logs[len(x.Logs)-1]); err != nil { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := runtime.Skip(dAtA[iNdEx:]) - if err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } if (iNdEx + skippy) > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF @@ -7291,31 +7291,23 @@ func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods } var ( - md_EthCallRequest protoreflect.MessageDescriptor - fd_EthCallRequest_args protoreflect.FieldDescriptor - fd_EthCallRequest_gas_cap protoreflect.FieldDescriptor - fd_EthCallRequest_proposer_address protoreflect.FieldDescriptor - fd_EthCallRequest_chain_id protoreflect.FieldDescriptor + md_QueryParamsRequest protoreflect.MessageDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_EthCallRequest = File_os_evm_v1_query_proto.Messages().ByName("EthCallRequest") - fd_EthCallRequest_args = md_EthCallRequest.Fields().ByName("args") - fd_EthCallRequest_gas_cap = md_EthCallRequest.Fields().ByName("gas_cap") - fd_EthCallRequest_proposer_address = md_EthCallRequest.Fields().ByName("proposer_address") - fd_EthCallRequest_chain_id = md_EthCallRequest.Fields().ByName("chain_id") + md_QueryParamsRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryParamsRequest") } -var _ protoreflect.Message = (*fastReflection_EthCallRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) -type fastReflection_EthCallRequest EthCallRequest +type fastReflection_QueryParamsRequest QueryParamsRequest -func (x *EthCallRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_EthCallRequest)(x) +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) } -func (x *EthCallRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -7327,43 +7319,43 @@ func (x *EthCallRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_EthCallRequest_messageType fastReflection_EthCallRequest_messageType -var _ protoreflect.MessageType = fastReflection_EthCallRequest_messageType{} +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} -type fastReflection_EthCallRequest_messageType struct{} +type fastReflection_QueryParamsRequest_messageType struct{} -func (x fastReflection_EthCallRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_EthCallRequest)(nil) +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) } -func (x fastReflection_EthCallRequest_messageType) New() protoreflect.Message { - return new(fastReflection_EthCallRequest) +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) } -func (x fastReflection_EthCallRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_EthCallRequest +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_EthCallRequest) Descriptor() protoreflect.MessageDescriptor { - return md_EthCallRequest +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_EthCallRequest) Type() protoreflect.MessageType { - return _fastReflection_EthCallRequest_messageType +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_EthCallRequest) New() protoreflect.Message { - return new(fastReflection_EthCallRequest) +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_EthCallRequest) Interface() protoreflect.ProtoMessage { - return (*EthCallRequest)(x) +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -7371,31 +7363,7 @@ func (x *fastReflection_EthCallRequest) Interface() protoreflect.ProtoMessage { // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_EthCallRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if len(x.Args) != 0 { - value := protoreflect.ValueOfBytes(x.Args) - if !f(fd_EthCallRequest_args, value) { - return - } - } - if x.GasCap != uint64(0) { - value := protoreflect.ValueOfUint64(x.GasCap) - if !f(fd_EthCallRequest_gas_cap, value) { - return - } - } - if len(x.ProposerAddress) != 0 { - value := protoreflect.ValueOfBytes(x.ProposerAddress) - if !f(fd_EthCallRequest_proposer_address, value) { - return - } - } - if x.ChainId != int64(0) { - value := protoreflect.ValueOfInt64(x.ChainId) - if !f(fd_EthCallRequest_chain_id, value) { - return - } - } +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { } // Has reports whether a field is populated. @@ -7409,21 +7377,13 @@ func (x *fastReflection_EthCallRequest) Range(f func(protoreflect.FieldDescripto // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_EthCallRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.EthCallRequest.args": - return len(x.Args) != 0 - case "os.evm.v1.EthCallRequest.gas_cap": - return x.GasCap != uint64(0) - case "os.evm.v1.EthCallRequest.proposer_address": - return len(x.ProposerAddress) != 0 - case "os.evm.v1.EthCallRequest.chain_id": - return x.ChainId != int64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) } - panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) } } @@ -7433,21 +7393,13 @@ func (x *fastReflection_EthCallRequest) Has(fd protoreflect.FieldDescriptor) boo // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_EthCallRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.EthCallRequest.args": - x.Args = nil - case "os.evm.v1.EthCallRequest.gas_cap": - x.GasCap = uint64(0) - case "os.evm.v1.EthCallRequest.proposer_address": - x.ProposerAddress = nil - case "os.evm.v1.EthCallRequest.chain_id": - x.ChainId = int64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) } - panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) } } @@ -7457,25 +7409,13 @@ func (x *fastReflection_EthCallRequest) Clear(fd protoreflect.FieldDescriptor) { // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_EthCallRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.EthCallRequest.args": - value := x.Args - return protoreflect.ValueOfBytes(value) - case "os.evm.v1.EthCallRequest.gas_cap": - value := x.GasCap - return protoreflect.ValueOfUint64(value) - case "os.evm.v1.EthCallRequest.proposer_address": - value := x.ProposerAddress - return protoreflect.ValueOfBytes(value) - case "os.evm.v1.EthCallRequest.chain_id": - value := x.ChainId - return protoreflect.ValueOfInt64(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) } - panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", descriptor.FullName())) } } @@ -7489,21 +7429,13 @@ func (x *fastReflection_EthCallRequest) Get(descriptor protoreflect.FieldDescrip // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_EthCallRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.EthCallRequest.args": - x.Args = value.Bytes() - case "os.evm.v1.EthCallRequest.gas_cap": - x.GasCap = value.Uint() - case "os.evm.v1.EthCallRequest.proposer_address": - x.ProposerAddress = value.Bytes() - case "os.evm.v1.EthCallRequest.chain_id": - x.ChainId = value.Int() default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) } - panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) } } @@ -7517,52 +7449,36 @@ func (x *fastReflection_EthCallRequest) Set(fd protoreflect.FieldDescriptor, val // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_EthCallRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.EthCallRequest.args": - panic(fmt.Errorf("field args of message os.evm.v1.EthCallRequest is not mutable")) - case "os.evm.v1.EthCallRequest.gas_cap": - panic(fmt.Errorf("field gas_cap of message os.evm.v1.EthCallRequest is not mutable")) - case "os.evm.v1.EthCallRequest.proposer_address": - panic(fmt.Errorf("field proposer_address of message os.evm.v1.EthCallRequest is not mutable")) - case "os.evm.v1.EthCallRequest.chain_id": - panic(fmt.Errorf("field chain_id of message os.evm.v1.EthCallRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) } - panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_EthCallRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.EthCallRequest.args": - return protoreflect.ValueOfBytes(nil) - case "os.evm.v1.EthCallRequest.gas_cap": - return protoreflect.ValueOfUint64(uint64(0)) - case "os.evm.v1.EthCallRequest.proposer_address": - return protoreflect.ValueOfBytes(nil) - case "os.evm.v1.EthCallRequest.chain_id": - return protoreflect.ValueOfInt64(int64(0)) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsRequest")) } - panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_EthCallRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.EthCallRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryParamsRequest", d.FullName())) } panic("unreachable") } @@ -7570,7 +7486,7 @@ func (x *fastReflection_EthCallRequest) WhichOneof(d protoreflect.OneofDescripto // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_EthCallRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -7581,7 +7497,7 @@ func (x *fastReflection_EthCallRequest) GetUnknown() protoreflect.RawFields { // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_EthCallRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -7593,7 +7509,7 @@ func (x *fastReflection_EthCallRequest) SetUnknown(fields protoreflect.RawFields // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_EthCallRequest) IsValid() bool { +func (x *fastReflection_QueryParamsRequest) IsValid() bool { return x != nil } @@ -7603,9 +7519,9 @@ func (x *fastReflection_EthCallRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_EthCallRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*EthCallRequest) + x := input.Message.Interface().(*QueryParamsRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -7617,20 +7533,6 @@ func (x *fastReflection_EthCallRequest) ProtoMethods() *protoiface.Methods { var n int var l int _ = l - l = len(x.Args) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } - if x.GasCap != 0 { - n += 1 + runtime.Sov(uint64(x.GasCap)) - } - l = len(x.ProposerAddress) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } - if x.ChainId != 0 { - n += 1 + runtime.Sov(uint64(x.ChainId)) - } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -7641,7 +7543,7 @@ func (x *fastReflection_EthCallRequest) ProtoMethods() *protoiface.Methods { } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*EthCallRequest) + x := input.Message.Interface().(*QueryParamsRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -7660,34 +7562,10 @@ func (x *fastReflection_EthCallRequest) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if x.ChainId != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.ChainId)) - i-- - dAtA[i] = 0x20 - } - if len(x.ProposerAddress) > 0 { - i -= len(x.ProposerAddress) - copy(dAtA[i:], x.ProposerAddress) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ProposerAddress))) - i-- - dAtA[i] = 0x1a - } - if x.GasCap != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.GasCap)) - i-- - dAtA[i] = 0x10 - } - if len(x.Args) > 0 { - i -= len(x.Args) - copy(dAtA[i:], x.Args) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Args))) - i-- - dAtA[i] = 0xa - } - if input.Buf != nil { - input.Buf = append(input.Buf, dAtA...) - } else { - input.Buf = dAtA + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA } return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -7695,7 +7573,7 @@ func (x *fastReflection_EthCallRequest) ProtoMethods() *protoiface.Methods { }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*EthCallRequest) + x := input.Message.Interface().(*QueryParamsRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -7727,118 +7605,12 @@ func (x *fastReflection_EthCallRequest) ProtoMethods() *protoiface.Methods { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: EthCallRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: EthCallRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 1: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Args", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + byteLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.Args = append(x.Args[:0], dAtA[iNdEx:postIndex]...) - if x.Args == nil { - x.Args = []byte{} - } - iNdEx = postIndex - case 2: - if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field GasCap", wireType) - } - x.GasCap = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - x.GasCap |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 3: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposerAddress", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + byteLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.ProposerAddress = append(x.ProposerAddress[:0], dAtA[iNdEx:postIndex]...) - if x.ProposerAddress == nil { - x.ProposerAddress = []byte{} - } - iNdEx = postIndex - case 4: - if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType) - } - x.ChainId = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - x.ChainId |= int64(b&0x7F) << shift - if b < 0x80 { - break - } - } default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -7875,25 +7647,25 @@ func (x *fastReflection_EthCallRequest) ProtoMethods() *protoiface.Methods { } var ( - md_EstimateGasResponse protoreflect.MessageDescriptor - fd_EstimateGasResponse_gas protoreflect.FieldDescriptor + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_EstimateGasResponse = File_os_evm_v1_query_proto.Messages().ByName("EstimateGasResponse") - fd_EstimateGasResponse_gas = md_EstimateGasResponse.Fields().ByName("gas") + md_QueryParamsResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") } -var _ protoreflect.Message = (*fastReflection_EstimateGasResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) -type fastReflection_EstimateGasResponse EstimateGasResponse +type fastReflection_QueryParamsResponse QueryParamsResponse -func (x *EstimateGasResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_EstimateGasResponse)(x) +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) } -func (x *EstimateGasResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -7905,43 +7677,43 @@ func (x *EstimateGasResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_EstimateGasResponse_messageType fastReflection_EstimateGasResponse_messageType -var _ protoreflect.MessageType = fastReflection_EstimateGasResponse_messageType{} +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} -type fastReflection_EstimateGasResponse_messageType struct{} +type fastReflection_QueryParamsResponse_messageType struct{} -func (x fastReflection_EstimateGasResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_EstimateGasResponse)(nil) +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) } -func (x fastReflection_EstimateGasResponse_messageType) New() protoreflect.Message { - return new(fastReflection_EstimateGasResponse) +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) } -func (x fastReflection_EstimateGasResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_EstimateGasResponse +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_EstimateGasResponse) Descriptor() protoreflect.MessageDescriptor { - return md_EstimateGasResponse +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_EstimateGasResponse) Type() protoreflect.MessageType { - return _fastReflection_EstimateGasResponse_messageType +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_EstimateGasResponse) New() protoreflect.Message { - return new(fastReflection_EstimateGasResponse) +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_EstimateGasResponse) Interface() protoreflect.ProtoMessage { - return (*EstimateGasResponse)(x) +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -7949,10 +7721,10 @@ func (x *fastReflection_EstimateGasResponse) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_EstimateGasResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Gas != uint64(0) { - value := protoreflect.ValueOfUint64(x.Gas) - if !f(fd_EstimateGasResponse_gas, value) { +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { return } } @@ -7969,15 +7741,15 @@ func (x *fastReflection_EstimateGasResponse) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_EstimateGasResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.EstimateGasResponse.gas": - return x.Gas != uint64(0) + case "os.evm.v1.QueryParamsResponse.params": + return x.Params != nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) } - panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) } } @@ -7987,15 +7759,15 @@ func (x *fastReflection_EstimateGasResponse) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_EstimateGasResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.EstimateGasResponse.gas": - x.Gas = uint64(0) + case "os.evm.v1.QueryParamsResponse.params": + x.Params = nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) } - panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) } } @@ -8005,16 +7777,16 @@ func (x *fastReflection_EstimateGasResponse) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_EstimateGasResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.EstimateGasResponse.gas": - value := x.Gas - return protoreflect.ValueOfUint64(value) + case "os.evm.v1.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) } - panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", descriptor.FullName())) } } @@ -8028,15 +7800,15 @@ func (x *fastReflection_EstimateGasResponse) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_EstimateGasResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.EstimateGasResponse.gas": - x.Gas = value.Uint() + case "os.evm.v1.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) } - panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) } } @@ -8050,40 +7822,44 @@ func (x *fastReflection_EstimateGasResponse) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_EstimateGasResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.EstimateGasResponse.gas": - panic(fmt.Errorf("field gas of message os.evm.v1.EstimateGasResponse is not mutable")) + case "os.evm.v1.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) } - panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_EstimateGasResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.EstimateGasResponse.gas": - return protoreflect.ValueOfUint64(uint64(0)) + case "os.evm.v1.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryParamsResponse")) } - panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryParamsResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_EstimateGasResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.EstimateGasResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryParamsResponse", d.FullName())) } panic("unreachable") } @@ -8091,7 +7867,7 @@ func (x *fastReflection_EstimateGasResponse) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_EstimateGasResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -8102,7 +7878,7 @@ func (x *fastReflection_EstimateGasResponse) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_EstimateGasResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -8114,7 +7890,7 @@ func (x *fastReflection_EstimateGasResponse) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_EstimateGasResponse) IsValid() bool { +func (x *fastReflection_QueryParamsResponse) IsValid() bool { return x != nil } @@ -8124,9 +7900,9 @@ func (x *fastReflection_EstimateGasResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*EstimateGasResponse) + x := input.Message.Interface().(*QueryParamsResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -8138,8 +7914,9 @@ func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - if x.Gas != 0 { - n += 1 + runtime.Sov(uint64(x.Gas)) + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) } if x.unknownFields != nil { n += len(x.unknownFields) @@ -8151,7 +7928,7 @@ func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*EstimateGasResponse) + x := input.Message.Interface().(*QueryParamsResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -8170,10 +7947,19 @@ func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if x.Gas != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.Gas)) + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) i-- - dAtA[i] = 0x8 + dAtA[i] = 0xa } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) @@ -8186,7 +7972,7 @@ func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*EstimateGasResponse) + x := input.Message.Interface().(*QueryParamsResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -8218,17 +8004,17 @@ func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: EstimateGasResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: EstimateGasResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Gas", wireType) + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } - x.Gas = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -8238,11 +8024,28 @@ func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods } b := dAtA[iNdEx] iNdEx++ - x.Gas |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -8278,93 +8081,32 @@ func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods } } -var _ protoreflect.List = (*_QueryTraceTxRequest_4_list)(nil) - -type _QueryTraceTxRequest_4_list struct { - list *[]*MsgEthereumTx -} - -func (x *_QueryTraceTxRequest_4_list) Len() int { - if x.list == nil { - return 0 - } - return len(*x.list) -} - -func (x *_QueryTraceTxRequest_4_list) Get(i int) protoreflect.Value { - return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) -} - -func (x *_QueryTraceTxRequest_4_list) Set(i int, value protoreflect.Value) { - valueUnwrapped := value.Message() - concreteValue := valueUnwrapped.Interface().(*MsgEthereumTx) - (*x.list)[i] = concreteValue -} - -func (x *_QueryTraceTxRequest_4_list) Append(value protoreflect.Value) { - valueUnwrapped := value.Message() - concreteValue := valueUnwrapped.Interface().(*MsgEthereumTx) - *x.list = append(*x.list, concreteValue) -} - -func (x *_QueryTraceTxRequest_4_list) AppendMutable() protoreflect.Value { - v := new(MsgEthereumTx) - *x.list = append(*x.list, v) - return protoreflect.ValueOfMessage(v.ProtoReflect()) -} - -func (x *_QueryTraceTxRequest_4_list) Truncate(n int) { - for i := n; i < len(*x.list); i++ { - (*x.list)[i] = nil - } - *x.list = (*x.list)[:n] -} - -func (x *_QueryTraceTxRequest_4_list) NewElement() protoreflect.Value { - v := new(MsgEthereumTx) - return protoreflect.ValueOfMessage(v.ProtoReflect()) -} - -func (x *_QueryTraceTxRequest_4_list) IsValid() bool { - return x.list != nil -} - var ( - md_QueryTraceTxRequest protoreflect.MessageDescriptor - fd_QueryTraceTxRequest_msg protoreflect.FieldDescriptor - fd_QueryTraceTxRequest_trace_config protoreflect.FieldDescriptor - fd_QueryTraceTxRequest_predecessors protoreflect.FieldDescriptor - fd_QueryTraceTxRequest_block_number protoreflect.FieldDescriptor - fd_QueryTraceTxRequest_block_hash protoreflect.FieldDescriptor - fd_QueryTraceTxRequest_block_time protoreflect.FieldDescriptor - fd_QueryTraceTxRequest_proposer_address protoreflect.FieldDescriptor - fd_QueryTraceTxRequest_chain_id protoreflect.FieldDescriptor - fd_QueryTraceTxRequest_block_max_gas protoreflect.FieldDescriptor + md_EthCallRequest protoreflect.MessageDescriptor + fd_EthCallRequest_args protoreflect.FieldDescriptor + fd_EthCallRequest_gas_cap protoreflect.FieldDescriptor + fd_EthCallRequest_proposer_address protoreflect.FieldDescriptor + fd_EthCallRequest_chain_id protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryTraceTxRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryTraceTxRequest") - fd_QueryTraceTxRequest_msg = md_QueryTraceTxRequest.Fields().ByName("msg") - fd_QueryTraceTxRequest_trace_config = md_QueryTraceTxRequest.Fields().ByName("trace_config") - fd_QueryTraceTxRequest_predecessors = md_QueryTraceTxRequest.Fields().ByName("predecessors") - fd_QueryTraceTxRequest_block_number = md_QueryTraceTxRequest.Fields().ByName("block_number") - fd_QueryTraceTxRequest_block_hash = md_QueryTraceTxRequest.Fields().ByName("block_hash") - fd_QueryTraceTxRequest_block_time = md_QueryTraceTxRequest.Fields().ByName("block_time") - fd_QueryTraceTxRequest_proposer_address = md_QueryTraceTxRequest.Fields().ByName("proposer_address") - fd_QueryTraceTxRequest_chain_id = md_QueryTraceTxRequest.Fields().ByName("chain_id") - fd_QueryTraceTxRequest_block_max_gas = md_QueryTraceTxRequest.Fields().ByName("block_max_gas") + md_EthCallRequest = File_os_evm_v1_query_proto.Messages().ByName("EthCallRequest") + fd_EthCallRequest_args = md_EthCallRequest.Fields().ByName("args") + fd_EthCallRequest_gas_cap = md_EthCallRequest.Fields().ByName("gas_cap") + fd_EthCallRequest_proposer_address = md_EthCallRequest.Fields().ByName("proposer_address") + fd_EthCallRequest_chain_id = md_EthCallRequest.Fields().ByName("chain_id") } -var _ protoreflect.Message = (*fastReflection_QueryTraceTxRequest)(nil) +var _ protoreflect.Message = (*fastReflection_EthCallRequest)(nil) -type fastReflection_QueryTraceTxRequest QueryTraceTxRequest +type fastReflection_EthCallRequest EthCallRequest -func (x *QueryTraceTxRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryTraceTxRequest)(x) +func (x *EthCallRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_EthCallRequest)(x) } -func (x *QueryTraceTxRequest) slowProtoReflect() protoreflect.Message { +func (x *EthCallRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -8376,43 +8118,43 @@ func (x *QueryTraceTxRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryTraceTxRequest_messageType fastReflection_QueryTraceTxRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryTraceTxRequest_messageType{} +var _fastReflection_EthCallRequest_messageType fastReflection_EthCallRequest_messageType +var _ protoreflect.MessageType = fastReflection_EthCallRequest_messageType{} -type fastReflection_QueryTraceTxRequest_messageType struct{} +type fastReflection_EthCallRequest_messageType struct{} -func (x fastReflection_QueryTraceTxRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryTraceTxRequest)(nil) +func (x fastReflection_EthCallRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_EthCallRequest)(nil) } -func (x fastReflection_QueryTraceTxRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryTraceTxRequest) +func (x fastReflection_EthCallRequest_messageType) New() protoreflect.Message { + return new(fastReflection_EthCallRequest) } -func (x fastReflection_QueryTraceTxRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTraceTxRequest +func (x fastReflection_EthCallRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_EthCallRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryTraceTxRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTraceTxRequest +func (x *fastReflection_EthCallRequest) Descriptor() protoreflect.MessageDescriptor { + return md_EthCallRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryTraceTxRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryTraceTxRequest_messageType +func (x *fastReflection_EthCallRequest) Type() protoreflect.MessageType { + return _fastReflection_EthCallRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryTraceTxRequest) New() protoreflect.Message { - return new(fastReflection_QueryTraceTxRequest) +func (x *fastReflection_EthCallRequest) New() protoreflect.Message { + return new(fastReflection_EthCallRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryTraceTxRequest) Interface() protoreflect.ProtoMessage { - return (*QueryTraceTxRequest)(x) +func (x *fastReflection_EthCallRequest) Interface() protoreflect.ProtoMessage { + return (*EthCallRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -8420,58 +8162,28 @@ func (x *fastReflection_QueryTraceTxRequest) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryTraceTxRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Msg != nil { - value := protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) - if !f(fd_QueryTraceTxRequest_msg, value) { - return - } - } - if x.TraceConfig != nil { - value := protoreflect.ValueOfMessage(x.TraceConfig.ProtoReflect()) - if !f(fd_QueryTraceTxRequest_trace_config, value) { - return - } - } - if len(x.Predecessors) != 0 { - value := protoreflect.ValueOfList(&_QueryTraceTxRequest_4_list{list: &x.Predecessors}) - if !f(fd_QueryTraceTxRequest_predecessors, value) { - return - } - } - if x.BlockNumber != int64(0) { - value := protoreflect.ValueOfInt64(x.BlockNumber) - if !f(fd_QueryTraceTxRequest_block_number, value) { - return - } - } - if x.BlockHash != "" { - value := protoreflect.ValueOfString(x.BlockHash) - if !f(fd_QueryTraceTxRequest_block_hash, value) { +func (x *fastReflection_EthCallRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Args) != 0 { + value := protoreflect.ValueOfBytes(x.Args) + if !f(fd_EthCallRequest_args, value) { return } } - if x.BlockTime != nil { - value := protoreflect.ValueOfMessage(x.BlockTime.ProtoReflect()) - if !f(fd_QueryTraceTxRequest_block_time, value) { + if x.GasCap != uint64(0) { + value := protoreflect.ValueOfUint64(x.GasCap) + if !f(fd_EthCallRequest_gas_cap, value) { return } } if len(x.ProposerAddress) != 0 { value := protoreflect.ValueOfBytes(x.ProposerAddress) - if !f(fd_QueryTraceTxRequest_proposer_address, value) { + if !f(fd_EthCallRequest_proposer_address, value) { return } } if x.ChainId != int64(0) { value := protoreflect.ValueOfInt64(x.ChainId) - if !f(fd_QueryTraceTxRequest_chain_id, value) { - return - } - } - if x.BlockMaxGas != int64(0) { - value := protoreflect.ValueOfInt64(x.BlockMaxGas) - if !f(fd_QueryTraceTxRequest_block_max_gas, value) { + if !f(fd_EthCallRequest_chain_id, value) { return } } @@ -8488,31 +8200,21 @@ func (x *fastReflection_QueryTraceTxRequest) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryTraceTxRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_EthCallRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxRequest.msg": - return x.Msg != nil - case "os.evm.v1.QueryTraceTxRequest.trace_config": - return x.TraceConfig != nil - case "os.evm.v1.QueryTraceTxRequest.predecessors": - return len(x.Predecessors) != 0 - case "os.evm.v1.QueryTraceTxRequest.block_number": - return x.BlockNumber != int64(0) - case "os.evm.v1.QueryTraceTxRequest.block_hash": - return x.BlockHash != "" - case "os.evm.v1.QueryTraceTxRequest.block_time": - return x.BlockTime != nil - case "os.evm.v1.QueryTraceTxRequest.proposer_address": - return len(x.ProposerAddress) != 0 - case "os.evm.v1.QueryTraceTxRequest.chain_id": - return x.ChainId != int64(0) - case "os.evm.v1.QueryTraceTxRequest.block_max_gas": - return x.BlockMaxGas != int64(0) + case "os.evm.v1.EthCallRequest.args": + return len(x.Args) != 0 + case "os.evm.v1.EthCallRequest.gas_cap": + return x.GasCap != uint64(0) + case "os.evm.v1.EthCallRequest.proposer_address": + return len(x.ProposerAddress) != 0 + case "os.evm.v1.EthCallRequest.chain_id": + return x.ChainId != int64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) } } @@ -8522,31 +8224,21 @@ func (x *fastReflection_QueryTraceTxRequest) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceTxRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_EthCallRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxRequest.msg": - x.Msg = nil - case "os.evm.v1.QueryTraceTxRequest.trace_config": - x.TraceConfig = nil - case "os.evm.v1.QueryTraceTxRequest.predecessors": - x.Predecessors = nil - case "os.evm.v1.QueryTraceTxRequest.block_number": - x.BlockNumber = int64(0) - case "os.evm.v1.QueryTraceTxRequest.block_hash": - x.BlockHash = "" - case "os.evm.v1.QueryTraceTxRequest.block_time": - x.BlockTime = nil - case "os.evm.v1.QueryTraceTxRequest.proposer_address": + case "os.evm.v1.EthCallRequest.args": + x.Args = nil + case "os.evm.v1.EthCallRequest.gas_cap": + x.GasCap = uint64(0) + case "os.evm.v1.EthCallRequest.proposer_address": x.ProposerAddress = nil - case "os.evm.v1.QueryTraceTxRequest.chain_id": + case "os.evm.v1.EthCallRequest.chain_id": x.ChainId = int64(0) - case "os.evm.v1.QueryTraceTxRequest.block_max_gas": - x.BlockMaxGas = int64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) } } @@ -8556,43 +8248,25 @@ func (x *fastReflection_QueryTraceTxRequest) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryTraceTxRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_EthCallRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryTraceTxRequest.msg": - value := x.Msg - return protoreflect.ValueOfMessage(value.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.trace_config": - value := x.TraceConfig - return protoreflect.ValueOfMessage(value.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.predecessors": - if len(x.Predecessors) == 0 { - return protoreflect.ValueOfList(&_QueryTraceTxRequest_4_list{}) - } - listValue := &_QueryTraceTxRequest_4_list{list: &x.Predecessors} - return protoreflect.ValueOfList(listValue) - case "os.evm.v1.QueryTraceTxRequest.block_number": - value := x.BlockNumber - return protoreflect.ValueOfInt64(value) - case "os.evm.v1.QueryTraceTxRequest.block_hash": - value := x.BlockHash - return protoreflect.ValueOfString(value) - case "os.evm.v1.QueryTraceTxRequest.block_time": - value := x.BlockTime - return protoreflect.ValueOfMessage(value.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.proposer_address": + case "os.evm.v1.EthCallRequest.args": + value := x.Args + return protoreflect.ValueOfBytes(value) + case "os.evm.v1.EthCallRequest.gas_cap": + value := x.GasCap + return protoreflect.ValueOfUint64(value) + case "os.evm.v1.EthCallRequest.proposer_address": value := x.ProposerAddress return protoreflect.ValueOfBytes(value) - case "os.evm.v1.QueryTraceTxRequest.chain_id": + case "os.evm.v1.EthCallRequest.chain_id": value := x.ChainId return protoreflect.ValueOfInt64(value) - case "os.evm.v1.QueryTraceTxRequest.block_max_gas": - value := x.BlockMaxGas - return protoreflect.ValueOfInt64(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", descriptor.FullName())) } } @@ -8606,33 +8280,21 @@ func (x *fastReflection_QueryTraceTxRequest) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceTxRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_EthCallRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxRequest.msg": - x.Msg = value.Message().Interface().(*MsgEthereumTx) - case "os.evm.v1.QueryTraceTxRequest.trace_config": - x.TraceConfig = value.Message().Interface().(*TraceConfig) - case "os.evm.v1.QueryTraceTxRequest.predecessors": - lv := value.List() - clv := lv.(*_QueryTraceTxRequest_4_list) - x.Predecessors = *clv.list - case "os.evm.v1.QueryTraceTxRequest.block_number": - x.BlockNumber = value.Int() - case "os.evm.v1.QueryTraceTxRequest.block_hash": - x.BlockHash = value.Interface().(string) - case "os.evm.v1.QueryTraceTxRequest.block_time": - x.BlockTime = value.Message().Interface().(*timestamppb.Timestamp) - case "os.evm.v1.QueryTraceTxRequest.proposer_address": + case "os.evm.v1.EthCallRequest.args": + x.Args = value.Bytes() + case "os.evm.v1.EthCallRequest.gas_cap": + x.GasCap = value.Uint() + case "os.evm.v1.EthCallRequest.proposer_address": x.ProposerAddress = value.Bytes() - case "os.evm.v1.QueryTraceTxRequest.chain_id": + case "os.evm.v1.EthCallRequest.chain_id": x.ChainId = value.Int() - case "os.evm.v1.QueryTraceTxRequest.block_max_gas": - x.BlockMaxGas = value.Int() default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) } } @@ -8646,89 +8308,52 @@ func (x *fastReflection_QueryTraceTxRequest) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceTxRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_EthCallRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxRequest.msg": - if x.Msg == nil { - x.Msg = new(MsgEthereumTx) - } - return protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.trace_config": - if x.TraceConfig == nil { - x.TraceConfig = new(TraceConfig) - } - return protoreflect.ValueOfMessage(x.TraceConfig.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.predecessors": - if x.Predecessors == nil { - x.Predecessors = []*MsgEthereumTx{} - } - value := &_QueryTraceTxRequest_4_list{list: &x.Predecessors} - return protoreflect.ValueOfList(value) - case "os.evm.v1.QueryTraceTxRequest.block_time": - if x.BlockTime == nil { - x.BlockTime = new(timestamppb.Timestamp) - } - return protoreflect.ValueOfMessage(x.BlockTime.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.block_number": - panic(fmt.Errorf("field block_number of message os.evm.v1.QueryTraceTxRequest is not mutable")) - case "os.evm.v1.QueryTraceTxRequest.block_hash": - panic(fmt.Errorf("field block_hash of message os.evm.v1.QueryTraceTxRequest is not mutable")) - case "os.evm.v1.QueryTraceTxRequest.proposer_address": - panic(fmt.Errorf("field proposer_address of message os.evm.v1.QueryTraceTxRequest is not mutable")) - case "os.evm.v1.QueryTraceTxRequest.chain_id": - panic(fmt.Errorf("field chain_id of message os.evm.v1.QueryTraceTxRequest is not mutable")) - case "os.evm.v1.QueryTraceTxRequest.block_max_gas": - panic(fmt.Errorf("field block_max_gas of message os.evm.v1.QueryTraceTxRequest is not mutable")) + case "os.evm.v1.EthCallRequest.args": + panic(fmt.Errorf("field args of message os.evm.v1.EthCallRequest is not mutable")) + case "os.evm.v1.EthCallRequest.gas_cap": + panic(fmt.Errorf("field gas_cap of message os.evm.v1.EthCallRequest is not mutable")) + case "os.evm.v1.EthCallRequest.proposer_address": + panic(fmt.Errorf("field proposer_address of message os.evm.v1.EthCallRequest is not mutable")) + case "os.evm.v1.EthCallRequest.chain_id": + panic(fmt.Errorf("field chain_id of message os.evm.v1.EthCallRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryTraceTxRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_EthCallRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxRequest.msg": - m := new(MsgEthereumTx) - return protoreflect.ValueOfMessage(m.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.trace_config": - m := new(TraceConfig) - return protoreflect.ValueOfMessage(m.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.predecessors": - list := []*MsgEthereumTx{} - return protoreflect.ValueOfList(&_QueryTraceTxRequest_4_list{list: &list}) - case "os.evm.v1.QueryTraceTxRequest.block_number": - return protoreflect.ValueOfInt64(int64(0)) - case "os.evm.v1.QueryTraceTxRequest.block_hash": - return protoreflect.ValueOfString("") - case "os.evm.v1.QueryTraceTxRequest.block_time": - m := new(timestamppb.Timestamp) - return protoreflect.ValueOfMessage(m.ProtoReflect()) - case "os.evm.v1.QueryTraceTxRequest.proposer_address": + case "os.evm.v1.EthCallRequest.args": return protoreflect.ValueOfBytes(nil) - case "os.evm.v1.QueryTraceTxRequest.chain_id": - return protoreflect.ValueOfInt64(int64(0)) - case "os.evm.v1.QueryTraceTxRequest.block_max_gas": + case "os.evm.v1.EthCallRequest.gas_cap": + return protoreflect.ValueOfUint64(uint64(0)) + case "os.evm.v1.EthCallRequest.proposer_address": + return protoreflect.ValueOfBytes(nil) + case "os.evm.v1.EthCallRequest.chain_id": return protoreflect.ValueOfInt64(int64(0)) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EthCallRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EthCallRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryTraceTxRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_EthCallRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTraceTxRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.EthCallRequest", d.FullName())) } panic("unreachable") } @@ -8736,7 +8361,7 @@ func (x *fastReflection_QueryTraceTxRequest) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryTraceTxRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_EthCallRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -8747,7 +8372,7 @@ func (x *fastReflection_QueryTraceTxRequest) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceTxRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_EthCallRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -8759,7 +8384,7 @@ func (x *fastReflection_QueryTraceTxRequest) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryTraceTxRequest) IsValid() bool { +func (x *fastReflection_EthCallRequest) IsValid() bool { return x != nil } @@ -8769,9 +8394,9 @@ func (x *fastReflection_QueryTraceTxRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_EthCallRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryTraceTxRequest) + x := input.Message.Interface().(*EthCallRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -8783,30 +8408,12 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods var n int var l int _ = l - if x.Msg != nil { - l = options.Size(x.Msg) - n += 1 + l + runtime.Sov(uint64(l)) - } - if x.TraceConfig != nil { - l = options.Size(x.TraceConfig) - n += 1 + l + runtime.Sov(uint64(l)) - } - if len(x.Predecessors) > 0 { - for _, e := range x.Predecessors { - l = options.Size(e) - n += 1 + l + runtime.Sov(uint64(l)) - } - } - if x.BlockNumber != 0 { - n += 1 + runtime.Sov(uint64(x.BlockNumber)) - } - l = len(x.BlockHash) + l = len(x.Args) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - if x.BlockTime != nil { - l = options.Size(x.BlockTime) - n += 1 + l + runtime.Sov(uint64(l)) + if x.GasCap != 0 { + n += 1 + runtime.Sov(uint64(x.GasCap)) } l = len(x.ProposerAddress) if l > 0 { @@ -8815,9 +8422,6 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods if x.ChainId != 0 { n += 1 + runtime.Sov(uint64(x.ChainId)) } - if x.BlockMaxGas != 0 { - n += 1 + runtime.Sov(uint64(x.BlockMaxGas)) - } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -8828,7 +8432,7 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryTraceTxRequest) + x := input.Message.Interface().(*EthCallRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -8847,90 +8451,27 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if x.BlockMaxGas != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.BlockMaxGas)) - i-- - dAtA[i] = 0x50 - } if x.ChainId != 0 { i = runtime.EncodeVarint(dAtA, i, uint64(x.ChainId)) i-- - dAtA[i] = 0x48 + dAtA[i] = 0x20 } if len(x.ProposerAddress) > 0 { i -= len(x.ProposerAddress) copy(dAtA[i:], x.ProposerAddress) i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ProposerAddress))) i-- - dAtA[i] = 0x42 + dAtA[i] = 0x1a } - if x.BlockTime != nil { - encoded, err := options.Marshal(x.BlockTime) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + if x.GasCap != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.GasCap)) i-- - dAtA[i] = 0x3a + dAtA[i] = 0x10 } - if len(x.BlockHash) > 0 { - i -= len(x.BlockHash) - copy(dAtA[i:], x.BlockHash) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BlockHash))) - i-- - dAtA[i] = 0x32 - } - if x.BlockNumber != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.BlockNumber)) - i-- - dAtA[i] = 0x28 - } - if len(x.Predecessors) > 0 { - for iNdEx := len(x.Predecessors) - 1; iNdEx >= 0; iNdEx-- { - encoded, err := options.Marshal(x.Predecessors[iNdEx]) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) - i-- - dAtA[i] = 0x22 - } - } - if x.TraceConfig != nil { - encoded, err := options.Marshal(x.TraceConfig) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) - i-- - dAtA[i] = 0x1a - } - if x.Msg != nil { - encoded, err := options.Marshal(x.Msg) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + if len(x.Args) > 0 { + i -= len(x.Args) + copy(dAtA[i:], x.Args) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Args))) i-- dAtA[i] = 0xa } @@ -8945,7 +8486,7 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryTraceTxRequest) + x := input.Message.Interface().(*EthCallRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -8977,89 +8518,17 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceTxRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: EthCallRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceTxRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: EthCallRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - if x.Msg == nil { - x.Msg = &MsgEthereumTx{} - } - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Msg); err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TraceConfig", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - if x.TraceConfig == nil { - x.TraceConfig = &TraceConfig{} - } - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.TraceConfig); err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Predecessors", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Args", wireType) } - var msglen int + var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -9069,82 +8538,31 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + byteLen |= int(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + if byteLen < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } - postIndex := iNdEx + msglen + postIndex := iNdEx + byteLen if postIndex < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Predecessors = append(x.Predecessors, &MsgEthereumTx{}) - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Predecessors[len(x.Predecessors)-1]); err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + x.Args = append(x.Args[:0], dAtA[iNdEx:postIndex]...) + if x.Args == nil { + x.Args = []byte{} } iNdEx = postIndex - case 5: + case 2: if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockNumber", wireType) - } - x.BlockNumber = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - x.BlockNumber |= int64(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 6: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockHash", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - x.BlockHash = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 7: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockTime", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field GasCap", wireType) } - var msglen int + x.GasCap = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -9154,29 +8572,12 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + x.GasCap |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength - } - if postIndex > l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - if x.BlockTime == nil { - x.BlockTime = ×tamppb.Timestamp{} - } - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.BlockTime); err != nil { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err - } - iNdEx = postIndex - case 8: + case 3: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposerAddress", wireType) } @@ -9210,7 +8611,7 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods x.ProposerAddress = []byte{} } iNdEx = postIndex - case 9: + case 4: if wireType != 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType) } @@ -9229,25 +8630,6 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods break } } - case 10: - if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockMaxGas", wireType) - } - x.BlockMaxGas = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - x.BlockMaxGas |= int64(b&0x7F) << shift - if b < 0x80 { - break - } - } default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -9284,25 +8666,29 @@ func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods } var ( - md_QueryTraceTxResponse protoreflect.MessageDescriptor - fd_QueryTraceTxResponse_data protoreflect.FieldDescriptor + md_EstimateGasResponse protoreflect.MessageDescriptor + fd_EstimateGasResponse_gas protoreflect.FieldDescriptor + fd_EstimateGasResponse_ret protoreflect.FieldDescriptor + fd_EstimateGasResponse_vm_error protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryTraceTxResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryTraceTxResponse") - fd_QueryTraceTxResponse_data = md_QueryTraceTxResponse.Fields().ByName("data") + md_EstimateGasResponse = File_os_evm_v1_query_proto.Messages().ByName("EstimateGasResponse") + fd_EstimateGasResponse_gas = md_EstimateGasResponse.Fields().ByName("gas") + fd_EstimateGasResponse_ret = md_EstimateGasResponse.Fields().ByName("ret") + fd_EstimateGasResponse_vm_error = md_EstimateGasResponse.Fields().ByName("vm_error") } -var _ protoreflect.Message = (*fastReflection_QueryTraceTxResponse)(nil) +var _ protoreflect.Message = (*fastReflection_EstimateGasResponse)(nil) -type fastReflection_QueryTraceTxResponse QueryTraceTxResponse +type fastReflection_EstimateGasResponse EstimateGasResponse -func (x *QueryTraceTxResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryTraceTxResponse)(x) +func (x *EstimateGasResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_EstimateGasResponse)(x) } -func (x *QueryTraceTxResponse) slowProtoReflect() protoreflect.Message { +func (x *EstimateGasResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -9314,43 +8700,43 @@ func (x *QueryTraceTxResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryTraceTxResponse_messageType fastReflection_QueryTraceTxResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryTraceTxResponse_messageType{} +var _fastReflection_EstimateGasResponse_messageType fastReflection_EstimateGasResponse_messageType +var _ protoreflect.MessageType = fastReflection_EstimateGasResponse_messageType{} -type fastReflection_QueryTraceTxResponse_messageType struct{} +type fastReflection_EstimateGasResponse_messageType struct{} -func (x fastReflection_QueryTraceTxResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryTraceTxResponse)(nil) +func (x fastReflection_EstimateGasResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_EstimateGasResponse)(nil) } -func (x fastReflection_QueryTraceTxResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryTraceTxResponse) +func (x fastReflection_EstimateGasResponse_messageType) New() protoreflect.Message { + return new(fastReflection_EstimateGasResponse) } -func (x fastReflection_QueryTraceTxResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTraceTxResponse +func (x fastReflection_EstimateGasResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_EstimateGasResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryTraceTxResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTraceTxResponse +func (x *fastReflection_EstimateGasResponse) Descriptor() protoreflect.MessageDescriptor { + return md_EstimateGasResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryTraceTxResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryTraceTxResponse_messageType +func (x *fastReflection_EstimateGasResponse) Type() protoreflect.MessageType { + return _fastReflection_EstimateGasResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryTraceTxResponse) New() protoreflect.Message { - return new(fastReflection_QueryTraceTxResponse) +func (x *fastReflection_EstimateGasResponse) New() protoreflect.Message { + return new(fastReflection_EstimateGasResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryTraceTxResponse) Interface() protoreflect.ProtoMessage { - return (*QueryTraceTxResponse)(x) +func (x *fastReflection_EstimateGasResponse) Interface() protoreflect.ProtoMessage { + return (*EstimateGasResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -9358,10 +8744,22 @@ func (x *fastReflection_QueryTraceTxResponse) Interface() protoreflect.ProtoMess // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryTraceTxResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if len(x.Data) != 0 { - value := protoreflect.ValueOfBytes(x.Data) - if !f(fd_QueryTraceTxResponse_data, value) { +func (x *fastReflection_EstimateGasResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Gas != uint64(0) { + value := protoreflect.ValueOfUint64(x.Gas) + if !f(fd_EstimateGasResponse_gas, value) { + return + } + } + if len(x.Ret) != 0 { + value := protoreflect.ValueOfBytes(x.Ret) + if !f(fd_EstimateGasResponse_ret, value) { + return + } + } + if x.VmError != "" { + value := protoreflect.ValueOfString(x.VmError) + if !f(fd_EstimateGasResponse_vm_error, value) { return } } @@ -9378,15 +8776,19 @@ func (x *fastReflection_QueryTraceTxResponse) Range(f func(protoreflect.FieldDes // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryTraceTxResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_EstimateGasResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxResponse.data": - return len(x.Data) != 0 + case "os.evm.v1.EstimateGasResponse.gas": + return x.Gas != uint64(0) + case "os.evm.v1.EstimateGasResponse.ret": + return len(x.Ret) != 0 + case "os.evm.v1.EstimateGasResponse.vm_error": + return x.VmError != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) } } @@ -9396,15 +8798,19 @@ func (x *fastReflection_QueryTraceTxResponse) Has(fd protoreflect.FieldDescripto // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceTxResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_EstimateGasResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxResponse.data": - x.Data = nil + case "os.evm.v1.EstimateGasResponse.gas": + x.Gas = uint64(0) + case "os.evm.v1.EstimateGasResponse.ret": + x.Ret = nil + case "os.evm.v1.EstimateGasResponse.vm_error": + x.VmError = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) } } @@ -9414,16 +8820,22 @@ func (x *fastReflection_QueryTraceTxResponse) Clear(fd protoreflect.FieldDescrip // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryTraceTxResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_EstimateGasResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryTraceTxResponse.data": - value := x.Data + case "os.evm.v1.EstimateGasResponse.gas": + value := x.Gas + return protoreflect.ValueOfUint64(value) + case "os.evm.v1.EstimateGasResponse.ret": + value := x.Ret return protoreflect.ValueOfBytes(value) + case "os.evm.v1.EstimateGasResponse.vm_error": + value := x.VmError + return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", descriptor.FullName())) } } @@ -9437,15 +8849,19 @@ func (x *fastReflection_QueryTraceTxResponse) Get(descriptor protoreflect.FieldD // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceTxResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_EstimateGasResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxResponse.data": - x.Data = value.Bytes() + case "os.evm.v1.EstimateGasResponse.gas": + x.Gas = value.Uint() + case "os.evm.v1.EstimateGasResponse.ret": + x.Ret = value.Bytes() + case "os.evm.v1.EstimateGasResponse.vm_error": + x.VmError = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) } } @@ -9459,40 +8875,48 @@ func (x *fastReflection_QueryTraceTxResponse) Set(fd protoreflect.FieldDescripto // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceTxResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_EstimateGasResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxResponse.data": - panic(fmt.Errorf("field data of message os.evm.v1.QueryTraceTxResponse is not mutable")) + case "os.evm.v1.EstimateGasResponse.gas": + panic(fmt.Errorf("field gas of message os.evm.v1.EstimateGasResponse is not mutable")) + case "os.evm.v1.EstimateGasResponse.ret": + panic(fmt.Errorf("field ret of message os.evm.v1.EstimateGasResponse is not mutable")) + case "os.evm.v1.EstimateGasResponse.vm_error": + panic(fmt.Errorf("field vm_error of message os.evm.v1.EstimateGasResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryTraceTxResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_EstimateGasResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTraceTxResponse.data": + case "os.evm.v1.EstimateGasResponse.gas": + return protoreflect.ValueOfUint64(uint64(0)) + case "os.evm.v1.EstimateGasResponse.ret": return protoreflect.ValueOfBytes(nil) + case "os.evm.v1.EstimateGasResponse.vm_error": + return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.EstimateGasResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.EstimateGasResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryTraceTxResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_EstimateGasResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTraceTxResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.EstimateGasResponse", d.FullName())) } panic("unreachable") } @@ -9500,7 +8924,7 @@ func (x *fastReflection_QueryTraceTxResponse) WhichOneof(d protoreflect.OneofDes // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryTraceTxResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_EstimateGasResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -9511,7 +8935,7 @@ func (x *fastReflection_QueryTraceTxResponse) GetUnknown() protoreflect.RawField // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceTxResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_EstimateGasResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -9523,7 +8947,7 @@ func (x *fastReflection_QueryTraceTxResponse) SetUnknown(fields protoreflect.Raw // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryTraceTxResponse) IsValid() bool { +func (x *fastReflection_EstimateGasResponse) IsValid() bool { return x != nil } @@ -9533,9 +8957,9 @@ func (x *fastReflection_QueryTraceTxResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_EstimateGasResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryTraceTxResponse) + x := input.Message.Interface().(*EstimateGasResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -9547,7 +8971,14 @@ func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - l = len(x.Data) + if x.Gas != 0 { + n += 1 + runtime.Sov(uint64(x.Gas)) + } + l = len(x.Ret) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.VmError) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -9561,7 +8992,7 @@ func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryTraceTxResponse) + x := input.Message.Interface().(*EstimateGasResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -9580,12 +9011,24 @@ func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Data) > 0 { - i -= len(x.Data) - copy(dAtA[i:], x.Data) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Data))) + if len(x.VmError) > 0 { + i -= len(x.VmError) + copy(dAtA[i:], x.VmError) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.VmError))) i-- - dAtA[i] = 0xa + dAtA[i] = 0x1a + } + if len(x.Ret) > 0 { + i -= len(x.Ret) + copy(dAtA[i:], x.Ret) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ret))) + i-- + dAtA[i] = 0x12 + } + if x.Gas != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Gas)) + i-- + dAtA[i] = 0x8 } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) @@ -9598,7 +9041,7 @@ func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryTraceTxResponse) + x := input.Message.Interface().(*EstimateGasResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -9630,15 +9073,34 @@ func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceTxResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: EstimateGasResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceTxResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: EstimateGasResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Gas", wireType) + } + x.Gas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Gas |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ret", wireType) } var byteLen int for shift := uint(0); ; shift += 7 { @@ -9665,10 +9127,42 @@ func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Data = append(x.Data[:0], dAtA[iNdEx:postIndex]...) - if x.Data == nil { - x.Data = []byte{} + x.Ret = append(x.Ret[:0], dAtA[iNdEx:postIndex]...) + if x.Ret == nil { + x.Ret = []byte{} + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VmError", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.VmError = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -9705,91 +9199,93 @@ func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods } } -var _ protoreflect.List = (*_QueryTraceBlockRequest_1_list)(nil) +var _ protoreflect.List = (*_QueryTraceTxRequest_4_list)(nil) -type _QueryTraceBlockRequest_1_list struct { +type _QueryTraceTxRequest_4_list struct { list *[]*MsgEthereumTx } -func (x *_QueryTraceBlockRequest_1_list) Len() int { +func (x *_QueryTraceTxRequest_4_list) Len() int { if x.list == nil { return 0 } return len(*x.list) } -func (x *_QueryTraceBlockRequest_1_list) Get(i int) protoreflect.Value { +func (x *_QueryTraceTxRequest_4_list) Get(i int) protoreflect.Value { return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) } -func (x *_QueryTraceBlockRequest_1_list) Set(i int, value protoreflect.Value) { +func (x *_QueryTraceTxRequest_4_list) Set(i int, value protoreflect.Value) { valueUnwrapped := value.Message() concreteValue := valueUnwrapped.Interface().(*MsgEthereumTx) (*x.list)[i] = concreteValue } -func (x *_QueryTraceBlockRequest_1_list) Append(value protoreflect.Value) { +func (x *_QueryTraceTxRequest_4_list) Append(value protoreflect.Value) { valueUnwrapped := value.Message() concreteValue := valueUnwrapped.Interface().(*MsgEthereumTx) *x.list = append(*x.list, concreteValue) } -func (x *_QueryTraceBlockRequest_1_list) AppendMutable() protoreflect.Value { +func (x *_QueryTraceTxRequest_4_list) AppendMutable() protoreflect.Value { v := new(MsgEthereumTx) *x.list = append(*x.list, v) return protoreflect.ValueOfMessage(v.ProtoReflect()) } -func (x *_QueryTraceBlockRequest_1_list) Truncate(n int) { +func (x *_QueryTraceTxRequest_4_list) Truncate(n int) { for i := n; i < len(*x.list); i++ { (*x.list)[i] = nil } *x.list = (*x.list)[:n] } -func (x *_QueryTraceBlockRequest_1_list) NewElement() protoreflect.Value { +func (x *_QueryTraceTxRequest_4_list) NewElement() protoreflect.Value { v := new(MsgEthereumTx) return protoreflect.ValueOfMessage(v.ProtoReflect()) } -func (x *_QueryTraceBlockRequest_1_list) IsValid() bool { +func (x *_QueryTraceTxRequest_4_list) IsValid() bool { return x.list != nil } var ( - md_QueryTraceBlockRequest protoreflect.MessageDescriptor - fd_QueryTraceBlockRequest_txs protoreflect.FieldDescriptor - fd_QueryTraceBlockRequest_trace_config protoreflect.FieldDescriptor - fd_QueryTraceBlockRequest_block_number protoreflect.FieldDescriptor - fd_QueryTraceBlockRequest_block_hash protoreflect.FieldDescriptor - fd_QueryTraceBlockRequest_block_time protoreflect.FieldDescriptor - fd_QueryTraceBlockRequest_proposer_address protoreflect.FieldDescriptor - fd_QueryTraceBlockRequest_chain_id protoreflect.FieldDescriptor - fd_QueryTraceBlockRequest_block_max_gas protoreflect.FieldDescriptor + md_QueryTraceTxRequest protoreflect.MessageDescriptor + fd_QueryTraceTxRequest_msg protoreflect.FieldDescriptor + fd_QueryTraceTxRequest_trace_config protoreflect.FieldDescriptor + fd_QueryTraceTxRequest_predecessors protoreflect.FieldDescriptor + fd_QueryTraceTxRequest_block_number protoreflect.FieldDescriptor + fd_QueryTraceTxRequest_block_hash protoreflect.FieldDescriptor + fd_QueryTraceTxRequest_block_time protoreflect.FieldDescriptor + fd_QueryTraceTxRequest_proposer_address protoreflect.FieldDescriptor + fd_QueryTraceTxRequest_chain_id protoreflect.FieldDescriptor + fd_QueryTraceTxRequest_block_max_gas protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryTraceBlockRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryTraceBlockRequest") - fd_QueryTraceBlockRequest_txs = md_QueryTraceBlockRequest.Fields().ByName("txs") - fd_QueryTraceBlockRequest_trace_config = md_QueryTraceBlockRequest.Fields().ByName("trace_config") - fd_QueryTraceBlockRequest_block_number = md_QueryTraceBlockRequest.Fields().ByName("block_number") - fd_QueryTraceBlockRequest_block_hash = md_QueryTraceBlockRequest.Fields().ByName("block_hash") - fd_QueryTraceBlockRequest_block_time = md_QueryTraceBlockRequest.Fields().ByName("block_time") - fd_QueryTraceBlockRequest_proposer_address = md_QueryTraceBlockRequest.Fields().ByName("proposer_address") - fd_QueryTraceBlockRequest_chain_id = md_QueryTraceBlockRequest.Fields().ByName("chain_id") - fd_QueryTraceBlockRequest_block_max_gas = md_QueryTraceBlockRequest.Fields().ByName("block_max_gas") + md_QueryTraceTxRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryTraceTxRequest") + fd_QueryTraceTxRequest_msg = md_QueryTraceTxRequest.Fields().ByName("msg") + fd_QueryTraceTxRequest_trace_config = md_QueryTraceTxRequest.Fields().ByName("trace_config") + fd_QueryTraceTxRequest_predecessors = md_QueryTraceTxRequest.Fields().ByName("predecessors") + fd_QueryTraceTxRequest_block_number = md_QueryTraceTxRequest.Fields().ByName("block_number") + fd_QueryTraceTxRequest_block_hash = md_QueryTraceTxRequest.Fields().ByName("block_hash") + fd_QueryTraceTxRequest_block_time = md_QueryTraceTxRequest.Fields().ByName("block_time") + fd_QueryTraceTxRequest_proposer_address = md_QueryTraceTxRequest.Fields().ByName("proposer_address") + fd_QueryTraceTxRequest_chain_id = md_QueryTraceTxRequest.Fields().ByName("chain_id") + fd_QueryTraceTxRequest_block_max_gas = md_QueryTraceTxRequest.Fields().ByName("block_max_gas") } -var _ protoreflect.Message = (*fastReflection_QueryTraceBlockRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryTraceTxRequest)(nil) -type fastReflection_QueryTraceBlockRequest QueryTraceBlockRequest +type fastReflection_QueryTraceTxRequest QueryTraceTxRequest -func (x *QueryTraceBlockRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryTraceBlockRequest)(x) +func (x *QueryTraceTxRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryTraceTxRequest)(x) } -func (x *QueryTraceBlockRequest) slowProtoReflect() protoreflect.Message { +func (x *QueryTraceTxRequest) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -9801,43 +9297,43 @@ func (x *QueryTraceBlockRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryTraceBlockRequest_messageType fastReflection_QueryTraceBlockRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryTraceBlockRequest_messageType{} +var _fastReflection_QueryTraceTxRequest_messageType fastReflection_QueryTraceTxRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryTraceTxRequest_messageType{} -type fastReflection_QueryTraceBlockRequest_messageType struct{} +type fastReflection_QueryTraceTxRequest_messageType struct{} -func (x fastReflection_QueryTraceBlockRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryTraceBlockRequest)(nil) +func (x fastReflection_QueryTraceTxRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryTraceTxRequest)(nil) } -func (x fastReflection_QueryTraceBlockRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryTraceBlockRequest) +func (x fastReflection_QueryTraceTxRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryTraceTxRequest) } -func (x fastReflection_QueryTraceBlockRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTraceBlockRequest +func (x fastReflection_QueryTraceTxRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTraceTxRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryTraceBlockRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTraceBlockRequest +func (x *fastReflection_QueryTraceTxRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTraceTxRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryTraceBlockRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryTraceBlockRequest_messageType +func (x *fastReflection_QueryTraceTxRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryTraceTxRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryTraceBlockRequest) New() protoreflect.Message { - return new(fastReflection_QueryTraceBlockRequest) +func (x *fastReflection_QueryTraceTxRequest) New() protoreflect.Message { + return new(fastReflection_QueryTraceTxRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryTraceBlockRequest) Interface() protoreflect.ProtoMessage { - return (*QueryTraceBlockRequest)(x) +func (x *fastReflection_QueryTraceTxRequest) Interface() protoreflect.ProtoMessage { + return (*QueryTraceTxRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -9845,52 +9341,58 @@ func (x *fastReflection_QueryTraceBlockRequest) Interface() protoreflect.ProtoMe // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryTraceBlockRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if len(x.Txs) != 0 { - value := protoreflect.ValueOfList(&_QueryTraceBlockRequest_1_list{list: &x.Txs}) - if !f(fd_QueryTraceBlockRequest_txs, value) { +func (x *fastReflection_QueryTraceTxRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Msg != nil { + value := protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) + if !f(fd_QueryTraceTxRequest_msg, value) { return } } if x.TraceConfig != nil { value := protoreflect.ValueOfMessage(x.TraceConfig.ProtoReflect()) - if !f(fd_QueryTraceBlockRequest_trace_config, value) { + if !f(fd_QueryTraceTxRequest_trace_config, value) { + return + } + } + if len(x.Predecessors) != 0 { + value := protoreflect.ValueOfList(&_QueryTraceTxRequest_4_list{list: &x.Predecessors}) + if !f(fd_QueryTraceTxRequest_predecessors, value) { return } } if x.BlockNumber != int64(0) { value := protoreflect.ValueOfInt64(x.BlockNumber) - if !f(fd_QueryTraceBlockRequest_block_number, value) { + if !f(fd_QueryTraceTxRequest_block_number, value) { return } } if x.BlockHash != "" { value := protoreflect.ValueOfString(x.BlockHash) - if !f(fd_QueryTraceBlockRequest_block_hash, value) { + if !f(fd_QueryTraceTxRequest_block_hash, value) { return } } if x.BlockTime != nil { value := protoreflect.ValueOfMessage(x.BlockTime.ProtoReflect()) - if !f(fd_QueryTraceBlockRequest_block_time, value) { + if !f(fd_QueryTraceTxRequest_block_time, value) { return } } if len(x.ProposerAddress) != 0 { value := protoreflect.ValueOfBytes(x.ProposerAddress) - if !f(fd_QueryTraceBlockRequest_proposer_address, value) { + if !f(fd_QueryTraceTxRequest_proposer_address, value) { return } } if x.ChainId != int64(0) { value := protoreflect.ValueOfInt64(x.ChainId) - if !f(fd_QueryTraceBlockRequest_chain_id, value) { + if !f(fd_QueryTraceTxRequest_chain_id, value) { return } } if x.BlockMaxGas != int64(0) { value := protoreflect.ValueOfInt64(x.BlockMaxGas) - if !f(fd_QueryTraceBlockRequest_block_max_gas, value) { + if !f(fd_QueryTraceTxRequest_block_max_gas, value) { return } } @@ -9907,29 +9409,31 @@ func (x *fastReflection_QueryTraceBlockRequest) Range(f func(protoreflect.FieldD // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryTraceBlockRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryTraceTxRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockRequest.txs": - return len(x.Txs) != 0 - case "os.evm.v1.QueryTraceBlockRequest.trace_config": + case "os.evm.v1.QueryTraceTxRequest.msg": + return x.Msg != nil + case "os.evm.v1.QueryTraceTxRequest.trace_config": return x.TraceConfig != nil - case "os.evm.v1.QueryTraceBlockRequest.block_number": + case "os.evm.v1.QueryTraceTxRequest.predecessors": + return len(x.Predecessors) != 0 + case "os.evm.v1.QueryTraceTxRequest.block_number": return x.BlockNumber != int64(0) - case "os.evm.v1.QueryTraceBlockRequest.block_hash": + case "os.evm.v1.QueryTraceTxRequest.block_hash": return x.BlockHash != "" - case "os.evm.v1.QueryTraceBlockRequest.block_time": + case "os.evm.v1.QueryTraceTxRequest.block_time": return x.BlockTime != nil - case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + case "os.evm.v1.QueryTraceTxRequest.proposer_address": return len(x.ProposerAddress) != 0 - case "os.evm.v1.QueryTraceBlockRequest.chain_id": + case "os.evm.v1.QueryTraceTxRequest.chain_id": return x.ChainId != int64(0) - case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + case "os.evm.v1.QueryTraceTxRequest.block_max_gas": return x.BlockMaxGas != int64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) } } @@ -9939,29 +9443,31 @@ func (x *fastReflection_QueryTraceBlockRequest) Has(fd protoreflect.FieldDescrip // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceBlockRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryTraceTxRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockRequest.txs": - x.Txs = nil - case "os.evm.v1.QueryTraceBlockRequest.trace_config": + case "os.evm.v1.QueryTraceTxRequest.msg": + x.Msg = nil + case "os.evm.v1.QueryTraceTxRequest.trace_config": x.TraceConfig = nil - case "os.evm.v1.QueryTraceBlockRequest.block_number": + case "os.evm.v1.QueryTraceTxRequest.predecessors": + x.Predecessors = nil + case "os.evm.v1.QueryTraceTxRequest.block_number": x.BlockNumber = int64(0) - case "os.evm.v1.QueryTraceBlockRequest.block_hash": + case "os.evm.v1.QueryTraceTxRequest.block_hash": x.BlockHash = "" - case "os.evm.v1.QueryTraceBlockRequest.block_time": + case "os.evm.v1.QueryTraceTxRequest.block_time": x.BlockTime = nil - case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + case "os.evm.v1.QueryTraceTxRequest.proposer_address": x.ProposerAddress = nil - case "os.evm.v1.QueryTraceBlockRequest.chain_id": + case "os.evm.v1.QueryTraceTxRequest.chain_id": x.ChainId = int64(0) - case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + case "os.evm.v1.QueryTraceTxRequest.block_max_gas": x.BlockMaxGas = int64(0) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) } } @@ -9971,40 +9477,43 @@ func (x *fastReflection_QueryTraceBlockRequest) Clear(fd protoreflect.FieldDescr // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryTraceBlockRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTraceTxRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryTraceBlockRequest.txs": - if len(x.Txs) == 0 { - return protoreflect.ValueOfList(&_QueryTraceBlockRequest_1_list{}) - } - listValue := &_QueryTraceBlockRequest_1_list{list: &x.Txs} - return protoreflect.ValueOfList(listValue) - case "os.evm.v1.QueryTraceBlockRequest.trace_config": + case "os.evm.v1.QueryTraceTxRequest.msg": + value := x.Msg + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "os.evm.v1.QueryTraceTxRequest.trace_config": value := x.TraceConfig return protoreflect.ValueOfMessage(value.ProtoReflect()) - case "os.evm.v1.QueryTraceBlockRequest.block_number": + case "os.evm.v1.QueryTraceTxRequest.predecessors": + if len(x.Predecessors) == 0 { + return protoreflect.ValueOfList(&_QueryTraceTxRequest_4_list{}) + } + listValue := &_QueryTraceTxRequest_4_list{list: &x.Predecessors} + return protoreflect.ValueOfList(listValue) + case "os.evm.v1.QueryTraceTxRequest.block_number": value := x.BlockNumber return protoreflect.ValueOfInt64(value) - case "os.evm.v1.QueryTraceBlockRequest.block_hash": + case "os.evm.v1.QueryTraceTxRequest.block_hash": value := x.BlockHash return protoreflect.ValueOfString(value) - case "os.evm.v1.QueryTraceBlockRequest.block_time": + case "os.evm.v1.QueryTraceTxRequest.block_time": value := x.BlockTime return protoreflect.ValueOfMessage(value.ProtoReflect()) - case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + case "os.evm.v1.QueryTraceTxRequest.proposer_address": value := x.ProposerAddress return protoreflect.ValueOfBytes(value) - case "os.evm.v1.QueryTraceBlockRequest.chain_id": + case "os.evm.v1.QueryTraceTxRequest.chain_id": value := x.ChainId return protoreflect.ValueOfInt64(value) - case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + case "os.evm.v1.QueryTraceTxRequest.block_max_gas": value := x.BlockMaxGas return protoreflect.ValueOfInt64(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", descriptor.FullName())) } } @@ -10018,31 +9527,33 @@ func (x *fastReflection_QueryTraceBlockRequest) Get(descriptor protoreflect.Fiel // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceBlockRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryTraceTxRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockRequest.txs": - lv := value.List() - clv := lv.(*_QueryTraceBlockRequest_1_list) - x.Txs = *clv.list - case "os.evm.v1.QueryTraceBlockRequest.trace_config": + case "os.evm.v1.QueryTraceTxRequest.msg": + x.Msg = value.Message().Interface().(*MsgEthereumTx) + case "os.evm.v1.QueryTraceTxRequest.trace_config": x.TraceConfig = value.Message().Interface().(*TraceConfig) - case "os.evm.v1.QueryTraceBlockRequest.block_number": + case "os.evm.v1.QueryTraceTxRequest.predecessors": + lv := value.List() + clv := lv.(*_QueryTraceTxRequest_4_list) + x.Predecessors = *clv.list + case "os.evm.v1.QueryTraceTxRequest.block_number": x.BlockNumber = value.Int() - case "os.evm.v1.QueryTraceBlockRequest.block_hash": + case "os.evm.v1.QueryTraceTxRequest.block_hash": x.BlockHash = value.Interface().(string) - case "os.evm.v1.QueryTraceBlockRequest.block_time": + case "os.evm.v1.QueryTraceTxRequest.block_time": x.BlockTime = value.Message().Interface().(*timestamppb.Timestamp) - case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + case "os.evm.v1.QueryTraceTxRequest.proposer_address": x.ProposerAddress = value.Bytes() - case "os.evm.v1.QueryTraceBlockRequest.chain_id": + case "os.evm.v1.QueryTraceTxRequest.chain_id": x.ChainId = value.Int() - case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + case "os.evm.v1.QueryTraceTxRequest.block_max_gas": x.BlockMaxGas = value.Int() default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) } } @@ -10056,81 +9567,89 @@ func (x *fastReflection_QueryTraceBlockRequest) Set(fd protoreflect.FieldDescrip // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceBlockRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTraceTxRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockRequest.txs": - if x.Txs == nil { - x.Txs = []*MsgEthereumTx{} + case "os.evm.v1.QueryTraceTxRequest.msg": + if x.Msg == nil { + x.Msg = new(MsgEthereumTx) } - value := &_QueryTraceBlockRequest_1_list{list: &x.Txs} - return protoreflect.ValueOfList(value) - case "os.evm.v1.QueryTraceBlockRequest.trace_config": + return protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) + case "os.evm.v1.QueryTraceTxRequest.trace_config": if x.TraceConfig == nil { x.TraceConfig = new(TraceConfig) } return protoreflect.ValueOfMessage(x.TraceConfig.ProtoReflect()) - case "os.evm.v1.QueryTraceBlockRequest.block_time": + case "os.evm.v1.QueryTraceTxRequest.predecessors": + if x.Predecessors == nil { + x.Predecessors = []*MsgEthereumTx{} + } + value := &_QueryTraceTxRequest_4_list{list: &x.Predecessors} + return protoreflect.ValueOfList(value) + case "os.evm.v1.QueryTraceTxRequest.block_time": if x.BlockTime == nil { x.BlockTime = new(timestamppb.Timestamp) } return protoreflect.ValueOfMessage(x.BlockTime.ProtoReflect()) - case "os.evm.v1.QueryTraceBlockRequest.block_number": - panic(fmt.Errorf("field block_number of message os.evm.v1.QueryTraceBlockRequest is not mutable")) - case "os.evm.v1.QueryTraceBlockRequest.block_hash": - panic(fmt.Errorf("field block_hash of message os.evm.v1.QueryTraceBlockRequest is not mutable")) - case "os.evm.v1.QueryTraceBlockRequest.proposer_address": - panic(fmt.Errorf("field proposer_address of message os.evm.v1.QueryTraceBlockRequest is not mutable")) - case "os.evm.v1.QueryTraceBlockRequest.chain_id": - panic(fmt.Errorf("field chain_id of message os.evm.v1.QueryTraceBlockRequest is not mutable")) - case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": - panic(fmt.Errorf("field block_max_gas of message os.evm.v1.QueryTraceBlockRequest is not mutable")) + case "os.evm.v1.QueryTraceTxRequest.block_number": + panic(fmt.Errorf("field block_number of message os.evm.v1.QueryTraceTxRequest is not mutable")) + case "os.evm.v1.QueryTraceTxRequest.block_hash": + panic(fmt.Errorf("field block_hash of message os.evm.v1.QueryTraceTxRequest is not mutable")) + case "os.evm.v1.QueryTraceTxRequest.proposer_address": + panic(fmt.Errorf("field proposer_address of message os.evm.v1.QueryTraceTxRequest is not mutable")) + case "os.evm.v1.QueryTraceTxRequest.chain_id": + panic(fmt.Errorf("field chain_id of message os.evm.v1.QueryTraceTxRequest is not mutable")) + case "os.evm.v1.QueryTraceTxRequest.block_max_gas": + panic(fmt.Errorf("field block_max_gas of message os.evm.v1.QueryTraceTxRequest is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryTraceBlockRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTraceTxRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockRequest.txs": - list := []*MsgEthereumTx{} - return protoreflect.ValueOfList(&_QueryTraceBlockRequest_1_list{list: &list}) - case "os.evm.v1.QueryTraceBlockRequest.trace_config": + case "os.evm.v1.QueryTraceTxRequest.msg": + m := new(MsgEthereumTx) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "os.evm.v1.QueryTraceTxRequest.trace_config": m := new(TraceConfig) return protoreflect.ValueOfMessage(m.ProtoReflect()) - case "os.evm.v1.QueryTraceBlockRequest.block_number": + case "os.evm.v1.QueryTraceTxRequest.predecessors": + list := []*MsgEthereumTx{} + return protoreflect.ValueOfList(&_QueryTraceTxRequest_4_list{list: &list}) + case "os.evm.v1.QueryTraceTxRequest.block_number": return protoreflect.ValueOfInt64(int64(0)) - case "os.evm.v1.QueryTraceBlockRequest.block_hash": + case "os.evm.v1.QueryTraceTxRequest.block_hash": return protoreflect.ValueOfString("") - case "os.evm.v1.QueryTraceBlockRequest.block_time": + case "os.evm.v1.QueryTraceTxRequest.block_time": m := new(timestamppb.Timestamp) return protoreflect.ValueOfMessage(m.ProtoReflect()) - case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + case "os.evm.v1.QueryTraceTxRequest.proposer_address": return protoreflect.ValueOfBytes(nil) - case "os.evm.v1.QueryTraceBlockRequest.chain_id": + case "os.evm.v1.QueryTraceTxRequest.chain_id": return protoreflect.ValueOfInt64(int64(0)) - case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + case "os.evm.v1.QueryTraceTxRequest.block_max_gas": return protoreflect.ValueOfInt64(int64(0)) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryTraceBlockRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryTraceTxRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTraceBlockRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTraceTxRequest", d.FullName())) } panic("unreachable") } @@ -10138,7 +9657,7 @@ func (x *fastReflection_QueryTraceBlockRequest) WhichOneof(d protoreflect.OneofD // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryTraceBlockRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryTraceTxRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -10149,7 +9668,7 @@ func (x *fastReflection_QueryTraceBlockRequest) GetUnknown() protoreflect.RawFie // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceBlockRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryTraceTxRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -10161,7 +9680,7 @@ func (x *fastReflection_QueryTraceBlockRequest) SetUnknown(fields protoreflect.R // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryTraceBlockRequest) IsValid() bool { +func (x *fastReflection_QueryTraceTxRequest) IsValid() bool { return x != nil } @@ -10171,9 +9690,9 @@ func (x *fastReflection_QueryTraceBlockRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryTraceTxRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryTraceBlockRequest) + x := input.Message.Interface().(*QueryTraceTxRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -10185,16 +9704,20 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho var n int var l int _ = l - if len(x.Txs) > 0 { - for _, e := range x.Txs { - l = options.Size(e) - n += 1 + l + runtime.Sov(uint64(l)) - } + if x.Msg != nil { + l = options.Size(x.Msg) + n += 1 + l + runtime.Sov(uint64(l)) } if x.TraceConfig != nil { l = options.Size(x.TraceConfig) n += 1 + l + runtime.Sov(uint64(l)) } + if len(x.Predecessors) > 0 { + for _, e := range x.Predecessors { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } if x.BlockNumber != 0 { n += 1 + runtime.Sov(uint64(x.BlockNumber)) } @@ -10226,7 +9749,7 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryTraceBlockRequest) + x := input.Message.Interface().(*QueryTraceTxRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -10288,6 +9811,22 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho i-- dAtA[i] = 0x28 } + if len(x.Predecessors) > 0 { + for iNdEx := len(x.Predecessors) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Predecessors[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } if x.TraceConfig != nil { encoded, err := options.Marshal(x.TraceConfig) if err != nil { @@ -10302,21 +9841,19 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho i-- dAtA[i] = 0x1a } - if len(x.Txs) > 0 { - for iNdEx := len(x.Txs) - 1; iNdEx >= 0; iNdEx-- { - encoded, err := options.Marshal(x.Txs[iNdEx]) - if err != nil { - return protoiface.MarshalOutput{ - NoUnkeyedLiterals: input.NoUnkeyedLiterals, - Buf: input.Buf, - }, err - } - i -= len(encoded) - copy(dAtA[i:], encoded) - i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) - i-- - dAtA[i] = 0xa + if x.Msg != nil { + encoded, err := options.Marshal(x.Msg) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) @@ -10329,7 +9866,7 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryTraceBlockRequest) + x := input.Message.Interface().(*QueryTraceTxRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -10361,15 +9898,15 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceBlockRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceTxRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceBlockRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceTxRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Txs", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -10396,8 +9933,10 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Txs = append(x.Txs, &MsgEthereumTx{}) - if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Txs[len(x.Txs)-1]); err != nil { + if x.Msg == nil { + x.Msg = &MsgEthereumTx{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Msg); err != nil { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex @@ -10437,6 +9976,40 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Predecessors", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Predecessors = append(x.Predecessors, &MsgEthereumTx{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Predecessors[len(x.Predecessors)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex case 5: if wireType != 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockNumber", wireType) @@ -10632,25 +10205,25 @@ func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Metho } var ( - md_QueryTraceBlockResponse protoreflect.MessageDescriptor - fd_QueryTraceBlockResponse_data protoreflect.FieldDescriptor + md_QueryTraceTxResponse protoreflect.MessageDescriptor + fd_QueryTraceTxResponse_data protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryTraceBlockResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryTraceBlockResponse") - fd_QueryTraceBlockResponse_data = md_QueryTraceBlockResponse.Fields().ByName("data") + md_QueryTraceTxResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryTraceTxResponse") + fd_QueryTraceTxResponse_data = md_QueryTraceTxResponse.Fields().ByName("data") } -var _ protoreflect.Message = (*fastReflection_QueryTraceBlockResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryTraceTxResponse)(nil) -type fastReflection_QueryTraceBlockResponse QueryTraceBlockResponse +type fastReflection_QueryTraceTxResponse QueryTraceTxResponse -func (x *QueryTraceBlockResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryTraceBlockResponse)(x) +func (x *QueryTraceTxResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryTraceTxResponse)(x) } -func (x *QueryTraceBlockResponse) slowProtoReflect() protoreflect.Message { +func (x *QueryTraceTxResponse) slowProtoReflect() protoreflect.Message { mi := &file_os_evm_v1_query_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -10662,43 +10235,43 @@ func (x *QueryTraceBlockResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryTraceBlockResponse_messageType fastReflection_QueryTraceBlockResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryTraceBlockResponse_messageType{} +var _fastReflection_QueryTraceTxResponse_messageType fastReflection_QueryTraceTxResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryTraceTxResponse_messageType{} -type fastReflection_QueryTraceBlockResponse_messageType struct{} +type fastReflection_QueryTraceTxResponse_messageType struct{} -func (x fastReflection_QueryTraceBlockResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryTraceBlockResponse)(nil) +func (x fastReflection_QueryTraceTxResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryTraceTxResponse)(nil) } -func (x fastReflection_QueryTraceBlockResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryTraceBlockResponse) +func (x fastReflection_QueryTraceTxResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryTraceTxResponse) } -func (x fastReflection_QueryTraceBlockResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTraceBlockResponse +func (x fastReflection_QueryTraceTxResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTraceTxResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryTraceBlockResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryTraceBlockResponse +func (x *fastReflection_QueryTraceTxResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTraceTxResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryTraceBlockResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryTraceBlockResponse_messageType +func (x *fastReflection_QueryTraceTxResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryTraceTxResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryTraceBlockResponse) New() protoreflect.Message { - return new(fastReflection_QueryTraceBlockResponse) +func (x *fastReflection_QueryTraceTxResponse) New() protoreflect.Message { + return new(fastReflection_QueryTraceTxResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryTraceBlockResponse) Interface() protoreflect.ProtoMessage { - return (*QueryTraceBlockResponse)(x) +func (x *fastReflection_QueryTraceTxResponse) Interface() protoreflect.ProtoMessage { + return (*QueryTraceTxResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -10706,10 +10279,10 @@ func (x *fastReflection_QueryTraceBlockResponse) Interface() protoreflect.ProtoM // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryTraceBlockResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +func (x *fastReflection_QueryTraceTxResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { if len(x.Data) != 0 { value := protoreflect.ValueOfBytes(x.Data) - if !f(fd_QueryTraceBlockResponse_data, value) { + if !f(fd_QueryTraceTxResponse_data, value) { return } } @@ -10726,15 +10299,15 @@ func (x *fastReflection_QueryTraceBlockResponse) Range(f func(protoreflect.Field // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryTraceBlockResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryTraceTxResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockResponse.data": + case "os.evm.v1.QueryTraceTxResponse.data": return len(x.Data) != 0 default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) } } @@ -10744,15 +10317,15 @@ func (x *fastReflection_QueryTraceBlockResponse) Has(fd protoreflect.FieldDescri // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceBlockResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryTraceTxResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockResponse.data": + case "os.evm.v1.QueryTraceTxResponse.data": x.Data = nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) } } @@ -10762,16 +10335,2142 @@ func (x *fastReflection_QueryTraceBlockResponse) Clear(fd protoreflect.FieldDesc // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryTraceBlockResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryTraceTxResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryTraceBlockResponse.data": + case "os.evm.v1.QueryTraceTxResponse.data": value := x.Data return protoreflect.ValueOfBytes(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceTxResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "os.evm.v1.QueryTraceTxResponse.data": + x.Data = value.Bytes() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceTxResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "os.evm.v1.QueryTraceTxResponse.data": + panic(fmt.Errorf("field data of message os.evm.v1.QueryTraceTxResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryTraceTxResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "os.evm.v1.QueryTraceTxResponse.data": + return protoreflect.ValueOfBytes(nil) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceTxResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceTxResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryTraceTxResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTraceTxResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryTraceTxResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceTxResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryTraceTxResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryTraceTxResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryTraceTxResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Data) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryTraceTxResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Data) > 0 { + i -= len(x.Data) + copy(dAtA[i:], x.Data) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Data))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryTraceTxResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceTxResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceTxResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Data = append(x.Data[:0], dAtA[iNdEx:postIndex]...) + if x.Data == nil { + x.Data = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryTraceBlockRequest_1_list)(nil) + +type _QueryTraceBlockRequest_1_list struct { + list *[]*MsgEthereumTx +} + +func (x *_QueryTraceBlockRequest_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryTraceBlockRequest_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryTraceBlockRequest_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*MsgEthereumTx) + (*x.list)[i] = concreteValue +} + +func (x *_QueryTraceBlockRequest_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*MsgEthereumTx) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryTraceBlockRequest_1_list) AppendMutable() protoreflect.Value { + v := new(MsgEthereumTx) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryTraceBlockRequest_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryTraceBlockRequest_1_list) NewElement() protoreflect.Value { + v := new(MsgEthereumTx) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryTraceBlockRequest_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryTraceBlockRequest protoreflect.MessageDescriptor + fd_QueryTraceBlockRequest_txs protoreflect.FieldDescriptor + fd_QueryTraceBlockRequest_trace_config protoreflect.FieldDescriptor + fd_QueryTraceBlockRequest_block_number protoreflect.FieldDescriptor + fd_QueryTraceBlockRequest_block_hash protoreflect.FieldDescriptor + fd_QueryTraceBlockRequest_block_time protoreflect.FieldDescriptor + fd_QueryTraceBlockRequest_proposer_address protoreflect.FieldDescriptor + fd_QueryTraceBlockRequest_chain_id protoreflect.FieldDescriptor + fd_QueryTraceBlockRequest_block_max_gas protoreflect.FieldDescriptor +) + +func init() { + file_os_evm_v1_query_proto_init() + md_QueryTraceBlockRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryTraceBlockRequest") + fd_QueryTraceBlockRequest_txs = md_QueryTraceBlockRequest.Fields().ByName("txs") + fd_QueryTraceBlockRequest_trace_config = md_QueryTraceBlockRequest.Fields().ByName("trace_config") + fd_QueryTraceBlockRequest_block_number = md_QueryTraceBlockRequest.Fields().ByName("block_number") + fd_QueryTraceBlockRequest_block_hash = md_QueryTraceBlockRequest.Fields().ByName("block_hash") + fd_QueryTraceBlockRequest_block_time = md_QueryTraceBlockRequest.Fields().ByName("block_time") + fd_QueryTraceBlockRequest_proposer_address = md_QueryTraceBlockRequest.Fields().ByName("proposer_address") + fd_QueryTraceBlockRequest_chain_id = md_QueryTraceBlockRequest.Fields().ByName("chain_id") + fd_QueryTraceBlockRequest_block_max_gas = md_QueryTraceBlockRequest.Fields().ByName("block_max_gas") +} + +var _ protoreflect.Message = (*fastReflection_QueryTraceBlockRequest)(nil) + +type fastReflection_QueryTraceBlockRequest QueryTraceBlockRequest + +func (x *QueryTraceBlockRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryTraceBlockRequest)(x) +} + +func (x *QueryTraceBlockRequest) slowProtoReflect() protoreflect.Message { + mi := &file_os_evm_v1_query_proto_msgTypes[22] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryTraceBlockRequest_messageType fastReflection_QueryTraceBlockRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryTraceBlockRequest_messageType{} + +type fastReflection_QueryTraceBlockRequest_messageType struct{} + +func (x fastReflection_QueryTraceBlockRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryTraceBlockRequest)(nil) +} +func (x fastReflection_QueryTraceBlockRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryTraceBlockRequest) +} +func (x fastReflection_QueryTraceBlockRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTraceBlockRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryTraceBlockRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTraceBlockRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryTraceBlockRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryTraceBlockRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryTraceBlockRequest) New() protoreflect.Message { + return new(fastReflection_QueryTraceBlockRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryTraceBlockRequest) Interface() protoreflect.ProtoMessage { + return (*QueryTraceBlockRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryTraceBlockRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Txs) != 0 { + value := protoreflect.ValueOfList(&_QueryTraceBlockRequest_1_list{list: &x.Txs}) + if !f(fd_QueryTraceBlockRequest_txs, value) { + return + } + } + if x.TraceConfig != nil { + value := protoreflect.ValueOfMessage(x.TraceConfig.ProtoReflect()) + if !f(fd_QueryTraceBlockRequest_trace_config, value) { + return + } + } + if x.BlockNumber != int64(0) { + value := protoreflect.ValueOfInt64(x.BlockNumber) + if !f(fd_QueryTraceBlockRequest_block_number, value) { + return + } + } + if x.BlockHash != "" { + value := protoreflect.ValueOfString(x.BlockHash) + if !f(fd_QueryTraceBlockRequest_block_hash, value) { + return + } + } + if x.BlockTime != nil { + value := protoreflect.ValueOfMessage(x.BlockTime.ProtoReflect()) + if !f(fd_QueryTraceBlockRequest_block_time, value) { + return + } + } + if len(x.ProposerAddress) != 0 { + value := protoreflect.ValueOfBytes(x.ProposerAddress) + if !f(fd_QueryTraceBlockRequest_proposer_address, value) { + return + } + } + if x.ChainId != int64(0) { + value := protoreflect.ValueOfInt64(x.ChainId) + if !f(fd_QueryTraceBlockRequest_chain_id, value) { + return + } + } + if x.BlockMaxGas != int64(0) { + value := protoreflect.ValueOfInt64(x.BlockMaxGas) + if !f(fd_QueryTraceBlockRequest_block_max_gas, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryTraceBlockRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockRequest.txs": + return len(x.Txs) != 0 + case "os.evm.v1.QueryTraceBlockRequest.trace_config": + return x.TraceConfig != nil + case "os.evm.v1.QueryTraceBlockRequest.block_number": + return x.BlockNumber != int64(0) + case "os.evm.v1.QueryTraceBlockRequest.block_hash": + return x.BlockHash != "" + case "os.evm.v1.QueryTraceBlockRequest.block_time": + return x.BlockTime != nil + case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + return len(x.ProposerAddress) != 0 + case "os.evm.v1.QueryTraceBlockRequest.chain_id": + return x.ChainId != int64(0) + case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + return x.BlockMaxGas != int64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceBlockRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockRequest.txs": + x.Txs = nil + case "os.evm.v1.QueryTraceBlockRequest.trace_config": + x.TraceConfig = nil + case "os.evm.v1.QueryTraceBlockRequest.block_number": + x.BlockNumber = int64(0) + case "os.evm.v1.QueryTraceBlockRequest.block_hash": + x.BlockHash = "" + case "os.evm.v1.QueryTraceBlockRequest.block_time": + x.BlockTime = nil + case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + x.ProposerAddress = nil + case "os.evm.v1.QueryTraceBlockRequest.chain_id": + x.ChainId = int64(0) + case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + x.BlockMaxGas = int64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryTraceBlockRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "os.evm.v1.QueryTraceBlockRequest.txs": + if len(x.Txs) == 0 { + return protoreflect.ValueOfList(&_QueryTraceBlockRequest_1_list{}) + } + listValue := &_QueryTraceBlockRequest_1_list{list: &x.Txs} + return protoreflect.ValueOfList(listValue) + case "os.evm.v1.QueryTraceBlockRequest.trace_config": + value := x.TraceConfig + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "os.evm.v1.QueryTraceBlockRequest.block_number": + value := x.BlockNumber + return protoreflect.ValueOfInt64(value) + case "os.evm.v1.QueryTraceBlockRequest.block_hash": + value := x.BlockHash + return protoreflect.ValueOfString(value) + case "os.evm.v1.QueryTraceBlockRequest.block_time": + value := x.BlockTime + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + value := x.ProposerAddress + return protoreflect.ValueOfBytes(value) + case "os.evm.v1.QueryTraceBlockRequest.chain_id": + value := x.ChainId + return protoreflect.ValueOfInt64(value) + case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + value := x.BlockMaxGas + return protoreflect.ValueOfInt64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceBlockRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockRequest.txs": + lv := value.List() + clv := lv.(*_QueryTraceBlockRequest_1_list) + x.Txs = *clv.list + case "os.evm.v1.QueryTraceBlockRequest.trace_config": + x.TraceConfig = value.Message().Interface().(*TraceConfig) + case "os.evm.v1.QueryTraceBlockRequest.block_number": + x.BlockNumber = value.Int() + case "os.evm.v1.QueryTraceBlockRequest.block_hash": + x.BlockHash = value.Interface().(string) + case "os.evm.v1.QueryTraceBlockRequest.block_time": + x.BlockTime = value.Message().Interface().(*timestamppb.Timestamp) + case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + x.ProposerAddress = value.Bytes() + case "os.evm.v1.QueryTraceBlockRequest.chain_id": + x.ChainId = value.Int() + case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + x.BlockMaxGas = value.Int() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceBlockRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockRequest.txs": + if x.Txs == nil { + x.Txs = []*MsgEthereumTx{} + } + value := &_QueryTraceBlockRequest_1_list{list: &x.Txs} + return protoreflect.ValueOfList(value) + case "os.evm.v1.QueryTraceBlockRequest.trace_config": + if x.TraceConfig == nil { + x.TraceConfig = new(TraceConfig) + } + return protoreflect.ValueOfMessage(x.TraceConfig.ProtoReflect()) + case "os.evm.v1.QueryTraceBlockRequest.block_time": + if x.BlockTime == nil { + x.BlockTime = new(timestamppb.Timestamp) + } + return protoreflect.ValueOfMessage(x.BlockTime.ProtoReflect()) + case "os.evm.v1.QueryTraceBlockRequest.block_number": + panic(fmt.Errorf("field block_number of message os.evm.v1.QueryTraceBlockRequest is not mutable")) + case "os.evm.v1.QueryTraceBlockRequest.block_hash": + panic(fmt.Errorf("field block_hash of message os.evm.v1.QueryTraceBlockRequest is not mutable")) + case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + panic(fmt.Errorf("field proposer_address of message os.evm.v1.QueryTraceBlockRequest is not mutable")) + case "os.evm.v1.QueryTraceBlockRequest.chain_id": + panic(fmt.Errorf("field chain_id of message os.evm.v1.QueryTraceBlockRequest is not mutable")) + case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + panic(fmt.Errorf("field block_max_gas of message os.evm.v1.QueryTraceBlockRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryTraceBlockRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockRequest.txs": + list := []*MsgEthereumTx{} + return protoreflect.ValueOfList(&_QueryTraceBlockRequest_1_list{list: &list}) + case "os.evm.v1.QueryTraceBlockRequest.trace_config": + m := new(TraceConfig) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "os.evm.v1.QueryTraceBlockRequest.block_number": + return protoreflect.ValueOfInt64(int64(0)) + case "os.evm.v1.QueryTraceBlockRequest.block_hash": + return protoreflect.ValueOfString("") + case "os.evm.v1.QueryTraceBlockRequest.block_time": + m := new(timestamppb.Timestamp) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "os.evm.v1.QueryTraceBlockRequest.proposer_address": + return protoreflect.ValueOfBytes(nil) + case "os.evm.v1.QueryTraceBlockRequest.chain_id": + return protoreflect.ValueOfInt64(int64(0)) + case "os.evm.v1.QueryTraceBlockRequest.block_max_gas": + return protoreflect.ValueOfInt64(int64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryTraceBlockRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTraceBlockRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryTraceBlockRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceBlockRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryTraceBlockRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryTraceBlockRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryTraceBlockRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Txs) > 0 { + for _, e := range x.Txs { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.TraceConfig != nil { + l = options.Size(x.TraceConfig) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.BlockNumber != 0 { + n += 1 + runtime.Sov(uint64(x.BlockNumber)) + } + l = len(x.BlockHash) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.BlockTime != nil { + l = options.Size(x.BlockTime) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.ProposerAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ChainId != 0 { + n += 1 + runtime.Sov(uint64(x.ChainId)) + } + if x.BlockMaxGas != 0 { + n += 1 + runtime.Sov(uint64(x.BlockMaxGas)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryTraceBlockRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.BlockMaxGas != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.BlockMaxGas)) + i-- + dAtA[i] = 0x50 + } + if x.ChainId != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ChainId)) + i-- + dAtA[i] = 0x48 + } + if len(x.ProposerAddress) > 0 { + i -= len(x.ProposerAddress) + copy(dAtA[i:], x.ProposerAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ProposerAddress))) + i-- + dAtA[i] = 0x42 + } + if x.BlockTime != nil { + encoded, err := options.Marshal(x.BlockTime) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x3a + } + if len(x.BlockHash) > 0 { + i -= len(x.BlockHash) + copy(dAtA[i:], x.BlockHash) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BlockHash))) + i-- + dAtA[i] = 0x32 + } + if x.BlockNumber != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.BlockNumber)) + i-- + dAtA[i] = 0x28 + } + if x.TraceConfig != nil { + encoded, err := options.Marshal(x.TraceConfig) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + if len(x.Txs) > 0 { + for iNdEx := len(x.Txs) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Txs[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryTraceBlockRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceBlockRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceBlockRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Txs", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Txs = append(x.Txs, &MsgEthereumTx{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Txs[len(x.Txs)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TraceConfig", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.TraceConfig == nil { + x.TraceConfig = &TraceConfig{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.TraceConfig); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockNumber", wireType) + } + x.BlockNumber = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.BlockNumber |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockHash", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BlockHash = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.BlockTime == nil { + x.BlockTime = ×tamppb.Timestamp{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.BlockTime); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 8: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposerAddress", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ProposerAddress = append(x.ProposerAddress[:0], dAtA[iNdEx:postIndex]...) + if x.ProposerAddress == nil { + x.ProposerAddress = []byte{} + } + iNdEx = postIndex + case 9: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType) + } + x.ChainId = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ChainId |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 10: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockMaxGas", wireType) + } + x.BlockMaxGas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.BlockMaxGas |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryTraceBlockResponse protoreflect.MessageDescriptor + fd_QueryTraceBlockResponse_data protoreflect.FieldDescriptor +) + +func init() { + file_os_evm_v1_query_proto_init() + md_QueryTraceBlockResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryTraceBlockResponse") + fd_QueryTraceBlockResponse_data = md_QueryTraceBlockResponse.Fields().ByName("data") +} + +var _ protoreflect.Message = (*fastReflection_QueryTraceBlockResponse)(nil) + +type fastReflection_QueryTraceBlockResponse QueryTraceBlockResponse + +func (x *QueryTraceBlockResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryTraceBlockResponse)(x) +} + +func (x *QueryTraceBlockResponse) slowProtoReflect() protoreflect.Message { + mi := &file_os_evm_v1_query_proto_msgTypes[23] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryTraceBlockResponse_messageType fastReflection_QueryTraceBlockResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryTraceBlockResponse_messageType{} + +type fastReflection_QueryTraceBlockResponse_messageType struct{} + +func (x fastReflection_QueryTraceBlockResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryTraceBlockResponse)(nil) +} +func (x fastReflection_QueryTraceBlockResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryTraceBlockResponse) +} +func (x fastReflection_QueryTraceBlockResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTraceBlockResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryTraceBlockResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryTraceBlockResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryTraceBlockResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryTraceBlockResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryTraceBlockResponse) New() protoreflect.Message { + return new(fastReflection_QueryTraceBlockResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryTraceBlockResponse) Interface() protoreflect.ProtoMessage { + return (*QueryTraceBlockResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryTraceBlockResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Data) != 0 { + value := protoreflect.ValueOfBytes(x.Data) + if !f(fd_QueryTraceBlockResponse_data, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryTraceBlockResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockResponse.data": + return len(x.Data) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceBlockResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockResponse.data": + x.Data = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryTraceBlockResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "os.evm.v1.QueryTraceBlockResponse.data": + value := x.Data + return protoreflect.ValueOfBytes(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceBlockResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockResponse.data": + x.Data = value.Bytes() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceBlockResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockResponse.data": + panic(fmt.Errorf("field data of message os.evm.v1.QueryTraceBlockResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryTraceBlockResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "os.evm.v1.QueryTraceBlockResponse.data": + return protoreflect.ValueOfBytes(nil) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryTraceBlockResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTraceBlockResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryTraceBlockResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryTraceBlockResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryTraceBlockResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryTraceBlockResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Data) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryTraceBlockResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Data) > 0 { + i -= len(x.Data) + copy(dAtA[i:], x.Data) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Data))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryTraceBlockResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceBlockResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceBlockResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Data = append(x.Data[:0], dAtA[iNdEx:postIndex]...) + if x.Data == nil { + x.Data = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryBaseFeeRequest protoreflect.MessageDescriptor +) + +func init() { + file_os_evm_v1_query_proto_init() + md_QueryBaseFeeRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryBaseFeeRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryBaseFeeRequest)(nil) + +type fastReflection_QueryBaseFeeRequest QueryBaseFeeRequest + +func (x *QueryBaseFeeRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBaseFeeRequest)(x) +} + +func (x *QueryBaseFeeRequest) slowProtoReflect() protoreflect.Message { + mi := &file_os_evm_v1_query_proto_msgTypes[24] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBaseFeeRequest_messageType fastReflection_QueryBaseFeeRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryBaseFeeRequest_messageType{} + +type fastReflection_QueryBaseFeeRequest_messageType struct{} + +func (x fastReflection_QueryBaseFeeRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBaseFeeRequest)(nil) +} +func (x fastReflection_QueryBaseFeeRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBaseFeeRequest) +} +func (x fastReflection_QueryBaseFeeRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBaseFeeRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBaseFeeRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBaseFeeRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBaseFeeRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryBaseFeeRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBaseFeeRequest) New() protoreflect.Message { + return new(fastReflection_QueryBaseFeeRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBaseFeeRequest) Interface() protoreflect.ProtoMessage { + return (*QueryBaseFeeRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBaseFeeRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBaseFeeRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBaseFeeRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBaseFeeRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBaseFeeRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBaseFeeRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBaseFeeRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + } + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBaseFeeRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryBaseFeeRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBaseFeeRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBaseFeeRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBaseFeeRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBaseFeeRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBaseFeeRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBaseFeeRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBaseFeeRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBaseFeeRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBaseFeeRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryBaseFeeResponse protoreflect.MessageDescriptor + fd_QueryBaseFeeResponse_base_fee protoreflect.FieldDescriptor +) + +func init() { + file_os_evm_v1_query_proto_init() + md_QueryBaseFeeResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryBaseFeeResponse") + fd_QueryBaseFeeResponse_base_fee = md_QueryBaseFeeResponse.Fields().ByName("base_fee") +} + +var _ protoreflect.Message = (*fastReflection_QueryBaseFeeResponse)(nil) + +type fastReflection_QueryBaseFeeResponse QueryBaseFeeResponse + +func (x *QueryBaseFeeResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBaseFeeResponse)(x) +} + +func (x *QueryBaseFeeResponse) slowProtoReflect() protoreflect.Message { + mi := &file_os_evm_v1_query_proto_msgTypes[25] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBaseFeeResponse_messageType fastReflection_QueryBaseFeeResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryBaseFeeResponse_messageType{} + +type fastReflection_QueryBaseFeeResponse_messageType struct{} + +func (x fastReflection_QueryBaseFeeResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBaseFeeResponse)(nil) +} +func (x fastReflection_QueryBaseFeeResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBaseFeeResponse) +} +func (x fastReflection_QueryBaseFeeResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBaseFeeResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBaseFeeResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBaseFeeResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBaseFeeResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryBaseFeeResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBaseFeeResponse) New() protoreflect.Message { + return new(fastReflection_QueryBaseFeeResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBaseFeeResponse) Interface() protoreflect.ProtoMessage { + return (*QueryBaseFeeResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBaseFeeResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.BaseFee != "" { + value := protoreflect.ValueOfString(x.BaseFee) + if !f(fd_QueryBaseFeeResponse_base_fee, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBaseFeeResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "os.evm.v1.QueryBaseFeeResponse.base_fee": + return x.BaseFee != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBaseFeeResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "os.evm.v1.QueryBaseFeeResponse.base_fee": + x.BaseFee = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) + } + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBaseFeeResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "os.evm.v1.QueryBaseFeeResponse.base_fee": + value := x.BaseFee + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", descriptor.FullName())) } } @@ -10785,15 +12484,15 @@ func (x *fastReflection_QueryTraceBlockResponse) Get(descriptor protoreflect.Fie // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceBlockResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryBaseFeeResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockResponse.data": - x.Data = value.Bytes() + case "os.evm.v1.QueryBaseFeeResponse.base_fee": + x.BaseFee = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) } } @@ -10807,40 +12506,40 @@ func (x *fastReflection_QueryTraceBlockResponse) Set(fd protoreflect.FieldDescri // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceBlockResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryBaseFeeResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockResponse.data": - panic(fmt.Errorf("field data of message os.evm.v1.QueryTraceBlockResponse is not mutable")) + case "os.evm.v1.QueryBaseFeeResponse.base_fee": + panic(fmt.Errorf("field base_fee of message os.evm.v1.QueryBaseFeeResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryTraceBlockResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryBaseFeeResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryTraceBlockResponse.data": - return protoreflect.ValueOfBytes(nil) + case "os.evm.v1.QueryBaseFeeResponse.base_fee": + return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryTraceBlockResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryTraceBlockResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryTraceBlockResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryBaseFeeResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryTraceBlockResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryBaseFeeResponse", d.FullName())) } panic("unreachable") } @@ -10848,7 +12547,7 @@ func (x *fastReflection_QueryTraceBlockResponse) WhichOneof(d protoreflect.Oneof // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryTraceBlockResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryBaseFeeResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -10859,7 +12558,7 @@ func (x *fastReflection_QueryTraceBlockResponse) GetUnknown() protoreflect.RawFi // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryTraceBlockResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryBaseFeeResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -10871,7 +12570,7 @@ func (x *fastReflection_QueryTraceBlockResponse) SetUnknown(fields protoreflect. // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryTraceBlockResponse) IsValid() bool { +func (x *fastReflection_QueryBaseFeeResponse) IsValid() bool { return x != nil } @@ -10881,9 +12580,9 @@ func (x *fastReflection_QueryTraceBlockResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryTraceBlockResponse) + x := input.Message.Interface().(*QueryBaseFeeResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -10895,7 +12594,7 @@ func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Meth var n int var l int _ = l - l = len(x.Data) + l = len(x.BaseFee) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -10909,7 +12608,7 @@ func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Meth } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryTraceBlockResponse) + x := input.Message.Interface().(*QueryBaseFeeResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -10928,10 +12627,10 @@ func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Meth i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Data) > 0 { - i -= len(x.Data) - copy(dAtA[i:], x.Data) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Data))) + if len(x.BaseFee) > 0 { + i -= len(x.BaseFee) + copy(dAtA[i:], x.BaseFee) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BaseFee))) i-- dAtA[i] = 0xa } @@ -10946,7 +12645,7 @@ func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Meth }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryTraceBlockResponse) + x := input.Message.Interface().(*QueryBaseFeeResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -10978,17 +12677,17 @@ func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Meth fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceBlockResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBaseFeeResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryTraceBlockResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBaseFeeResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BaseFee", wireType) } - var byteLen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow @@ -10998,25 +12697,23 @@ func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Meth } b := dAtA[iNdEx] iNdEx++ - byteLen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if byteLen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } - postIndex := iNdEx + byteLen + postIndex := iNdEx + intStringLen if postIndex < 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength } if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Data = append(x.Data[:0], dAtA[iNdEx:postIndex]...) - if x.Data == nil { - x.Data = []byte{} - } + x.BaseFee = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -11054,24 +12751,24 @@ func (x *fastReflection_QueryTraceBlockResponse) ProtoMethods() *protoiface.Meth } var ( - md_QueryBaseFeeRequest protoreflect.MessageDescriptor + md_QueryGlobalMinGasPriceRequest protoreflect.MessageDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryBaseFeeRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryBaseFeeRequest") + md_QueryGlobalMinGasPriceRequest = File_os_evm_v1_query_proto.Messages().ByName("QueryGlobalMinGasPriceRequest") } -var _ protoreflect.Message = (*fastReflection_QueryBaseFeeRequest)(nil) +var _ protoreflect.Message = (*fastReflection_QueryGlobalMinGasPriceRequest)(nil) -type fastReflection_QueryBaseFeeRequest QueryBaseFeeRequest +type fastReflection_QueryGlobalMinGasPriceRequest QueryGlobalMinGasPriceRequest -func (x *QueryBaseFeeRequest) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryBaseFeeRequest)(x) +func (x *QueryGlobalMinGasPriceRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryGlobalMinGasPriceRequest)(x) } -func (x *QueryBaseFeeRequest) slowProtoReflect() protoreflect.Message { - mi := &file_os_evm_v1_query_proto_msgTypes[22] +func (x *QueryGlobalMinGasPriceRequest) slowProtoReflect() protoreflect.Message { + mi := &file_os_evm_v1_query_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11082,43 +12779,43 @@ func (x *QueryBaseFeeRequest) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryBaseFeeRequest_messageType fastReflection_QueryBaseFeeRequest_messageType -var _ protoreflect.MessageType = fastReflection_QueryBaseFeeRequest_messageType{} +var _fastReflection_QueryGlobalMinGasPriceRequest_messageType fastReflection_QueryGlobalMinGasPriceRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryGlobalMinGasPriceRequest_messageType{} -type fastReflection_QueryBaseFeeRequest_messageType struct{} +type fastReflection_QueryGlobalMinGasPriceRequest_messageType struct{} -func (x fastReflection_QueryBaseFeeRequest_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryBaseFeeRequest)(nil) +func (x fastReflection_QueryGlobalMinGasPriceRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryGlobalMinGasPriceRequest)(nil) } -func (x fastReflection_QueryBaseFeeRequest_messageType) New() protoreflect.Message { - return new(fastReflection_QueryBaseFeeRequest) +func (x fastReflection_QueryGlobalMinGasPriceRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryGlobalMinGasPriceRequest) } -func (x fastReflection_QueryBaseFeeRequest_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryBaseFeeRequest +func (x fastReflection_QueryGlobalMinGasPriceRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryGlobalMinGasPriceRequest } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryBaseFeeRequest) Descriptor() protoreflect.MessageDescriptor { - return md_QueryBaseFeeRequest +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryGlobalMinGasPriceRequest } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryBaseFeeRequest) Type() protoreflect.MessageType { - return _fastReflection_QueryBaseFeeRequest_messageType +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryGlobalMinGasPriceRequest_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryBaseFeeRequest) New() protoreflect.Message { - return new(fastReflection_QueryBaseFeeRequest) +func (x *fastReflection_QueryGlobalMinGasPriceRequest) New() protoreflect.Message { + return new(fastReflection_QueryGlobalMinGasPriceRequest) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryBaseFeeRequest) Interface() protoreflect.ProtoMessage { - return (*QueryBaseFeeRequest)(x) +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Interface() protoreflect.ProtoMessage { + return (*QueryGlobalMinGasPriceRequest)(x) } // Range iterates over every populated field in an undefined order, @@ -11126,7 +12823,7 @@ func (x *fastReflection_QueryBaseFeeRequest) Interface() protoreflect.ProtoMessa // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryBaseFeeRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { } // Has reports whether a field is populated. @@ -11140,13 +12837,13 @@ func (x *fastReflection_QueryBaseFeeRequest) Range(f func(protoreflect.FieldDesc // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryBaseFeeRequest) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceRequest does not contain field %s", fd.FullName())) } } @@ -11156,13 +12853,13 @@ func (x *fastReflection_QueryBaseFeeRequest) Has(fd protoreflect.FieldDescriptor // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBaseFeeRequest) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceRequest does not contain field %s", fd.FullName())) } } @@ -11172,13 +12869,13 @@ func (x *fastReflection_QueryBaseFeeRequest) Clear(fd protoreflect.FieldDescript // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryBaseFeeRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceRequest does not contain field %s", descriptor.FullName())) } } @@ -11192,13 +12889,13 @@ func (x *fastReflection_QueryBaseFeeRequest) Get(descriptor protoreflect.FieldDe // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBaseFeeRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceRequest does not contain field %s", fd.FullName())) } } @@ -11212,36 +12909,36 @@ func (x *fastReflection_QueryBaseFeeRequest) Set(fd protoreflect.FieldDescriptor // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBaseFeeRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceRequest does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryBaseFeeRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeRequest")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceRequest")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeRequest does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceRequest does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryBaseFeeRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryBaseFeeRequest", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryGlobalMinGasPriceRequest", d.FullName())) } panic("unreachable") } @@ -11249,7 +12946,7 @@ func (x *fastReflection_QueryBaseFeeRequest) WhichOneof(d protoreflect.OneofDesc // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryBaseFeeRequest) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -11260,7 +12957,7 @@ func (x *fastReflection_QueryBaseFeeRequest) GetUnknown() protoreflect.RawFields // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBaseFeeRequest) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -11272,7 +12969,7 @@ func (x *fastReflection_QueryBaseFeeRequest) SetUnknown(fields protoreflect.RawF // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryBaseFeeRequest) IsValid() bool { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) IsValid() bool { return x != nil } @@ -11282,9 +12979,9 @@ func (x *fastReflection_QueryBaseFeeRequest) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryBaseFeeRequest) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryGlobalMinGasPriceRequest) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryBaseFeeRequest) + x := input.Message.Interface().(*QueryGlobalMinGasPriceRequest) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -11306,7 +13003,7 @@ func (x *fastReflection_QueryBaseFeeRequest) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryBaseFeeRequest) + x := input.Message.Interface().(*QueryGlobalMinGasPriceRequest) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -11336,7 +13033,7 @@ func (x *fastReflection_QueryBaseFeeRequest) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryBaseFeeRequest) + x := input.Message.Interface().(*QueryGlobalMinGasPriceRequest) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -11368,10 +13065,10 @@ func (x *fastReflection_QueryBaseFeeRequest) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBaseFeeRequest: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryGlobalMinGasPriceRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBaseFeeRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryGlobalMinGasPriceRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: @@ -11410,26 +13107,26 @@ func (x *fastReflection_QueryBaseFeeRequest) ProtoMethods() *protoiface.Methods } var ( - md_QueryBaseFeeResponse protoreflect.MessageDescriptor - fd_QueryBaseFeeResponse_base_fee protoreflect.FieldDescriptor + md_QueryGlobalMinGasPriceResponse protoreflect.MessageDescriptor + fd_QueryGlobalMinGasPriceResponse_min_gas_price protoreflect.FieldDescriptor ) func init() { file_os_evm_v1_query_proto_init() - md_QueryBaseFeeResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryBaseFeeResponse") - fd_QueryBaseFeeResponse_base_fee = md_QueryBaseFeeResponse.Fields().ByName("base_fee") + md_QueryGlobalMinGasPriceResponse = File_os_evm_v1_query_proto.Messages().ByName("QueryGlobalMinGasPriceResponse") + fd_QueryGlobalMinGasPriceResponse_min_gas_price = md_QueryGlobalMinGasPriceResponse.Fields().ByName("min_gas_price") } -var _ protoreflect.Message = (*fastReflection_QueryBaseFeeResponse)(nil) +var _ protoreflect.Message = (*fastReflection_QueryGlobalMinGasPriceResponse)(nil) -type fastReflection_QueryBaseFeeResponse QueryBaseFeeResponse +type fastReflection_QueryGlobalMinGasPriceResponse QueryGlobalMinGasPriceResponse -func (x *QueryBaseFeeResponse) ProtoReflect() protoreflect.Message { - return (*fastReflection_QueryBaseFeeResponse)(x) +func (x *QueryGlobalMinGasPriceResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryGlobalMinGasPriceResponse)(x) } -func (x *QueryBaseFeeResponse) slowProtoReflect() protoreflect.Message { - mi := &file_os_evm_v1_query_proto_msgTypes[23] +func (x *QueryGlobalMinGasPriceResponse) slowProtoReflect() protoreflect.Message { + mi := &file_os_evm_v1_query_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11440,43 +13137,43 @@ func (x *QueryBaseFeeResponse) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_QueryBaseFeeResponse_messageType fastReflection_QueryBaseFeeResponse_messageType -var _ protoreflect.MessageType = fastReflection_QueryBaseFeeResponse_messageType{} +var _fastReflection_QueryGlobalMinGasPriceResponse_messageType fastReflection_QueryGlobalMinGasPriceResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryGlobalMinGasPriceResponse_messageType{} -type fastReflection_QueryBaseFeeResponse_messageType struct{} +type fastReflection_QueryGlobalMinGasPriceResponse_messageType struct{} -func (x fastReflection_QueryBaseFeeResponse_messageType) Zero() protoreflect.Message { - return (*fastReflection_QueryBaseFeeResponse)(nil) +func (x fastReflection_QueryGlobalMinGasPriceResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryGlobalMinGasPriceResponse)(nil) } -func (x fastReflection_QueryBaseFeeResponse_messageType) New() protoreflect.Message { - return new(fastReflection_QueryBaseFeeResponse) +func (x fastReflection_QueryGlobalMinGasPriceResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryGlobalMinGasPriceResponse) } -func (x fastReflection_QueryBaseFeeResponse_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_QueryBaseFeeResponse +func (x fastReflection_QueryGlobalMinGasPriceResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryGlobalMinGasPriceResponse } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_QueryBaseFeeResponse) Descriptor() protoreflect.MessageDescriptor { - return md_QueryBaseFeeResponse +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryGlobalMinGasPriceResponse } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_QueryBaseFeeResponse) Type() protoreflect.MessageType { - return _fastReflection_QueryBaseFeeResponse_messageType +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryGlobalMinGasPriceResponse_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_QueryBaseFeeResponse) New() protoreflect.Message { - return new(fastReflection_QueryBaseFeeResponse) +func (x *fastReflection_QueryGlobalMinGasPriceResponse) New() protoreflect.Message { + return new(fastReflection_QueryGlobalMinGasPriceResponse) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_QueryBaseFeeResponse) Interface() protoreflect.ProtoMessage { - return (*QueryBaseFeeResponse)(x) +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Interface() protoreflect.ProtoMessage { + return (*QueryGlobalMinGasPriceResponse)(x) } // Range iterates over every populated field in an undefined order, @@ -11484,10 +13181,10 @@ func (x *fastReflection_QueryBaseFeeResponse) Interface() protoreflect.ProtoMess // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_QueryBaseFeeResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.BaseFee != "" { - value := protoreflect.ValueOfString(x.BaseFee) - if !f(fd_QueryBaseFeeResponse_base_fee, value) { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.MinGasPrice != "" { + value := protoreflect.ValueOfString(x.MinGasPrice) + if !f(fd_QueryGlobalMinGasPriceResponse_min_gas_price, value) { return } } @@ -11504,15 +13201,15 @@ func (x *fastReflection_QueryBaseFeeResponse) Range(f func(protoreflect.FieldDes // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_QueryBaseFeeResponse) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "os.evm.v1.QueryBaseFeeResponse.base_fee": - return x.BaseFee != "" + case "os.evm.v1.QueryGlobalMinGasPriceResponse.min_gas_price": + return x.MinGasPrice != "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceResponse does not contain field %s", fd.FullName())) } } @@ -11522,15 +13219,15 @@ func (x *fastReflection_QueryBaseFeeResponse) Has(fd protoreflect.FieldDescripto // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBaseFeeResponse) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "os.evm.v1.QueryBaseFeeResponse.base_fee": - x.BaseFee = "" + case "os.evm.v1.QueryGlobalMinGasPriceResponse.min_gas_price": + x.MinGasPrice = "" default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceResponse does not contain field %s", fd.FullName())) } } @@ -11540,16 +13237,16 @@ func (x *fastReflection_QueryBaseFeeResponse) Clear(fd protoreflect.FieldDescrip // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_QueryBaseFeeResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "os.evm.v1.QueryBaseFeeResponse.base_fee": - value := x.BaseFee + case "os.evm.v1.QueryGlobalMinGasPriceResponse.min_gas_price": + value := x.MinGasPrice return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceResponse does not contain field %s", descriptor.FullName())) } } @@ -11563,15 +13260,15 @@ func (x *fastReflection_QueryBaseFeeResponse) Get(descriptor protoreflect.FieldD // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBaseFeeResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "os.evm.v1.QueryBaseFeeResponse.base_fee": - x.BaseFee = value.Interface().(string) + case "os.evm.v1.QueryGlobalMinGasPriceResponse.min_gas_price": + x.MinGasPrice = value.Interface().(string) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceResponse does not contain field %s", fd.FullName())) } } @@ -11585,40 +13282,40 @@ func (x *fastReflection_QueryBaseFeeResponse) Set(fd protoreflect.FieldDescripto // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBaseFeeResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryBaseFeeResponse.base_fee": - panic(fmt.Errorf("field base_fee of message os.evm.v1.QueryBaseFeeResponse is not mutable")) + case "os.evm.v1.QueryGlobalMinGasPriceResponse.min_gas_price": + panic(fmt.Errorf("field min_gas_price of message os.evm.v1.QueryGlobalMinGasPriceResponse is not mutable")) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceResponse does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_QueryBaseFeeResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "os.evm.v1.QueryBaseFeeResponse.base_fee": + case "os.evm.v1.QueryGlobalMinGasPriceResponse.min_gas_price": return protoreflect.ValueOfString("") default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryBaseFeeResponse")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: os.evm.v1.QueryGlobalMinGasPriceResponse")) } - panic(fmt.Errorf("message os.evm.v1.QueryBaseFeeResponse does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message os.evm.v1.QueryGlobalMinGasPriceResponse does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_QueryBaseFeeResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryBaseFeeResponse", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in os.evm.v1.QueryGlobalMinGasPriceResponse", d.FullName())) } panic("unreachable") } @@ -11626,7 +13323,7 @@ func (x *fastReflection_QueryBaseFeeResponse) WhichOneof(d protoreflect.OneofDes // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_QueryBaseFeeResponse) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -11637,7 +13334,7 @@ func (x *fastReflection_QueryBaseFeeResponse) GetUnknown() protoreflect.RawField // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_QueryBaseFeeResponse) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -11649,7 +13346,7 @@ func (x *fastReflection_QueryBaseFeeResponse) SetUnknown(fields protoreflect.Raw // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_QueryBaseFeeResponse) IsValid() bool { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) IsValid() bool { return x != nil } @@ -11659,9 +13356,9 @@ func (x *fastReflection_QueryBaseFeeResponse) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_QueryGlobalMinGasPriceResponse) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*QueryBaseFeeResponse) + x := input.Message.Interface().(*QueryGlobalMinGasPriceResponse) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -11673,7 +13370,7 @@ func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods var n int var l int _ = l - l = len(x.BaseFee) + l = len(x.MinGasPrice) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -11687,7 +13384,7 @@ func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*QueryBaseFeeResponse) + x := input.Message.Interface().(*QueryGlobalMinGasPriceResponse) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -11706,10 +13403,10 @@ func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.BaseFee) > 0 { - i -= len(x.BaseFee) - copy(dAtA[i:], x.BaseFee) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BaseFee))) + if len(x.MinGasPrice) > 0 { + i -= len(x.MinGasPrice) + copy(dAtA[i:], x.MinGasPrice) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MinGasPrice))) i-- dAtA[i] = 0xa } @@ -11724,7 +13421,7 @@ func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*QueryBaseFeeResponse) + x := input.Message.Interface().(*QueryGlobalMinGasPriceResponse) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -11756,15 +13453,15 @@ func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBaseFeeResponse: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryGlobalMinGasPriceResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBaseFeeResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryGlobalMinGasPriceResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BaseFee", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinGasPrice", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -11792,7 +13489,7 @@ func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.BaseFee = string(dAtA[iNdEx:postIndex]) + x.MinGasPrice = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -11829,21 +13526,85 @@ func (x *fastReflection_QueryBaseFeeResponse) ProtoMethods() *protoiface.Methods } } -// Copyright Tharsis Labs Ltd.(Evmos) -// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: os/evm/v1/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryConfigRequest defines the request type for querying the config +type QueryConfigRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryConfigRequest) Reset() { + *x = QueryConfigRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_os_evm_v1_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryConfigRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryConfigRequest) ProtoMessage() {} + +// Deprecated: Use QueryConfigRequest.ProtoReflect.Descriptor instead. +func (*QueryConfigRequest) Descriptor() ([]byte, []int) { + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{0} +} + +// QueryConfigResponse returns the EVM config. +type QueryConfigResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // config is the evm configuration + Config *ChainConfig `protobuf:"bytes,1,opt,name=config,proto3" json:"config,omitempty"` +} + +func (x *QueryConfigResponse) Reset() { + *x = QueryConfigResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_os_evm_v1_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryConfigResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.27.0 -// protoc (unknown) -// source: os/evm/v1/query.proto +func (*QueryConfigResponse) ProtoMessage() {} -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) +// Deprecated: Use QueryConfigResponse.ProtoReflect.Descriptor instead. +func (*QueryConfigResponse) Descriptor() ([]byte, []int) { + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryConfigResponse) GetConfig() *ChainConfig { + if x != nil { + return x.Config + } + return nil +} // QueryAccountRequest is the request type for the Query/Account RPC method. type QueryAccountRequest struct { @@ -11858,7 +13619,7 @@ type QueryAccountRequest struct { func (x *QueryAccountRequest) Reset() { *x = QueryAccountRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[0] + mi := &file_os_evm_v1_query_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11872,7 +13633,7 @@ func (*QueryAccountRequest) ProtoMessage() {} // Deprecated: Use QueryAccountRequest.ProtoReflect.Descriptor instead. func (*QueryAccountRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{0} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{2} } func (x *QueryAccountRequest) GetAddress() string { @@ -11899,7 +13660,7 @@ type QueryAccountResponse struct { func (x *QueryAccountResponse) Reset() { *x = QueryAccountResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[1] + mi := &file_os_evm_v1_query_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11913,7 +13674,7 @@ func (*QueryAccountResponse) ProtoMessage() {} // Deprecated: Use QueryAccountResponse.ProtoReflect.Descriptor instead. func (*QueryAccountResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{1} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{3} } func (x *QueryAccountResponse) GetBalance() string { @@ -11951,7 +13712,7 @@ type QueryCosmosAccountRequest struct { func (x *QueryCosmosAccountRequest) Reset() { *x = QueryCosmosAccountRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[2] + mi := &file_os_evm_v1_query_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11965,7 +13726,7 @@ func (*QueryCosmosAccountRequest) ProtoMessage() {} // Deprecated: Use QueryCosmosAccountRequest.ProtoReflect.Descriptor instead. func (*QueryCosmosAccountRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{2} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{4} } func (x *QueryCosmosAccountRequest) GetAddress() string { @@ -11993,7 +13754,7 @@ type QueryCosmosAccountResponse struct { func (x *QueryCosmosAccountResponse) Reset() { *x = QueryCosmosAccountResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[3] + mi := &file_os_evm_v1_query_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12007,7 +13768,7 @@ func (*QueryCosmosAccountResponse) ProtoMessage() {} // Deprecated: Use QueryCosmosAccountResponse.ProtoReflect.Descriptor instead. func (*QueryCosmosAccountResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{3} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{5} } func (x *QueryCosmosAccountResponse) GetCosmosAddress() string { @@ -12045,7 +13806,7 @@ type QueryValidatorAccountRequest struct { func (x *QueryValidatorAccountRequest) Reset() { *x = QueryValidatorAccountRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[4] + mi := &file_os_evm_v1_query_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12059,7 +13820,7 @@ func (*QueryValidatorAccountRequest) ProtoMessage() {} // Deprecated: Use QueryValidatorAccountRequest.ProtoReflect.Descriptor instead. func (*QueryValidatorAccountRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{4} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{6} } func (x *QueryValidatorAccountRequest) GetConsAddress() string { @@ -12087,7 +13848,7 @@ type QueryValidatorAccountResponse struct { func (x *QueryValidatorAccountResponse) Reset() { *x = QueryValidatorAccountResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[5] + mi := &file_os_evm_v1_query_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12101,7 +13862,7 @@ func (*QueryValidatorAccountResponse) ProtoMessage() {} // Deprecated: Use QueryValidatorAccountResponse.ProtoReflect.Descriptor instead. func (*QueryValidatorAccountResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{5} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{7} } func (x *QueryValidatorAccountResponse) GetAccountAddress() string { @@ -12138,7 +13899,7 @@ type QueryBalanceRequest struct { func (x *QueryBalanceRequest) Reset() { *x = QueryBalanceRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[6] + mi := &file_os_evm_v1_query_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12152,7 +13913,7 @@ func (*QueryBalanceRequest) ProtoMessage() {} // Deprecated: Use QueryBalanceRequest.ProtoReflect.Descriptor instead. func (*QueryBalanceRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{6} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{8} } func (x *QueryBalanceRequest) GetAddress() string { @@ -12175,7 +13936,7 @@ type QueryBalanceResponse struct { func (x *QueryBalanceResponse) Reset() { *x = QueryBalanceResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[7] + mi := &file_os_evm_v1_query_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12189,7 +13950,7 @@ func (*QueryBalanceResponse) ProtoMessage() {} // Deprecated: Use QueryBalanceResponse.ProtoReflect.Descriptor instead. func (*QueryBalanceResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{7} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{9} } func (x *QueryBalanceResponse) GetBalance() string { @@ -12214,7 +13975,7 @@ type QueryStorageRequest struct { func (x *QueryStorageRequest) Reset() { *x = QueryStorageRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[8] + mi := &file_os_evm_v1_query_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12228,7 +13989,7 @@ func (*QueryStorageRequest) ProtoMessage() {} // Deprecated: Use QueryStorageRequest.ProtoReflect.Descriptor instead. func (*QueryStorageRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{8} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{10} } func (x *QueryStorageRequest) GetAddress() string { @@ -12259,7 +14020,7 @@ type QueryStorageResponse struct { func (x *QueryStorageResponse) Reset() { *x = QueryStorageResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[9] + mi := &file_os_evm_v1_query_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12273,7 +14034,7 @@ func (*QueryStorageResponse) ProtoMessage() {} // Deprecated: Use QueryStorageResponse.ProtoReflect.Descriptor instead. func (*QueryStorageResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{9} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{11} } func (x *QueryStorageResponse) GetValue() string { @@ -12296,7 +14057,7 @@ type QueryCodeRequest struct { func (x *QueryCodeRequest) Reset() { *x = QueryCodeRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[10] + mi := &file_os_evm_v1_query_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12310,7 +14071,7 @@ func (*QueryCodeRequest) ProtoMessage() {} // Deprecated: Use QueryCodeRequest.ProtoReflect.Descriptor instead. func (*QueryCodeRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{10} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{12} } func (x *QueryCodeRequest) GetAddress() string { @@ -12334,7 +14095,7 @@ type QueryCodeResponse struct { func (x *QueryCodeResponse) Reset() { *x = QueryCodeResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[11] + mi := &file_os_evm_v1_query_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12348,7 +14109,7 @@ func (*QueryCodeResponse) ProtoMessage() {} // Deprecated: Use QueryCodeResponse.ProtoReflect.Descriptor instead. func (*QueryCodeResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{11} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{13} } func (x *QueryCodeResponse) GetCode() []byte { @@ -12373,7 +14134,7 @@ type QueryTxLogsRequest struct { func (x *QueryTxLogsRequest) Reset() { *x = QueryTxLogsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[12] + mi := &file_os_evm_v1_query_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12387,7 +14148,7 @@ func (*QueryTxLogsRequest) ProtoMessage() {} // Deprecated: Use QueryTxLogsRequest.ProtoReflect.Descriptor instead. func (*QueryTxLogsRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{12} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{14} } func (x *QueryTxLogsRequest) GetHash() string { @@ -12419,7 +14180,7 @@ type QueryTxLogsResponse struct { func (x *QueryTxLogsResponse) Reset() { *x = QueryTxLogsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[13] + mi := &file_os_evm_v1_query_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12433,7 +14194,7 @@ func (*QueryTxLogsResponse) ProtoMessage() {} // Deprecated: Use QueryTxLogsResponse.ProtoReflect.Descriptor instead. func (*QueryTxLogsResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{13} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{15} } func (x *QueryTxLogsResponse) GetLogs() []*Log { @@ -12460,7 +14221,7 @@ type QueryParamsRequest struct { func (x *QueryParamsRequest) Reset() { *x = QueryParamsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[14] + mi := &file_os_evm_v1_query_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12474,7 +14235,7 @@ func (*QueryParamsRequest) ProtoMessage() {} // Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{14} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{16} } // QueryParamsResponse defines the response type for querying x/evm parameters. @@ -12490,7 +14251,7 @@ type QueryParamsResponse struct { func (x *QueryParamsResponse) Reset() { *x = QueryParamsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[15] + mi := &file_os_evm_v1_query_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12504,7 +14265,7 @@ func (*QueryParamsResponse) ProtoMessage() {} // Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{15} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{17} } func (x *QueryParamsResponse) GetParams() *Params { @@ -12533,7 +14294,7 @@ type EthCallRequest struct { func (x *EthCallRequest) Reset() { *x = EthCallRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[16] + mi := &file_os_evm_v1_query_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12547,7 +14308,7 @@ func (*EthCallRequest) ProtoMessage() {} // Deprecated: Use EthCallRequest.ProtoReflect.Descriptor instead. func (*EthCallRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{16} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{18} } func (x *EthCallRequest) GetArgs() []byte { @@ -12586,12 +14347,17 @@ type EstimateGasResponse struct { // gas returns the estimated gas Gas uint64 `protobuf:"varint,1,opt,name=gas,proto3" json:"gas,omitempty"` + // ret is the returned data from evm function (result or data supplied with + // revert opcode) + Ret []byte `protobuf:"bytes,2,opt,name=ret,proto3" json:"ret,omitempty"` + // vm_error is the error returned by vm execution + VmError string `protobuf:"bytes,3,opt,name=vm_error,json=vmError,proto3" json:"vm_error,omitempty"` } func (x *EstimateGasResponse) Reset() { *x = EstimateGasResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[17] + mi := &file_os_evm_v1_query_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12605,7 +14371,7 @@ func (*EstimateGasResponse) ProtoMessage() {} // Deprecated: Use EstimateGasResponse.ProtoReflect.Descriptor instead. func (*EstimateGasResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{17} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{19} } func (x *EstimateGasResponse) GetGas() uint64 { @@ -12615,6 +14381,20 @@ func (x *EstimateGasResponse) GetGas() uint64 { return 0 } +func (x *EstimateGasResponse) GetRet() []byte { + if x != nil { + return x.Ret + } + return nil +} + +func (x *EstimateGasResponse) GetVmError() string { + if x != nil { + return x.VmError + } + return "" +} + // QueryTraceTxRequest defines TraceTx request type QueryTraceTxRequest struct { state protoimpl.MessageState @@ -12645,7 +14425,7 @@ type QueryTraceTxRequest struct { func (x *QueryTraceTxRequest) Reset() { *x = QueryTraceTxRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[18] + mi := &file_os_evm_v1_query_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12659,7 +14439,7 @@ func (*QueryTraceTxRequest) ProtoMessage() {} // Deprecated: Use QueryTraceTxRequest.ProtoReflect.Descriptor instead. func (*QueryTraceTxRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{18} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{20} } func (x *QueryTraceTxRequest) GetMsg() *MsgEthereumTx { @@ -12738,7 +14518,7 @@ type QueryTraceTxResponse struct { func (x *QueryTraceTxResponse) Reset() { *x = QueryTraceTxResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[19] + mi := &file_os_evm_v1_query_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12752,7 +14532,7 @@ func (*QueryTraceTxResponse) ProtoMessage() {} // Deprecated: Use QueryTraceTxResponse.ProtoReflect.Descriptor instead. func (*QueryTraceTxResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{19} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{21} } func (x *QueryTraceTxResponse) GetData() []byte { @@ -12789,7 +14569,7 @@ type QueryTraceBlockRequest struct { func (x *QueryTraceBlockRequest) Reset() { *x = QueryTraceBlockRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[20] + mi := &file_os_evm_v1_query_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12803,7 +14583,7 @@ func (*QueryTraceBlockRequest) ProtoMessage() {} // Deprecated: Use QueryTraceBlockRequest.ProtoReflect.Descriptor instead. func (*QueryTraceBlockRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{20} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{22} } func (x *QueryTraceBlockRequest) GetTxs() []*MsgEthereumTx { @@ -12875,7 +14655,7 @@ type QueryTraceBlockResponse struct { func (x *QueryTraceBlockResponse) Reset() { *x = QueryTraceBlockResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[21] + mi := &file_os_evm_v1_query_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12889,7 +14669,7 @@ func (*QueryTraceBlockResponse) ProtoMessage() {} // Deprecated: Use QueryTraceBlockResponse.ProtoReflect.Descriptor instead. func (*QueryTraceBlockResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{21} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{23} } func (x *QueryTraceBlockResponse) GetData() []byte { @@ -12910,7 +14690,7 @@ type QueryBaseFeeRequest struct { func (x *QueryBaseFeeRequest) Reset() { *x = QueryBaseFeeRequest{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[22] + mi := &file_os_evm_v1_query_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12924,7 +14704,7 @@ func (*QueryBaseFeeRequest) ProtoMessage() {} // Deprecated: Use QueryBaseFeeRequest.ProtoReflect.Descriptor instead. func (*QueryBaseFeeRequest) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{22} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{24} } // QueryBaseFeeResponse returns the EIP1559 base fee. @@ -12940,7 +14720,7 @@ type QueryBaseFeeResponse struct { func (x *QueryBaseFeeResponse) Reset() { *x = QueryBaseFeeResponse{} if protoimpl.UnsafeEnabled { - mi := &file_os_evm_v1_query_proto_msgTypes[23] + mi := &file_os_evm_v1_query_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12954,7 +14734,7 @@ func (*QueryBaseFeeResponse) ProtoMessage() {} // Deprecated: Use QueryBaseFeeResponse.ProtoReflect.Descriptor instead. func (*QueryBaseFeeResponse) Descriptor() ([]byte, []int) { - return file_os_evm_v1_query_proto_rawDescGZIP(), []int{23} + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{25} } func (x *QueryBaseFeeResponse) GetBaseFee() string { @@ -12964,6 +14744,71 @@ func (x *QueryBaseFeeResponse) GetBaseFee() string { return "" } +// QueryGlobalMinGasPriceRequest defines the request type for querying the +// GlobalMinGasPrice +type QueryGlobalMinGasPriceRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryGlobalMinGasPriceRequest) Reset() { + *x = QueryGlobalMinGasPriceRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_os_evm_v1_query_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryGlobalMinGasPriceRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryGlobalMinGasPriceRequest) ProtoMessage() {} + +// Deprecated: Use QueryGlobalMinGasPriceRequest.ProtoReflect.Descriptor instead. +func (*QueryGlobalMinGasPriceRequest) Descriptor() ([]byte, []int) { + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{26} +} + +// QueryGlobalMinGasPriceResponse returns the GlobalMinGasPrice +type QueryGlobalMinGasPriceResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // min_gas_price is the feemarket's min_gas_price + MinGasPrice string `protobuf:"bytes,1,opt,name=min_gas_price,json=minGasPrice,proto3" json:"min_gas_price,omitempty"` +} + +func (x *QueryGlobalMinGasPriceResponse) Reset() { + *x = QueryGlobalMinGasPriceResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_os_evm_v1_query_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryGlobalMinGasPriceResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryGlobalMinGasPriceResponse) ProtoMessage() {} + +// Deprecated: Use QueryGlobalMinGasPriceResponse.ProtoReflect.Descriptor instead. +func (*QueryGlobalMinGasPriceResponse) Descriptor() ([]byte, []int) { + return file_os_evm_v1_query_proto_rawDescGZIP(), []int{27} +} + +func (x *QueryGlobalMinGasPriceResponse) GetMinGasPrice() string { + if x != nil { + return x.MinGasPrice + } + return "" +} + var File_os_evm_v1_query_proto protoreflect.FileDescriptor var file_os_evm_v1_query_proto_rawDesc = []byte{ @@ -12981,170 +14826,187 @@ var file_os_evm_v1_query_proto_rawDesc = []byte{ 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x13, 0x6f, 0x73, 0x2f, 0x65, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x2f, 0x65, 0x76, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x12, 0x6f, 0x73, 0x2f, 0x65, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, - 0x39, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, - 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x63, 0x0a, 0x14, 0x51, 0x75, - 0x65, 0x72, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x1b, 0x0a, 0x09, - 0x63, 0x6f, 0x64, 0x65, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x63, 0x6f, 0x64, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x14, 0x0a, 0x05, 0x6e, 0x6f, 0x6e, - 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x6e, 0x6f, 0x6e, 0x63, 0x65, 0x22, - 0x3f, 0x0a, 0x19, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x41, 0x63, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, - 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, - 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, - 0x22, 0x86, 0x01, 0x0a, 0x1a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x14, 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x45, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, + 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2e, 0x0a, 0x06, + 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x6f, + 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x43, 0x6f, + 0x6e, 0x66, 0x69, 0x67, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x22, 0x39, 0x0a, 0x13, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x08, 0x88, + 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x63, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x25, 0x0a, 0x0e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x41, - 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, - 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, - 0x63, 0x65, 0x12, 0x25, 0x0a, 0x0e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x6e, 0x75, - 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0d, 0x61, 0x63, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x22, 0x4b, 0x0a, 0x1c, 0x51, 0x75, 0x65, - 0x72, 0x79, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x41, 0x63, 0x63, 0x6f, 0x75, - 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, - 0x73, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x08, 0x88, 0xa0, - 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x8b, 0x01, 0x0a, 0x1d, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x63, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x12, 0x25, 0x0a, - 0x0e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0d, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x75, - 0x6d, 0x62, 0x65, 0x72, 0x22, 0x39, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x6c, - 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, - 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, - 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, - 0x30, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, - 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, - 0x65, 0x22, 0x4b, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, + 0x18, 0x0a, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x6f, 0x64, + 0x65, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x6f, + 0x64, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x14, 0x0a, 0x05, 0x6e, 0x6f, 0x6e, 0x63, 0x65, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x6e, 0x6f, 0x6e, 0x63, 0x65, 0x22, 0x3f, 0x0a, 0x19, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x86, 0x01, + 0x0a, 0x1a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x25, 0x0a, 0x0e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x41, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x12, + 0x25, 0x0a, 0x0e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, + 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0d, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x22, 0x4b, 0x0a, 0x1c, 0x51, 0x75, 0x65, 0x72, 0x79, 0x56, + 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x73, 0x5f, 0x61, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, + 0x6e, 0x73, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, + 0xa0, 0x1f, 0x00, 0x22, 0x8b, 0x01, 0x0a, 0x1d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x56, 0x61, 0x6c, + 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1a, + 0x0a, 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, + 0x52, 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x12, 0x25, 0x0a, 0x0e, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x04, 0x52, 0x0d, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x75, 0x6d, 0x62, 0x65, + 0x72, 0x22, 0x39, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, - 0x73, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x03, 0x6b, 0x65, 0x79, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x2c, - 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x36, 0x0a, 0x10, - 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, - 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x27, 0x0a, 0x11, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x64, - 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x22, 0x7a, 0x0a, - 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x78, 0x4c, 0x6f, 0x67, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, - 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x3a, - 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x82, 0x01, 0x0a, 0x13, 0x51, 0x75, - 0x65, 0x72, 0x79, 0x54, 0x78, 0x4c, 0x6f, 0x67, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x22, 0x0a, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x0e, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x52, - 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, - 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x14, - 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x22, 0x4b, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, - 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x34, 0x0a, 0x06, 0x70, - 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x6f, 0x73, - 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, - 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, - 0x73, 0x22, 0xb7, 0x01, 0x0a, 0x0e, 0x45, 0x74, 0x68, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x61, 0x72, 0x67, 0x73, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x04, 0x61, 0x72, 0x67, 0x73, 0x12, 0x17, 0x0a, 0x07, 0x67, 0x61, 0x73, 0x5f, - 0x63, 0x61, 0x70, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x67, 0x61, 0x73, 0x43, 0x61, - 0x70, 0x12, 0x5d, 0x0a, 0x10, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x5f, 0x61, 0x64, - 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x32, 0xfa, 0xde, 0x1f, - 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, - 0x70, 0x65, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, - 0x0f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, - 0x12, 0x19, 0x0a, 0x08, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x07, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x22, 0x27, 0x0a, 0x13, 0x45, - 0x73, 0x74, 0x69, 0x6d, 0x61, 0x74, 0x65, 0x47, 0x61, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x67, 0x61, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, - 0x03, 0x67, 0x61, 0x73, 0x22, 0xf4, 0x03, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x72, - 0x61, 0x63, 0x65, 0x54, 0x78, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2a, 0x0a, 0x03, - 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6f, 0x73, 0x2e, 0x65, + 0x73, 0x73, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x30, 0x0a, 0x14, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x4b, + 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, + 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, + 0x79, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x2c, 0x0a, 0x14, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x36, 0x0a, 0x10, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, + 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, + 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, + 0x00, 0x22, 0x27, 0x0a, 0x11, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x22, 0x7a, 0x0a, 0x12, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x54, 0x78, 0x4c, 0x6f, 0x67, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x68, 0x61, 0x73, 0x68, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x3a, 0x08, 0x88, 0xa0, + 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, 0x82, 0x01, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x54, 0x78, 0x4c, 0x6f, 0x67, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x22, + 0x0a, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x6f, + 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x52, 0x04, 0x6c, 0x6f, + 0x67, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, + 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x14, 0x0a, 0x12, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x22, 0x4b, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x34, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, + 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, + 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0xb7, + 0x01, 0x0a, 0x0e, 0x45, 0x74, 0x68, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x12, 0x0a, 0x04, 0x61, 0x72, 0x67, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, + 0x04, 0x61, 0x72, 0x67, 0x73, 0x12, 0x17, 0x0a, 0x07, 0x67, 0x61, 0x73, 0x5f, 0x63, 0x61, 0x70, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x67, 0x61, 0x73, 0x43, 0x61, 0x70, 0x12, 0x5d, + 0x0a, 0x10, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x32, 0xfa, 0xde, 0x1f, 0x2e, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, + 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x0f, 0x70, 0x72, + 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x19, 0x0a, + 0x08, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x07, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x22, 0x54, 0x0a, 0x13, 0x45, 0x73, 0x74, 0x69, + 0x6d, 0x61, 0x74, 0x65, 0x47, 0x61, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x10, 0x0a, 0x03, 0x67, 0x61, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x67, 0x61, + 0x73, 0x12, 0x10, 0x0a, 0x03, 0x72, 0x65, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, + 0x72, 0x65, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x76, 0x6d, 0x5f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x6d, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x22, 0xf4, + 0x03, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x72, 0x61, 0x63, 0x65, 0x54, 0x78, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2a, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, + 0x4d, 0x73, 0x67, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x54, 0x78, 0x52, 0x03, 0x6d, + 0x73, 0x67, 0x12, 0x39, 0x0a, 0x0c, 0x74, 0x72, 0x61, 0x63, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x66, + 0x69, 0x67, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, + 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, + 0x52, 0x0b, 0x74, 0x72, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x3c, 0x0a, + 0x0c, 0x70, 0x72, 0x65, 0x64, 0x65, 0x63, 0x65, 0x73, 0x73, 0x6f, 0x72, 0x73, 0x18, 0x04, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, + 0x4d, 0x73, 0x67, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x54, 0x78, 0x52, 0x0c, 0x70, + 0x72, 0x65, 0x64, 0x65, 0x63, 0x65, 0x73, 0x73, 0x6f, 0x72, 0x73, 0x12, 0x21, 0x0a, 0x0c, 0x62, + 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1d, + 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x12, 0x48, 0x0a, + 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x0d, 0xc8, + 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x09, 0x62, 0x6c, + 0x6f, 0x63, 0x6b, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x5d, 0x0a, 0x10, 0x70, 0x72, 0x6f, 0x70, 0x6f, + 0x73, 0x65, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x0c, 0x42, 0x32, 0xfa, 0xde, 0x1f, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, + 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, + 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x41, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x0f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x41, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, + 0x69, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x49, + 0x64, 0x12, 0x22, 0x0a, 0x0d, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x67, + 0x61, 0x73, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4d, + 0x61, 0x78, 0x47, 0x61, 0x73, 0x4a, 0x04, 0x08, 0x02, 0x10, 0x03, 0x52, 0x08, 0x74, 0x78, 0x5f, + 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x2a, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x72, + 0x61, 0x63, 0x65, 0x54, 0x78, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, + 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, + 0x61, 0x22, 0xa9, 0x03, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x72, 0x61, 0x63, 0x65, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2a, 0x0a, 0x03, + 0x74, 0x78, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, - 0x6d, 0x54, 0x78, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x39, 0x0a, 0x0c, 0x74, 0x72, 0x61, 0x63, + 0x6d, 0x54, 0x78, 0x52, 0x03, 0x74, 0x78, 0x73, 0x12, 0x39, 0x0a, 0x0c, 0x74, 0x72, 0x61, 0x63, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x0b, 0x74, 0x72, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, - 0x66, 0x69, 0x67, 0x12, 0x3c, 0x0a, 0x0c, 0x70, 0x72, 0x65, 0x64, 0x65, 0x63, 0x65, 0x73, 0x73, - 0x6f, 0x72, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6f, 0x73, 0x2e, 0x65, - 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, - 0x6d, 0x54, 0x78, 0x52, 0x0c, 0x70, 0x72, 0x65, 0x64, 0x65, 0x63, 0x65, 0x73, 0x73, 0x6f, 0x72, - 0x73, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, - 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, - 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x48, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x74, 0x69, 0x6d, - 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, - 0x61, 0x6d, 0x70, 0x42, 0x0d, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0xa8, 0xe7, 0xb0, - 0x2a, 0x01, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x5d, 0x0a, - 0x10, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x32, 0xfa, 0xde, 0x1f, 0x2e, 0x67, 0x69, 0x74, - 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, - 0x43, 0x6f, 0x6e, 0x73, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x0f, 0x70, 0x72, 0x6f, - 0x70, 0x6f, 0x73, 0x65, 0x72, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x19, 0x0a, 0x08, - 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, - 0x63, 0x68, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x12, 0x22, 0x0a, 0x0d, 0x62, 0x6c, 0x6f, 0x63, 0x6b, - 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x67, 0x61, 0x73, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, - 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4d, 0x61, 0x78, 0x47, 0x61, 0x73, 0x4a, 0x04, 0x08, 0x02, 0x10, - 0x03, 0x52, 0x08, 0x74, 0x78, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x2a, 0x0a, 0x14, 0x51, - 0x75, 0x65, 0x72, 0x79, 0x54, 0x72, 0x61, 0x63, 0x65, 0x54, 0x78, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0xa9, 0x03, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x54, 0x72, 0x61, 0x63, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x12, 0x2a, 0x0a, 0x03, 0x74, 0x78, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x18, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, - 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x54, 0x78, 0x52, 0x03, 0x74, 0x78, 0x73, 0x12, 0x39, - 0x0a, 0x0c, 0x74, 0x72, 0x61, 0x63, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, - 0x2e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x0b, 0x74, 0x72, - 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, - 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, - 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x12, 0x48, 0x0a, 0x0a, 0x62, - 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x0d, 0xc8, 0xde, 0x1f, - 0x00, 0x90, 0xdf, 0x1f, 0x01, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, - 0x6b, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x5d, 0x0a, 0x10, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, - 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x42, - 0x32, 0xfa, 0xde, 0x1f, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, - 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x41, 0x64, 0x64, 0x72, - 0x65, 0x73, 0x73, 0x52, 0x0f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x41, 0x64, 0x64, - 0x72, 0x65, 0x73, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x69, 0x64, - 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x12, - 0x22, 0x0a, 0x0d, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x67, 0x61, 0x73, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4d, 0x61, 0x78, - 0x47, 0x61, 0x73, 0x22, 0x2d, 0x0a, 0x17, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x72, 0x61, 0x63, - 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, - 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, - 0x74, 0x61, 0x22, 0x15, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x73, 0x65, 0x46, - 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x4c, 0x0a, 0x14, 0x51, 0x75, 0x65, - 0x72, 0x79, 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x34, 0x0a, 0x08, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x42, 0x19, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, - 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x07, - 0x62, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x32, 0x93, 0x0b, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, + 0x66, 0x69, 0x67, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, + 0x62, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, + 0x6b, 0x48, 0x61, 0x73, 0x68, 0x12, 0x48, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x74, + 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, + 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x0d, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0xa8, + 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x54, 0x69, 0x6d, 0x65, 0x12, + 0x5d, 0x0a, 0x10, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x32, 0xfa, 0xde, 0x1f, 0x2e, 0x67, + 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x74, 0x79, 0x70, 0x65, + 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x0f, 0x70, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x19, + 0x0a, 0x08, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x07, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x12, 0x22, 0x0a, 0x0d, 0x62, 0x6c, 0x6f, + 0x63, 0x6b, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x67, 0x61, 0x73, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4d, 0x61, 0x78, 0x47, 0x61, 0x73, 0x22, 0x2d, 0x0a, + 0x17, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x72, 0x61, 0x63, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x15, 0x0a, 0x13, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x22, 0x4c, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x73, 0x65, + 0x46, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x34, 0x0a, 0x08, 0x62, + 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x19, 0xda, + 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, + 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x07, 0x62, 0x61, 0x73, 0x65, 0x46, 0x65, + 0x65, 0x22, 0x1f, 0x0a, 0x1d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x47, 0x6c, 0x6f, 0x62, 0x61, 0x6c, + 0x4d, 0x69, 0x6e, 0x47, 0x61, 0x73, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x22, 0x63, 0x0a, 0x1e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x47, 0x6c, 0x6f, 0x62, 0x61, + 0x6c, 0x4d, 0x69, 0x6e, 0x47, 0x61, 0x73, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x41, 0x0a, 0x0d, 0x6d, 0x69, 0x6e, 0x5f, 0x67, 0x61, 0x73, 0x5f, + 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, + 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, + 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0b, 0x6d, 0x69, 0x6e, 0x47, + 0x61, 0x73, 0x50, 0x72, 0x69, 0x63, 0x65, 0x32, 0x8a, 0x0d, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x73, 0x0a, 0x07, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1e, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x6f, @@ -13233,16 +15095,32 @@ var file_os_evm_v1_query_proto_rawDesc = []byte{ 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, 0x12, 0x16, 0x2f, 0x65, 0x76, 0x6d, 0x6f, 0x73, 0x2f, 0x65, 0x76, - 0x6d, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x42, 0x83, 0x01, - 0x0a, 0x0d, 0x63, 0x6f, 0x6d, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x42, - 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x20, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, - 0x6f, 0x73, 0x2f, 0x65, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x3b, 0x65, 0x76, 0x6d, 0x76, 0x31, 0xa2, - 0x02, 0x03, 0x4f, 0x45, 0x58, 0xaa, 0x02, 0x09, 0x4f, 0x73, 0x2e, 0x45, 0x76, 0x6d, 0x2e, 0x56, - 0x31, 0xca, 0x02, 0x09, 0x4f, 0x73, 0x5c, 0x45, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x15, - 0x4f, 0x73, 0x5c, 0x45, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, - 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0b, 0x4f, 0x73, 0x3a, 0x3a, 0x45, 0x76, 0x6d, 0x3a, - 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6d, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x12, 0x65, 0x0a, + 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x1d, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, + 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, + 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1c, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x16, 0x12, 0x14, + 0x2f, 0x65, 0x76, 0x6d, 0x6f, 0x73, 0x2f, 0x65, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x2f, 0x63, 0x6f, + 0x6e, 0x66, 0x69, 0x67, 0x12, 0x8d, 0x01, 0x0a, 0x11, 0x47, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x4d, + 0x69, 0x6e, 0x47, 0x61, 0x73, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x28, 0x2e, 0x6f, 0x73, 0x2e, + 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x47, 0x6c, 0x6f, 0x62, + 0x61, 0x6c, 0x4d, 0x69, 0x6e, 0x47, 0x61, 0x73, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x6f, 0x73, 0x2e, 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x47, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x4d, 0x69, 0x6e, 0x47, + 0x61, 0x73, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x65, 0x76, 0x6d, 0x6f, 0x73, 0x2f, + 0x65, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x69, 0x6e, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x70, + 0x72, 0x69, 0x63, 0x65, 0x42, 0x83, 0x01, 0x0a, 0x0d, 0x63, 0x6f, 0x6d, 0x2e, 0x6f, 0x73, 0x2e, + 0x65, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, + 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6f, 0x73, 0x2f, 0x65, 0x76, 0x6d, 0x2f, 0x76, 0x31, + 0x3b, 0x65, 0x76, 0x6d, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4f, 0x45, 0x58, 0xaa, 0x02, 0x09, 0x4f, + 0x73, 0x2e, 0x45, 0x76, 0x6d, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x09, 0x4f, 0x73, 0x5c, 0x45, 0x76, + 0x6d, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x15, 0x4f, 0x73, 0x5c, 0x45, 0x76, 0x6d, 0x5c, 0x56, 0x31, + 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0b, 0x4f, + 0x73, 0x3a, 0x3a, 0x45, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, } var ( @@ -13257,82 +15135,92 @@ func file_os_evm_v1_query_proto_rawDescGZIP() []byte { return file_os_evm_v1_query_proto_rawDescData } -var file_os_evm_v1_query_proto_msgTypes = make([]protoimpl.MessageInfo, 24) +var file_os_evm_v1_query_proto_msgTypes = make([]protoimpl.MessageInfo, 28) var file_os_evm_v1_query_proto_goTypes = []interface{}{ - (*QueryAccountRequest)(nil), // 0: os.evm.v1.QueryAccountRequest - (*QueryAccountResponse)(nil), // 1: os.evm.v1.QueryAccountResponse - (*QueryCosmosAccountRequest)(nil), // 2: os.evm.v1.QueryCosmosAccountRequest - (*QueryCosmosAccountResponse)(nil), // 3: os.evm.v1.QueryCosmosAccountResponse - (*QueryValidatorAccountRequest)(nil), // 4: os.evm.v1.QueryValidatorAccountRequest - (*QueryValidatorAccountResponse)(nil), // 5: os.evm.v1.QueryValidatorAccountResponse - (*QueryBalanceRequest)(nil), // 6: os.evm.v1.QueryBalanceRequest - (*QueryBalanceResponse)(nil), // 7: os.evm.v1.QueryBalanceResponse - (*QueryStorageRequest)(nil), // 8: os.evm.v1.QueryStorageRequest - (*QueryStorageResponse)(nil), // 9: os.evm.v1.QueryStorageResponse - (*QueryCodeRequest)(nil), // 10: os.evm.v1.QueryCodeRequest - (*QueryCodeResponse)(nil), // 11: os.evm.v1.QueryCodeResponse - (*QueryTxLogsRequest)(nil), // 12: os.evm.v1.QueryTxLogsRequest - (*QueryTxLogsResponse)(nil), // 13: os.evm.v1.QueryTxLogsResponse - (*QueryParamsRequest)(nil), // 14: os.evm.v1.QueryParamsRequest - (*QueryParamsResponse)(nil), // 15: os.evm.v1.QueryParamsResponse - (*EthCallRequest)(nil), // 16: os.evm.v1.EthCallRequest - (*EstimateGasResponse)(nil), // 17: os.evm.v1.EstimateGasResponse - (*QueryTraceTxRequest)(nil), // 18: os.evm.v1.QueryTraceTxRequest - (*QueryTraceTxResponse)(nil), // 19: os.evm.v1.QueryTraceTxResponse - (*QueryTraceBlockRequest)(nil), // 20: os.evm.v1.QueryTraceBlockRequest - (*QueryTraceBlockResponse)(nil), // 21: os.evm.v1.QueryTraceBlockResponse - (*QueryBaseFeeRequest)(nil), // 22: os.evm.v1.QueryBaseFeeRequest - (*QueryBaseFeeResponse)(nil), // 23: os.evm.v1.QueryBaseFeeResponse - (*v1beta1.PageRequest)(nil), // 24: cosmos.base.query.v1beta1.PageRequest - (*Log)(nil), // 25: os.evm.v1.Log - (*v1beta1.PageResponse)(nil), // 26: cosmos.base.query.v1beta1.PageResponse - (*Params)(nil), // 27: os.evm.v1.Params - (*MsgEthereumTx)(nil), // 28: os.evm.v1.MsgEthereumTx - (*TraceConfig)(nil), // 29: os.evm.v1.TraceConfig - (*timestamppb.Timestamp)(nil), // 30: google.protobuf.Timestamp - (*MsgEthereumTxResponse)(nil), // 31: os.evm.v1.MsgEthereumTxResponse + (*QueryConfigRequest)(nil), // 0: os.evm.v1.QueryConfigRequest + (*QueryConfigResponse)(nil), // 1: os.evm.v1.QueryConfigResponse + (*QueryAccountRequest)(nil), // 2: os.evm.v1.QueryAccountRequest + (*QueryAccountResponse)(nil), // 3: os.evm.v1.QueryAccountResponse + (*QueryCosmosAccountRequest)(nil), // 4: os.evm.v1.QueryCosmosAccountRequest + (*QueryCosmosAccountResponse)(nil), // 5: os.evm.v1.QueryCosmosAccountResponse + (*QueryValidatorAccountRequest)(nil), // 6: os.evm.v1.QueryValidatorAccountRequest + (*QueryValidatorAccountResponse)(nil), // 7: os.evm.v1.QueryValidatorAccountResponse + (*QueryBalanceRequest)(nil), // 8: os.evm.v1.QueryBalanceRequest + (*QueryBalanceResponse)(nil), // 9: os.evm.v1.QueryBalanceResponse + (*QueryStorageRequest)(nil), // 10: os.evm.v1.QueryStorageRequest + (*QueryStorageResponse)(nil), // 11: os.evm.v1.QueryStorageResponse + (*QueryCodeRequest)(nil), // 12: os.evm.v1.QueryCodeRequest + (*QueryCodeResponse)(nil), // 13: os.evm.v1.QueryCodeResponse + (*QueryTxLogsRequest)(nil), // 14: os.evm.v1.QueryTxLogsRequest + (*QueryTxLogsResponse)(nil), // 15: os.evm.v1.QueryTxLogsResponse + (*QueryParamsRequest)(nil), // 16: os.evm.v1.QueryParamsRequest + (*QueryParamsResponse)(nil), // 17: os.evm.v1.QueryParamsResponse + (*EthCallRequest)(nil), // 18: os.evm.v1.EthCallRequest + (*EstimateGasResponse)(nil), // 19: os.evm.v1.EstimateGasResponse + (*QueryTraceTxRequest)(nil), // 20: os.evm.v1.QueryTraceTxRequest + (*QueryTraceTxResponse)(nil), // 21: os.evm.v1.QueryTraceTxResponse + (*QueryTraceBlockRequest)(nil), // 22: os.evm.v1.QueryTraceBlockRequest + (*QueryTraceBlockResponse)(nil), // 23: os.evm.v1.QueryTraceBlockResponse + (*QueryBaseFeeRequest)(nil), // 24: os.evm.v1.QueryBaseFeeRequest + (*QueryBaseFeeResponse)(nil), // 25: os.evm.v1.QueryBaseFeeResponse + (*QueryGlobalMinGasPriceRequest)(nil), // 26: os.evm.v1.QueryGlobalMinGasPriceRequest + (*QueryGlobalMinGasPriceResponse)(nil), // 27: os.evm.v1.QueryGlobalMinGasPriceResponse + (*ChainConfig)(nil), // 28: os.evm.v1.ChainConfig + (*v1beta1.PageRequest)(nil), // 29: cosmos.base.query.v1beta1.PageRequest + (*Log)(nil), // 30: os.evm.v1.Log + (*v1beta1.PageResponse)(nil), // 31: cosmos.base.query.v1beta1.PageResponse + (*Params)(nil), // 32: os.evm.v1.Params + (*MsgEthereumTx)(nil), // 33: os.evm.v1.MsgEthereumTx + (*TraceConfig)(nil), // 34: os.evm.v1.TraceConfig + (*timestamppb.Timestamp)(nil), // 35: google.protobuf.Timestamp + (*MsgEthereumTxResponse)(nil), // 36: os.evm.v1.MsgEthereumTxResponse } var file_os_evm_v1_query_proto_depIdxs = []int32{ - 24, // 0: os.evm.v1.QueryTxLogsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest - 25, // 1: os.evm.v1.QueryTxLogsResponse.logs:type_name -> os.evm.v1.Log - 26, // 2: os.evm.v1.QueryTxLogsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse - 27, // 3: os.evm.v1.QueryParamsResponse.params:type_name -> os.evm.v1.Params - 28, // 4: os.evm.v1.QueryTraceTxRequest.msg:type_name -> os.evm.v1.MsgEthereumTx - 29, // 5: os.evm.v1.QueryTraceTxRequest.trace_config:type_name -> os.evm.v1.TraceConfig - 28, // 6: os.evm.v1.QueryTraceTxRequest.predecessors:type_name -> os.evm.v1.MsgEthereumTx - 30, // 7: os.evm.v1.QueryTraceTxRequest.block_time:type_name -> google.protobuf.Timestamp - 28, // 8: os.evm.v1.QueryTraceBlockRequest.txs:type_name -> os.evm.v1.MsgEthereumTx - 29, // 9: os.evm.v1.QueryTraceBlockRequest.trace_config:type_name -> os.evm.v1.TraceConfig - 30, // 10: os.evm.v1.QueryTraceBlockRequest.block_time:type_name -> google.protobuf.Timestamp - 0, // 11: os.evm.v1.Query.Account:input_type -> os.evm.v1.QueryAccountRequest - 2, // 12: os.evm.v1.Query.CosmosAccount:input_type -> os.evm.v1.QueryCosmosAccountRequest - 4, // 13: os.evm.v1.Query.ValidatorAccount:input_type -> os.evm.v1.QueryValidatorAccountRequest - 6, // 14: os.evm.v1.Query.Balance:input_type -> os.evm.v1.QueryBalanceRequest - 8, // 15: os.evm.v1.Query.Storage:input_type -> os.evm.v1.QueryStorageRequest - 10, // 16: os.evm.v1.Query.Code:input_type -> os.evm.v1.QueryCodeRequest - 14, // 17: os.evm.v1.Query.Params:input_type -> os.evm.v1.QueryParamsRequest - 16, // 18: os.evm.v1.Query.EthCall:input_type -> os.evm.v1.EthCallRequest - 16, // 19: os.evm.v1.Query.EstimateGas:input_type -> os.evm.v1.EthCallRequest - 18, // 20: os.evm.v1.Query.TraceTx:input_type -> os.evm.v1.QueryTraceTxRequest - 20, // 21: os.evm.v1.Query.TraceBlock:input_type -> os.evm.v1.QueryTraceBlockRequest - 22, // 22: os.evm.v1.Query.BaseFee:input_type -> os.evm.v1.QueryBaseFeeRequest - 1, // 23: os.evm.v1.Query.Account:output_type -> os.evm.v1.QueryAccountResponse - 3, // 24: os.evm.v1.Query.CosmosAccount:output_type -> os.evm.v1.QueryCosmosAccountResponse - 5, // 25: os.evm.v1.Query.ValidatorAccount:output_type -> os.evm.v1.QueryValidatorAccountResponse - 7, // 26: os.evm.v1.Query.Balance:output_type -> os.evm.v1.QueryBalanceResponse - 9, // 27: os.evm.v1.Query.Storage:output_type -> os.evm.v1.QueryStorageResponse - 11, // 28: os.evm.v1.Query.Code:output_type -> os.evm.v1.QueryCodeResponse - 15, // 29: os.evm.v1.Query.Params:output_type -> os.evm.v1.QueryParamsResponse - 31, // 30: os.evm.v1.Query.EthCall:output_type -> os.evm.v1.MsgEthereumTxResponse - 17, // 31: os.evm.v1.Query.EstimateGas:output_type -> os.evm.v1.EstimateGasResponse - 19, // 32: os.evm.v1.Query.TraceTx:output_type -> os.evm.v1.QueryTraceTxResponse - 21, // 33: os.evm.v1.Query.TraceBlock:output_type -> os.evm.v1.QueryTraceBlockResponse - 23, // 34: os.evm.v1.Query.BaseFee:output_type -> os.evm.v1.QueryBaseFeeResponse - 23, // [23:35] is the sub-list for method output_type - 11, // [11:23] is the sub-list for method input_type - 11, // [11:11] is the sub-list for extension type_name - 11, // [11:11] is the sub-list for extension extendee - 0, // [0:11] is the sub-list for field type_name + 28, // 0: os.evm.v1.QueryConfigResponse.config:type_name -> os.evm.v1.ChainConfig + 29, // 1: os.evm.v1.QueryTxLogsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 30, // 2: os.evm.v1.QueryTxLogsResponse.logs:type_name -> os.evm.v1.Log + 31, // 3: os.evm.v1.QueryTxLogsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 32, // 4: os.evm.v1.QueryParamsResponse.params:type_name -> os.evm.v1.Params + 33, // 5: os.evm.v1.QueryTraceTxRequest.msg:type_name -> os.evm.v1.MsgEthereumTx + 34, // 6: os.evm.v1.QueryTraceTxRequest.trace_config:type_name -> os.evm.v1.TraceConfig + 33, // 7: os.evm.v1.QueryTraceTxRequest.predecessors:type_name -> os.evm.v1.MsgEthereumTx + 35, // 8: os.evm.v1.QueryTraceTxRequest.block_time:type_name -> google.protobuf.Timestamp + 33, // 9: os.evm.v1.QueryTraceBlockRequest.txs:type_name -> os.evm.v1.MsgEthereumTx + 34, // 10: os.evm.v1.QueryTraceBlockRequest.trace_config:type_name -> os.evm.v1.TraceConfig + 35, // 11: os.evm.v1.QueryTraceBlockRequest.block_time:type_name -> google.protobuf.Timestamp + 2, // 12: os.evm.v1.Query.Account:input_type -> os.evm.v1.QueryAccountRequest + 4, // 13: os.evm.v1.Query.CosmosAccount:input_type -> os.evm.v1.QueryCosmosAccountRequest + 6, // 14: os.evm.v1.Query.ValidatorAccount:input_type -> os.evm.v1.QueryValidatorAccountRequest + 8, // 15: os.evm.v1.Query.Balance:input_type -> os.evm.v1.QueryBalanceRequest + 10, // 16: os.evm.v1.Query.Storage:input_type -> os.evm.v1.QueryStorageRequest + 12, // 17: os.evm.v1.Query.Code:input_type -> os.evm.v1.QueryCodeRequest + 16, // 18: os.evm.v1.Query.Params:input_type -> os.evm.v1.QueryParamsRequest + 18, // 19: os.evm.v1.Query.EthCall:input_type -> os.evm.v1.EthCallRequest + 18, // 20: os.evm.v1.Query.EstimateGas:input_type -> os.evm.v1.EthCallRequest + 20, // 21: os.evm.v1.Query.TraceTx:input_type -> os.evm.v1.QueryTraceTxRequest + 22, // 22: os.evm.v1.Query.TraceBlock:input_type -> os.evm.v1.QueryTraceBlockRequest + 24, // 23: os.evm.v1.Query.BaseFee:input_type -> os.evm.v1.QueryBaseFeeRequest + 0, // 24: os.evm.v1.Query.Config:input_type -> os.evm.v1.QueryConfigRequest + 26, // 25: os.evm.v1.Query.GlobalMinGasPrice:input_type -> os.evm.v1.QueryGlobalMinGasPriceRequest + 3, // 26: os.evm.v1.Query.Account:output_type -> os.evm.v1.QueryAccountResponse + 5, // 27: os.evm.v1.Query.CosmosAccount:output_type -> os.evm.v1.QueryCosmosAccountResponse + 7, // 28: os.evm.v1.Query.ValidatorAccount:output_type -> os.evm.v1.QueryValidatorAccountResponse + 9, // 29: os.evm.v1.Query.Balance:output_type -> os.evm.v1.QueryBalanceResponse + 11, // 30: os.evm.v1.Query.Storage:output_type -> os.evm.v1.QueryStorageResponse + 13, // 31: os.evm.v1.Query.Code:output_type -> os.evm.v1.QueryCodeResponse + 17, // 32: os.evm.v1.Query.Params:output_type -> os.evm.v1.QueryParamsResponse + 36, // 33: os.evm.v1.Query.EthCall:output_type -> os.evm.v1.MsgEthereumTxResponse + 19, // 34: os.evm.v1.Query.EstimateGas:output_type -> os.evm.v1.EstimateGasResponse + 21, // 35: os.evm.v1.Query.TraceTx:output_type -> os.evm.v1.QueryTraceTxResponse + 23, // 36: os.evm.v1.Query.TraceBlock:output_type -> os.evm.v1.QueryTraceBlockResponse + 25, // 37: os.evm.v1.Query.BaseFee:output_type -> os.evm.v1.QueryBaseFeeResponse + 1, // 38: os.evm.v1.Query.Config:output_type -> os.evm.v1.QueryConfigResponse + 27, // 39: os.evm.v1.Query.GlobalMinGasPrice:output_type -> os.evm.v1.QueryGlobalMinGasPriceResponse + 26, // [26:40] is the sub-list for method output_type + 12, // [12:26] is the sub-list for method input_type + 12, // [12:12] is the sub-list for extension type_name + 12, // [12:12] is the sub-list for extension extendee + 0, // [0:12] is the sub-list for field type_name } func init() { file_os_evm_v1_query_proto_init() } @@ -13344,7 +15232,7 @@ func file_os_evm_v1_query_proto_init() { file_os_evm_v1_tx_proto_init() if !protoimpl.UnsafeEnabled { file_os_evm_v1_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryAccountRequest); i { + switch v := v.(*QueryConfigRequest); i { case 0: return &v.state case 1: @@ -13356,7 +15244,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryAccountResponse); i { + switch v := v.(*QueryConfigResponse); i { case 0: return &v.state case 1: @@ -13368,7 +15256,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryCosmosAccountRequest); i { + switch v := v.(*QueryAccountRequest); i { case 0: return &v.state case 1: @@ -13380,7 +15268,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryCosmosAccountResponse); i { + switch v := v.(*QueryAccountResponse); i { case 0: return &v.state case 1: @@ -13392,7 +15280,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryValidatorAccountRequest); i { + switch v := v.(*QueryCosmosAccountRequest); i { case 0: return &v.state case 1: @@ -13404,7 +15292,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryValidatorAccountResponse); i { + switch v := v.(*QueryCosmosAccountResponse); i { case 0: return &v.state case 1: @@ -13416,7 +15304,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryBalanceRequest); i { + switch v := v.(*QueryValidatorAccountRequest); i { case 0: return &v.state case 1: @@ -13428,7 +15316,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryBalanceResponse); i { + switch v := v.(*QueryValidatorAccountResponse); i { case 0: return &v.state case 1: @@ -13440,7 +15328,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryStorageRequest); i { + switch v := v.(*QueryBalanceRequest); i { case 0: return &v.state case 1: @@ -13452,7 +15340,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryStorageResponse); i { + switch v := v.(*QueryBalanceResponse); i { case 0: return &v.state case 1: @@ -13464,7 +15352,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryCodeRequest); i { + switch v := v.(*QueryStorageRequest); i { case 0: return &v.state case 1: @@ -13476,7 +15364,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryCodeResponse); i { + switch v := v.(*QueryStorageResponse); i { case 0: return &v.state case 1: @@ -13488,7 +15376,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryTxLogsRequest); i { + switch v := v.(*QueryCodeRequest); i { case 0: return &v.state case 1: @@ -13500,7 +15388,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryTxLogsResponse); i { + switch v := v.(*QueryCodeResponse); i { case 0: return &v.state case 1: @@ -13512,7 +15400,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryParamsRequest); i { + switch v := v.(*QueryTxLogsRequest); i { case 0: return &v.state case 1: @@ -13524,7 +15412,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryParamsResponse); i { + switch v := v.(*QueryTxLogsResponse); i { case 0: return &v.state case 1: @@ -13536,7 +15424,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*EthCallRequest); i { + switch v := v.(*QueryParamsRequest); i { case 0: return &v.state case 1: @@ -13548,7 +15436,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*EstimateGasResponse); i { + switch v := v.(*QueryParamsResponse); i { case 0: return &v.state case 1: @@ -13560,7 +15448,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryTraceTxRequest); i { + switch v := v.(*EthCallRequest); i { case 0: return &v.state case 1: @@ -13572,7 +15460,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryTraceTxResponse); i { + switch v := v.(*EstimateGasResponse); i { case 0: return &v.state case 1: @@ -13584,7 +15472,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryTraceBlockRequest); i { + switch v := v.(*QueryTraceTxRequest); i { case 0: return &v.state case 1: @@ -13596,7 +15484,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryTraceBlockResponse); i { + switch v := v.(*QueryTraceTxResponse); i { case 0: return &v.state case 1: @@ -13608,7 +15496,7 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*QueryBaseFeeRequest); i { + switch v := v.(*QueryTraceBlockRequest); i { case 0: return &v.state case 1: @@ -13620,6 +15508,30 @@ func file_os_evm_v1_query_proto_init() { } } file_os_evm_v1_query_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryTraceBlockResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_os_evm_v1_query_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBaseFeeRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_os_evm_v1_query_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*QueryBaseFeeResponse); i { case 0: return &v.state @@ -13631,6 +15543,30 @@ func file_os_evm_v1_query_proto_init() { return nil } } + file_os_evm_v1_query_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryGlobalMinGasPriceRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_os_evm_v1_query_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryGlobalMinGasPriceResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } type x struct{} out := protoimpl.TypeBuilder{ @@ -13638,7 +15574,7 @@ func file_os_evm_v1_query_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_os_evm_v1_query_proto_rawDesc, NumEnums: 0, - NumMessages: 24, + NumMessages: 28, NumExtensions: 0, NumServices: 1, }, diff --git a/api/os/evm/v1/query_grpc.pb.go b/api/os/evm/v1/query_grpc.pb.go index ecfa6f83..f370b78b 100644 --- a/api/os/evm/v1/query_grpc.pb.go +++ b/api/os/evm/v1/query_grpc.pb.go @@ -22,18 +22,20 @@ import ( const _ = grpc.SupportPackageIsVersion7 const ( - Query_Account_FullMethodName = "/os.evm.v1.Query/Account" - Query_CosmosAccount_FullMethodName = "/os.evm.v1.Query/CosmosAccount" - Query_ValidatorAccount_FullMethodName = "/os.evm.v1.Query/ValidatorAccount" - Query_Balance_FullMethodName = "/os.evm.v1.Query/Balance" - Query_Storage_FullMethodName = "/os.evm.v1.Query/Storage" - Query_Code_FullMethodName = "/os.evm.v1.Query/Code" - Query_Params_FullMethodName = "/os.evm.v1.Query/Params" - Query_EthCall_FullMethodName = "/os.evm.v1.Query/EthCall" - Query_EstimateGas_FullMethodName = "/os.evm.v1.Query/EstimateGas" - Query_TraceTx_FullMethodName = "/os.evm.v1.Query/TraceTx" - Query_TraceBlock_FullMethodName = "/os.evm.v1.Query/TraceBlock" - Query_BaseFee_FullMethodName = "/os.evm.v1.Query/BaseFee" + Query_Account_FullMethodName = "/os.evm.v1.Query/Account" + Query_CosmosAccount_FullMethodName = "/os.evm.v1.Query/CosmosAccount" + Query_ValidatorAccount_FullMethodName = "/os.evm.v1.Query/ValidatorAccount" + Query_Balance_FullMethodName = "/os.evm.v1.Query/Balance" + Query_Storage_FullMethodName = "/os.evm.v1.Query/Storage" + Query_Code_FullMethodName = "/os.evm.v1.Query/Code" + Query_Params_FullMethodName = "/os.evm.v1.Query/Params" + Query_EthCall_FullMethodName = "/os.evm.v1.Query/EthCall" + Query_EstimateGas_FullMethodName = "/os.evm.v1.Query/EstimateGas" + Query_TraceTx_FullMethodName = "/os.evm.v1.Query/TraceTx" + Query_TraceBlock_FullMethodName = "/os.evm.v1.Query/TraceBlock" + Query_BaseFee_FullMethodName = "/os.evm.v1.Query/BaseFee" + Query_Config_FullMethodName = "/os.evm.v1.Query/Config" + Query_GlobalMinGasPrice_FullMethodName = "/os.evm.v1.Query/GlobalMinGasPrice" ) // QueryClient is the client API for Query service. @@ -69,6 +71,13 @@ type QueryClient interface { // it's similar to feemarket module's method, but also checks london hardfork // status. BaseFee(ctx context.Context, in *QueryBaseFeeRequest, opts ...grpc.CallOption) (*QueryBaseFeeResponse, error) + // Config queries the EVM configuration + Config(ctx context.Context, in *QueryConfigRequest, opts ...grpc.CallOption) (*QueryConfigResponse, error) + // GlobalMinGasPrice queries the MinGasPrice + // it's similar to feemarket module's method, + // but makes the conversion to 18 decimals + // when the evm denom is represented with a different precision. + GlobalMinGasPrice(ctx context.Context, in *QueryGlobalMinGasPriceRequest, opts ...grpc.CallOption) (*QueryGlobalMinGasPriceResponse, error) } type queryClient struct { @@ -187,6 +196,24 @@ func (c *queryClient) BaseFee(ctx context.Context, in *QueryBaseFeeRequest, opts return out, nil } +func (c *queryClient) Config(ctx context.Context, in *QueryConfigRequest, opts ...grpc.CallOption) (*QueryConfigResponse, error) { + out := new(QueryConfigResponse) + err := c.cc.Invoke(ctx, Query_Config_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) GlobalMinGasPrice(ctx context.Context, in *QueryGlobalMinGasPriceRequest, opts ...grpc.CallOption) (*QueryGlobalMinGasPriceResponse, error) { + out := new(QueryGlobalMinGasPriceResponse) + err := c.cc.Invoke(ctx, Query_GlobalMinGasPrice_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // QueryServer is the server API for Query service. // All implementations must embed UnimplementedQueryServer // for forward compatibility @@ -220,6 +247,13 @@ type QueryServer interface { // it's similar to feemarket module's method, but also checks london hardfork // status. BaseFee(context.Context, *QueryBaseFeeRequest) (*QueryBaseFeeResponse, error) + // Config queries the EVM configuration + Config(context.Context, *QueryConfigRequest) (*QueryConfigResponse, error) + // GlobalMinGasPrice queries the MinGasPrice + // it's similar to feemarket module's method, + // but makes the conversion to 18 decimals + // when the evm denom is represented with a different precision. + GlobalMinGasPrice(context.Context, *QueryGlobalMinGasPriceRequest) (*QueryGlobalMinGasPriceResponse, error) mustEmbedUnimplementedQueryServer() } @@ -263,6 +297,12 @@ func (UnimplementedQueryServer) TraceBlock(context.Context, *QueryTraceBlockRequ func (UnimplementedQueryServer) BaseFee(context.Context, *QueryBaseFeeRequest) (*QueryBaseFeeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method BaseFee not implemented") } +func (UnimplementedQueryServer) Config(context.Context, *QueryConfigRequest) (*QueryConfigResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Config not implemented") +} +func (UnimplementedQueryServer) GlobalMinGasPrice(context.Context, *QueryGlobalMinGasPriceRequest) (*QueryGlobalMinGasPriceResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GlobalMinGasPrice not implemented") +} func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} // UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. @@ -492,6 +532,42 @@ func _Query_BaseFee_Handler(srv interface{}, ctx context.Context, dec func(inter return interceptor(ctx, in, info, handler) } +func _Query_Config_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryConfigRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Config(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Config_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Config(ctx, req.(*QueryConfigRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_GlobalMinGasPrice_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryGlobalMinGasPriceRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).GlobalMinGasPrice(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_GlobalMinGasPrice_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).GlobalMinGasPrice(ctx, req.(*QueryGlobalMinGasPriceRequest)) + } + return interceptor(ctx, in, info, handler) +} + // Query_ServiceDesc is the grpc.ServiceDesc for Query service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -547,6 +623,14 @@ var Query_ServiceDesc = grpc.ServiceDesc{ MethodName: "BaseFee", Handler: _Query_BaseFee_Handler, }, + { + MethodName: "Config", + Handler: _Query_Config_Handler, + }, + { + MethodName: "GlobalMinGasPrice", + Handler: _Query_GlobalMinGasPrice_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "os/evm/v1/query.proto", diff --git a/api/os/feemarket/v1/feemarket.pulsar.go b/api/os/feemarket/v1/feemarket.pulsar.go index 81eefba1..b4c2d98d 100644 --- a/api/os/feemarket/v1/feemarket.pulsar.go +++ b/api/os/feemarket/v1/feemarket.pulsar.go @@ -880,7 +880,7 @@ var file_os_feemarket_v1_feemarket_proto_rawDesc = []byte{ 0x6f, 0x12, 0x0f, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xda, 0x03, 0x0a, 0x06, + 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xe0, 0x03, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1e, 0x0a, 0x0b, 0x6e, 0x6f, 0x5f, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x6e, 0x6f, 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x12, 0x3d, 0x0a, 0x1b, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, @@ -893,36 +893,36 @@ var file_os_feemarket_v1_feemarket_proto_rawDesc = []byte{ 0x4d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x12, 0x23, 0x0a, 0x0d, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, - 0x3d, 0x0a, 0x08, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x09, 0x42, 0x22, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, - 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, - 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x07, 0x62, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x12, 0x4c, - 0x0a, 0x0d, 0x6d, 0x69, 0x6e, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, - 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x28, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, - 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, - 0x0b, 0x6d, 0x69, 0x6e, 0x47, 0x61, 0x73, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x56, 0x0a, 0x12, - 0x6d, 0x69, 0x6e, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, - 0x65, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x42, 0x28, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, - 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, - 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0xa8, 0xe7, 0xb0, - 0x2a, 0x01, 0x52, 0x10, 0x6d, 0x69, 0x6e, 0x47, 0x61, 0x73, 0x4d, 0x75, 0x6c, 0x74, 0x69, 0x70, - 0x6c, 0x69, 0x65, 0x72, 0x3a, 0x1a, 0x8a, 0xe7, 0xb0, 0x2a, 0x15, 0x6f, 0x73, 0x2f, 0x78, 0x2f, - 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, - 0x4a, 0x04, 0x08, 0x04, 0x10, 0x05, 0x52, 0x10, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c, 0x5f, - 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x42, 0xb1, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, - 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, - 0x42, 0x0e, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x50, 0x01, 0x5a, 0x2c, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, - 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6f, 0x73, 0x2f, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, - 0x74, 0x2f, 0x76, 0x31, 0x3b, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x76, 0x31, - 0xa2, 0x02, 0x03, 0x4f, 0x46, 0x58, 0xaa, 0x02, 0x0f, 0x4f, 0x73, 0x2e, 0x46, 0x65, 0x65, 0x6d, - 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0f, 0x4f, 0x73, 0x5c, 0x46, 0x65, - 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1b, 0x4f, 0x73, 0x5c, - 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, - 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x4f, 0x73, 0x3a, 0x3a, 0x46, - 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, + 0x43, 0x0a, 0x08, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x28, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x07, 0x62, 0x61, 0x73, + 0x65, 0x46, 0x65, 0x65, 0x12, 0x4c, 0x0a, 0x0d, 0x6d, 0x69, 0x6e, 0x5f, 0x67, 0x61, 0x73, 0x5f, + 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x28, 0xc8, 0xde, 0x1f, + 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, + 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, + 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x0b, 0x6d, 0x69, 0x6e, 0x47, 0x61, 0x73, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x12, 0x56, 0x0a, 0x12, 0x6d, 0x69, 0x6e, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x6d, 0x75, + 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x42, 0x28, + 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, + 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x44, 0x65, 0x63, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x10, 0x6d, 0x69, 0x6e, 0x47, 0x61, 0x73, + 0x4d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x3a, 0x1a, 0x8a, 0xe7, 0xb0, 0x2a, + 0x15, 0x6f, 0x73, 0x2f, 0x78, 0x2f, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x4a, 0x04, 0x08, 0x04, 0x10, 0x05, 0x52, 0x10, 0x69, 0x6e, + 0x69, 0x74, 0x69, 0x61, 0x6c, 0x5f, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x42, 0xb1, + 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x42, 0x0e, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2c, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6f, 0x73, 0x2f, 0x66, 0x65, + 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x3b, 0x66, 0x65, 0x65, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4f, 0x46, 0x58, 0xaa, 0x02, 0x0f, 0x4f, + 0x73, 0x2e, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x56, 0x31, 0xca, 0x02, + 0x0f, 0x4f, 0x73, 0x5c, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, + 0xe2, 0x02, 0x1b, 0x4f, 0x73, 0x5c, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, + 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x11, 0x4f, 0x73, 0x3a, 0x3a, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x3a, 0x3a, + 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/api/os/feemarket/v1/query.pulsar.go b/api/os/feemarket/v1/query.pulsar.go index b53c4483..912d24fc 100644 --- a/api/os/feemarket/v1/query.pulsar.go +++ b/api/os/feemarket/v1/query.pulsar.go @@ -2572,51 +2572,51 @@ var file_os_feemarket_v1_query_proto_rawDesc = []byte{ 0x65, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x15, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x4c, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, - 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x34, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x52, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, + 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3a, 0x0a, 0x08, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x42, 0x19, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, - 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x07, 0x62, 0x61, 0x73, - 0x65, 0x46, 0x65, 0x65, 0x22, 0x16, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x47, 0x61, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x29, 0x0a, 0x15, - 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x67, 0x61, 0x73, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x03, 0x67, 0x61, 0x73, 0x32, 0xf7, 0x02, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x12, 0x74, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x23, 0x2e, 0x6f, 0x73, - 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, - 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x24, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, - 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1f, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x19, 0x12, 0x17, - 0x2f, 0x6f, 0x73, 0x2f, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, - 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x79, 0x0a, 0x07, 0x42, 0x61, 0x73, 0x65, 0x46, - 0x65, 0x65, 0x12, 0x24, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, - 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, - 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, + 0x42, 0x1f, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, + 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, + 0x63, 0x52, 0x07, 0x62, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x22, 0x16, 0x0a, 0x14, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x22, 0x29, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x47, 0x61, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x67, + 0x61, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x67, 0x61, 0x73, 0x32, 0xf7, 0x02, + 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x74, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x12, 0x23, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1f, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x19, 0x12, 0x17, 0x2f, 0x6f, 0x73, 0x2f, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x79, 0x0a, + 0x07, 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x12, 0x24, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x21, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1b, 0x12, 0x19, 0x2f, 0x6f, 0x73, 0x2f, 0x66, 0x65, 0x65, - 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, - 0x65, 0x65, 0x12, 0x7d, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x12, 0x25, + 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, - 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, - 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x47, 0x61, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x6f, 0x73, 0x2f, 0x66, 0x65, 0x65, 0x6d, 0x61, - 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x67, 0x61, - 0x73, 0x42, 0xad, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, - 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2c, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, - 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6f, 0x73, 0x2f, 0x66, 0x65, 0x65, - 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x3b, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, - 0x6b, 0x65, 0x74, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4f, 0x46, 0x58, 0xaa, 0x02, 0x0f, 0x4f, 0x73, - 0x2e, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0f, - 0x4f, 0x73, 0x5c, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0xe2, - 0x02, 0x1b, 0x4f, 0x73, 0x5c, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, - 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, - 0x4f, 0x73, 0x3a, 0x3a, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x3a, 0x3a, 0x56, - 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x21, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1b, 0x12, 0x19, 0x2f, + 0x6f, 0x73, 0x2f, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x2f, + 0x62, 0x61, 0x73, 0x65, 0x5f, 0x66, 0x65, 0x65, 0x12, 0x7d, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x47, 0x61, 0x73, 0x12, 0x25, 0x2e, 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x47, 0x61, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x6f, 0x73, + 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x6f, 0x73, + 0x2f, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x6c, + 0x6f, 0x63, 0x6b, 0x5f, 0x67, 0x61, 0x73, 0x42, 0xad, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, + 0x6f, 0x73, 0x2e, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x42, + 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2c, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x6f, 0x73, 0x2f, 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x3b, + 0x66, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4f, 0x46, + 0x58, 0xaa, 0x02, 0x0f, 0x4f, 0x73, 0x2e, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0f, 0x4f, 0x73, 0x5c, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1b, 0x4f, 0x73, 0x5c, 0x46, 0x65, 0x65, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x4f, 0x73, 0x3a, 0x3a, 0x46, 0x65, 0x65, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/api/os/types/v1/dynamic_fee.pulsar.go b/api/os/types/v1/dynamic_fee.pulsar.go index 93c4180d..df8608d5 100644 --- a/api/os/types/v1/dynamic_fee.pulsar.go +++ b/api/os/types/v1/dynamic_fee.pulsar.go @@ -497,24 +497,24 @@ var file_os_types_v1_dynamic_fee_proto_rawDesc = []byte{ 0x0b, 0x6f, 0x73, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x76, 0x31, 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x6f, 0x0a, 0x1b, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x75, 0x0a, 0x1b, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x79, 0x6e, 0x61, 0x6d, 0x69, 0x63, 0x46, - 0x65, 0x65, 0x54, 0x78, 0x12, 0x50, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x70, 0x72, 0x69, 0x6f, + 0x65, 0x65, 0x54, 0x78, 0x12, 0x56, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x70, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x5f, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x42, 0x22, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xa8, - 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x10, 0x6d, 0x61, 0x78, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, - 0x79, 0x50, 0x72, 0x69, 0x63, 0x65, 0x42, 0x96, 0x01, 0x0a, 0x0f, 0x63, 0x6f, 0x6d, 0x2e, 0x6f, - 0x73, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x76, 0x31, 0x42, 0x0f, 0x44, 0x79, 0x6e, 0x61, - 0x6d, 0x69, 0x63, 0x46, 0x65, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x24, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, - 0x6f, 0x73, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x74, 0x79, 0x70, 0x65, - 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4f, 0x54, 0x58, 0xaa, 0x02, 0x0b, 0x4f, 0x73, 0x2e, 0x54, - 0x79, 0x70, 0x65, 0x73, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0b, 0x4f, 0x73, 0x5c, 0x54, 0x79, 0x70, - 0x65, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x17, 0x4f, 0x73, 0x5c, 0x54, 0x79, 0x70, 0x65, 0x73, - 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, - 0x02, 0x0d, 0x4f, 0x73, 0x3a, 0x3a, 0x54, 0x79, 0x70, 0x65, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, - 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x42, 0x28, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x44, 0x65, 0x63, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x10, 0x6d, 0x61, 0x78, 0x50, + 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x50, 0x72, 0x69, 0x63, 0x65, 0x42, 0x96, 0x01, 0x0a, + 0x0f, 0x63, 0x6f, 0x6d, 0x2e, 0x6f, 0x73, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x76, 0x31, + 0x42, 0x0f, 0x44, 0x79, 0x6e, 0x61, 0x6d, 0x69, 0x63, 0x46, 0x65, 0x65, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x24, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, + 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6f, 0x73, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x76, + 0x31, 0x3b, 0x74, 0x79, 0x70, 0x65, 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x4f, 0x54, 0x58, 0xaa, + 0x02, 0x0b, 0x4f, 0x73, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0b, + 0x4f, 0x73, 0x5c, 0x54, 0x79, 0x70, 0x65, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x17, 0x4f, 0x73, + 0x5c, 0x54, 0x79, 0x70, 0x65, 0x73, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0d, 0x4f, 0x73, 0x3a, 0x3a, 0x54, 0x79, 0x70, 0x65, + 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/contracts/hardhat.config.js b/contracts/hardhat.config.js index 8dcd414c..e170ff74 100644 --- a/contracts/hardhat.config.js +++ b/contracts/hardhat.config.js @@ -1,7 +1,17 @@ /** @type import('hardhat/config').HardhatUserConfig */ module.exports = { - solidity: '0.8.20', + solidity: { + compilers: [ + { + version: "0.8.20", + }, + // This version is required to compile the werc9 contract. + { + version: "0.4.22", + }, + ], + }, paths: { - sources: './solidity' - } -} + sources: "./solidity", + }, +}; diff --git a/contracts/package-lock.json b/contracts/package-lock.json index c5773350..8c787efa 100644 --- a/contracts/package-lock.json +++ b/contracts/package-lock.json @@ -2990,20 +2990,47 @@ "dev": true }, "node_modules/secp256k1": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/secp256k1/-/secp256k1-4.0.3.tgz", - "integrity": "sha512-NLZVf+ROMxwtEj3Xa562qgv2BK5e2WNmXPiOdVIPLgs6lyTzMvBq0aWTYMI5XCP9jZMVKOcqZLw/Wc4vDkuxhA==", + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/secp256k1/-/secp256k1-4.0.4.tgz", + "integrity": "sha512-6JfvwvjUOn8F/jUoBY2Q1v5WY5XS+rj8qSe0v8Y4ezH4InLgTEeOOPQsRll9OV429Pvo6BCHGavIyJfr3TAhsw==", "dev": true, "hasInstallScript": true, "dependencies": { - "elliptic": "^6.5.4", - "node-addon-api": "^2.0.0", + "elliptic": "^6.5.7", + "node-addon-api": "^5.0.0", "node-gyp-build": "^4.2.0" }, "engines": { - "node": ">=10.0.0" + "node": ">=18.0.0" + } + }, + "node_modules/secp256k1/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", + "dev": true + }, + "node_modules/secp256k1/node_modules/elliptic": { + "version": "6.5.7", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.7.tgz", + "integrity": "sha512-ESVCtTwiA+XhY3wyh24QqRGBoP3rEdDUl3EDUUo9tft074fi19IrdpH7hLCMMP3CIj7jb3W96rn8lt/BqIlt5Q==", + "dev": true, + "dependencies": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" } }, + "node_modules/secp256k1/node_modules/node-addon-api": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-5.1.0.tgz", + "integrity": "sha512-eh0GgfEkpnoWDq+VY8OyvYhFEzBk6jIYbRKdIlyTiAXIVJ8PyBaKb0rp7oDtoddbdoHWhq8wwr+XZ81F1rpNdA==", + "dev": true + }, "node_modules/semver": { "version": "6.3.1", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", diff --git a/ethereum/eip712/eip712_fuzzer_test.go b/ethereum/eip712/eip712_fuzzer_test.go index 7ee0481d..b1e85c23 100644 --- a/ethereum/eip712/eip712_fuzzer_test.go +++ b/ethereum/eip712/eip712_fuzzer_test.go @@ -187,6 +187,6 @@ func (suite *EIP712TestSuite) createRandomString() string { } // createRandomIntInRange provides a random integer between [min, max) -func (suite *EIP712TestSuite) createRandomIntInRange(min int, max int) int { - return rand.Intn(max-min) + min +func (suite *EIP712TestSuite) createRandomIntInRange(minInt int, maxInt int) int { + return rand.Intn(maxInt-minInt) + minInt } diff --git a/ethereum/eip712/eip712_test.go b/ethereum/eip712/eip712_test.go index bd35b131..3ea858be 100644 --- a/ethereum/eip712/eip712_test.go +++ b/ethereum/eip712/eip712_test.go @@ -27,6 +27,7 @@ import ( "github.com/evmos/os/crypto/ethsecp256k1" "github.com/evmos/os/ethereum/eip712" "github.com/evmos/os/testutil/integration/os/network" + evmtypes "github.com/evmos/os/x/evm/types" "github.com/stretchr/testify/suite" "github.com/tidwall/gjson" "github.com/tidwall/sjson" @@ -69,7 +70,7 @@ func (suite *EIP712TestSuite) SetupTest() { nw := network.New() suite.config = nw.GetEncodingConfig() suite.clientCtx = client.Context{}.WithTxConfig(suite.config.TxConfig) - suite.denom = constants.ExampleAttoDenom + suite.denom = evmtypes.GetEVMCoinDenom() sdk.GetConfig().SetBech32PrefixForAccount(chainconfig.Bech32Prefix, "") } diff --git a/ethereum/eip712/preprocess_test.go b/ethereum/eip712/preprocess_test.go index 34376c66..3b362757 100644 --- a/ethereum/eip712/preprocess_test.go +++ b/ethereum/eip712/preprocess_test.go @@ -21,6 +21,7 @@ import ( "github.com/evmos/os/ethereum/eip712" utiltx "github.com/evmos/os/testutil/tx" "github.com/evmos/os/types" + evmtypes "github.com/evmos/os/x/evm/types" "github.com/stretchr/testify/require" ) @@ -109,7 +110,7 @@ func TestLedgerPreprocessing(t *testing.T) { require.Equal(t, txFeePayer, tc.expectedFeePayer) require.Equal(t, tx.GetGas(), tc.expectedGas) - require.Equal(t, tx.GetFee().AmountOf(constants.ExampleAttoDenom), tc.expectedFee) + require.Equal(t, tx.GetFee().AmountOf(evmtypes.GetEVMCoinDenom()), tc.expectedFee) require.Equal(t, tx.GetMemo(), tc.expectedMemo) // Verify message is unchanged @@ -207,7 +208,7 @@ func createPopulatedTestCase(t *testing.T) TestCaseStruct { txBuilder.SetFeeAmount(sdk.NewCoins( sdk.NewCoin( - constants.ExampleAttoDenom, + evmtypes.GetEVMCoinDenom(), feeAmount, ))) @@ -219,7 +220,7 @@ func createPopulatedTestCase(t *testing.T) TestCaseStruct { ToAddress: "evmos12luku6uxehhak02py4rcz65zu0swh7wjun6msa", Amount: sdk.NewCoins( sdk.NewCoin( - constants.ExampleAttoDenom, + evmtypes.GetEVMCoinDenom(), math.NewInt(10000000), ), ), diff --git a/example_chain/ante/evm_benchmark_test.go b/example_chain/ante/evm_benchmark_test.go index 8fe5b0a0..bb953639 100644 --- a/example_chain/ante/evm_benchmark_test.go +++ b/example_chain/ante/evm_benchmark_test.go @@ -126,7 +126,7 @@ func (s *benchmarkSuite) generateTxType(txType string) (sdktypes.Tx, error) { receiver, sdktypes.NewCoins( sdktypes.NewCoin( - s.network.GetDenom(), + s.network.GetBaseDenom(), math.NewInt(1000), ), ), @@ -152,6 +152,6 @@ func (s *benchmarkSuite) generateHandlerOptions() chainante.HandlerOptions { SignModeHandler: encCfg.TxConfig.SignModeHandler(), SigGasConsumer: ante.SigVerificationGasConsumer, MaxTxGasWanted: 1_000_000_000, - TxFeeChecker: ethante.NewDynamicFeeChecker(s.network.App.EVMKeeper), + TxFeeChecker: ethante.NewDynamicFeeChecker(s.network.App.FeeMarketKeeper), } } diff --git a/example_chain/ante/handler_options_test.go b/example_chain/ante/handler_options_test.go index a0f7f5ae..4612450c 100644 --- a/example_chain/ante/handler_options_test.go +++ b/example_chain/ante/handler_options_test.go @@ -129,7 +129,7 @@ func TestValidateHandlerOptions(t *testing.T) { SignModeHandler: nw.GetEncodingConfig().TxConfig.SignModeHandler(), SigGasConsumer: ante.SigVerificationGasConsumer, MaxTxGasWanted: 40000000, - TxFeeChecker: ethante.NewDynamicFeeChecker(nw.App.EVMKeeper), + TxFeeChecker: ethante.NewDynamicFeeChecker(nw.App.FeeMarketKeeper), }, true, }, diff --git a/example_chain/ante/integration_test.go b/example_chain/ante/integration_test.go index 5575b81d..b758087f 100644 --- a/example_chain/ante/integration_test.go +++ b/example_chain/ante/integration_test.go @@ -1,11 +1,10 @@ package ante_test import ( - sdkmath "cosmossdk.io/math" + "cosmossdk.io/math" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/evmos/os/testutil/constants" commonfactory "github.com/evmos/os/testutil/integration/common/factory" "github.com/evmos/os/testutil/integration/os/factory" "github.com/evmos/os/testutil/integration/os/grpc" @@ -57,9 +56,9 @@ var _ = Describe("when sending a Cosmos transaction", Label("AnteHandler"), Orde rewards sdk.DecCoins // minExpRewards are the minimun rewards that should be accrued // for the test case - minExpRewards = sdk.DecCoins{sdk.DecCoin{Amount: sdkmath.LegacyNewDec(1e5), Denom: constants.ExampleAttoDenom}} - delegationCoin = sdk.Coin{Amount: sdkmath.NewInt(1e15), Denom: constants.ExampleAttoDenom} - transferAmt = sdkmath.NewInt(1e14) + minExpRewards = sdk.DecCoins{sdk.DecCoin{Amount: math.LegacyNewDec(1e5), Denom: s.network.GetBaseDenom()}} + delegationCoin = sdk.Coin{Amount: math.NewInt(1e15), Denom: s.network.GetBaseDenom()} + transferAmt = math.NewInt(1e14) ) BeforeEach(func() { @@ -70,7 +69,7 @@ var _ = Describe("when sending a Cosmos transaction", Label("AnteHandler"), Orde msg = &banktypes.MsgSend{ FromAddress: addr.String(), ToAddress: "evmos1dx67l23hz9l0k9hcher8xz04uj7wf3yu26l2yn", - Amount: sdk.Coins{sdk.Coin{Amount: transferAmt, Denom: constants.ExampleAttoDenom}}, + Amount: sdk.Coins{sdk.Coin{Amount: transferAmt, Denom: s.network.GetBaseDenom()}}, } valAddr := s.network.GetValidators()[0].OperatorAddress @@ -82,18 +81,20 @@ var _ = Describe("when sending a Cosmos transaction", Label("AnteHandler"), Orde }) It("should succeed & not withdraw any staking rewards", func() { - prevBalanceRes, err := s.grpcHandler.GetBalance(addr, s.network.GetDenom()) + prevBalanceRes, err := s.grpcHandler.GetBalanceFromBank(addr, s.network.GetBaseDenom()) Expect(err).To(BeNil()) - baseFeeRes, err := s.grpcHandler.GetBaseFee() + baseFeeRes, err := s.grpcHandler.GetEvmBaseFee() Expect(err).To(BeNil()) Expect(baseFeeRes).ToNot(BeNil(), "baseFeeRes is nil") + gasPrice := baseFeeRes.BaseFee + res, err := s.factory.ExecuteCosmosTx( priv, commonfactory.CosmosTxArgs{ Msgs: []sdk.Msg{msg}, - GasPrice: baseFeeRes.BaseFee, + GasPrice: gasPrice, }, ) Expect(err).To(BeNil()) @@ -106,8 +107,8 @@ var _ = Describe("when sending a Cosmos transaction", Label("AnteHandler"), Orde // fees should be deducted from balance Expect(baseFeeRes.BaseFee).ToNot(BeNil(), "baseFeeRes.BaseFee is nil") - feesAmt := sdkmath.NewInt(res.GasWanted).Mul(*baseFeeRes.BaseFee) - balanceRes, err := s.grpcHandler.GetBalance(addr, s.network.GetDenom()) + feesAmt := math.NewInt(res.GasWanted).Mul(*baseFeeRes.BaseFee) + balanceRes, err := s.grpcHandler.GetBalanceFromBank(addr, s.network.GetBaseDenom()) Expect(err).To(BeNil()) Expect(balanceRes.Balance.Amount).To(Equal(prevBalanceRes.Balance.Amount.Sub(transferAmt).Sub(feesAmt))) @@ -132,8 +133,8 @@ var _ = Describe("when sending a Cosmos transaction", Label("AnteHandler"), Orde addr, sdk.Coins{ sdk.Coin{ - Amount: sdkmath.NewInt(1), - Denom: constants.ExampleAttoDenom, + Amount: math.NewInt(1), + Denom: s.network.GetBaseDenom(), }, }, ) @@ -144,7 +145,7 @@ var _ = Describe("when sending a Cosmos transaction", Label("AnteHandler"), Orde msg = &banktypes.MsgSend{ FromAddress: addr.String(), ToAddress: "evmos1dx67l23hz9l0k9hcher8xz04uj7wf3yu26l2yn", - Amount: sdk.Coins{sdk.Coin{Amount: sdkmath.NewInt(1e14), Denom: constants.ExampleAttoDenom}}, + Amount: sdk.Coins{sdk.Coin{Amount: math.NewInt(1e14), Denom: s.network.GetBaseDenom()}}, } }) diff --git a/example_chain/app.go b/example_chain/app.go index 0719ef22..f5cead5d 100644 --- a/example_chain/app.go +++ b/example_chain/app.go @@ -9,12 +9,12 @@ import ( "io" "maps" "os" - "path/filepath" "sort" autocliv1 "cosmossdk.io/api/cosmos/autocli/v1" reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" "cosmossdk.io/client/v2/autocli" + clienthelpers "cosmossdk.io/client/v2/helpers" "cosmossdk.io/core/appmodule" "cosmossdk.io/log" storetypes "cosmossdk.io/store/types" @@ -135,12 +135,11 @@ func init() { sdk.DefaultPowerReduction = evmostypes.AttoPowerReduction // get the user's home directory - userHomeDir, err := os.UserHomeDir() + var err error + DefaultNodeHome, err = clienthelpers.GetNodeHomeDirectory(".osd") if err != nil { panic(err) } - - DefaultNodeHome = filepath.Join(userHomeDir, ".osd") } const appName = "os" @@ -280,6 +279,11 @@ func NewExampleApp( bApp.SetInterfaceRegistry(interfaceRegistry) bApp.SetTxEncoder(txConfig.TxEncoder()) + // initialize the evmOS application configuration + if err := InitializeAppConfiguration(bApp.ChainID()); err != nil { + panic(err) + } + keys := storetypes.NewKVStoreKeys( authtypes.StoreKey, banktypes.StoreKey, stakingtypes.StoreKey, minttypes.StoreKey, distrtypes.StoreKey, slashingtypes.StoreKey, @@ -568,6 +572,8 @@ func NewExampleApp( app.TransferKeeper, app.IBCKeeper.ChannelKeeper, app.EVMKeeper, + app.GovKeeper, + app.SlashingKeeper, ), ) @@ -642,7 +648,8 @@ func NewExampleApp( ibcexported.ModuleName, ibctransfertypes.ModuleName, // evmOS BeginBlockers - evmtypes.ModuleName, erc20types.ModuleName, feemarkettypes.ModuleName, + erc20types.ModuleName, feemarkettypes.ModuleName, + evmtypes.ModuleName, // NOTE: EVM BeginBlocker must come after FeeMarket BeginBlocker // TODO: remove no-ops? check if all are no-ops before removing distrtypes.ModuleName, slashingtypes.ModuleName, @@ -801,7 +808,7 @@ func (app *ExampleChain) setAnteHandler(txConfig client.TxConfig, maxGasWanted u SignModeHandler: txConfig.SignModeHandler(), SigGasConsumer: evmosante.SigVerificationGasConsumer, MaxTxGasWanted: maxGasWanted, - TxFeeChecker: evmosevmante.NewDynamicFeeChecker(app.EVMKeeper), + TxFeeChecker: evmosevmante.NewDynamicFeeChecker(app.FeeMarketKeeper), } if err := options.Validate(); err != nil { panic(err) diff --git a/example_chain/config.go b/example_chain/config.go new file mode 100644 index 00000000..65120024 --- /dev/null +++ b/example_chain/config.go @@ -0,0 +1,84 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +//go:build !test +// +build !test + +package example_chain + +import ( + "strings" + + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" + evmtypes "github.com/evmos/os/x/evm/types" +) + +var sealed = false + +// ChainsCoinInfo is a map of the chain id and its corresponding EvmCoinInfo +// that allows initializing the app with different coin info based on the +// chain id +var ChainsCoinInfo = map[string]evmtypes.EvmCoinInfo{ + EighteenDecimalsChainID: { + Denom: ExampleChainDenom, + DisplayDenom: ExampleDisplayDenom, + Decimals: evmtypes.EighteenDecimals, + }, +} + +// InitializeAppConfiguration allows to setup the global configuration +// for the evmOS EVM. +func InitializeAppConfiguration(chainID string) error { + if sealed { + return nil + } + + // When calling any CLI command, it creates a tempApp inside RootCmdHandler with an empty chainID. + // In that case we want to return here and not touch the app configuration. + if chainID == "" { + return nil + } + + id := strings.Split(chainID, "-")[0] + coinInfo, found := ChainsCoinInfo[id] + if !found { + // default to 18 decimals coin info + coinInfo = ChainsCoinInfo[EighteenDecimalsChainID] + } + + // set the denom info for the chain + if err := setBaseDenom(coinInfo); err != nil { + return err + } + + baseDenom, err := sdk.GetBaseDenom() + if err != nil { + return err + } + + ethCfg := evmtypes.DefaultChainConfig(chainID) + + err = evmtypes.NewEVMConfigurator(). + WithChainConfig(ethCfg). + // NOTE: we're using the 18 decimals default for the example chain + WithEVMCoinInfo(baseDenom, uint8(coinInfo.Decimals)). + Configure() + if err != nil { + return err + } + + sealed = true + return nil +} + +// setBaseDenom registers the display denom and base denom and sets the +// base denom for the chain. +func setBaseDenom(ci evmtypes.EvmCoinInfo) error { + if err := sdk.RegisterDenom(ci.DisplayDenom, math.LegacyOneDec()); err != nil { + return err + } + + // sdk.RegisterDenom will automatically overwrite the base denom when the new denom units are lower than the current base denom's units. + return sdk.RegisterDenom(ci.Denom, math.LegacyNewDecWithPrec(1, int64(ci.Decimals))) +} diff --git a/example_chain/config_testing.go b/example_chain/config_testing.go new file mode 100644 index 00000000..11d4b5ab --- /dev/null +++ b/example_chain/config_testing.go @@ -0,0 +1,93 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +//go:build test +// +build test + +package example_chain + +import ( + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/evmos/os/example_chain/eips" + testconstants "github.com/evmos/os/testutil/constants" + "github.com/evmos/os/x/evm/core/vm" + evmtypes "github.com/evmos/os/x/evm/types" +) + +// ChainsCoinInfo is a map of the chain id and its corresponding EvmCoinInfo +// that allows initializing the app with different coin info based on the +// chain id +var ChainsCoinInfo = map[string]evmtypes.EvmCoinInfo{ + EighteenDecimalsChainID: { + Denom: ExampleChainDenom, + DisplayDenom: ExampleChainDenom, + Decimals: evmtypes.EighteenDecimals, + }, + SixDecimalsChainID: { + Denom: testconstants.ExampleMicroDenom, + DisplayDenom: testconstants.ExampleDisplayDenom, + Decimals: evmtypes.SixDecimals, + }, +} + +// InitializeAppConfiguration allows to setup the global configuration +// for tests within the Evmos EVM. We're not using the sealed flag +// and resetting the configuration to the provided one on every test setup +func InitializeAppConfiguration(chainID string) error { + coinInfo, found := ChainsCoinInfo[chainID] + if !found { + // default to mainnet + coinInfo = ChainsCoinInfo[EighteenDecimalsChainID] + } + + // set the base denom considering if its mainnet or testnet + if err := setBaseDenom(coinInfo); err != nil { + return err + } + + baseDenom, err := sdk.GetBaseDenom() + if err != nil { + return err + } + + ethCfg := evmtypes.DefaultChainConfig(chainID) + + configurator := evmtypes.NewEVMConfigurator() + // reset configuration to set the new one + configurator.ResetTestConfig() + err = configurator. + WithExtendedEips(evmosActivators). + WithChainConfig(ethCfg). + WithEVMCoinInfo(baseDenom, uint8(coinInfo.Decimals)). + Configure() + if err != nil { + return err + } + + return nil +} + +// EvmosActivators defines a map of opcode modifiers associated +// with a key defining the corresponding EIP. +var evmosActivators = map[string]func(*vm.JumpTable){ + "evmos_0": eips.Enable0000, + "evmos_1": eips.Enable0001, + "evmos_2": eips.Enable0002, +} + +// setBaseDenom registers the display denom and base denom and sets the +// base denom for the chain. The function registered different values based on +// the EvmCoinInfo to allow different configurations in mainnet and testnet. +func setBaseDenom(ci evmtypes.EvmCoinInfo) (err error) { + // Defer setting the base denom, and capture any potential error from it. + // So when failing because the denom was already registered, we ignore it and set + // the corresponding denom to be base denom + defer func() { + err = sdk.SetBaseDenom(ci.Denom) + }() + if err := sdk.RegisterDenom(ci.DisplayDenom, math.LegacyOneDec()); err != nil { + return err + } + return sdk.RegisterDenom(ci.Denom, math.LegacyNewDecWithPrec(1, int64(ci.Decimals))) +} diff --git a/example_chain/constants.go b/example_chain/constants.go index 6c770c36..037a5c07 100644 --- a/example_chain/constants.go +++ b/example_chain/constants.go @@ -6,4 +6,13 @@ package example_chain const ( // ExampleChainDenom is the denomination of the evmOS example chain's base coin. ExampleChainDenom = "aevmos" + + // ExampleDisplayDenom is the display denomination of the evmOS example chain's base coin. + ExampleDisplayDenom = "evmos" + + // EighteenDecimalsChainID is the chain ID for the 18 decimals chain. + EighteenDecimalsChainID = "os_9001" + + // SixDecimalsChainID is the chain ID for the 6 decimals chain. + SixDecimalsChainID = "ossix_9002" ) diff --git a/example_chain/eips/README.md b/example_chain/eips/README.md new file mode 100644 index 00000000..18c1f4ef --- /dev/null +++ b/example_chain/eips/README.md @@ -0,0 +1,258 @@ +# Evmos Custom EIPs + +This document explain how **evmOS** allows chain built on top of it to define custom EIPs to modify the behavior of EVM +opcodes. + +## Custom EIPs + +Inside an EVM, every state transition or query is executed by evaluating opcodes. Custom EIPs are functions used to +change the behavior of these opcodes to tailor the EVM functionalities to fit the app-chain requirements. + +Custom EIPs should be defined in an `eips` package inside the `./app/eips/` folder of chains using the **evmOS** +framework. This organization of custom implementations is not a strict requirement, but is the suggested approach to +have a clean organization of functionalities. In this file, only the custom modifier should be defined. + +Inside this package, custom EIP should be defined in a file called `eips.go`. In this file, the EIPs modifier should be +defined with the signature: + +```go +func(jt *vm.JumpTable) {} +``` + +where `vm` is the package `"github.com/evmos/os/x/evm/core/vm"`. + +Custom EIPs are used to modify the behavior of opcodes, which are described by the `operation` structure: + +```go +type operation struct { + // execute is the operation function + execute executionFunc + constantGas uint64 + dynamicGas gasFunc + // minStack tells how many stack items are required + minStack int + // maxStack specifies the max length the stack can have for this operation + // to not overflow the stack. + maxStack int + + // memorySize returns the memory size required for the operation + memorySize memorySizeFunc +} +``` + +With the **evmOS** framework, it is possible to modify any of the fields defined in the type via the `operation` setter +methods: + +- `SetExecute`: update the execution logic for the opcode. + +- `SetConstantGas`: update the value used for the constant gas cost. + +- `SetDynamicGas`: update the function used to compute the dynamic gas cost. + +- `SetMinStack`: update the minimum number of items in the stack required to execute the `operation`. + +- `SetMaxStack`: update the maximum number of items that will be in the stack after executing the `operation`. + +- `SetMemorySize`: the memory size required by the `operation`. + +An example for an EIP which modifies the constant gas used for the `CREATE` opcode is reported below: + +```go +// Enable a custom EIP-0000 +func Enable0000(jt *vm.JumpTable) { + jt[vm.CREATE].SetConstantGas(1) +} +``` + +In the same folder should also be defined tests and contracts used to verify the EIPs logic. + +## Activate Custom EIPs + +The activation of custom EIPs should be done inside the `config.go` file defined in the `./app/` folder. This file has +the role of the single source for modify the EVM implementation which is defined in the +[`x/evm/`](https://github.com/evmos/os/tree/main/x/evm) folder +of **evmOS**. + +In this file, 3 main components should be defined: + +- The custom EIPs, also called activators. +- The additional default EIPs enabled. +- The EVM configurator instance. + +All these components will be described in the following sections. + +### Opcode & EIP Activators + +Activators is the name provided by [Go-ethereum](https://geth.ethereum.org/) to the definition of the structure +grouping all possible non-default EIPs: + +```go +var activators = map[int]func(*JumpTable){ + 3855: enable3855, + ... +} +``` + +It can be interpreted as a list of available functionalities that can be toggled to change opcodes behavior. The +structure is a map where the key is the EIP number in the octal representation, and the value is the custom EIP +function that has to be evaluated. + +In **evmOS**, custom activators should be defined in a structure with the same data type, like in the example below: + +```go +// Activate custom EIPs: 0000, 0001, 0002, etc +evmosActivators = map[int]func(*vm.JumpTable){ + "evmos_0": eips.Enable0000, + "evmos_1": eips.Enable0001, + "evmos_2": eips.Enable0002, +} +``` + +It should be noted that the value of each key in the example is the modifier defined in the `eips` package in the +example provided at the of the [Custom EIPs](#custom-eips) section. + +### Default EIPs + +Custom EIPs defined in the `activators` map are not enabled by default. This type is only used to define the list of +custom functionalities that can be activated. To specify which custom EIP activate, we should modify the +**evmOS** `x/evm` module params. The parameter orchestrating enabled custom EIPs is the `DefaultExtraEIPs` and +**evmOS** provide an easy and safe way to customize it. + +To specify which activator enable in the chain, a new variable containing a slice of keys of the custom activators +should be defined. An example is reported below: + +```go +evmosEnabledEIPs = []int64{ + "evmos_0", +} +``` + +In this way, even though the custom activators defined $3$ new EIPs, we are going to activate only the number `evmos_0` + +### EVM Configurator + +The EVM configuration is the type used to modify the EVM configuration before starting a node. The type is defined as: + +```go +type EVMConfigurator struct { + extendedEIPs map[int]func(*vm.JumpTable) + extendedDefaultExtraEIPs []int64 + sealed bool +} +``` + +Currently, only 2 customizations are possible: + +- `WithExtendedEips`: extended the default available EIPs. + +- `WithExtendedDefaultExtraEIPs`: extended the default active EIPs. + +It is important to notice that the configurator will only allow to append new entries to the default ones defined by +**evmOS**. The reason behind this choice is to ensure the correct and safe execution of the virtual machine but still +allowing partners to customize their implementation. + +The `EVMConfigurator` type should be constructed using the builder pattern inside the `init()` function of the file so +that it is run during the creation of the application. + +An example of the usage of the configurator is reported below: + +```go +configurator := evmconfig.NewEVMConfigurator(). + WithExtendedEips(customActivators). + WithExtendedDefaultExtraEIPs(defaultEnabledEIPs...). + Configure() + +err := configurator.Configure() +``` + +Errors are raised when the configurator tries to append an item with the same name of one of the default one. Since +this type is used to configure the EVM before starting the node, it is safe, and suggested, to panic: + +```go +if err != nil { + panic(err) +} +``` + +## Custom EIPs Deep Dive + +When the chain receives an EVM transaction, it is handled by the `MsgServer` of the `x/evm` within the method +`EthereumTx`. The method then calls `ApplyTransaction` where the EVM configuration is created: + +```go +cfg, err := k.EVMConfig(ctx, sdk.ConsAddress(ctx.BlockHeader().ProposerAddress), k.eip155ChainID) +``` + +During the creation of this type, a query is made to retrieve the `x/evm` params. After this step, the request is +passed inside the `ApplyMessageWithConfig` where a new instance of the EVM is created: + +```go +evm := k.NewEVM(ctx, msg, cfg, tracer, stateDB) +``` + +The `NewEVM` method calls the `NewEVMWithHooks` where a new instance of the virtual machine interpreter is created: + +```go +evm.interpreter = NewEVMInterpreter(evm, config) +``` + +The management of activators is handled in this function: + +```go +func NewEVMInterpreter(evm *EVM, cfg Config) *EVMInterpreter { + // If jump table was not initialised we set the default one. + if cfg.JumpTable == nil { + cfg.JumpTable = DefaultJumpTable(evm.chainRules) + for i, eip := range cfg.ExtraEips { + // Deep-copy jumptable to prevent modification of opcodes in other tables + copy := CopyJumpTable(cfg.JumpTable) + if err := EnableEIP(eip, copy); err != nil { + // Disable it, so caller can check if it's activated or not + cfg.ExtraEips = append(cfg.ExtraEips[:i], cfg.ExtraEips[i+1:]...) + log.Error("EIP activation failed", "eip", eip, "error", err) + } + cfg.JumpTable = copy + } + } + + return &EVMInterpreter{ + evm: evm, + cfg: cfg, + } +} +``` + +As we can see, a new `JumpTable` is created if it is not received from previous evm executions in the same transaction. +After that, the function iterate over the `ExtraEips` defined in the configuration. Then, it is checked if the EIP is +associated with an activator. If yes, the activator function is execute, otherwise an error is returned and the EIP is +removed from the VM configuration. At this point, all the opcodes are ready to be executed. + +## How to Use It + +In previous sections has been described required structures and files to use the EVM configurator to enable custom +EIPs. In this the general procedure is taken into considerations. Two different scenarios are described: + +- New chain. + +- Running chain. + +### New Chain + +For a new chain starting from block genesis, the procedure described in the sections above is enough. To summarize it: + +- Create the eip file with custom activators. + +- Create the config file with custom activators, default EIPs, and the configurator. + +After starting the chain, the genesis validation will perform all the required checks and the chain will be ready using +the new custom EIPs. + +### Running Chain + +The proper approach to include and enable new EIPs, with the current state of the development, is via coordinate chain +upgrade. During the chain upgrade it is important to define the custom activators since they are not stored in the +chain. To enable them there are two possibilities: + +- Write a migration to add the new enabled EIPsm during the upgrade. + +- After the upgrade, create a governance proposal to modify the `x/evm` params. diff --git a/example_chain/eips/eips.go b/example_chain/eips/eips.go new file mode 100644 index 00000000..2c309414 --- /dev/null +++ b/example_chain/eips/eips.go @@ -0,0 +1,36 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package eips + +import ( + "github.com/evmos/os/x/evm/core/vm" +) + +var ( + Multiplier = uint64(10) + SstoreConstantGas = uint64(500) +) + +// enable0000 contains the logic to modify the CREATE and CREATE2 opcodes +// constant gas value. +func Enable0000(jt *vm.JumpTable) { + currentValCreate := jt[vm.CREATE].GetConstantGas() + jt[vm.CREATE].SetConstantGas(currentValCreate * Multiplier) + + currentValCreate2 := jt[vm.CREATE2].GetConstantGas() + jt[vm.CREATE2].SetConstantGas(currentValCreate2 * Multiplier) +} + +// enable0001 contains the logic to modify the CALL opcode +// constant gas value. +func Enable0001(jt *vm.JumpTable) { + currentVal := jt[vm.CALL].GetConstantGas() + jt[vm.CALL].SetConstantGas(currentVal * Multiplier) +} + +// enable0002 contains the logic to modify the SSTORE opcode +// constant gas value. +func Enable0002(jt *vm.JumpTable) { + jt[vm.SSTORE].SetConstantGas(SstoreConstantGas) +} diff --git a/example_chain/eips/eips_test.go b/example_chain/eips/eips_test.go new file mode 100644 index 00000000..c9c14a5a --- /dev/null +++ b/example_chain/eips/eips_test.go @@ -0,0 +1,441 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package eips_test + +import ( + "fmt" + "math/big" + "testing" + + "github.com/cosmos/cosmos-sdk/crypto/types" + "github.com/ethereum/go-ethereum/common" + "github.com/evmos/os/example_chain/eips" + "github.com/evmos/os/example_chain/eips/testdata" + "github.com/evmos/os/testutil/integration/os/factory" + "github.com/evmos/os/testutil/integration/os/grpc" + "github.com/evmos/os/testutil/integration/os/keyring" + "github.com/evmos/os/testutil/integration/os/network" + integrationutils "github.com/evmos/os/testutil/integration/os/utils" + + evmtypes "github.com/evmos/os/x/evm/types" + + "github.com/ethereum/go-ethereum/params" + + //nolint:revive // dot imports are fine for Ginkgo + . "github.com/onsi/ginkgo/v2" + //nolint:revive // dot imports are fine for Ginkgo + . "github.com/onsi/gomega" +) + +// Below tests are divided in 3 steps: +// 1. Deploy and interact with contracts to compute the gas used BEFORE enabling +// the IP. +// 2. Activate the IP under test. +// 3. Deploy and interact with contracts to compute the gas used AFTER enabling +// the IP. + +func TestIPs(t *testing.T) { + RegisterFailHandler(Fail) + RunSpecs(t, "EvmosIPs Suite") +} + +var _ = Describe("Improvement proposal evmos_0 - ", Ordered, func() { + var ( + in network.Network + tf factory.TxFactory + gh grpc.Handler + k keyring.Keyring + + senderPriv types.PrivKey + senderPriv2 types.PrivKey + senderAddr2 common.Address + + // Gas used before enabling the IP. + gasUsedPre int64 + ) + + // Multiplier used to modify the opcodes associated with evmos_0 IP. + ipMultiplier := uint64(5) + + // The factory counter is used because it will create a new instance of + // the counter contract, allowing to test the CREATE opcode. + counterFactoryContract, err := testdata.LoadCounterFactoryContract() + Expect(err).ToNot(HaveOccurred(), "failed to load Counter Factory contract") + + deploymentData := factory.ContractDeploymentData{ + Contract: counterFactoryContract, + ConstructorArgs: []interface{}{}, + } + + BeforeAll(func() { + k = keyring.New(2) + in = network.New( + network.WithPreFundedAccounts(k.GetAllAccAddrs()...), + ) + gh = grpc.NewIntegrationHandler(in) + tf = factory.New(in, gh) + + // Account used to deploy the contract before enabling the IP. + senderPriv = k.GetPrivKey(0) + // Account used to deploy the contract after enabling the IP. A second + // account is used to avoid possible additional gas costs due to the change + // in the Nonce. + senderPriv2 = k.GetPrivKey(1) + senderAddr2 = k.GetAddr(1) + + // Set extra IPs to empty to allow testing a single modifier. + defaultParams := evmtypes.DefaultParams() + defaultParams.ExtraEIPs = []string{} + + err := integrationutils.UpdateEvmParams( + integrationutils.UpdateParamsInput{ + Tf: tf, + Network: in, + Pk: senderPriv, + Params: defaultParams, + }, + ) + Expect(err).To(BeNil(), "failed during update of evm params") + Expect(in.NextBlock()).To(BeNil()) + }) + + It("should deploy the contract before enabling the IP", func() { + deploymentTxArgs, err := tf.GenerateDeployContractArgs(senderAddr2, evmtypes.EvmTxArgs{}, deploymentData) + Expect(err).To(BeNil(), "failed to create deployment tx args") + + res, err := tf.ExecuteEthTx(senderPriv2, deploymentTxArgs) + Expect(err).To(BeNil(), "failed during contract deployment") + gasUsedPre = res.GasUsed + }) + + It("should enable the new IP", func() { + eips.Multiplier = ipMultiplier + newIP := "evmos_0" + + qRes, err := gh.GetEvmParams() + Expect(err).To(BeNil(), "failed during query to evm params") + qRes.Params.ExtraEIPs = append(qRes.Params.ExtraEIPs, newIP) + err = integrationutils.UpdateEvmParams( + integrationutils.UpdateParamsInput{ + Tf: tf, + Network: in, + Pk: senderPriv, + Params: qRes.Params, + }, + ) + Expect(err).To(BeNil(), "failed during update of evm params") + + Expect(in.NextBlock()).To(BeNil()) + + qRes, err = gh.GetEvmParams() + Expect(err).To(BeNil(), "failed during query to evm params") + Expect(qRes.Params.ExtraEIPs).To(ContainElement(newIP), "expected to have IP evmos_0 in evm params") + }) + + It("should change CREATE opcode constant gas after enabling evmos_0 IP", func() { + gasCostPre := params.CreateGas + + deploymentTxArgs, err := tf.GenerateDeployContractArgs(senderAddr2, evmtypes.EvmTxArgs{}, deploymentData) + Expect(err).To(BeNil(), "failed to create deployment tx args") + + res, err := tf.ExecuteEthTx(senderPriv2, deploymentTxArgs) + Expect(err).To(BeNil(), "failed during contract deployment") + // commit block to update sender nonce + Expect(in.NextBlock()).To(BeNil()) + + gasUsedPost := res.GasUsed + + // The difference in gas is the new cost of the opcode, minus the cost of the + // opcode before enabling the new eip. + gasUsedDiff := ipMultiplier*gasCostPre - gasCostPre + expectedGas := gasUsedPre + int64(gasUsedDiff) + Expect(gasUsedPost).To(Equal(expectedGas)) + }) +}) + +var _ = Describe("Improvement proposal evmos_1 - ", Ordered, func() { + var ( + in network.Network + tf factory.TxFactory + gh grpc.Handler + k keyring.Keyring + + senderPriv types.PrivKey + + // Gas used before enabling the IP. + gasUsedPre int64 + + // The address of the factory counter. + counterFactoryAddr common.Address + ) + + // Multiplier used to modify the opcodes associated with evmos_1. + eipMultiplier := uint64(5) + initialCounterValue := 1 + + // The counter factory contract is used to deploy a counter contract and + // perform state transition using the CALL opcode. + counterFactoryContract, err := testdata.LoadCounterFactoryContract() + Expect(err).ToNot(HaveOccurred(), "failed to load Counter Factory contract") + + BeforeAll(func() { + k = keyring.New(1) + in = network.New( + network.WithPreFundedAccounts(k.GetAllAccAddrs()...), + ) + gh = grpc.NewIntegrationHandler(in) + tf = factory.New(in, gh) + + senderPriv = k.GetPrivKey(0) + + // Set extra IPs to empty to allow testing a single modifier. + defaultParams := evmtypes.DefaultParams() + defaultParams.ExtraEIPs = []string{} + err = integrationutils.UpdateEvmParams( + integrationutils.UpdateParamsInput{ + Tf: tf, + Network: in, + Pk: senderPriv, + Params: defaultParams, + }, + ) + Expect(err).To(BeNil(), "failed during update of evm params") + + Expect(in.NextBlock()).To(BeNil()) + }) + + It("should deploy the contract before enabling the IP", func() { + counterFactoryAddr, err = tf.DeployContract( + senderPriv, + evmtypes.EvmTxArgs{}, + factory.ContractDeploymentData{ + Contract: counterFactoryContract, + ConstructorArgs: []interface{}{}, + }, + ) + Expect(err).ToNot(HaveOccurred(), "failed to deploy counter factory contract") + Expect(in.NextBlock()).To(BeNil()) + + res, err := tf.ExecuteContractCall( + senderPriv, + evmtypes.EvmTxArgs{To: &counterFactoryAddr}, + factory.CallArgs{ + ContractABI: counterFactoryContract.ABI, + MethodName: "incrementCounter", + Args: []interface{}{}, + }, + ) + Expect(err).ToNot(HaveOccurred(), "failed to increment counter value") + gasUsedPre = res.GasUsed + + Expect(in.NextBlock()).To(BeNil()) + + // Query the counter value to check proper state transition later. + res, err = tf.ExecuteContractCall( + senderPriv, + evmtypes.EvmTxArgs{To: &counterFactoryAddr}, + factory.CallArgs{ + ContractABI: counterFactoryContract.ABI, + MethodName: "getCounterValue", + Args: []interface{}{}, + }, + ) + Expect(err).ToNot(HaveOccurred(), "failed to get counter value") + Expect(in.NextBlock()).To(BeNil()) + + ethRes, err := evmtypes.DecodeTxResponse(res.Data) + Expect(err).ToNot(HaveOccurred(), "failed to decode tx response") + + unpacked, err := counterFactoryContract.ABI.Unpack( + "getCounterValue", + ethRes.Ret, + ) + Expect(err).ToNot(HaveOccurred(), "failed to unpack counter value") + + counter, ok := unpacked[0].(*big.Int) + Expect(ok).To(BeTrue(), "failed to convert counter to big.Int") + Expect(counter.String()).To(Equal(fmt.Sprintf("%d", initialCounterValue+1)), "counter is not correct") + }) + It("should enable the new IP", func() { + eips.Multiplier = eipMultiplier + newIP := "evmos_1" + + qRes, err := gh.GetEvmParams() + Expect(err).To(BeNil(), "failed during query to evm params") + qRes.Params.ExtraEIPs = append(qRes.Params.ExtraEIPs, newIP) + + err = integrationutils.UpdateEvmParams( + integrationutils.UpdateParamsInput{ + Tf: tf, + Network: in, + Pk: senderPriv, + Params: qRes.Params, + }, + ) + Expect(err).To(BeNil(), "failed during update of evm params") + + Expect(in.NextBlock()).To(BeNil()) + + qRes, err = gh.GetEvmParams() + Expect(err).To(BeNil(), "failed during query to evm params") + Expect(qRes.Params.ExtraEIPs).To(ContainElement(newIP), "expected to have ip evmos_1 in evm params") + }) + It("should change CALL opcode constant gas after enabling IP", func() { + // Constant gas cost used before enabling the new IP. + gasCostPre := params.WarmStorageReadCostEIP2929 + + res, err := tf.ExecuteContractCall( + senderPriv, + evmtypes.EvmTxArgs{To: &counterFactoryAddr}, + factory.CallArgs{ + ContractABI: counterFactoryContract.ABI, + MethodName: "incrementCounter", + Args: []interface{}{}, + }, + ) + Expect(err).ToNot(HaveOccurred(), "failed to increment counter value") + gasUsedPost := res.GasUsed + Expect(in.NextBlock()).To(BeNil()) + + res, err = tf.ExecuteContractCall( + senderPriv, + evmtypes.EvmTxArgs{To: &counterFactoryAddr}, + factory.CallArgs{ + ContractABI: counterFactoryContract.ABI, + MethodName: "getCounterValue", + Args: []interface{}{}, + }, + ) + Expect(err).ToNot(HaveOccurred(), "failed to get counter value") + Expect(in.NextBlock()).To(BeNil()) + + ethRes, err := evmtypes.DecodeTxResponse(res.Data) + Expect(err).ToNot(HaveOccurred(), "failed to decode tx response") + + unpacked, err := counterFactoryContract.ABI.Unpack( + "getCounterValue", + ethRes.Ret, + ) + Expect(err).ToNot(HaveOccurred(), "failed to unpack counter value") + + counter, ok := unpacked[0].(*big.Int) + Expect(ok).To(BeTrue(), "failed to convert counter to big.Int") + Expect(counter.String()).To(Equal(fmt.Sprintf("%d", initialCounterValue+2)), "counter is not updated correctly") + + // The difference in gas is the new cost of the opcode, minus the cost of the + // opcode before enabling the new eip. + gasUsedDiff := eipMultiplier*gasCostPre - gasCostPre + expectedGas := gasUsedPre + int64(gasUsedDiff) + Expect(gasUsedPost).To(Equal(expectedGas)) + }) +}) + +var _ = Describe("Improvement proposal evmos_2 - ", Ordered, func() { + var ( + in network.Network + tf factory.TxFactory + gh grpc.Handler + k keyring.Keyring + + senderPriv types.PrivKey + senderAddr common.Address + senderPriv2 types.PrivKey + senderAddr2 common.Address + gasUsedPre int64 + ) + // Constant gas used to modify the opcodes associated with evmos_2. + constantGas := uint64(500) + + counterContract, err := testdata.LoadCounterContract() + Expect(err).ToNot(HaveOccurred(), "failed to load Counter contract") + + deploymentData := factory.ContractDeploymentData{ + Contract: counterContract, + ConstructorArgs: []interface{}{}, + } + BeforeAll(func() { + k = keyring.New(2) + in = network.New( + network.WithPreFundedAccounts(k.GetAllAccAddrs()...), + ) + gh = grpc.NewIntegrationHandler(in) + tf = factory.New(in, gh) + + // Account used to deploy the contract before enabling the IP. + senderPriv = k.GetPrivKey(0) + senderAddr = k.GetAddr(0) + // Account used to deploy the contract after enabling the IP. A second + // account is used to avoid possible additional gas costs due to the change + // in the Nonce. + senderPriv2 = k.GetPrivKey(0) + senderAddr2 = k.GetAddr(0) + + // Set extra IPs to empty to allow testing a single modifier. + defaultParams := evmtypes.DefaultParams() + defaultParams.ExtraEIPs = []string{} + + err = integrationutils.UpdateEvmParams( + integrationutils.UpdateParamsInput{ + Tf: tf, + Network: in, + Pk: senderPriv, + Params: defaultParams, + }, + ) + Expect(err).To(BeNil(), "failed during update of evm params") + + Expect(in.NextBlock()).To(BeNil()) + }) + + It("should deploy the contract before enabling the IP", func() { + deploymentTxArgs, err := tf.GenerateDeployContractArgs(senderAddr, evmtypes.EvmTxArgs{}, deploymentData) + Expect(err).To(BeNil(), "failed to create deployment tx args") + + res, err := tf.ExecuteEthTx(senderPriv, deploymentTxArgs) + Expect(err).To(BeNil(), "failed during contract deployment") + Expect(in.NextBlock()).To(BeNil()) + + gasUsedPre = res.GasUsed + }) + + It("should enable the new IP", func() { + eips.SstoreConstantGas = constantGas + newIP := "evmos_2" + + qRes, err := gh.GetEvmParams() + Expect(err).To(BeNil(), "failed during query to evm params") + qRes.Params.ExtraEIPs = append(qRes.Params.ExtraEIPs, newIP) + err = integrationutils.UpdateEvmParams( + integrationutils.UpdateParamsInput{ + Tf: tf, + Network: in, + Pk: senderPriv, + Params: qRes.Params, + }, + ) + Expect(err).To(BeNil(), "failed during update of evm params") + + Expect(in.NextBlock()).To(BeNil()) + + qRes, err = gh.GetEvmParams() + Expect(err).To(BeNil(), "failed during query to evm params") + Expect(qRes.Params.ExtraEIPs).To(ContainElement(newIP), "expected to have ip evmos_2 in evm params") + }) + + It("should change SSTORE opcode constant gas after enabling IP", func() { + deploymentTxArgs, err := tf.GenerateDeployContractArgs(senderAddr2, evmtypes.EvmTxArgs{}, deploymentData) + Expect(err).To(BeNil(), "failed to create deployment tx args") + + res, err := tf.ExecuteEthTx(senderPriv2, deploymentTxArgs) + Expect(err).To(BeNil(), "failed during contract deployment") + Expect(in.NextBlock()).To(BeNil()) + + gasUsedPost := res.GasUsed + + // The expected gas is previous gas plus the constant gas because + // previous this eip, SSTORE was using only the dynamic gas. + expectedGas := gasUsedPre + int64(constantGas) + Expect(gasUsedPost).To(Equal(expectedGas)) + }) +}) diff --git a/example_chain/eips/testdata/Counter.json b/example_chain/eips/testdata/Counter.json new file mode 100644 index 00000000..f5260dc1 --- /dev/null +++ b/example_chain/eips/testdata/Counter.json @@ -0,0 +1,38 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "Counter", + "sourceName": "solidity/example_chain/eips/testdata/Counter.sol", + "abi": [ + { + "inputs": [], + "name": "counter", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decrement", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "increment", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": "0x6080604052600160005534801561001557600080fd5b506101ba806100256000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c80632baeceb71461004657806361bc221a14610050578063d09de08a1461006e575b600080fd5b61004e610078565b005b610058610091565b60405161006591906100c9565b60405180910390f35b610076610097565b005b60008081548092919061008a90610113565b9190505550565b60005481565b6000808154809291906100a99061013c565b9190505550565b6000819050919050565b6100c3816100b0565b82525050565b60006020820190506100de60008301846100ba565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061011e826100b0565b915060008203610131576101306100e4565b5b600182039050919050565b6000610147826100b0565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610179576101786100e4565b5b60018201905091905056fea264697066735822122007fccd3f63ef8e5e0232afe2b678cec0cc66f753d5e56a92274b60545a3d930164736f6c63430008140033", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100415760003560e01c80632baeceb71461004657806361bc221a14610050578063d09de08a1461006e575b600080fd5b61004e610078565b005b610058610091565b60405161006591906100c9565b60405180910390f35b610076610097565b005b60008081548092919061008a90610113565b9190505550565b60005481565b6000808154809291906100a99061013c565b9190505550565b6000819050919050565b6100c3816100b0565b82525050565b60006020820190506100de60008301846100ba565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061011e826100b0565b915060008203610131576101306100e4565b5b600182039050919050565b6000610147826100b0565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610179576101786100e4565b5b60018201905091905056fea264697066735822122007fccd3f63ef8e5e0232afe2b678cec0cc66f753d5e56a92274b60545a3d930164736f6c63430008140033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/example_chain/eips/testdata/Counter.sol b/example_chain/eips/testdata/Counter.sol new file mode 100644 index 00000000..30ba0869 --- /dev/null +++ b/example_chain/eips/testdata/Counter.sol @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: LGPL-3.0-only + +pragma solidity >=0.7.0 <0.9.0; + +contract Counter { + uint256 public counter = 1; + + function increment() external { + counter++; + } + + function decrement() external { + counter--; + } +} diff --git a/example_chain/eips/testdata/CounterFactory.json b/example_chain/eips/testdata/CounterFactory.json new file mode 100644 index 00000000..e1ba79a5 --- /dev/null +++ b/example_chain/eips/testdata/CounterFactory.json @@ -0,0 +1,56 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "Counterfactory", + "sourceName": "solidity/example_chain/eips/testdata/CounterFactory.sol", + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [], + "name": "counterInstance", + "outputs": [ + { + "internalType": "contract Counter", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decrementCounter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getCounterValue", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "incrementCounter", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": "0x608060405234801561001057600080fd5b5060405161001d9061007e565b604051809103906000f080158015610039573d6000803e3d6000fd5b506000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555061008b565b6101df8061045c83390190565b6103c28061009a6000396000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c80635b34b9661461005157806372142b891461005b578063aef38e7214610079578063f5c5ad8314610097575b600080fd5b6100596100a1565b005b610063610123565b6040516100709190610279565b60405180910390f35b6100816101ba565b60405161008e9190610313565b60405180910390f35b61009f6101de565b005b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d09de08a6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561010957600080fd5b505af115801561011d573d6000803e3d6000fd5b50505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166361bc221a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610191573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101b5919061035f565b905090565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632baeceb76040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561024657600080fd5b505af115801561025a573d6000803e3d6000fd5b50505050565b6000819050919050565b61027381610260565b82525050565b600060208201905061028e600083018461026a565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60006102d96102d46102cf84610294565b6102b4565b610294565b9050919050565b60006102eb826102be565b9050919050565b60006102fd826102e0565b9050919050565b61030d816102f2565b82525050565b60006020820190506103286000830184610304565b92915050565b600080fd5b61033c81610260565b811461034757600080fd5b50565b60008151905061035981610333565b92915050565b6000602082840312156103755761037461032e565b5b60006103838482850161034a565b9150509291505056fea264697066735822122003185381561ec23eef539da5292be8c3d1b13687477af785fbbc16ac3027fadf64736f6c634300081400336080604052600160005534801561001557600080fd5b506101ba806100256000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c80632baeceb71461004657806361bc221a14610050578063d09de08a1461006e575b600080fd5b61004e610078565b005b610058610091565b60405161006591906100c9565b60405180910390f35b610076610097565b005b60008081548092919061008a90610113565b9190505550565b60005481565b6000808154809291906100a99061013c565b9190505550565b6000819050919050565b6100c3816100b0565b82525050565b60006020820190506100de60008301846100ba565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061011e826100b0565b915060008203610131576101306100e4565b5b600182039050919050565b6000610147826100b0565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610179576101786100e4565b5b60018201905091905056fea264697066735822122007fccd3f63ef8e5e0232afe2b678cec0cc66f753d5e56a92274b60545a3d930164736f6c63430008140033", + "deployedBytecode": "0x608060405234801561001057600080fd5b506004361061004c5760003560e01c80635b34b9661461005157806372142b891461005b578063aef38e7214610079578063f5c5ad8314610097575b600080fd5b6100596100a1565b005b610063610123565b6040516100709190610279565b60405180910390f35b6100816101ba565b60405161008e9190610313565b60405180910390f35b61009f6101de565b005b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d09de08a6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561010957600080fd5b505af115801561011d573d6000803e3d6000fd5b50505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166361bc221a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610191573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101b5919061035f565b905090565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632baeceb76040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561024657600080fd5b505af115801561025a573d6000803e3d6000fd5b50505050565b6000819050919050565b61027381610260565b82525050565b600060208201905061028e600083018461026a565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60006102d96102d46102cf84610294565b6102b4565b610294565b9050919050565b60006102eb826102be565b9050919050565b60006102fd826102e0565b9050919050565b61030d816102f2565b82525050565b60006020820190506103286000830184610304565b92915050565b600080fd5b61033c81610260565b811461034757600080fd5b50565b60008151905061035981610333565b92915050565b6000602082840312156103755761037461032e565b5b60006103838482850161034a565b9150509291505056fea264697066735822122003185381561ec23eef539da5292be8c3d1b13687477af785fbbc16ac3027fadf64736f6c63430008140033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/example_chain/eips/testdata/CounterFactory.sol b/example_chain/eips/testdata/CounterFactory.sol new file mode 100644 index 00000000..7b64412d --- /dev/null +++ b/example_chain/eips/testdata/CounterFactory.sol @@ -0,0 +1,25 @@ +// SPDX-License-Identifier: LGPL-3.0-only + +pragma solidity >=0.7.0 <0.9.0; + +import "./Counter.sol"; + +contract Counterfactory { + Counter public counterInstance; + + constructor() { + counterInstance = new Counter(); + } + + function incrementCounter() public { + counterInstance.increment(); + } + + function decrementCounter() public { + counterInstance.decrement(); + } + + function getCounterValue() public view returns (uint256) { + return counterInstance.counter(); + } +} diff --git a/example_chain/eips/testdata/contracts.go b/example_chain/eips/testdata/contracts.go new file mode 100644 index 00000000..2d336b52 --- /dev/null +++ b/example_chain/eips/testdata/contracts.go @@ -0,0 +1,17 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package testdata + +import ( + contractutils "github.com/evmos/os/contracts/utils" + evmtypes "github.com/evmos/os/x/evm/types" +) + +func LoadCounterContract() (evmtypes.CompiledContract, error) { + return contractutils.LoadContractFromJSONFile("Counter.json") +} + +func LoadCounterFactoryContract() (evmtypes.CompiledContract, error) { + return contractutils.LoadContractFromJSONFile("CounterFactory.json") +} diff --git a/example_chain/genesis.go b/example_chain/genesis.go index a7fcd5f8..8ed25177 100644 --- a/example_chain/genesis.go +++ b/example_chain/genesis.go @@ -26,7 +26,6 @@ type GenesisState map[string]json.RawMessage // and enable ALL precompiles. func NewEVMGenesisState() *evmtypes.GenesisState { evmGenState := evmtypes.DefaultGenesisState() - evmGenState.Params.EvmDenom = ExampleChainDenom evmGenState.Params.ActiveStaticPrecompiles = evmtypes.AvailableStaticPrecompiles return evmGenState diff --git a/example_chain/go.mod b/example_chain/go.mod index 5062f5ec..3fa54055 100644 --- a/example_chain/go.mod +++ b/example_chain/go.mod @@ -1,41 +1,41 @@ module github.com/evmos/os/example_chain -go 1.22.5 +go 1.22.8 require ( - cosmossdk.io/api v0.7.5 - cosmossdk.io/client/v2 v2.0.0-beta.3 + cosmossdk.io/api v0.7.6 + cosmossdk.io/client/v2 v2.0.0-beta.5 cosmossdk.io/core v0.11.1 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.4.0 - cosmossdk.io/math v1.3.0 - cosmossdk.io/store v1.1.0 + cosmossdk.io/log v1.5.0 + cosmossdk.io/math v1.4.0 + cosmossdk.io/store v1.1.1 cosmossdk.io/tools/confix v0.1.2 cosmossdk.io/x/evidence v0.1.1 cosmossdk.io/x/feegrant v0.1.1 - cosmossdk.io/x/tx v0.13.4 + cosmossdk.io/x/tx v0.13.5 cosmossdk.io/x/upgrade v0.1.4 - github.com/cometbft/cometbft v0.38.11 + github.com/cometbft/cometbft v0.38.15 github.com/cosmos/cosmos-db v1.0.2 - github.com/cosmos/cosmos-sdk v0.50.9 + github.com/cosmos/cosmos-sdk v0.50.10 github.com/cosmos/gogoproto v1.7.0 github.com/cosmos/ibc-go/modules/capability v1.0.1 - github.com/cosmos/ibc-go/v8 v8.5.1 + github.com/cosmos/ibc-go/v8 v8.5.2 github.com/ethereum/go-ethereum v1.11.5 github.com/evmos/os v0.0.0-20240806115830-ab675cc0c776 - github.com/onsi/ginkgo/v2 v2.19.1 - github.com/onsi/gomega v1.34.0 + github.com/onsi/ginkgo/v2 v2.22.0 + github.com/onsi/gomega v1.35.1 github.com/spf13/cast v1.7.0 github.com/spf13/cobra v1.8.1 github.com/spf13/viper v1.19.0 - github.com/stretchr/testify v1.9.0 + github.com/stretchr/testify v1.10.0 ) require ( cloud.google.com/go v0.115.0 // indirect cloud.google.com/go/auth v0.6.0 // indirect cloud.google.com/go/auth/oauth2adapt v0.2.2 // indirect - cloud.google.com/go/compute/metadata v0.3.0 // indirect + cloud.google.com/go/compute/metadata v0.5.0 // indirect cloud.google.com/go/iam v1.1.9 // indirect cloud.google.com/go/storage v1.41.0 // indirect cosmossdk.io/collections v0.4.0 // indirect @@ -54,24 +54,29 @@ require ( github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect github.com/bits-and-blooms/bitset v1.8.0 // indirect github.com/btcsuite/btcd v0.24.2 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect + github.com/btcsuite/btcd/btcec/v2 v2.3.4 // indirect github.com/btcsuite/btcd/btcutil v1.1.6 // indirect github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0 // indirect + github.com/bytedance/sonic v1.12.3 // indirect + github.com/bytedance/sonic/loader v0.2.0 // indirect github.com/cenkalti/backoff/v4 v4.1.3 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/chzyer/readline v1.5.1 // indirect + github.com/cloudwego/base64x v0.1.4 // indirect + github.com/cloudwego/iasm v0.2.0 // indirect github.com/cockroachdb/apd/v2 v2.0.2 // indirect - github.com/cockroachdb/errors v1.11.1 // indirect + github.com/cockroachdb/errors v1.11.3 // indirect + github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/pebble v1.1.0 // indirect + github.com/cockroachdb/pebble v1.1.1 // indirect github.com/cockroachdb/redact v1.1.5 // indirect github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect - github.com/cometbft/cometbft-db v0.12.0 // indirect + github.com/cometbft/cometbft-db v0.14.1 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/cosmos-proto v1.0.0-beta.5 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect - github.com/cosmos/iavl v1.1.2 // indirect + github.com/cosmos/iavl v1.2.0 // indirect github.com/cosmos/ics23/go v0.11.0 // indirect github.com/cosmos/ledger-cosmos-go v0.13.3 // indirect github.com/creachadair/atomicfile v0.3.1 // indirect @@ -79,7 +84,7 @@ require ( github.com/danieljoos/wincred v1.1.2 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/deckarep/golang-set v1.8.0 // indirect - github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 // indirect github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect github.com/dgraph-io/badger/v4 v4.2.0 // indirect github.com/dgraph-io/ristretto v0.1.1 // indirect @@ -94,7 +99,7 @@ require ( github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/getsentry/sentry-go v0.27.0 // indirect github.com/gin-gonic/gin v1.9.1 // indirect - github.com/go-kit/kit v0.12.0 // indirect + github.com/go-kit/kit v0.13.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect github.com/go-logr/logr v1.4.2 // indirect @@ -106,16 +111,16 @@ require ( github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/glog v1.2.1 // indirect + github.com/golang/glog v1.2.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/mock v1.6.0 // indirect github.com/golang/protobuf v1.5.4 // indirect github.com/golang/snappy v0.0.4 // indirect - github.com/google/btree v1.1.2 // indirect + github.com/google/btree v1.1.3 // indirect github.com/google/flatbuffers v23.5.26+incompatible // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/google/orderedcode v0.0.1 // indirect - github.com/google/pprof v0.0.0-20240424215950-a892ee059fd6 // indirect + github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db // indirect github.com/google/s2a-go v0.1.7 // indirect github.com/google/uuid v1.6.0 // indirect github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect @@ -147,42 +152,43 @@ require ( github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect - github.com/klauspost/compress v1.17.7 // indirect + github.com/klauspost/compress v1.17.9 // indirect + github.com/klauspost/cpuid/v2 v2.2.5 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect - github.com/lib/pq v1.10.7 // indirect + github.com/lib/pq v1.10.9 // indirect github.com/linxGnu/grocksdb v1.9.2 // indirect github.com/magiconair/properties v1.8.7 // indirect github.com/manifoldco/promptui v0.9.0 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.20 // indirect github.com/mattn/go-runewidth v0.0.9 // indirect - github.com/minio/highwayhash v1.0.2 // indirect + github.com/minio/highwayhash v1.0.3 // indirect github.com/mitchellh/go-homedir v1.1.0 // indirect github.com/mitchellh/go-testing-interface v1.14.1 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect github.com/mtibben/percent v0.2.1 // indirect + github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a // indirect github.com/oklog/run v1.1.0 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect - github.com/opencontainers/runc v1.1.12 // indirect github.com/pelletier/go-toml/v2 v2.2.2 // indirect - github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67 // indirect + github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect - github.com/prometheus/client_golang v1.19.0 // indirect + github.com/prometheus/client_golang v1.20.5 // indirect github.com/prometheus/client_model v0.6.1 // indirect - github.com/prometheus/common v0.52.2 // indirect - github.com/prometheus/procfs v0.13.0 // indirect + github.com/prometheus/common v0.60.1 // indirect + github.com/prometheus/procfs v0.15.1 // indirect github.com/prometheus/tsdb v0.10.0 // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect github.com/rjeczalik/notify v0.9.3 // indirect github.com/rogpeppe/go-internal v1.12.0 // indirect - github.com/rs/cors v1.11.0 // indirect + github.com/rs/cors v1.11.1 // indirect github.com/rs/zerolog v1.33.0 // indirect github.com/sagikazarmark/locafero v0.4.0 // indirect github.com/sagikazarmark/slog-shim v0.1.0 // indirect - github.com/sasha-s/go-deadlock v0.3.1 // indirect + github.com/sasha-s/go-deadlock v0.3.5 // indirect github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect github.com/sourcegraph/conc v0.3.0 // indirect github.com/spf13/afero v1.11.0 // indirect @@ -191,12 +197,13 @@ require ( github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d // indirect github.com/tendermint/go-amino v0.16.0 // indirect github.com/tidwall/btree v1.7.0 // indirect - github.com/tidwall/gjson v1.17.3 // indirect + github.com/tidwall/gjson v1.18.0 // indirect github.com/tidwall/match v1.1.1 // indirect github.com/tidwall/pretty v1.2.0 // indirect github.com/tidwall/sjson v1.2.5 // indirect github.com/tklauser/go-sysconf v0.3.11 // indirect github.com/tklauser/numcpus v0.6.0 // indirect + github.com/twitchyliquid64/golang-asm v0.15.1 // indirect github.com/tyler-smith/go-bip39 v1.1.0 // indirect github.com/ulikunitz/xz v0.5.11 // indirect github.com/zondax/hid v0.9.2 // indirect @@ -209,22 +216,23 @@ require ( go.opentelemetry.io/otel/metric v1.24.0 // indirect go.opentelemetry.io/otel/trace v1.24.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.27.0 // indirect + golang.org/x/arch v0.3.0 // indirect + golang.org/x/crypto v0.29.0 // indirect golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect - golang.org/x/net v0.29.0 // indirect - golang.org/x/oauth2 v0.21.0 // indirect - golang.org/x/sync v0.8.0 // indirect - golang.org/x/sys v0.25.0 // indirect - golang.org/x/term v0.24.0 // indirect - golang.org/x/text v0.18.0 // indirect + golang.org/x/net v0.31.0 // indirect + golang.org/x/oauth2 v0.23.0 // indirect + golang.org/x/sync v0.9.0 // indirect + golang.org/x/sys v0.27.0 // indirect + golang.org/x/term v0.26.0 // indirect + golang.org/x/text v0.20.0 // indirect golang.org/x/time v0.5.0 // indirect - golang.org/x/tools v0.23.0 // indirect + golang.org/x/tools v0.26.0 // indirect google.golang.org/api v0.186.0 // indirect google.golang.org/genproto v0.0.0-20240701130421-f6361c86f094 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20240624140628-dc46fd24d27d // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5 // indirect - google.golang.org/grpc v1.66.2 // indirect - google.golang.org/protobuf v1.34.2 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 // indirect + google.golang.org/grpc v1.68.0 // indirect + google.golang.org/protobuf v1.35.2 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect gopkg.in/yaml.v2 v2.4.0 // indirect diff --git a/example_chain/go.sum b/example_chain/go.sum index da649ba6..bfe3204a 100644 --- a/example_chain/go.sum +++ b/example_chain/go.sum @@ -72,8 +72,8 @@ cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz cloud.google.com/go/compute v1.6.1/go.mod h1:g85FgpzFvNULZ+S8AYq87axRKuf2Kh7deLqV/jJ3thU= cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQHHZWZxy9U= cloud.google.com/go/compute v1.10.0/go.mod h1:ER5CLbMxl90o2jtNbGSbtfOpQKR0t15FOtRsugnLrlU= -cloud.google.com/go/compute/metadata v0.3.0 h1:Tz+eQXMEqDIKRsmY3cHTL6FVaynIjX2QxYC4trgAKZc= -cloud.google.com/go/compute/metadata v0.3.0/go.mod h1:zFmK7XCadkQkj6TtorcaGlCW1hT1fIilQDwofLpJ20k= +cloud.google.com/go/compute/metadata v0.5.0 h1:Zr0eK8JbFv6+Wi4ilXAR8FJ3wyNdpxHKJNPos6LTZOY= +cloud.google.com/go/compute/metadata v0.5.0/go.mod h1:aHnloV2TPI38yx4s9+wAZhHykWvVCfu7hQbF+9CWoiY= cloud.google.com/go/containeranalysis v0.5.1/go.mod h1:1D92jd8gRR/c0fGMlymRgxWD3Qw9C1ff6/T7mLgVL8I= cloud.google.com/go/containeranalysis v0.6.0/go.mod h1:HEJoiEIu+lEXM+k7+qLCci0h33lX3ZqoYFdmPcoO7s4= cloud.google.com/go/datacatalog v1.3.0/go.mod h1:g9svFY6tuR+j+hrTw3J2dNcmI0dzmSiyOzm8kpLq0a0= @@ -186,10 +186,10 @@ cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xX cloud.google.com/go/webrisk v1.5.0/go.mod h1:iPG6fr52Tv7sGk0H6qUFzmL3HHZev1htXuWDEEsqMTg= cloud.google.com/go/workflows v1.6.0/go.mod h1:6t9F5h/unJz41YqfBmqSASJSXccBLtD1Vwf+KmJENM0= cloud.google.com/go/workflows v1.7.0/go.mod h1:JhSrZuVZWuiDfKEFxU0/F1PQjmpnpcoISEXH2bcHC3M= -cosmossdk.io/api v0.7.5 h1:eMPTReoNmGUm8DeiQL9DyM8sYDjEhWzL1+nLbI9DqtQ= -cosmossdk.io/api v0.7.5/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= -cosmossdk.io/client/v2 v2.0.0-beta.3 h1:+TTuH0DwQYsUq2JFAl3fDZzKq5gQG7nt3dAattkjFDU= -cosmossdk.io/client/v2 v2.0.0-beta.3/go.mod h1:CZcL41HpJPOOayTCO28j8weNBQprG+SRiKX39votypo= +cosmossdk.io/api v0.7.6 h1:PC20PcXy1xYKH2KU4RMurVoFjjKkCgYRbVAD4PdqUuY= +cosmossdk.io/api v0.7.6/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= +cosmossdk.io/client/v2 v2.0.0-beta.5 h1:0LVv3nEByn//hFDIrYLs2WvsEU3HodOelh4SDHnA/1I= +cosmossdk.io/client/v2 v2.0.0-beta.5/go.mod h1:4p0P6o0ro+FizakJUYS9SeM94RNbv0thLmkHRw5o5as= cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= @@ -198,10 +198,10 @@ cosmossdk.io/depinject v1.0.0 h1:dQaTu6+O6askNXO06+jyeUAnF2/ssKwrrszP9t5q050= cosmossdk.io/depinject v1.0.0/go.mod h1:zxK/h3HgHoA/eJVtiSsoaRaRA2D5U4cJ5thIG4ssbB8= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.4.0 h1:Ttt9d6fQ0GlktwhcysOeNiIjixW7l0rYBocmoXOb11k= -cosmossdk.io/log v1.4.0/go.mod h1:k08v0Pyq+gCP6phvdI6RCGhLf/r425UT6Rk/m+o74rU= -cosmossdk.io/math v1.3.0 h1:RC+jryuKeytIiictDslBP9i1fhkVm6ZDmZEoNP316zE= -cosmossdk.io/math v1.3.0/go.mod h1:vnRTxewy+M7BtXBNFybkuhSH4WfedVAAnERHgVFhp3k= +cosmossdk.io/log v1.5.0 h1:dVdzPJW9kMrnAYyMf1duqacoidB9uZIl+7c6z0mnq0g= +cosmossdk.io/log v1.5.0/go.mod h1:Tr46PUJjiUthlwQ+hxYtUtPn4D/oCZXAkYevBeh5+FI= +cosmossdk.io/math v1.4.0 h1:XbgExXFnXmF/CccPPEto40gOO7FpWu9yWNAZPN3nkNQ= +cosmossdk.io/math v1.4.0/go.mod h1:O5PkD4apz2jZs4zqFdTr16e1dcaQCc5z6lkEnrrppuk= cosmossdk.io/tools/confix v0.1.2 h1:2hoM1oFCNisd0ltSAAZw2i4ponARPmlhuNu3yy0VwI4= cosmossdk.io/tools/confix v0.1.2/go.mod h1:7XfcbK9sC/KNgVGxgLM0BrFbVcR/+6Dg7MFfpx7duYo= cosmossdk.io/x/circuit v0.1.1 h1:KPJCnLChWrxD4jLwUiuQaf5mFD/1m7Omyo7oooefBVQ= @@ -210,8 +210,8 @@ cosmossdk.io/x/evidence v0.1.1 h1:Ks+BLTa3uftFpElLTDp9L76t2b58htjVbSZ86aoK/E4= cosmossdk.io/x/evidence v0.1.1/go.mod h1:OoDsWlbtuyqS70LY51aX8FBTvguQqvFrt78qL7UzeNc= cosmossdk.io/x/feegrant v0.1.1 h1:EKFWOeo/pup0yF0svDisWWKAA9Zags6Zd0P3nRvVvw8= cosmossdk.io/x/feegrant v0.1.1/go.mod h1:2GjVVxX6G2fta8LWj7pC/ytHjryA6MHAJroBWHFNiEQ= -cosmossdk.io/x/tx v0.13.4 h1:Eg0PbJgeO0gM8p5wx6xa0fKR7hIV6+8lC56UrsvSo0Y= -cosmossdk.io/x/tx v0.13.4/go.mod h1:BkFqrnGGgW50Y6cwTy+JvgAhiffbGEKW6KF9ufcDpvk= +cosmossdk.io/x/tx v0.13.5 h1:FdnU+MdmFWn1pTsbfU0OCf2u6mJ8cqc1H4OMG418MLw= +cosmossdk.io/x/tx v0.13.5/go.mod h1:V6DImnwJMTq5qFjeGWpXNiT/fjgE4HtmclRmTqRVM3w= cosmossdk.io/x/upgrade v0.1.4 h1:/BWJim24QHoXde8Bc64/2BSEB6W4eTydq0X/2f8+g38= cosmossdk.io/x/upgrade v0.1.4/go.mod h1:9v0Aj+fs97O+Ztw+tG3/tp5JSlrmT7IcFhAebQHmOPo= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= @@ -241,8 +241,8 @@ github.com/VictoriaMetrics/fastcache v1.6.0 h1:C/3Oi3EiBCqufydp1neRZkqcwmEiuRT9c github.com/VictoriaMetrics/fastcache v1.6.0/go.mod h1:0qHz5QP0GMX4pfmMA/zt5RgfNuXJrTP0zS7DqpHGGTw= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= -github.com/adlio/schema v1.3.3 h1:oBJn8I02PyTB466pZO1UZEn1TV5XLlifBSyMrmHl/1I= -github.com/adlio/schema v1.3.3/go.mod h1:1EsRssiv9/Ce2CMzq5DoL7RiMshhuigQxrR4DMV9fHg= +github.com/adlio/schema v1.3.6 h1:k1/zc2jNfeiZBA5aFTRy37jlBIuCkXCm0XmvpzCKI9I= +github.com/adlio/schema v1.3.6/go.mod h1:qkxwLgPBd1FgLRHYVCmQT/rrBr3JH38J9LjmVzWNudg= github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= @@ -284,8 +284,8 @@ github.com/btcsuite/btcd v0.24.2 h1:aLmxPguqxza+4ag8R1I2nnJjSu2iFn/kqtHTIImswcY= github.com/btcsuite/btcd v0.24.2/go.mod h1:5C8ChTkl5ejr3WHj8tkQSCmydiMEPB0ZhQhehpq7Dgg= github.com/btcsuite/btcd/btcec/v2 v2.1.0/go.mod h1:2VzYrv4Gm4apmbVVsSq5bqf1Ec8v56E48Vt0Y/umPgA= github.com/btcsuite/btcd/btcec/v2 v2.1.3/go.mod h1:ctjw4H1kknNJmRN4iP1R7bTQ+v3GJkZBd6mui8ZsAZE= -github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= -github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= +github.com/btcsuite/btcd/btcec/v2 v2.3.4 h1:3EJjcN70HCu/mwqlUsGK8GcNVyLVxFDlWurTXGPFfiQ= +github.com/btcsuite/btcd/btcec/v2 v2.3.4/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/btcutil v1.0.0/go.mod h1:Uoxwv0pqYWhD//tfTiipkxNfdhG9UrLwaeswfjfdF0A= github.com/btcsuite/btcd/btcutil v1.1.0/go.mod h1:5OapHB7A2hBBWLm48mmw4MOHNJCcUBTwmWH/0Jn8VHE= github.com/btcsuite/btcd/btcutil v1.1.5/go.mod h1:PSZZ4UitpLBWzxGd5VGOrLnmOjtPP/a6HaFo12zMs00= @@ -307,8 +307,12 @@ github.com/btcsuite/winsvc v1.0.0/go.mod h1:jsenWakMcC0zFBFurPLEAyrnc/teJEM1O46f github.com/bufbuild/protocompile v0.6.0 h1:Uu7WiSQ6Yj9DbkdnOe7U4mNKp58y9WDMKDn28/ZlunY= github.com/bufbuild/protocompile v0.6.0/go.mod h1:YNP35qEYoYGme7QMtz5SBCoN4kL4g12jTtjuzRNdjpE= github.com/bytedance/sonic v1.5.0/go.mod h1:ED5hyg4y6t3/9Ku1R6dU/4KyJ48DZ4jPhfY1O2AihPM= -github.com/bytedance/sonic v1.9.1 h1:6iJ6NqdoxCDr6mbY8h18oSO+cShGSMRGCEo7F2h0x8s= github.com/bytedance/sonic v1.9.1/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= +github.com/bytedance/sonic v1.12.3 h1:W2MGa7RCU1QTeYRTPE3+88mVC0yXmsRQRChiyVocVjU= +github.com/bytedance/sonic v1.12.3/go.mod h1:B8Gt/XvtZ3Fqj+iSKMypzymZxw/FVwgIGKzMzT9r/rk= +github.com/bytedance/sonic/loader v0.1.1/go.mod h1:ncP89zfokxS5LZrJxl5z0UJcsk4M4yY2JpfqGeCtNLU= +github.com/bytedance/sonic/loader v0.2.0 h1:zNprn+lsIP06C/IqCHs3gPQIvnvpKbbxyXQP1iU4kWM= +github.com/bytedance/sonic/loader v0.2.0/go.mod h1:ncP89zfokxS5LZrJxl5z0UJcsk4M4yY2JpfqGeCtNLU= github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= @@ -324,7 +328,6 @@ github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UF github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cheggaaa/pb v1.0.27/go.mod h1:pQciLPpbU0oxA0h+VJYYLxO+XeDQb5pZijXscXHm81s= github.com/chenzhuoyu/base64x v0.0.0-20211019084208-fb5309c8db06/go.mod h1:DH46F32mSOjUmXrMHnKwZdA8wcEefY7UVqBKYGjpdQY= -github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 h1:qSGYFH7+jGhDF8vLC+iwCD4WpbV1EBDSzWkJODFLams= github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311/go.mod h1:b583jCggY9gE99b6G5LEC39OIiVsWj+R97kbl5odCEk= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/logex v1.2.1 h1:XHDu3E6q+gdHgsdTPH6ImJMIp436vR6MPtH8gP05QzM= @@ -339,6 +342,10 @@ github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6D github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4dUb/I5gc9Hdhagfvm9+RyrPryS/auMzxE= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= +github.com/cloudwego/base64x v0.1.4 h1:jwCgWpFanWmN8xoIUHa2rtzmkd5J2plF/dnLS6Xd/0Y= +github.com/cloudwego/base64x v0.1.4/go.mod h1:0zlkT4Wn5C6NdauXdJRhSKRlJvmclQ1hhJgA0rcu/8w= +github.com/cloudwego/iasm v0.2.0 h1:1KNIy1I1H9hNNFEEH3DVnI4UujN+1zjpuk6gwHLTssg= +github.com/cloudwego/iasm v0.2.0/go.mod h1:8rXZaNYT2n95jn+zTI1sDr+IgcD2GVs0nlbbQPiEFhY= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= @@ -353,21 +360,23 @@ github.com/cockroachdb/apd/v2 v2.0.2/go.mod h1:DDxRlzC2lo3/vSlmSoS7JkqbbrARPuFOG github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= 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/errors v1.11.3 h1:5bA+k2Y6r+oz/6Z/RFlNeVCesGARKuC6YymtcDrbC/I= +github.com/cockroachdb/errors v1.11.3/go.mod h1:m4UIW4CDjx+R5cybPsNrRbreomiFqt8o1h1wUVazSd8= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce h1:giXvy4KSc/6g/esnpM7Geqxka4WSqI1SZc7sMJFd3y4= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce/go.mod h1:9/y3cnZ5GKakj/H4y9r9GTjCvAFta7KLgSHPJJYc52M= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= -github.com/cockroachdb/pebble v1.1.0 h1:pcFh8CdCIt2kmEpK0OIatq67Ln9uGDYY3d5XnE0LJG4= -github.com/cockroachdb/pebble v1.1.0/go.mod h1:sEHm5NOXxyiAoKWhoFxT8xMgd/f3RA6qUqQ1BXKrh2E= +github.com/cockroachdb/pebble v1.1.1 h1:XnKU22oiCLy2Xn8vp1re67cXg4SAasg/WDt1NtcRFaw= +github.com/cockroachdb/pebble v1.1.1/go.mod h1:4exszw1r40423ZsmkG/09AFEG83I0uDgfujJdbL6kYU= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= -github.com/cometbft/cometbft v0.38.11 h1:6bNDUB8/xq4uYonYwIfGc9OqK1ZH4NkdaMmR1LZIJqk= -github.com/cometbft/cometbft v0.38.11/go.mod h1:jHPx9vQpWzPHEAiYI/7EDKaB1NXhK6o3SArrrY8ExKc= -github.com/cometbft/cometbft-db v0.12.0 h1:v77/z0VyfSU7k682IzZeZPFZrQAKiQwkqGN0QzAjMi0= -github.com/cometbft/cometbft-db v0.12.0/go.mod h1:aX2NbCrjNVd2ZajYxt1BsiFf/Z+TQ2MN0VxdicheYuw= +github.com/cometbft/cometbft v0.38.15 h1:5veFd8k1uXM27PBg9sMO3hAfRJ3vbh4OmmLf6cVrqXg= +github.com/cometbft/cometbft v0.38.15/go.mod h1:+wh6ap6xctVG+JOHwbl8pPKZ0GeqdPYqISu7F4b43cQ= +github.com/cometbft/cometbft-db v0.14.1 h1:SxoamPghqICBAIcGpleHbmoPqy+crij/++eZz3DlerQ= +github.com/cometbft/cometbft-db v0.14.1/go.mod h1:KHP1YghilyGV/xjD5DP3+2hyigWx0WTp9X+0Gnx0RxQ= github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= github.com/containerd/continuity v0.3.0/go.mod h1:wJEAIwKOm/pBZuBd0JmeTvnLquTB1Ag8espWhkykbPM= github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= @@ -387,12 +396,12 @@ github.com/cosmos/gogogateway v1.2.0/go.mod h1:iQpLkGWxYcnCdz5iAdLcRBSw3h7NXeOkZ github.com/cosmos/gogoproto v1.4.2/go.mod h1:cLxOsn1ljAHSV527CHOtaIP91kK6cCrZETRBrkzItWU= github.com/cosmos/gogoproto v1.7.0 h1:79USr0oyXAbxg3rspGh/m4SWNyoz/GLaAh0QlCe2fro= github.com/cosmos/gogoproto v1.7.0/go.mod h1:yWChEv5IUEYURQasfyBW5ffkMHR/90hiHgbNgrtp4j0= -github.com/cosmos/iavl v1.1.2 h1:zL9FK7C4L/P4IF1Dm5fIwz0WXCnn7Bp1M2FxH0ayM7Y= -github.com/cosmos/iavl v1.1.2/go.mod h1:jLeUvm6bGT1YutCaL2fIar/8vGUE8cPZvh/gXEWDaDM= +github.com/cosmos/iavl v1.2.0 h1:kVxTmjTh4k0Dh1VNL046v6BXqKziqMDzxo93oh3kOfM= +github.com/cosmos/iavl v1.2.0/go.mod h1:HidWWLVAtODJqFD6Hbne2Y0q3SdxByJepHUOeoH4LiI= github.com/cosmos/ibc-go/modules/capability v1.0.1 h1:ibwhrpJ3SftEEZRxCRkH0fQZ9svjthrX2+oXdZvzgGI= github.com/cosmos/ibc-go/modules/capability v1.0.1/go.mod h1:rquyOV262nGJplkumH+/LeYs04P3eV8oB7ZM4Ygqk4E= -github.com/cosmos/ibc-go/v8 v8.5.1 h1:3JleEMKBjRKa3FeTKt4fjg22za/qygLBo7mDkoYTNBs= -github.com/cosmos/ibc-go/v8 v8.5.1/go.mod h1:P5hkAvq0Qbg0h18uLxDVA9q1kOJ0l36htMsskiNwXbo= +github.com/cosmos/ibc-go/v8 v8.5.2 h1:27s9oeD2AxLQF3e9BQsYt9doONyZ7FwZi/qkBv6Sdks= +github.com/cosmos/ibc-go/v8 v8.5.2/go.mod h1:P5hkAvq0Qbg0h18uLxDVA9q1kOJ0l36htMsskiNwXbo= github.com/cosmos/ics23/go v0.11.0 h1:jk5skjT0TqX5e5QJbEnwXIS2yI2vnmLOgpQPeM5RtnU= github.com/cosmos/ics23/go v0.11.0/go.mod h1:A8OjxPE67hHST4Icw94hOxxFEJMBG031xIGF/JHNIY0= github.com/cosmos/keyring v1.2.0 h1:8C1lBP9xhImmIabyXW4c3vFjjLiBdGCmfLUfeZlV1Yo= @@ -421,8 +430,8 @@ github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn 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.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= -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/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f/go.mod h1:xH/i4TFMt8koVQZ6WFms69WAsDWr2XsYL3Hkl7jkoLE= @@ -510,8 +519,8 @@ github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2 github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgOZ7o= -github.com/go-kit/kit v0.12.0 h1:e4o3o3IsBfAKQh5Qbbiqyfu97Ku7jrO/JbohvztANh4= -github.com/go-kit/kit v0.12.0/go.mod h1:lHd+EkCZPIwYItmGDDRdhinkzX2A1sj+M9biaEaizzs= +github.com/go-kit/kit v0.13.0 h1:OoneCcHKHQ03LfBpoQCUfCluwd2Vt3ohz+kvbJneZAU= +github.com/go-kit/kit v0.13.0/go.mod h1:phqEHMMUbyrCFCTgH48JueqrM3md2HcAZ8N3XE4FKDg= github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= @@ -543,15 +552,12 @@ 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/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI= github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8= +github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee h1:s+21KNqlpePfkah2I+gwHF8xmJWRjooY+5248k6m4A0= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= -github.com/gobwas/httphead v0.1.0 h1:exrUm0f4YX0L7EBwZHuCF4GDp8aJfVeBrlLQrs6NqWU= -github.com/gobwas/httphead v0.1.0/go.mod h1:O/RXo79gxV8G+RqlR/otEwx4Q36zl9rqC5u12GKvMCM= +github.com/gobwas/pool v0.2.0 h1:QEmUOlnSjWtnpRGHF3SauEiOsy82Cup83Vf2LcMlnc8= github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= -github.com/gobwas/pool v0.2.1 h1:xfeeEhW7pwmX8nuLVlqbzVc7udMDrwetjEv+TZIz1og= -github.com/gobwas/pool v0.2.1/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= +github.com/gobwas/ws v1.0.2 h1:CoAavW/wd/kulfZmSIBt6p24n4j7tHgNVCjsfHVNUbo= github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= -github.com/gobwas/ws v1.2.1 h1:F2aeBZrm2NDsc7vbovKrWSogd4wvfAxg0FQ89/iqOTk= -github.com/gobwas/ws v1.2.1/go.mod h1:hRKAFb8wOxFROYNsT1bqfWnhX+b5MFeJM9r2ZSwg/KY= github.com/goccy/go-json v0.10.2 h1:CrxCmQqYDkv1z7lO7Wbh2HN93uovUHgrECaO5ZrCXAU= github.com/goccy/go-json v0.10.2/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= @@ -570,8 +576,8 @@ github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69 github.com/golang-jwt/jwt/v4 v4.3.0 h1:kHL1vqdqWNfATmA0FNMdmZNMyZI1U6O31X4rlIPoBog= github.com/golang-jwt/jwt/v4 v4.3.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/glog v1.2.1 h1:OptwRhECazUx5ix5TTWC3EZhsZEHWcYWY4FQHTIubm4= -github.com/golang/glog v1.2.1/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= +github.com/golang/glog v1.2.2 h1:1+mZ9upx1Dh6FmUTFR1naJ77miKiXgALjWOZ3NVFPmY= +github.com/golang/glog v1.2.2/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -615,8 +621,8 @@ github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/btree v1.1.2 h1:xf4v41cLI2Z6FxbKm+8Bu+m8ifhj15JuZ9sa0jZCMUU= -github.com/google/btree v1.1.2/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= +github.com/google/btree v1.1.3 h1:CVpQJjYgC4VbzxeGVHfvZrv1ctoYCAI8vbl07Fcxlyg= +github.com/google/btree v1.1.3/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= github.com/google/flatbuffers v23.5.26+incompatible h1:M9dgRyhJemaM4Sw8+66GHBu8ioaQmyPLg1b8VwK5WJg= github.com/google/flatbuffers v23.5.26+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -663,8 +669,8 @@ github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20240424215950-a892ee059fd6 h1:k7nVchz72niMH6YLQNvHSdIE7iqsQxK1P41mySCvssg= -github.com/google/pprof v0.0.0-20240424215950-a892ee059fd6/go.mod h1:kf6iHlnVGwgKolg33glAes7Yg/8iWP8ukqeldJSO7jw= +github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db h1:097atOisP2aRj7vFgYQBbFN4U4JNXUNYpxael3UzMyo= +github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= @@ -824,12 +830,13 @@ github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6 github.com/klauspost/compress v1.10.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.11.7/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.15.11/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= -github.com/klauspost/compress v1.17.7 h1:ehO88t2UGzQK66LMdE8tibEd1ErmzZjNEqWkjLAKQQg= -github.com/klauspost/compress v1.17.7/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw= +github.com/klauspost/compress v1.17.9 h1:6KIumPrER1LHsvBVuDa0r5xaG0Es51mhhB9BQB2qeMA= +github.com/klauspost/compress v1.17.9/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/klauspost/cpuid/v2 v2.2.4/go.mod h1:RVVoqg1df56z8g3pUjL/3lE5UfnlrJX8tyFgg4nqhuY= 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/knz/go-libedit v1.10.1/go.mod h1:MZTVkCWyz0oBc7JOWP3wNAzd002ZbM/5hgShxwh4x8M= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= @@ -841,10 +848,12 @@ 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/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/leodido/go-urn v1.2.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q= github.com/leodido/go-urn v1.2.4/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= -github.com/lib/pq v1.10.7 h1:p7ZhMD+KsSRozJr34udlUrhboJwWAgCg34+/ZZNvZZw= -github.com/lib/pq v1.10.7/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= +github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw= +github.com/lib/pq v1.10.9/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= github.com/linxGnu/grocksdb v1.9.2 h1:O3mzvO0wuzQ9mtlHbDrShixyVjVbmuqTjFrzlf43wZ8= @@ -873,8 +882,8 @@ github.com/mattn/go-runewidth v0.0.9 h1:Lm995f3rfxdpd6TSmuVCHVb/QhupuXlYr8sCI/Qd 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/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= -github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA/g= -github.com/minio/highwayhash v1.0.2/go.mod h1:BQskDq+xkJ12lmlUUi7U0M5Swg3EWR+dLTk+kldvVxY= +github.com/minio/highwayhash v1.0.3 h1:kbnuUMoHYyVl7szWjSxJnxw11k2U709jqFPPmIUyD6Q= +github.com/minio/highwayhash v1.0.3/go.mod h1:GGYsuwP/fPD6Y9hMiXuapVvlIUEhFhMTh0rxU3ik1LQ= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= @@ -899,6 +908,8 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mtibben/percent v0.2.1/go.mod h1:KG9uO+SZkUp+VkRHsCdYQV3XSZrrSpR3O9ibNBTZrns= +github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= +github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= @@ -930,14 +941,14 @@ github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108 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.19.1 h1:QXgq3Z8Crl5EL1WBAC98A5sEBHARrAJNzAmMxzLcRF0= -github.com/onsi/ginkgo/v2 v2.19.1/go.mod h1:O3DtEWQkPa/F7fBMgmZQKKsluAy8pd3rEQdrjkPb9zA= +github.com/onsi/ginkgo/v2 v2.22.0 h1:Yed107/8DjTr0lKCNt7Dn8yQ6ybuDRQoMGrNFKzMfHg= +github.com/onsi/ginkgo/v2 v2.22.0/go.mod h1:7Du3c42kxCUegi0IImZ1wUQzMBVecgIHjR1C+NkhLQo= 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.34.0 h1:eSSPsPNp6ZpsG8X1OVmOTxig+CblTc4AxpPBykhe2Os= -github.com/onsi/gomega v1.34.0/go.mod h1:MIKI8c+f+QLWk+hxbePD4i0LMJSExPaZOVfkoex4cAo= +github.com/onsi/gomega v1.35.1 h1:Cwbd75ZBPxFSuZ6T+rN/WCb/gOc6YgFBXLlZLhC7Ds4= +github.com/onsi/gomega v1.35.1/go.mod h1:PvZbdDc8J6XJEpDK4HCuRBm8a6Fzp9/DmhC9C7yFlog= github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= @@ -964,9 +975,8 @@ github.com/pelletier/go-toml/v2 v2.0.8/go.mod h1:vuYfssBdrU2XDZ9bYydBu6t+6a6PYNc github.com/pelletier/go-toml/v2 v2.2.2 h1:aYUidT7k73Pcl9nb2gScu7NSrKCSHIDE89b3+6Wq+LM= github.com/pelletier/go-toml/v2 v2.2.2/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs= github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= -github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= -github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67 h1:jik8PHtAIsPlCRJjJzl4udgEf7hawInF9texMeO2jrU= -github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= +github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 h1:Dx7Ovyv/SFnMFw3fD4oEoeorXc6saIiQ23LrGLth0Gw= +github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc= github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= @@ -987,8 +997,8 @@ github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5Fsn github.com/prometheus/client_golang v1.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeDPbaTKGT+JTgUa3og= github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= -github.com/prometheus/client_golang v1.19.0 h1:ygXvpU1AoN1MhdzckN+PyD9QJOSD4x7kmXYlnfbA6JU= -github.com/prometheus/client_golang v1.19.0/go.mod h1:ZRM9uEAypZakd+q/x7+gmsvXdURP+DABIEIjnmDdp+k= +github.com/prometheus/client_golang v1.20.5 h1:cxppBPuYhUnsO6yo/aoRol4L7q7UFfdm+bR9r+8l63Y= +github.com/prometheus/client_golang v1.20.5/go.mod h1:PIEt8X02hGcP8JWbeHyeZ53Y/jReSnHgO035n//V5WE= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= @@ -1003,16 +1013,16 @@ github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt2 github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.15.0/go.mod h1:U+gB1OBLb1lF3O42bTCL+FK18tX9Oar16Clt/msog/s= -github.com/prometheus/common v0.52.2 h1:LW8Vk7BccEdONfrJBDffQGRtpSzi5CQaRZGtboOO2ck= -github.com/prometheus/common v0.52.2/go.mod h1:lrWtQx+iDfn2mbH5GUzlH9TSHyfZpHkSiG1W7y3sF2Q= +github.com/prometheus/common v0.60.1 h1:FUas6GcOw66yB/73KC+BOZoFJmbo/1pojoILArPAaSc= +github.com/prometheus/common v0.60.1/go.mod h1:h0LYf1R1deLSKtD4Vdg8gy4RuOvENW2J/h19V5NADQw= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.3.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.13.0 h1:GqzLlQyfsPbaEHaQkO7tbDlriv/4o5Hudv6OXHGKX7o= -github.com/prometheus/procfs v0.13.0/go.mod h1:cd4PFCR54QLnGKPaKGA6l+cfuNXtht43ZKY6tow0Y1g= +github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0learggepc= +github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk= github.com/prometheus/tsdb v0.10.0 h1:If5rVCMTp6W2SiRAQFlbpJNgVlgMEd+U2GZckwK38ic= github.com/prometheus/tsdb v0.10.0/go.mod h1:oi49uRhEe9dPUTlS3JRZOwJuVi6tmh10QSgwXEyGCt4= github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= @@ -1027,8 +1037,8 @@ github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/f github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= -github.com/rs/cors v1.11.0 h1:0B9GE/r9Bc2UxRMMtymBkHTenPkHDv0CW4Y98GBY+po= -github.com/rs/cors v1.11.0/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= +github.com/rs/cors v1.11.1 h1:eU3gRzXLRK57F5rKMGMZURNdIG4EoAmX8k94r9wXWHA= +github.com/rs/cors v1.11.1/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/zerolog v1.33.0 h1:1cU2KZkvPxNyfgEmhHAz/1A9Bz+llsdYzklWFzgp0r8= github.com/rs/zerolog v1.33.0/go.mod h1:/7mN4D5sKwJLZQ2b/znpjC3/GQWY/xaDXUM0kKWRHss= @@ -1041,8 +1051,8 @@ github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgY github.com/sagikazarmark/slog-shim v0.1.0 h1:diDBnUNK9N/354PgrxMywXnAwEr1QZcOr6gto+ugjYE= github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= -github.com/sasha-s/go-deadlock v0.3.1 h1:sqv7fDNShgjcaxkO0JNcOAlr8B9+cV5Ey/OB71efZx0= -github.com/sasha-s/go-deadlock v0.3.1/go.mod h1:F73l+cr82YSh10GxyRI6qZiCgK64VaZjwesgfQ1/iLM= +github.com/sasha-s/go-deadlock v0.3.5 h1:tNCOEEDG6tBqrNDOX35j/7hL5FcFViG6awUGROb2NsU= +github.com/sasha-s/go-deadlock v0.3.5/go.mod h1:bugP6EGbdGYObIlx7pUZtWqlvo8k9H6vCBBsiChJQ5U= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= 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= @@ -1051,8 +1061,8 @@ github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPx github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sirupsen/logrus v1.9.0 h1:trlNQbNUG3OdDrDil03MCb1H2o9nJ1x4/5LYw7byDE0= -github.com/sirupsen/logrus v1.9.0/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= +github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= +github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= 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/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= @@ -1094,8 +1104,9 @@ github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= +github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= @@ -1105,8 +1116,8 @@ github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoM github.com/tidwall/btree v1.7.0 h1:L1fkJH/AuEh5zBnnBbmTwQ5Lt+bRJ5A8EWecslvo9iI= github.com/tidwall/btree v1.7.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= github.com/tidwall/gjson v1.14.2/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= -github.com/tidwall/gjson v1.17.3 h1:bwWLZU7icoKRG+C+0PNwIKC6FCJO/Q3p2pZvuP0jN94= -github.com/tidwall/gjson v1.17.3/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= +github.com/tidwall/gjson v1.18.0 h1:FIDeeyB800efLX89e5a8Y0BNH+LOngJyGrIWxG2FKQY= +github.com/tidwall/gjson v1.18.0/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= github.com/tidwall/match v1.1.1 h1:+Ho715JplO36QYgwN9PGYNhgZvoUSc9X2c80KVTi+GA= github.com/tidwall/match v1.1.1/go.mod h1:eRSPERbgtNPcGhD8UCthc6PmLEQXEWd3PRB5JTxsfmM= github.com/tidwall/pretty v1.2.0 h1:RWIZEg2iJ8/g6fDDYzMpobmaoGh5OLl4AXtGUGPcqCs= @@ -1204,8 +1215,8 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= golang.org/x/crypto v0.9.0/go.mod h1:yrmDGqONDYtNj3tH8X9dzUun2m2lzPa9ngI6/RUPGR0= -golang.org/x/crypto v0.27.0 h1:GXm2NjJrPaiv/h1tb2UH8QfgC/hOf/+z0p6PT8o1w7A= -golang.org/x/crypto v0.27.0/go.mod h1:1Xngt8kV6Dvbssa53Ziq6Eqn0HqbZi5Z6R0ZpwQzt70= +golang.org/x/crypto v0.29.0 h1:L5SG1JTTXupVV3n6sUqMTeWbjAyfPwoda2DLX8J8FrQ= +golang.org/x/crypto v0.29.0/go.mod h1:+F4F4N5hv6v38hfeYwTdx20oUvLLc+QfrE9Ax9HtgRg= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -1246,8 +1257,8 @@ golang.org/x/mod v0.4.1/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.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.19.0 h1:fEdghXQSo20giMthA7cd28ZC+jts4amQ3YMXiP5oMQ8= -golang.org/x/mod v0.19.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= +golang.org/x/mod v0.21.0 h1:vvrHzRwRfVKSiLrG+d4FMl/Qi4ukBCE6kZlTUkDYRT0= +golang.org/x/mod v0.21.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= 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= @@ -1311,8 +1322,8 @@ golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg= -golang.org/x/net v0.29.0 h1:5ORfpBpCs4HzDYoodCDBbwHzdR5UrLBZ3sOnUJmFoHo= -golang.org/x/net v0.29.0/go.mod h1:gLkgy8jTGERgjzMic6DS9+SP0ajcu6Xu3Orq/SpETg0= +golang.org/x/net v0.31.0 h1:68CPQngjLL0r2AlUKiSxtQFKvzRVbnzLwMUn5SzcLHo= +golang.org/x/net v0.31.0/go.mod h1:P4fl1q7dY2hnZFxEk4pPSkDHF+QqjitcnDjUQyMM+pM= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -1338,8 +1349,8 @@ golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094/go.mod h1:h4gKUeWbJ4rQPri golang.org/x/oauth2 v0.0.0-20220909003341-f21342109be1/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.1.0/go.mod h1:G9FE4dLTsbXUu90h/Pf85g4w1D+SSAgR+q46nJZ8M4A= -golang.org/x/oauth2 v0.21.0 h1:tsimM75w1tF/uws5rbeHzIWxEqElMehnc+iW793zsZs= -golang.org/x/oauth2 v0.21.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= +golang.org/x/oauth2 v0.23.0 h1:PbgcYx2W7i4LvjJWEbf0ngHV6qJYr86PkAV3bXdLEbs= +golang.org/x/oauth2 v0.23.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= 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= @@ -1355,8 +1366,8 @@ golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.8.0 h1:3NFvSEYkUoMifnESzZl15y791HH1qU2xm6eCJU5ZPXQ= -golang.org/x/sync v0.8.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.9.0 h1:fEo0HyrW1GIgZdpbhCRO0PkJajUS5H9IFUztCgEo2jQ= +golang.org/x/sync v0.9.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/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= @@ -1366,7 +1377,6 @@ golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190130150945-aca44879d564/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-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1459,16 +1469,17 @@ 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.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34= -golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.27.0 h1:wBqf8DvsY9Y/2P8gAfPDEYNuS30J4lPHJxXSb/nJZ+s= +golang.org/x/sys v0.27.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= -golang.org/x/term v0.24.0 h1:Mh5cbb+Zk2hqqXNO7S1iTjEphVL+jb8ZWaqh/g+JWkM= -golang.org/x/term v0.24.0/go.mod h1:lOBK/LVxemqiMij05LGJ0tzNr8xlmwBRJ81PX6wVLH8= +golang.org/x/term v0.26.0 h1:WEQa6V3Gja/BhNxg540hBip/kkaYtRg3cxg4oXSw4AU= +golang.org/x/term v0.26.0/go.mod h1:Si5m1o57C5nBNQo5z1iq+XDijt21BDBDp2bK0QI8e3E= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= 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= @@ -1483,8 +1494,8 @@ golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= -golang.org/x/text v0.18.0 h1:XvMDiNzPAl0jr17s6W9lcaIhGUfUORdGCNsuLmPG224= -golang.org/x/text v0.18.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY= +golang.org/x/text v0.20.0 h1:gK/Kv2otX8gz+wn7Rmb3vT96ZwuoxnQlY+HlJVj7Qug= +golang.org/x/text v0.20.0/go.mod h1:D4IsuqiFMhST5bX19pQ9ikHC2GsaKyk/oF+pn3ducp4= 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-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -1554,8 +1565,8 @@ golang.org/x/tools v0.1.4/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.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= -golang.org/x/tools v0.23.0 h1:SGsXPZ+2l4JsgaCKkx+FQ9YZ5XEtA1GZYuoDjenLjvg= -golang.org/x/tools v0.23.0/go.mod h1:pnu6ufv6vQkll6szChhK3C3L/ruaIv5eBeztNG8wtsI= +golang.org/x/tools v0.26.0 h1:v/60pFQmzmT9ExmjDv2gGIfi3OqfKoEP6I5+umXlbnQ= +golang.org/x/tools v0.26.0/go.mod h1:TPVVj70c7JJ3WCazhD8OdXcZg/og+b9+tH/KxylGwH0= 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= @@ -1733,10 +1744,10 @@ google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= google.golang.org/genproto v0.0.0-20240701130421-f6361c86f094 h1:6whtk83KtD3FkGrVb2hFXuQ+ZMbCNdakARIn/aHMmG8= google.golang.org/genproto v0.0.0-20240701130421-f6361c86f094/go.mod h1:Zs4wYw8z1zr6RNF4cwYb31mvN/EGaKAdQjNCF3DW6K4= -google.golang.org/genproto/googleapis/api v0.0.0-20240624140628-dc46fd24d27d h1:Aqf0fiIdUQEj0Gn9mKFFXoQfTTEaNopWpfVyYADxiSg= -google.golang.org/genproto/googleapis/api v0.0.0-20240624140628-dc46fd24d27d/go.mod h1:Od4k8V1LQSizPRUK4OzZ7TBE/20k+jPczUDAEyvn69Y= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5 h1:SbSDUWW1PAO24TNpLdeheoYPd7kllICcLU52x6eD4kQ= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY= +google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 h1:hjSy6tcFQZ171igDaN5QHOw2n6vx40juYbC/x67CEhc= +google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:qpvKtACPCQhAdu3PyQgV4l3LMXZEtft7y8QcarRsp9I= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 h1:pPJltXNxVzT4pK9yD8vR9X75DaWYYmLGMsEvBfFQZzQ= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:UqMtugtsSgubUsoxbuAoiCXvqvErP7Gf0so0mK9tHxU= 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.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= @@ -1778,8 +1789,8 @@ google.golang.org/grpc v1.48.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACu google.golang.org/grpc v1.49.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= -google.golang.org/grpc v1.66.2 h1:3QdXkuq3Bkh7w+ywLdLvM56cmGvQHUMZpiCzt6Rqaoo= -google.golang.org/grpc v1.66.2/go.mod h1:s3/l6xSSCURdVfAnL+TqCNMyTDAGN6+lZeVxnZR128Y= +google.golang.org/grpc v1.68.0 h1:aHQeeJbo8zAkAa3pRzrVjZlbz6uSfeOXlJNQM0RAbz0= +google.golang.org/grpc v1.68.0/go.mod h1:fmSPC5AsjSBCK54MyHRx48kpOti1/jRfOlwEWywNjWA= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= 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= @@ -1797,8 +1808,8 @@ google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQ google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.30.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= -google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= +google.golang.org/protobuf v1.35.2 h1:8Ar7bF+apOIoThw1EdZl0p1oWvMqTHmpA2fRTyZO8io= +google.golang.org/protobuf v1.35.2/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= 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/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -1846,6 +1857,7 @@ honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9 nhooyr.io/websocket v1.8.6/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= nhooyr.io/websocket v1.8.7 h1:usjR2uOr/zjjkVMy0lW+PPohFok7PCow5sDjLgX4P4g= nhooyr.io/websocket v1.8.7/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= +nullprogram.com/x/optparse v1.0.0/go.mod h1:KdyPE+Igbe0jQUrVfMqDMeJQIJZEuyV7pjYmp6pbG50= pgregory.net/rapid v1.1.0 h1:CMa0sjHSru3puNx+J0MIAuiiEV4N0qj8/cMWGBBCsjw= pgregory.net/rapid v1.1.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= diff --git a/example_chain/local_node.sh b/example_chain/local_node.sh index 59ed3c0c..bd364814 100755 --- a/example_chain/local_node.sh +++ b/example_chain/local_node.sh @@ -132,7 +132,7 @@ if [[ $overwrite == "y" || $overwrite == "Y" ]]; then jq '.app_state["mint"]["params"]["mint_denom"]="aevmos"' "$GENESIS" >"$TMP_GENESIS" && mv "$TMP_GENESIS" "$GENESIS" # Enable precompiles in EVM params - jq '.app_state["evm"]["params"]["active_static_precompiles"]=["0x0000000000000000000000000000000000000100","0x0000000000000000000000000000000000000400","0x0000000000000000000000000000000000000800","0x0000000000000000000000000000000000000801","0x0000000000000000000000000000000000000802","0x0000000000000000000000000000000000000803","0x0000000000000000000000000000000000000804"]' "$GENESIS" >"$TMP_GENESIS" && mv "$TMP_GENESIS" "$GENESIS" + jq '.app_state["evm"]["params"]["active_static_precompiles"]=["0x0000000000000000000000000000000000000100","0x0000000000000000000000000000000000000400","0x0000000000000000000000000000000000000800","0x0000000000000000000000000000000000000801","0x0000000000000000000000000000000000000802","0x0000000000000000000000000000000000000803","0x0000000000000000000000000000000000000804","0x0000000000000000000000000000000000000805"]' "$GENESIS" >"$TMP_GENESIS" && mv "$TMP_GENESIS" "$GENESIS" # Set gas limit in genesis jq '.consensus_params["block"]["max_gas"]="10000000"' "$GENESIS" >"$TMP_GENESIS" && mv "$TMP_GENESIS" "$GENESIS" @@ -183,11 +183,11 @@ if [[ $overwrite == "y" || $overwrite == "Y" ]]; then sed -i.bak 's/pruning-interval = "0"/pruning-interval = "10"/g' "$APP_TOML" # Allocate genesis accounts (cosmos formatted addresses) - osd genesis add-genesis-account "$(osd keys show "$VAL_KEY" -a --keyring-backend "$KEYRING" --home "$HOMEDIR")" 100000000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" - osd genesis add-genesis-account "$(osd keys show "$USER1_KEY" -a --keyring-backend "$KEYRING" --home "$HOMEDIR")" 1000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" - osd genesis add-genesis-account "$(osd keys show "$USER2_KEY" -a --keyring-backend "$KEYRING" --home "$HOMEDIR")" 1000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" - osd genesis add-genesis-account "$(osd keys show "$USER3_KEY" -a --keyring-backend "$KEYRING" --home "$HOMEDIR")" 1000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" - osd genesis add-genesis-account "$(osd keys show "$USER4_KEY" -a --keyring-backend "$KEYRING" --home "$HOMEDIR")" 1000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" + osd genesis add-genesis-account "$VAL_KEY" 100000000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" + osd genesis add-genesis-account "$USER1_KEY" 1000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" + osd genesis add-genesis-account "$USER2_KEY" 1000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" + osd genesis add-genesis-account "$USER3_KEY" 1000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" + osd genesis add-genesis-account "$USER4_KEY" 1000000000000000000000aevmos --keyring-backend "$KEYRING" --home "$HOMEDIR" # Sign genesis transaction osd genesis gentx "$VAL_KEY" 1000000000000000000000aevmos --gas-prices ${BASEFEE}aevmos --keyring-backend "$KEYRING" --chain-id "$CHAINID" --home "$HOMEDIR" diff --git a/example_chain/osd/cmd/root.go b/example_chain/osd/cmd/root.go index c0fe5e61..66983dbd 100644 --- a/example_chain/osd/cmd/root.go +++ b/example_chain/osd/cmd/root.go @@ -96,6 +96,7 @@ func NewRootCmd() *cobra.Command { cmd.SetOut(cmd.OutOrStdout()) cmd.SetErr(cmd.ErrOrStderr()) + initClientCtx = initClientCtx.WithCmdContext(cmd.Context()) initClientCtx, err := client.ReadPersistentCommandFlags(initClientCtx, cmd.Flags()) if err != nil { return err diff --git a/example_chain/osd/config/config.go b/example_chain/osd/config/config.go index 52b35f68..9899d4c9 100644 --- a/example_chain/osd/config/config.go +++ b/example_chain/osd/config/config.go @@ -4,7 +4,6 @@ package config import ( - "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -41,14 +40,3 @@ func SetBech32Prefixes(config *sdk.Config) { config.SetBech32PrefixForValidator(Bech32PrefixValAddr, Bech32PrefixValPub) config.SetBech32PrefixForConsensusNode(Bech32PrefixConsAddr, Bech32PrefixConsPub) } - -// RegisterDenoms registers the base and display denominations to the SDK. -func RegisterDenoms() { - if err := sdk.RegisterDenom(DisplayDenom, math.LegacyOneDec()); err != nil { - panic(err) - } - - if err := sdk.RegisterDenom(BaseDenom, math.LegacyNewDecWithPrec(1, BaseDenomUnit)); err != nil { - panic(err) - } -} diff --git a/example_chain/osd/main.go b/example_chain/osd/main.go index 259265eb..24ab83c2 100644 --- a/example_chain/osd/main.go +++ b/example_chain/osd/main.go @@ -16,7 +16,6 @@ import ( func main() { setupSDKConfig() - chainconfig.RegisterDenoms() rootCmd := cmd.NewRootCmd() if err := svrcmd.Execute(rootCmd, "osd", examplechain.DefaultNodeHome); err != nil { diff --git a/example_chain/precompiles.go b/example_chain/precompiles.go index a0ced57c..6c08e1d1 100644 --- a/example_chain/precompiles.go +++ b/example_chain/precompiles.go @@ -10,14 +10,18 @@ import ( authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" distributionkeeper "github.com/cosmos/cosmos-sdk/x/distribution/keeper" + govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" + slashingkeeper "github.com/cosmos/cosmos-sdk/x/slashing/keeper" stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" channelkeeper "github.com/cosmos/ibc-go/v8/modules/core/04-channel/keeper" "github.com/ethereum/go-ethereum/common" bankprecompile "github.com/evmos/os/precompiles/bank" "github.com/evmos/os/precompiles/bech32" distprecompile "github.com/evmos/os/precompiles/distribution" + govprecompile "github.com/evmos/os/precompiles/gov" ics20precompile "github.com/evmos/os/precompiles/ics20" "github.com/evmos/os/precompiles/p256" + slashingprecompile "github.com/evmos/os/precompiles/slashing" stakingprecompile "github.com/evmos/os/precompiles/staking" erc20Keeper "github.com/evmos/os/x/erc20/keeper" "github.com/evmos/os/x/evm/core/vm" @@ -39,6 +43,8 @@ func NewAvailableStaticPrecompiles( transferKeeper transferkeeper.Keeper, channelKeeper channelkeeper.Keeper, evmKeeper *evmkeeper.Keeper, + govKeeper govkeeper.Keeper, + slashingKeeper slashingkeeper.Keeper, ) map[common.Address]vm.PrecompiledContract { // Clone the mapping from the latest EVM fork. precompiles := maps.Clone(vm.PrecompiledContractsBerlin) @@ -82,6 +88,16 @@ func NewAvailableStaticPrecompiles( panic(fmt.Errorf("failed to instantiate bank precompile: %w", err)) } + govPrecompile, err := govprecompile.NewPrecompile(govKeeper, authzKeeper) + if err != nil { + panic(fmt.Errorf("failed to instantiate gov precompile: %w", err)) + } + + slashingPrecompile, err := slashingprecompile.NewPrecompile(slashingKeeper, authzKeeper) + if err != nil { + panic(fmt.Errorf("failed to instantiate slashing precompile: %w", err)) + } + // Stateless precompiles precompiles[bech32Precompile.Address()] = bech32Precompile precompiles[p256Precompile.Address()] = p256Precompile @@ -91,6 +107,8 @@ func NewAvailableStaticPrecompiles( precompiles[distributionPrecompile.Address()] = distributionPrecompile precompiles[ibcTransferPrecompile.Address()] = ibcTransferPrecompile precompiles[bankPrecompile.Address()] = bankPrecompile + precompiles[govPrecompile.Address()] = govPrecompile + precompiles[slashingPrecompile.Address()] = slashingPrecompile return precompiles } diff --git a/example_chain/testutil/abci.go b/example_chain/testutil/abci.go index 75008a48..b8d9d0d6 100644 --- a/example_chain/testutil/abci.go +++ b/example_chain/testutil/abci.go @@ -94,7 +94,7 @@ func DeliverEthTx( ) (abci.ExecTxResult, error) { txConfig := exampleApp.GetTxConfig() - tx, err := tx.PrepareEthTx(txConfig, exampleApp, priv, msgs...) + tx, err := tx.PrepareEthTx(txConfig, priv, msgs...) if err != nil { return abci.ExecTxResult{}, err } @@ -121,7 +121,7 @@ func DeliverEthTxWithoutCheck( ) (abci.ExecTxResult, error) { txConfig := exampleApp.GetTxConfig() - tx, err := tx.PrepareEthTx(txConfig, exampleApp, priv, msgs...) + tx, err := tx.PrepareEthTx(txConfig, priv, msgs...) if err != nil { return abci.ExecTxResult{}, err } @@ -170,7 +170,7 @@ func CheckEthTx( ) (abci.ResponseCheckTx, error) { txConfig := exampleApp.GetTxConfig() - tx, err := tx.PrepareEthTx(txConfig, exampleApp, priv, msgs...) + tx, err := tx.PrepareEthTx(txConfig, priv, msgs...) if err != nil { return abci.ResponseCheckTx{}, err } diff --git a/example_chain/testutil/contract.go b/example_chain/testutil/contract.go index 8771d1b7..8795d399 100644 --- a/example_chain/testutil/contract.go +++ b/example_chain/testutil/contract.go @@ -22,6 +22,7 @@ import ( exampleapp "github.com/evmos/os/example_chain" "github.com/evmos/os/testutil/tx" evm "github.com/evmos/os/x/evm/types" + evmtypes "github.com/evmos/os/x/evm/types" ) // ContractArgs are the params used for calling a smart contract. @@ -60,7 +61,7 @@ func DeployContract( contract evm.CompiledContract, constructorArgs ...interface{}, ) (common.Address, error) { - chainID := app.EVMKeeper.ChainID() + chainID := evmtypes.GetEthChainConfig().ChainID from := common.BytesToAddress(priv.PubKey().Address().Bytes()) nonce := app.EVMKeeper.GetNonce(ctx, from) @@ -75,11 +76,16 @@ func DeployContract( return common.Address{}, err } + baseFeeRes, err := queryClientEvm.BaseFee(ctx, &evmtypes.QueryBaseFeeRequest{}) + if err != nil { + return common.Address{}, err + } + msgEthereumTx := evm.NewTx(&evm.EvmTxArgs{ ChainID: chainID, Nonce: nonce, GasLimit: gas, - GasFeeCap: app.FeeMarketKeeper.GetBaseFee(ctx), + GasFeeCap: baseFeeRes.BaseFee.BigInt(), GasTipCap: big.NewInt(1), Input: data, Accesses: ðtypes.AccessList{}, @@ -106,7 +112,7 @@ func DeployContractWithFactory( priv cryptotypes.PrivKey, factoryAddress common.Address, ) (common.Address, abci.ExecTxResult, error) { - chainID := exampleApp.EVMKeeper.ChainID() + chainID := evmtypes.GetEthChainConfig().ChainID from := common.BytesToAddress(priv.PubKey().Address().Bytes()) factoryNonce := exampleApp.EVMKeeper.GetNonce(ctx, factoryAddress) nonce := exampleApp.EVMKeeper.GetNonce(ctx, from) diff --git a/go.mod b/go.mod index b02aa785..bda0086d 100644 --- a/go.mod +++ b/go.mod @@ -1,28 +1,28 @@ module github.com/evmos/os -go 1.22.5 +go 1.22.8 require ( - cosmossdk.io/api v0.7.5 + cosmossdk.io/api v0.7.6 cosmossdk.io/core v0.11.1 cosmossdk.io/errors v1.0.1 - cosmossdk.io/log v1.4.0 - cosmossdk.io/math v1.3.0 - cosmossdk.io/store v1.1.0 + cosmossdk.io/log v1.5.0 + cosmossdk.io/math v1.4.0 + cosmossdk.io/store v1.1.1 cosmossdk.io/tools/confix v0.1.2 cosmossdk.io/x/evidence v0.1.1 cosmossdk.io/x/feegrant v0.1.1 - cosmossdk.io/x/tx v0.13.4 + cosmossdk.io/x/tx v0.13.5 github.com/btcsuite/btcd v0.24.2 github.com/btcsuite/btcd/btcutil v1.1.6 - github.com/cometbft/cometbft v0.38.11 + github.com/cometbft/cometbft v0.38.15 github.com/cosmos/cosmos-db v1.0.2 github.com/cosmos/cosmos-proto v1.0.0-beta.5 - github.com/cosmos/cosmos-sdk v0.50.9 + github.com/cosmos/cosmos-sdk v0.50.10 github.com/cosmos/go-bip39 v1.0.0 github.com/cosmos/gogoproto v1.7.0 github.com/cosmos/ibc-go/modules/capability v1.0.1 - github.com/cosmos/ibc-go/v8 v8.5.1 + github.com/cosmos/ibc-go/v8 v8.5.2 github.com/creachadair/tomledit v0.0.24 github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc github.com/dop251/goja v0.0.0-20220405120441-9037c2b61cbf @@ -36,26 +36,26 @@ require ( github.com/hashicorp/go-metrics v0.5.3 github.com/holiman/uint256 v1.3.1 github.com/improbable-eng/grpc-web v0.15.0 - github.com/onsi/ginkgo/v2 v2.19.1 - github.com/onsi/gomega v1.34.0 + github.com/onsi/ginkgo/v2 v2.22.0 + github.com/onsi/gomega v1.35.1 github.com/pkg/errors v0.9.1 - github.com/rs/cors v1.11.0 + github.com/rs/cors v1.11.1 github.com/spf13/cast v1.7.0 github.com/spf13/cobra v1.8.1 github.com/spf13/viper v1.19.0 - github.com/stretchr/testify v1.9.0 - github.com/tidwall/gjson v1.17.3 + github.com/stretchr/testify v1.10.0 + github.com/tidwall/gjson v1.18.0 github.com/tidwall/sjson v1.2.5 github.com/tyler-smith/go-bip39 v1.1.0 github.com/zondax/hid v0.9.2 - golang.org/x/crypto v0.27.0 + golang.org/x/crypto v0.29.0 golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 - golang.org/x/net v0.29.0 - golang.org/x/sync v0.8.0 - golang.org/x/text v0.18.0 - google.golang.org/genproto/googleapis/api v0.0.0-20240624140628-dc46fd24d27d - google.golang.org/grpc v1.66.2 - google.golang.org/protobuf v1.34.2 + golang.org/x/net v0.31.0 + golang.org/x/sync v0.9.0 + golang.org/x/text v0.20.0 + google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 + google.golang.org/grpc v1.68.0 + google.golang.org/protobuf v1.35.2 sigs.k8s.io/yaml v1.4.0 ) @@ -63,10 +63,10 @@ require ( cloud.google.com/go v0.115.0 // indirect cloud.google.com/go/auth v0.6.0 // indirect cloud.google.com/go/auth/oauth2adapt v0.2.2 // indirect - cloud.google.com/go/compute/metadata v0.3.0 // indirect + cloud.google.com/go/compute/metadata v0.5.0 // indirect cloud.google.com/go/iam v1.1.9 // indirect cloud.google.com/go/storage v1.41.0 // indirect - cosmossdk.io/client/v2 v2.0.0-beta.3 // indirect + cosmossdk.io/client/v2 v2.0.0-beta.5 // indirect cosmossdk.io/collections v0.4.0 // indirect cosmossdk.io/depinject v1.0.0 // indirect cosmossdk.io/x/circuit v0.1.1 // indirect @@ -83,27 +83,32 @@ require ( github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect github.com/bits-and-blooms/bitset v1.8.0 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect + github.com/btcsuite/btcd/btcec/v2 v2.3.4 // indirect github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0 // indirect + github.com/bytedance/sonic v1.12.3 // indirect + github.com/bytedance/sonic/loader v0.2.0 // indirect github.com/cenkalti/backoff/v4 v4.1.3 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/chzyer/readline v1.5.1 // indirect + github.com/cloudwego/base64x v0.1.4 // indirect + github.com/cloudwego/iasm v0.2.0 // indirect github.com/cockroachdb/apd/v2 v2.0.2 // indirect - github.com/cockroachdb/errors v1.11.1 // indirect + github.com/cockroachdb/errors v1.11.3 // indirect + github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/pebble v1.1.0 // indirect + github.com/cockroachdb/pebble v1.1.1 // indirect github.com/cockroachdb/redact v1.1.5 // indirect github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect - github.com/cometbft/cometbft-db v0.12.0 // indirect + github.com/cometbft/cometbft-db v0.14.1 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect - github.com/cosmos/iavl v1.1.2 // indirect + github.com/cosmos/iavl v1.2.0 // indirect github.com/cosmos/ics23/go v0.11.0 // indirect github.com/cosmos/ledger-cosmos-go v0.13.3 // indirect github.com/creachadair/atomicfile v0.3.1 // indirect github.com/danieljoos/wincred v1.1.2 // indirect github.com/deckarep/golang-set v1.8.0 // indirect - github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 // indirect github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect github.com/dgraph-io/badger/v4 v4.2.0 // indirect github.com/dgraph-io/ristretto v0.1.1 // indirect @@ -116,7 +121,7 @@ require ( github.com/felixge/httpsnoop v1.0.4 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/getsentry/sentry-go v0.27.0 // indirect - github.com/go-kit/kit v0.12.0 // indirect + github.com/go-kit/kit v0.13.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect github.com/go-logr/logr v1.4.2 // indirect @@ -128,14 +133,14 @@ require ( github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/glog v1.2.1 // indirect + github.com/golang/glog v1.2.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/snappy v0.0.4 // indirect - github.com/google/btree v1.1.2 // indirect + github.com/google/btree v1.1.3 // indirect github.com/google/flatbuffers v23.5.26+incompatible // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/google/orderedcode v0.0.1 // indirect - github.com/google/pprof v0.0.0-20240424215950-a892ee059fd6 // indirect + github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db // indirect github.com/google/s2a-go v0.1.7 // indirect github.com/google/uuid v1.6.0 // indirect github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect @@ -162,32 +167,33 @@ require ( github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect - github.com/klauspost/compress v1.17.7 // indirect + github.com/klauspost/compress v1.17.9 // indirect github.com/klauspost/cpuid/v2 v2.2.5 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect - github.com/lib/pq v1.10.7 // indirect + github.com/lib/pq v1.10.9 // indirect github.com/linxGnu/grocksdb v1.9.2 // indirect github.com/magiconair/properties v1.8.7 // indirect github.com/manifoldco/promptui v0.9.0 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.20 // indirect github.com/mattn/go-runewidth v0.0.9 // indirect - github.com/minio/highwayhash v1.0.2 // indirect + github.com/minio/highwayhash v1.0.3 // indirect github.com/mitchellh/go-homedir v1.1.0 // indirect github.com/mitchellh/go-testing-interface v1.14.1 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect github.com/mtibben/percent v0.2.1 // indirect + github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a // indirect github.com/oklog/run v1.1.0 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect github.com/pelletier/go-toml/v2 v2.2.2 // indirect - github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67 // indirect + github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect - github.com/prometheus/client_golang v1.19.0 // indirect + github.com/prometheus/client_golang v1.20.5 // indirect github.com/prometheus/client_model v0.6.1 // indirect - github.com/prometheus/common v0.52.2 // indirect - github.com/prometheus/procfs v0.13.0 // indirect + github.com/prometheus/common v0.60.1 // indirect + github.com/prometheus/procfs v0.15.1 // indirect github.com/prometheus/tsdb v0.10.0 // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect github.com/rjeczalik/notify v0.9.3 // indirect @@ -195,7 +201,7 @@ require ( github.com/rs/zerolog v1.33.0 // indirect github.com/sagikazarmark/locafero v0.4.0 // indirect github.com/sagikazarmark/slog-shim v0.1.0 // indirect - github.com/sasha-s/go-deadlock v0.3.1 // indirect + github.com/sasha-s/go-deadlock v0.3.5 // indirect github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect github.com/sourcegraph/conc v0.3.0 // indirect github.com/spf13/afero v1.11.0 // indirect @@ -210,6 +216,7 @@ require ( github.com/tidwall/pretty v1.2.0 // indirect github.com/tklauser/go-sysconf v0.3.11 // indirect github.com/tklauser/numcpus v0.6.0 // indirect + github.com/twitchyliquid64/golang-asm v0.15.1 // indirect github.com/ulikunitz/xz v0.5.11 // indirect github.com/zondax/ledger-go v0.14.3 // indirect go.etcd.io/bbolt v1.4.0-alpha.0.0.20240404170359-43604f3112c5 // indirect @@ -220,14 +227,15 @@ require ( go.opentelemetry.io/otel/metric v1.24.0 // indirect go.opentelemetry.io/otel/trace v1.24.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/oauth2 v0.21.0 // indirect - golang.org/x/sys v0.25.0 // indirect - golang.org/x/term v0.24.0 // indirect + golang.org/x/arch v0.3.0 // indirect + golang.org/x/oauth2 v0.23.0 // indirect + golang.org/x/sys v0.27.0 // indirect + golang.org/x/term v0.26.0 // indirect golang.org/x/time v0.5.0 // indirect - golang.org/x/tools v0.23.0 // indirect + golang.org/x/tools v0.26.0 // indirect google.golang.org/api v0.186.0 // indirect google.golang.org/genproto v0.0.0-20240701130421-f6361c86f094 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect gopkg.in/yaml.v2 v2.4.0 // indirect @@ -237,8 +245,8 @@ require ( pgregory.net/rapid v1.1.0 // indirect ) -// // replace for local development -// replace github.com/evmos/os/example_chain => ./example_chain +// replace for local development +replace github.com/evmos/os/example_chain => ./example_chain replace ( // need this replace when importing cosmos/rosetta pkg diff --git a/go.sum b/go.sum index 76e9a011..69756fe6 100644 --- a/go.sum +++ b/go.sum @@ -72,8 +72,8 @@ cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz cloud.google.com/go/compute v1.6.1/go.mod h1:g85FgpzFvNULZ+S8AYq87axRKuf2Kh7deLqV/jJ3thU= cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQHHZWZxy9U= cloud.google.com/go/compute v1.10.0/go.mod h1:ER5CLbMxl90o2jtNbGSbtfOpQKR0t15FOtRsugnLrlU= -cloud.google.com/go/compute/metadata v0.3.0 h1:Tz+eQXMEqDIKRsmY3cHTL6FVaynIjX2QxYC4trgAKZc= -cloud.google.com/go/compute/metadata v0.3.0/go.mod h1:zFmK7XCadkQkj6TtorcaGlCW1hT1fIilQDwofLpJ20k= +cloud.google.com/go/compute/metadata v0.5.0 h1:Zr0eK8JbFv6+Wi4ilXAR8FJ3wyNdpxHKJNPos6LTZOY= +cloud.google.com/go/compute/metadata v0.5.0/go.mod h1:aHnloV2TPI38yx4s9+wAZhHykWvVCfu7hQbF+9CWoiY= cloud.google.com/go/containeranalysis v0.5.1/go.mod h1:1D92jd8gRR/c0fGMlymRgxWD3Qw9C1ff6/T7mLgVL8I= cloud.google.com/go/containeranalysis v0.6.0/go.mod h1:HEJoiEIu+lEXM+k7+qLCci0h33lX3ZqoYFdmPcoO7s4= cloud.google.com/go/datacatalog v1.3.0/go.mod h1:g9svFY6tuR+j+hrTw3J2dNcmI0dzmSiyOzm8kpLq0a0= @@ -186,10 +186,10 @@ cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xX cloud.google.com/go/webrisk v1.5.0/go.mod h1:iPG6fr52Tv7sGk0H6qUFzmL3HHZev1htXuWDEEsqMTg= cloud.google.com/go/workflows v1.6.0/go.mod h1:6t9F5h/unJz41YqfBmqSASJSXccBLtD1Vwf+KmJENM0= cloud.google.com/go/workflows v1.7.0/go.mod h1:JhSrZuVZWuiDfKEFxU0/F1PQjmpnpcoISEXH2bcHC3M= -cosmossdk.io/api v0.7.5 h1:eMPTReoNmGUm8DeiQL9DyM8sYDjEhWzL1+nLbI9DqtQ= -cosmossdk.io/api v0.7.5/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= -cosmossdk.io/client/v2 v2.0.0-beta.3 h1:+TTuH0DwQYsUq2JFAl3fDZzKq5gQG7nt3dAattkjFDU= -cosmossdk.io/client/v2 v2.0.0-beta.3/go.mod h1:CZcL41HpJPOOayTCO28j8weNBQprG+SRiKX39votypo= +cosmossdk.io/api v0.7.6 h1:PC20PcXy1xYKH2KU4RMurVoFjjKkCgYRbVAD4PdqUuY= +cosmossdk.io/api v0.7.6/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= +cosmossdk.io/client/v2 v2.0.0-beta.5 h1:0LVv3nEByn//hFDIrYLs2WvsEU3HodOelh4SDHnA/1I= +cosmossdk.io/client/v2 v2.0.0-beta.5/go.mod h1:4p0P6o0ro+FizakJUYS9SeM94RNbv0thLmkHRw5o5as= cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= @@ -198,10 +198,10 @@ cosmossdk.io/depinject v1.0.0 h1:dQaTu6+O6askNXO06+jyeUAnF2/ssKwrrszP9t5q050= cosmossdk.io/depinject v1.0.0/go.mod h1:zxK/h3HgHoA/eJVtiSsoaRaRA2D5U4cJ5thIG4ssbB8= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.4.0 h1:Ttt9d6fQ0GlktwhcysOeNiIjixW7l0rYBocmoXOb11k= -cosmossdk.io/log v1.4.0/go.mod h1:k08v0Pyq+gCP6phvdI6RCGhLf/r425UT6Rk/m+o74rU= -cosmossdk.io/math v1.3.0 h1:RC+jryuKeytIiictDslBP9i1fhkVm6ZDmZEoNP316zE= -cosmossdk.io/math v1.3.0/go.mod h1:vnRTxewy+M7BtXBNFybkuhSH4WfedVAAnERHgVFhp3k= +cosmossdk.io/log v1.5.0 h1:dVdzPJW9kMrnAYyMf1duqacoidB9uZIl+7c6z0mnq0g= +cosmossdk.io/log v1.5.0/go.mod h1:Tr46PUJjiUthlwQ+hxYtUtPn4D/oCZXAkYevBeh5+FI= +cosmossdk.io/math v1.4.0 h1:XbgExXFnXmF/CccPPEto40gOO7FpWu9yWNAZPN3nkNQ= +cosmossdk.io/math v1.4.0/go.mod h1:O5PkD4apz2jZs4zqFdTr16e1dcaQCc5z6lkEnrrppuk= cosmossdk.io/tools/confix v0.1.2 h1:2hoM1oFCNisd0ltSAAZw2i4ponARPmlhuNu3yy0VwI4= cosmossdk.io/tools/confix v0.1.2/go.mod h1:7XfcbK9sC/KNgVGxgLM0BrFbVcR/+6Dg7MFfpx7duYo= cosmossdk.io/x/circuit v0.1.1 h1:KPJCnLChWrxD4jLwUiuQaf5mFD/1m7Omyo7oooefBVQ= @@ -210,8 +210,8 @@ cosmossdk.io/x/evidence v0.1.1 h1:Ks+BLTa3uftFpElLTDp9L76t2b58htjVbSZ86aoK/E4= cosmossdk.io/x/evidence v0.1.1/go.mod h1:OoDsWlbtuyqS70LY51aX8FBTvguQqvFrt78qL7UzeNc= cosmossdk.io/x/feegrant v0.1.1 h1:EKFWOeo/pup0yF0svDisWWKAA9Zags6Zd0P3nRvVvw8= cosmossdk.io/x/feegrant v0.1.1/go.mod h1:2GjVVxX6G2fta8LWj7pC/ytHjryA6MHAJroBWHFNiEQ= -cosmossdk.io/x/tx v0.13.4 h1:Eg0PbJgeO0gM8p5wx6xa0fKR7hIV6+8lC56UrsvSo0Y= -cosmossdk.io/x/tx v0.13.4/go.mod h1:BkFqrnGGgW50Y6cwTy+JvgAhiffbGEKW6KF9ufcDpvk= +cosmossdk.io/x/tx v0.13.5 h1:FdnU+MdmFWn1pTsbfU0OCf2u6mJ8cqc1H4OMG418MLw= +cosmossdk.io/x/tx v0.13.5/go.mod h1:V6DImnwJMTq5qFjeGWpXNiT/fjgE4HtmclRmTqRVM3w= cosmossdk.io/x/upgrade v0.1.4 h1:/BWJim24QHoXde8Bc64/2BSEB6W4eTydq0X/2f8+g38= cosmossdk.io/x/upgrade v0.1.4/go.mod h1:9v0Aj+fs97O+Ztw+tG3/tp5JSlrmT7IcFhAebQHmOPo= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= @@ -241,8 +241,8 @@ github.com/VictoriaMetrics/fastcache v1.6.0 h1:C/3Oi3EiBCqufydp1neRZkqcwmEiuRT9c github.com/VictoriaMetrics/fastcache v1.6.0/go.mod h1:0qHz5QP0GMX4pfmMA/zt5RgfNuXJrTP0zS7DqpHGGTw= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= -github.com/adlio/schema v1.3.3 h1:oBJn8I02PyTB466pZO1UZEn1TV5XLlifBSyMrmHl/1I= -github.com/adlio/schema v1.3.3/go.mod h1:1EsRssiv9/Ce2CMzq5DoL7RiMshhuigQxrR4DMV9fHg= +github.com/adlio/schema v1.3.6 h1:k1/zc2jNfeiZBA5aFTRy37jlBIuCkXCm0XmvpzCKI9I= +github.com/adlio/schema v1.3.6/go.mod h1:qkxwLgPBd1FgLRHYVCmQT/rrBr3JH38J9LjmVzWNudg= github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= @@ -284,8 +284,8 @@ github.com/btcsuite/btcd v0.24.2 h1:aLmxPguqxza+4ag8R1I2nnJjSu2iFn/kqtHTIImswcY= github.com/btcsuite/btcd v0.24.2/go.mod h1:5C8ChTkl5ejr3WHj8tkQSCmydiMEPB0ZhQhehpq7Dgg= github.com/btcsuite/btcd/btcec/v2 v2.1.0/go.mod h1:2VzYrv4Gm4apmbVVsSq5bqf1Ec8v56E48Vt0Y/umPgA= github.com/btcsuite/btcd/btcec/v2 v2.1.3/go.mod h1:ctjw4H1kknNJmRN4iP1R7bTQ+v3GJkZBd6mui8ZsAZE= -github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= -github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= +github.com/btcsuite/btcd/btcec/v2 v2.3.4 h1:3EJjcN70HCu/mwqlUsGK8GcNVyLVxFDlWurTXGPFfiQ= +github.com/btcsuite/btcd/btcec/v2 v2.3.4/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/btcutil v1.0.0/go.mod h1:Uoxwv0pqYWhD//tfTiipkxNfdhG9UrLwaeswfjfdF0A= github.com/btcsuite/btcd/btcutil v1.1.0/go.mod h1:5OapHB7A2hBBWLm48mmw4MOHNJCcUBTwmWH/0Jn8VHE= github.com/btcsuite/btcd/btcutil v1.1.5/go.mod h1:PSZZ4UitpLBWzxGd5VGOrLnmOjtPP/a6HaFo12zMs00= @@ -307,8 +307,12 @@ github.com/btcsuite/winsvc v1.0.0/go.mod h1:jsenWakMcC0zFBFurPLEAyrnc/teJEM1O46f github.com/bufbuild/protocompile v0.6.0 h1:Uu7WiSQ6Yj9DbkdnOe7U4mNKp58y9WDMKDn28/ZlunY= github.com/bufbuild/protocompile v0.6.0/go.mod h1:YNP35qEYoYGme7QMtz5SBCoN4kL4g12jTtjuzRNdjpE= github.com/bytedance/sonic v1.5.0/go.mod h1:ED5hyg4y6t3/9Ku1R6dU/4KyJ48DZ4jPhfY1O2AihPM= -github.com/bytedance/sonic v1.9.1 h1:6iJ6NqdoxCDr6mbY8h18oSO+cShGSMRGCEo7F2h0x8s= github.com/bytedance/sonic v1.9.1/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= +github.com/bytedance/sonic v1.12.3 h1:W2MGa7RCU1QTeYRTPE3+88mVC0yXmsRQRChiyVocVjU= +github.com/bytedance/sonic v1.12.3/go.mod h1:B8Gt/XvtZ3Fqj+iSKMypzymZxw/FVwgIGKzMzT9r/rk= +github.com/bytedance/sonic/loader v0.1.1/go.mod h1:ncP89zfokxS5LZrJxl5z0UJcsk4M4yY2JpfqGeCtNLU= +github.com/bytedance/sonic/loader v0.2.0 h1:zNprn+lsIP06C/IqCHs3gPQIvnvpKbbxyXQP1iU4kWM= +github.com/bytedance/sonic/loader v0.2.0/go.mod h1:ncP89zfokxS5LZrJxl5z0UJcsk4M4yY2JpfqGeCtNLU= github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= @@ -324,7 +328,6 @@ github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UF github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cheggaaa/pb v1.0.27/go.mod h1:pQciLPpbU0oxA0h+VJYYLxO+XeDQb5pZijXscXHm81s= github.com/chenzhuoyu/base64x v0.0.0-20211019084208-fb5309c8db06/go.mod h1:DH46F32mSOjUmXrMHnKwZdA8wcEefY7UVqBKYGjpdQY= -github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 h1:qSGYFH7+jGhDF8vLC+iwCD4WpbV1EBDSzWkJODFLams= github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311/go.mod h1:b583jCggY9gE99b6G5LEC39OIiVsWj+R97kbl5odCEk= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/logex v1.2.1 h1:XHDu3E6q+gdHgsdTPH6ImJMIp436vR6MPtH8gP05QzM= @@ -339,6 +342,10 @@ github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6D github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4dUb/I5gc9Hdhagfvm9+RyrPryS/auMzxE= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= +github.com/cloudwego/base64x v0.1.4 h1:jwCgWpFanWmN8xoIUHa2rtzmkd5J2plF/dnLS6Xd/0Y= +github.com/cloudwego/base64x v0.1.4/go.mod h1:0zlkT4Wn5C6NdauXdJRhSKRlJvmclQ1hhJgA0rcu/8w= +github.com/cloudwego/iasm v0.2.0 h1:1KNIy1I1H9hNNFEEH3DVnI4UujN+1zjpuk6gwHLTssg= +github.com/cloudwego/iasm v0.2.0/go.mod h1:8rXZaNYT2n95jn+zTI1sDr+IgcD2GVs0nlbbQPiEFhY= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= @@ -353,21 +360,23 @@ github.com/cockroachdb/apd/v2 v2.0.2/go.mod h1:DDxRlzC2lo3/vSlmSoS7JkqbbrARPuFOG github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= 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/errors v1.11.3 h1:5bA+k2Y6r+oz/6Z/RFlNeVCesGARKuC6YymtcDrbC/I= +github.com/cockroachdb/errors v1.11.3/go.mod h1:m4UIW4CDjx+R5cybPsNrRbreomiFqt8o1h1wUVazSd8= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce h1:giXvy4KSc/6g/esnpM7Geqxka4WSqI1SZc7sMJFd3y4= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce/go.mod h1:9/y3cnZ5GKakj/H4y9r9GTjCvAFta7KLgSHPJJYc52M= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= -github.com/cockroachdb/pebble v1.1.0 h1:pcFh8CdCIt2kmEpK0OIatq67Ln9uGDYY3d5XnE0LJG4= -github.com/cockroachdb/pebble v1.1.0/go.mod h1:sEHm5NOXxyiAoKWhoFxT8xMgd/f3RA6qUqQ1BXKrh2E= +github.com/cockroachdb/pebble v1.1.1 h1:XnKU22oiCLy2Xn8vp1re67cXg4SAasg/WDt1NtcRFaw= +github.com/cockroachdb/pebble v1.1.1/go.mod h1:4exszw1r40423ZsmkG/09AFEG83I0uDgfujJdbL6kYU= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= -github.com/cometbft/cometbft v0.38.11 h1:6bNDUB8/xq4uYonYwIfGc9OqK1ZH4NkdaMmR1LZIJqk= -github.com/cometbft/cometbft v0.38.11/go.mod h1:jHPx9vQpWzPHEAiYI/7EDKaB1NXhK6o3SArrrY8ExKc= -github.com/cometbft/cometbft-db v0.12.0 h1:v77/z0VyfSU7k682IzZeZPFZrQAKiQwkqGN0QzAjMi0= -github.com/cometbft/cometbft-db v0.12.0/go.mod h1:aX2NbCrjNVd2ZajYxt1BsiFf/Z+TQ2MN0VxdicheYuw= +github.com/cometbft/cometbft v0.38.15 h1:5veFd8k1uXM27PBg9sMO3hAfRJ3vbh4OmmLf6cVrqXg= +github.com/cometbft/cometbft v0.38.15/go.mod h1:+wh6ap6xctVG+JOHwbl8pPKZ0GeqdPYqISu7F4b43cQ= +github.com/cometbft/cometbft-db v0.14.1 h1:SxoamPghqICBAIcGpleHbmoPqy+crij/++eZz3DlerQ= +github.com/cometbft/cometbft-db v0.14.1/go.mod h1:KHP1YghilyGV/xjD5DP3+2hyigWx0WTp9X+0Gnx0RxQ= github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= github.com/containerd/continuity v0.3.0/go.mod h1:wJEAIwKOm/pBZuBd0JmeTvnLquTB1Ag8espWhkykbPM= github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= @@ -387,12 +396,12 @@ github.com/cosmos/gogogateway v1.2.0/go.mod h1:iQpLkGWxYcnCdz5iAdLcRBSw3h7NXeOkZ github.com/cosmos/gogoproto v1.4.2/go.mod h1:cLxOsn1ljAHSV527CHOtaIP91kK6cCrZETRBrkzItWU= github.com/cosmos/gogoproto v1.7.0 h1:79USr0oyXAbxg3rspGh/m4SWNyoz/GLaAh0QlCe2fro= github.com/cosmos/gogoproto v1.7.0/go.mod h1:yWChEv5IUEYURQasfyBW5ffkMHR/90hiHgbNgrtp4j0= -github.com/cosmos/iavl v1.1.2 h1:zL9FK7C4L/P4IF1Dm5fIwz0WXCnn7Bp1M2FxH0ayM7Y= -github.com/cosmos/iavl v1.1.2/go.mod h1:jLeUvm6bGT1YutCaL2fIar/8vGUE8cPZvh/gXEWDaDM= +github.com/cosmos/iavl v1.2.0 h1:kVxTmjTh4k0Dh1VNL046v6BXqKziqMDzxo93oh3kOfM= +github.com/cosmos/iavl v1.2.0/go.mod h1:HidWWLVAtODJqFD6Hbne2Y0q3SdxByJepHUOeoH4LiI= github.com/cosmos/ibc-go/modules/capability v1.0.1 h1:ibwhrpJ3SftEEZRxCRkH0fQZ9svjthrX2+oXdZvzgGI= github.com/cosmos/ibc-go/modules/capability v1.0.1/go.mod h1:rquyOV262nGJplkumH+/LeYs04P3eV8oB7ZM4Ygqk4E= -github.com/cosmos/ibc-go/v8 v8.5.1 h1:3JleEMKBjRKa3FeTKt4fjg22za/qygLBo7mDkoYTNBs= -github.com/cosmos/ibc-go/v8 v8.5.1/go.mod h1:P5hkAvq0Qbg0h18uLxDVA9q1kOJ0l36htMsskiNwXbo= +github.com/cosmos/ibc-go/v8 v8.5.2 h1:27s9oeD2AxLQF3e9BQsYt9doONyZ7FwZi/qkBv6Sdks= +github.com/cosmos/ibc-go/v8 v8.5.2/go.mod h1:P5hkAvq0Qbg0h18uLxDVA9q1kOJ0l36htMsskiNwXbo= github.com/cosmos/ics23/go v0.11.0 h1:jk5skjT0TqX5e5QJbEnwXIS2yI2vnmLOgpQPeM5RtnU= github.com/cosmos/ics23/go v0.11.0/go.mod h1:A8OjxPE67hHST4Icw94hOxxFEJMBG031xIGF/JHNIY0= github.com/cosmos/keyring v1.2.0 h1:8C1lBP9xhImmIabyXW4c3vFjjLiBdGCmfLUfeZlV1Yo= @@ -421,8 +430,8 @@ github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn 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.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= -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/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f/go.mod h1:xH/i4TFMt8koVQZ6WFms69WAsDWr2XsYL3Hkl7jkoLE= @@ -475,8 +484,6 @@ github.com/evmos/cosmos-sdk/store v0.0.0-20240718141609-414cbd051fbe h1:CKvjP3Cc github.com/evmos/cosmos-sdk/store v0.0.0-20240718141609-414cbd051fbe/go.mod h1:Bm6h8ZkYgVTytHK5vhHOMKw9OHyiumm3b1UbkYIJ/Ug= github.com/evmos/go-ethereum v1.10.26-evmos-rc4 h1:vwDVMScuB2KSu8ze5oWUuxm6v3bMUp6dL3PWvJNJY+I= github.com/evmos/go-ethereum v1.10.26-evmos-rc4/go.mod h1:/6CsT5Ceen2WPLI/oCA3xMcZ5sWMF/D46SjM/ayY0Oo= -github.com/evmos/os/example_chain v0.0.0-20240924163020-b2a4187dad50 h1:zWJYHc0WXE5YnuzYJnUzjMwuloxSz5ALCoNSzcuhKsA= -github.com/evmos/os/example_chain v0.0.0-20240924163020-b2a4187dad50/go.mod h1:+SPMqw9wtbWO3jG02uLbLtVVjMHBldmXTN51kxbWqJ8= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs= @@ -514,8 +521,8 @@ github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2 github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgOZ7o= -github.com/go-kit/kit v0.12.0 h1:e4o3o3IsBfAKQh5Qbbiqyfu97Ku7jrO/JbohvztANh4= -github.com/go-kit/kit v0.12.0/go.mod h1:lHd+EkCZPIwYItmGDDRdhinkzX2A1sj+M9biaEaizzs= +github.com/go-kit/kit v0.13.0 h1:OoneCcHKHQ03LfBpoQCUfCluwd2Vt3ohz+kvbJneZAU= +github.com/go-kit/kit v0.13.0/go.mod h1:phqEHMMUbyrCFCTgH48JueqrM3md2HcAZ8N3XE4FKDg= github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= @@ -547,15 +554,12 @@ 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/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI= github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8= +github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee h1:s+21KNqlpePfkah2I+gwHF8xmJWRjooY+5248k6m4A0= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= -github.com/gobwas/httphead v0.1.0 h1:exrUm0f4YX0L7EBwZHuCF4GDp8aJfVeBrlLQrs6NqWU= -github.com/gobwas/httphead v0.1.0/go.mod h1:O/RXo79gxV8G+RqlR/otEwx4Q36zl9rqC5u12GKvMCM= +github.com/gobwas/pool v0.2.0 h1:QEmUOlnSjWtnpRGHF3SauEiOsy82Cup83Vf2LcMlnc8= github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= -github.com/gobwas/pool v0.2.1 h1:xfeeEhW7pwmX8nuLVlqbzVc7udMDrwetjEv+TZIz1og= -github.com/gobwas/pool v0.2.1/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= +github.com/gobwas/ws v1.0.2 h1:CoAavW/wd/kulfZmSIBt6p24n4j7tHgNVCjsfHVNUbo= github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= -github.com/gobwas/ws v1.2.1 h1:F2aeBZrm2NDsc7vbovKrWSogd4wvfAxg0FQ89/iqOTk= -github.com/gobwas/ws v1.2.1/go.mod h1:hRKAFb8wOxFROYNsT1bqfWnhX+b5MFeJM9r2ZSwg/KY= github.com/goccy/go-json v0.10.2 h1:CrxCmQqYDkv1z7lO7Wbh2HN93uovUHgrECaO5ZrCXAU= github.com/goccy/go-json v0.10.2/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= @@ -574,8 +578,8 @@ github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69 github.com/golang-jwt/jwt/v4 v4.3.0 h1:kHL1vqdqWNfATmA0FNMdmZNMyZI1U6O31X4rlIPoBog= github.com/golang-jwt/jwt/v4 v4.3.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/glog v1.2.1 h1:OptwRhECazUx5ix5TTWC3EZhsZEHWcYWY4FQHTIubm4= -github.com/golang/glog v1.2.1/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= +github.com/golang/glog v1.2.2 h1:1+mZ9upx1Dh6FmUTFR1naJ77miKiXgALjWOZ3NVFPmY= +github.com/golang/glog v1.2.2/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -619,8 +623,8 @@ github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/btree v1.1.2 h1:xf4v41cLI2Z6FxbKm+8Bu+m8ifhj15JuZ9sa0jZCMUU= -github.com/google/btree v1.1.2/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= +github.com/google/btree v1.1.3 h1:CVpQJjYgC4VbzxeGVHfvZrv1ctoYCAI8vbl07Fcxlyg= +github.com/google/btree v1.1.3/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= github.com/google/flatbuffers v23.5.26+incompatible h1:M9dgRyhJemaM4Sw8+66GHBu8ioaQmyPLg1b8VwK5WJg= github.com/google/flatbuffers v23.5.26+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -667,8 +671,8 @@ github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20240424215950-a892ee059fd6 h1:k7nVchz72niMH6YLQNvHSdIE7iqsQxK1P41mySCvssg= -github.com/google/pprof v0.0.0-20240424215950-a892ee059fd6/go.mod h1:kf6iHlnVGwgKolg33glAes7Yg/8iWP8ukqeldJSO7jw= +github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db h1:097atOisP2aRj7vFgYQBbFN4U4JNXUNYpxael3UzMyo= +github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= @@ -828,12 +832,13 @@ github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6 github.com/klauspost/compress v1.10.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.11.7/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.15.11/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= -github.com/klauspost/compress v1.17.7 h1:ehO88t2UGzQK66LMdE8tibEd1ErmzZjNEqWkjLAKQQg= -github.com/klauspost/compress v1.17.7/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw= +github.com/klauspost/compress v1.17.9 h1:6KIumPrER1LHsvBVuDa0r5xaG0Es51mhhB9BQB2qeMA= +github.com/klauspost/compress v1.17.9/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/klauspost/cpuid/v2 v2.2.4/go.mod h1:RVVoqg1df56z8g3pUjL/3lE5UfnlrJX8tyFgg4nqhuY= 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/knz/go-libedit v1.10.1/go.mod h1:MZTVkCWyz0oBc7JOWP3wNAzd002ZbM/5hgShxwh4x8M= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= @@ -845,10 +850,12 @@ 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/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/leodido/go-urn v1.2.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q= github.com/leodido/go-urn v1.2.4/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= -github.com/lib/pq v1.10.7 h1:p7ZhMD+KsSRozJr34udlUrhboJwWAgCg34+/ZZNvZZw= -github.com/lib/pq v1.10.7/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= +github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw= +github.com/lib/pq v1.10.9/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= github.com/linxGnu/grocksdb v1.9.2 h1:O3mzvO0wuzQ9mtlHbDrShixyVjVbmuqTjFrzlf43wZ8= @@ -877,8 +884,8 @@ github.com/mattn/go-runewidth v0.0.9 h1:Lm995f3rfxdpd6TSmuVCHVb/QhupuXlYr8sCI/Qd 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/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= -github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA/g= -github.com/minio/highwayhash v1.0.2/go.mod h1:BQskDq+xkJ12lmlUUi7U0M5Swg3EWR+dLTk+kldvVxY= +github.com/minio/highwayhash v1.0.3 h1:kbnuUMoHYyVl7szWjSxJnxw11k2U709jqFPPmIUyD6Q= +github.com/minio/highwayhash v1.0.3/go.mod h1:GGYsuwP/fPD6Y9hMiXuapVvlIUEhFhMTh0rxU3ik1LQ= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= @@ -903,6 +910,8 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mtibben/percent v0.2.1/go.mod h1:KG9uO+SZkUp+VkRHsCdYQV3XSZrrSpR3O9ibNBTZrns= +github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= +github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= @@ -934,14 +943,14 @@ github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108 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.19.1 h1:QXgq3Z8Crl5EL1WBAC98A5sEBHARrAJNzAmMxzLcRF0= -github.com/onsi/ginkgo/v2 v2.19.1/go.mod h1:O3DtEWQkPa/F7fBMgmZQKKsluAy8pd3rEQdrjkPb9zA= +github.com/onsi/ginkgo/v2 v2.22.0 h1:Yed107/8DjTr0lKCNt7Dn8yQ6ybuDRQoMGrNFKzMfHg= +github.com/onsi/ginkgo/v2 v2.22.0/go.mod h1:7Du3c42kxCUegi0IImZ1wUQzMBVecgIHjR1C+NkhLQo= 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.34.0 h1:eSSPsPNp6ZpsG8X1OVmOTxig+CblTc4AxpPBykhe2Os= -github.com/onsi/gomega v1.34.0/go.mod h1:MIKI8c+f+QLWk+hxbePD4i0LMJSExPaZOVfkoex4cAo= +github.com/onsi/gomega v1.35.1 h1:Cwbd75ZBPxFSuZ6T+rN/WCb/gOc6YgFBXLlZLhC7Ds4= +github.com/onsi/gomega v1.35.1/go.mod h1:PvZbdDc8J6XJEpDK4HCuRBm8a6Fzp9/DmhC9C7yFlog= github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= @@ -968,9 +977,8 @@ github.com/pelletier/go-toml/v2 v2.0.8/go.mod h1:vuYfssBdrU2XDZ9bYydBu6t+6a6PYNc github.com/pelletier/go-toml/v2 v2.2.2 h1:aYUidT7k73Pcl9nb2gScu7NSrKCSHIDE89b3+6Wq+LM= github.com/pelletier/go-toml/v2 v2.2.2/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs= github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= -github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= -github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67 h1:jik8PHtAIsPlCRJjJzl4udgEf7hawInF9texMeO2jrU= -github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= +github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 h1:Dx7Ovyv/SFnMFw3fD4oEoeorXc6saIiQ23LrGLth0Gw= +github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc= github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= @@ -991,8 +999,8 @@ github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5Fsn github.com/prometheus/client_golang v1.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeDPbaTKGT+JTgUa3og= github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= -github.com/prometheus/client_golang v1.19.0 h1:ygXvpU1AoN1MhdzckN+PyD9QJOSD4x7kmXYlnfbA6JU= -github.com/prometheus/client_golang v1.19.0/go.mod h1:ZRM9uEAypZakd+q/x7+gmsvXdURP+DABIEIjnmDdp+k= +github.com/prometheus/client_golang v1.20.5 h1:cxppBPuYhUnsO6yo/aoRol4L7q7UFfdm+bR9r+8l63Y= +github.com/prometheus/client_golang v1.20.5/go.mod h1:PIEt8X02hGcP8JWbeHyeZ53Y/jReSnHgO035n//V5WE= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= @@ -1007,16 +1015,16 @@ github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt2 github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.15.0/go.mod h1:U+gB1OBLb1lF3O42bTCL+FK18tX9Oar16Clt/msog/s= -github.com/prometheus/common v0.52.2 h1:LW8Vk7BccEdONfrJBDffQGRtpSzi5CQaRZGtboOO2ck= -github.com/prometheus/common v0.52.2/go.mod h1:lrWtQx+iDfn2mbH5GUzlH9TSHyfZpHkSiG1W7y3sF2Q= +github.com/prometheus/common v0.60.1 h1:FUas6GcOw66yB/73KC+BOZoFJmbo/1pojoILArPAaSc= +github.com/prometheus/common v0.60.1/go.mod h1:h0LYf1R1deLSKtD4Vdg8gy4RuOvENW2J/h19V5NADQw= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.3.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.13.0 h1:GqzLlQyfsPbaEHaQkO7tbDlriv/4o5Hudv6OXHGKX7o= -github.com/prometheus/procfs v0.13.0/go.mod h1:cd4PFCR54QLnGKPaKGA6l+cfuNXtht43ZKY6tow0Y1g= +github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0learggepc= +github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk= github.com/prometheus/tsdb v0.10.0 h1:If5rVCMTp6W2SiRAQFlbpJNgVlgMEd+U2GZckwK38ic= github.com/prometheus/tsdb v0.10.0/go.mod h1:oi49uRhEe9dPUTlS3JRZOwJuVi6tmh10QSgwXEyGCt4= github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= @@ -1031,8 +1039,8 @@ github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/f github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= -github.com/rs/cors v1.11.0 h1:0B9GE/r9Bc2UxRMMtymBkHTenPkHDv0CW4Y98GBY+po= -github.com/rs/cors v1.11.0/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= +github.com/rs/cors v1.11.1 h1:eU3gRzXLRK57F5rKMGMZURNdIG4EoAmX8k94r9wXWHA= +github.com/rs/cors v1.11.1/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/zerolog v1.33.0 h1:1cU2KZkvPxNyfgEmhHAz/1A9Bz+llsdYzklWFzgp0r8= github.com/rs/zerolog v1.33.0/go.mod h1:/7mN4D5sKwJLZQ2b/znpjC3/GQWY/xaDXUM0kKWRHss= @@ -1045,8 +1053,8 @@ github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgY github.com/sagikazarmark/slog-shim v0.1.0 h1:diDBnUNK9N/354PgrxMywXnAwEr1QZcOr6gto+ugjYE= github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= -github.com/sasha-s/go-deadlock v0.3.1 h1:sqv7fDNShgjcaxkO0JNcOAlr8B9+cV5Ey/OB71efZx0= -github.com/sasha-s/go-deadlock v0.3.1/go.mod h1:F73l+cr82YSh10GxyRI6qZiCgK64VaZjwesgfQ1/iLM= +github.com/sasha-s/go-deadlock v0.3.5 h1:tNCOEEDG6tBqrNDOX35j/7hL5FcFViG6awUGROb2NsU= +github.com/sasha-s/go-deadlock v0.3.5/go.mod h1:bugP6EGbdGYObIlx7pUZtWqlvo8k9H6vCBBsiChJQ5U= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= 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= @@ -1055,8 +1063,8 @@ github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPx github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sirupsen/logrus v1.9.0 h1:trlNQbNUG3OdDrDil03MCb1H2o9nJ1x4/5LYw7byDE0= -github.com/sirupsen/logrus v1.9.0/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= +github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= +github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= 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/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= @@ -1100,8 +1108,9 @@ github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= +github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= @@ -1111,8 +1120,8 @@ github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoM github.com/tidwall/btree v1.7.0 h1:L1fkJH/AuEh5zBnnBbmTwQ5Lt+bRJ5A8EWecslvo9iI= github.com/tidwall/btree v1.7.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= github.com/tidwall/gjson v1.14.2/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= -github.com/tidwall/gjson v1.17.3 h1:bwWLZU7icoKRG+C+0PNwIKC6FCJO/Q3p2pZvuP0jN94= -github.com/tidwall/gjson v1.17.3/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= +github.com/tidwall/gjson v1.18.0 h1:FIDeeyB800efLX89e5a8Y0BNH+LOngJyGrIWxG2FKQY= +github.com/tidwall/gjson v1.18.0/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= github.com/tidwall/match v1.1.1 h1:+Ho715JplO36QYgwN9PGYNhgZvoUSc9X2c80KVTi+GA= github.com/tidwall/match v1.1.1/go.mod h1:eRSPERbgtNPcGhD8UCthc6PmLEQXEWd3PRB5JTxsfmM= github.com/tidwall/pretty v1.2.0 h1:RWIZEg2iJ8/g6fDDYzMpobmaoGh5OLl4AXtGUGPcqCs= @@ -1210,8 +1219,8 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= golang.org/x/crypto v0.9.0/go.mod h1:yrmDGqONDYtNj3tH8X9dzUun2m2lzPa9ngI6/RUPGR0= -golang.org/x/crypto v0.27.0 h1:GXm2NjJrPaiv/h1tb2UH8QfgC/hOf/+z0p6PT8o1w7A= -golang.org/x/crypto v0.27.0/go.mod h1:1Xngt8kV6Dvbssa53Ziq6Eqn0HqbZi5Z6R0ZpwQzt70= +golang.org/x/crypto v0.29.0 h1:L5SG1JTTXupVV3n6sUqMTeWbjAyfPwoda2DLX8J8FrQ= +golang.org/x/crypto v0.29.0/go.mod h1:+F4F4N5hv6v38hfeYwTdx20oUvLLc+QfrE9Ax9HtgRg= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -1252,8 +1261,8 @@ golang.org/x/mod v0.4.1/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.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.19.0 h1:fEdghXQSo20giMthA7cd28ZC+jts4amQ3YMXiP5oMQ8= -golang.org/x/mod v0.19.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= +golang.org/x/mod v0.21.0 h1:vvrHzRwRfVKSiLrG+d4FMl/Qi4ukBCE6kZlTUkDYRT0= +golang.org/x/mod v0.21.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= 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= @@ -1317,8 +1326,8 @@ golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg= -golang.org/x/net v0.29.0 h1:5ORfpBpCs4HzDYoodCDBbwHzdR5UrLBZ3sOnUJmFoHo= -golang.org/x/net v0.29.0/go.mod h1:gLkgy8jTGERgjzMic6DS9+SP0ajcu6Xu3Orq/SpETg0= +golang.org/x/net v0.31.0 h1:68CPQngjLL0r2AlUKiSxtQFKvzRVbnzLwMUn5SzcLHo= +golang.org/x/net v0.31.0/go.mod h1:P4fl1q7dY2hnZFxEk4pPSkDHF+QqjitcnDjUQyMM+pM= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -1344,8 +1353,8 @@ golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094/go.mod h1:h4gKUeWbJ4rQPri golang.org/x/oauth2 v0.0.0-20220909003341-f21342109be1/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.1.0/go.mod h1:G9FE4dLTsbXUu90h/Pf85g4w1D+SSAgR+q46nJZ8M4A= -golang.org/x/oauth2 v0.21.0 h1:tsimM75w1tF/uws5rbeHzIWxEqElMehnc+iW793zsZs= -golang.org/x/oauth2 v0.21.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= +golang.org/x/oauth2 v0.23.0 h1:PbgcYx2W7i4LvjJWEbf0ngHV6qJYr86PkAV3bXdLEbs= +golang.org/x/oauth2 v0.23.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= 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= @@ -1361,8 +1370,8 @@ golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.8.0 h1:3NFvSEYkUoMifnESzZl15y791HH1qU2xm6eCJU5ZPXQ= -golang.org/x/sync v0.8.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.9.0 h1:fEo0HyrW1GIgZdpbhCRO0PkJajUS5H9IFUztCgEo2jQ= +golang.org/x/sync v0.9.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/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= @@ -1372,7 +1381,6 @@ golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190130150945-aca44879d564/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-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1465,16 +1473,17 @@ 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.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34= -golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.27.0 h1:wBqf8DvsY9Y/2P8gAfPDEYNuS30J4lPHJxXSb/nJZ+s= +golang.org/x/sys v0.27.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= -golang.org/x/term v0.24.0 h1:Mh5cbb+Zk2hqqXNO7S1iTjEphVL+jb8ZWaqh/g+JWkM= -golang.org/x/term v0.24.0/go.mod h1:lOBK/LVxemqiMij05LGJ0tzNr8xlmwBRJ81PX6wVLH8= +golang.org/x/term v0.26.0 h1:WEQa6V3Gja/BhNxg540hBip/kkaYtRg3cxg4oXSw4AU= +golang.org/x/term v0.26.0/go.mod h1:Si5m1o57C5nBNQo5z1iq+XDijt21BDBDp2bK0QI8e3E= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= 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= @@ -1489,8 +1498,8 @@ golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= -golang.org/x/text v0.18.0 h1:XvMDiNzPAl0jr17s6W9lcaIhGUfUORdGCNsuLmPG224= -golang.org/x/text v0.18.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY= +golang.org/x/text v0.20.0 h1:gK/Kv2otX8gz+wn7Rmb3vT96ZwuoxnQlY+HlJVj7Qug= +golang.org/x/text v0.20.0/go.mod h1:D4IsuqiFMhST5bX19pQ9ikHC2GsaKyk/oF+pn3ducp4= 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-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -1560,8 +1569,8 @@ golang.org/x/tools v0.1.4/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.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= -golang.org/x/tools v0.23.0 h1:SGsXPZ+2l4JsgaCKkx+FQ9YZ5XEtA1GZYuoDjenLjvg= -golang.org/x/tools v0.23.0/go.mod h1:pnu6ufv6vQkll6szChhK3C3L/ruaIv5eBeztNG8wtsI= +golang.org/x/tools v0.26.0 h1:v/60pFQmzmT9ExmjDv2gGIfi3OqfKoEP6I5+umXlbnQ= +golang.org/x/tools v0.26.0/go.mod h1:TPVVj70c7JJ3WCazhD8OdXcZg/og+b9+tH/KxylGwH0= 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= @@ -1739,10 +1748,10 @@ google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= google.golang.org/genproto v0.0.0-20240701130421-f6361c86f094 h1:6whtk83KtD3FkGrVb2hFXuQ+ZMbCNdakARIn/aHMmG8= google.golang.org/genproto v0.0.0-20240701130421-f6361c86f094/go.mod h1:Zs4wYw8z1zr6RNF4cwYb31mvN/EGaKAdQjNCF3DW6K4= -google.golang.org/genproto/googleapis/api v0.0.0-20240624140628-dc46fd24d27d h1:Aqf0fiIdUQEj0Gn9mKFFXoQfTTEaNopWpfVyYADxiSg= -google.golang.org/genproto/googleapis/api v0.0.0-20240624140628-dc46fd24d27d/go.mod h1:Od4k8V1LQSizPRUK4OzZ7TBE/20k+jPczUDAEyvn69Y= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5 h1:SbSDUWW1PAO24TNpLdeheoYPd7kllICcLU52x6eD4kQ= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY= +google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 h1:hjSy6tcFQZ171igDaN5QHOw2n6vx40juYbC/x67CEhc= +google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:qpvKtACPCQhAdu3PyQgV4l3LMXZEtft7y8QcarRsp9I= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 h1:pPJltXNxVzT4pK9yD8vR9X75DaWYYmLGMsEvBfFQZzQ= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:UqMtugtsSgubUsoxbuAoiCXvqvErP7Gf0so0mK9tHxU= 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.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= @@ -1784,8 +1793,8 @@ google.golang.org/grpc v1.48.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACu google.golang.org/grpc v1.49.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= -google.golang.org/grpc v1.66.2 h1:3QdXkuq3Bkh7w+ywLdLvM56cmGvQHUMZpiCzt6Rqaoo= -google.golang.org/grpc v1.66.2/go.mod h1:s3/l6xSSCURdVfAnL+TqCNMyTDAGN6+lZeVxnZR128Y= +google.golang.org/grpc v1.68.0 h1:aHQeeJbo8zAkAa3pRzrVjZlbz6uSfeOXlJNQM0RAbz0= +google.golang.org/grpc v1.68.0/go.mod h1:fmSPC5AsjSBCK54MyHRx48kpOti1/jRfOlwEWywNjWA= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= 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= @@ -1803,8 +1812,8 @@ google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQ google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.30.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= -google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= +google.golang.org/protobuf v1.35.2 h1:8Ar7bF+apOIoThw1EdZl0p1oWvMqTHmpA2fRTyZO8io= +google.golang.org/protobuf v1.35.2/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= 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/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -1852,6 +1861,7 @@ honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9 nhooyr.io/websocket v1.8.6/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= nhooyr.io/websocket v1.8.7 h1:usjR2uOr/zjjkVMy0lW+PPohFok7PCow5sDjLgX4P4g= nhooyr.io/websocket v1.8.7/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= +nullprogram.com/x/optparse v1.0.0/go.mod h1:KdyPE+Igbe0jQUrVfMqDMeJQIJZEuyV7pjYmp6pbG50= pgregory.net/rapid v1.1.0 h1:CMa0sjHSru3puNx+J0MIAuiiEV4N0qj8/cMWGBBCsjw= pgregory.net/rapid v1.1.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= diff --git a/go.work b/go.work deleted file mode 100644 index f1c98a24..00000000 --- a/go.work +++ /dev/null @@ -1,8 +0,0 @@ -go 1.22.5 - -use ( - . - example_chain -) - -replace github.com/cosmos/cosmos-sdk => github.com/evmos/cosmos-sdk v0.50.9-evmos diff --git a/go.work.sum b/go.work.sum deleted file mode 100644 index 783978a2..00000000 --- a/go.work.sum +++ /dev/null @@ -1,2689 +0,0 @@ -4d63.com/gocheckcompilerdirectives v1.2.1 h1:AHcMYuw56NPjq/2y615IGg2kYkBdTvOaojYCBcRE7MA= -4d63.com/gocheckcompilerdirectives v1.2.1/go.mod h1:yjDJSxmDTtIHHCqX0ufRYZDL6vQtMG7tJdKVeWwsqvs= -4d63.com/gochecknoglobals v0.1.0 h1:zeZSRqj5yCg28tCkIV/z/lWbwvNm5qnKVS15PI8nhD0= -4d63.com/gochecknoglobals v0.1.0/go.mod h1:wfdC5ZjKSPr7CybKEcgJhUOgeAQW1+7WcyK8OvUilfo= -4d63.com/gochecknoglobals v0.2.1 h1:1eiorGsgHOFOuoOiJDy2psSrQbRdIHrlge0IJIkUgDc= -4d63.com/gochecknoglobals v0.2.1/go.mod h1:KRE8wtJB3CXCsb1xy421JfTHIIbmT3U5ruxw2Qu8fSU= -cel.dev/expr v0.15.0 h1:O1jzfJCQBfL5BFoYktaxwIhuttaQPsVWerH9/EEKx0w= -cel.dev/expr v0.15.0/go.mod h1:TRSuuV7DlVCE/uwv5QbAiW/v8l5O8C4eEPHeu7gf7Sg= -cloud.google.com/go v0.0.0-20170206221025-ce650573d812/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= -cloud.google.com/go v0.75.0/go.mod h1:VGuuCn7PG0dwsd5XPVm2Mm3wlh3EL55/79EKB6hlPTY= -cloud.google.com/go v0.110.10/go.mod h1:v1OoFqYxiBkUrruItNM3eT4lLByNjxmJSV/xDKJNnic= -cloud.google.com/go v0.112.0/go.mod h1:3jEEVwZ/MHU4djK5t5RHuKOA/GbLddgTdVubX1qnPD4= -cloud.google.com/go v0.112.2/go.mod h1:iEqjp//KquGIJV/m+Pk3xecgKNhV+ry+vVTsy4TbDms= -cloud.google.com/go/accessapproval v1.7.5 h1:uzmAMSgYcnlHa9X9YSQZ4Q1wlfl4NNkZyQgho1Z6p04= -cloud.google.com/go/accessapproval v1.7.5/go.mod h1:g88i1ok5dvQ9XJsxpUInWWvUBrIZhyPDPbk4T01OoJ0= -cloud.google.com/go/accessapproval v1.7.8 h1:4P74qfEnwspOs5lEOn6o6lCkleNQfD0b+O/D1kY7hO0= -cloud.google.com/go/accessapproval v1.7.8/go.mod h1:7xkMRHJmgTAb08b6mKdyYTfPBTwiw4XvnI1l+jTvrdk= -cloud.google.com/go/accesscontextmanager v1.8.5 h1:2GLNaNu9KRJhJBFTIVRoPwk6xE5mUDgD47abBq4Zp/I= -cloud.google.com/go/accesscontextmanager v1.8.5/go.mod h1:TInEhcZ7V9jptGNqN3EzZ5XMhT6ijWxTGjzyETwmL0Q= -cloud.google.com/go/accesscontextmanager v1.8.8 h1:MJuGDYmvtV7lcaQp2NLOTtqRR16V+v/PM+DyvVc1u1w= -cloud.google.com/go/accesscontextmanager v1.8.8/go.mod h1:XmIMhWxcTG9GTEAOBm3geKRKdVxM35FY10FSBS8zaDs= -cloud.google.com/go/aiplatform v1.60.0 h1:0cSrii1ZeLr16MbBoocyy5KVnrSdiQ3KN/vtrTe7RqE= -cloud.google.com/go/aiplatform v1.60.0/go.mod h1:eTlGuHOahHprZw3Hio5VKmtThIOak5/qy6pzdsqcQnM= -cloud.google.com/go/aiplatform v1.68.0 h1:EPPqgHDJpBZKRvv+OsB3cr0jYz3EL2pZ+802rBPcG8U= -cloud.google.com/go/aiplatform v1.68.0/go.mod h1:105MFA3svHjC3Oazl7yjXAmIR89LKhRAeNdnDKJczME= -cloud.google.com/go/analytics v0.23.0 h1:Q+y94XH84jM8SK8O7qiY/PJRexb6n7dRbQ6PiUa4YGM= -cloud.google.com/go/analytics v0.23.0/go.mod h1:YPd7Bvik3WS95KBok2gPXDqQPHy08TsCQG6CdUCb+u0= -cloud.google.com/go/analytics v0.23.3 h1:LbZ2MgTv7QqT/E8IQl+cEKQEg/I9nHVdPg2w6HvwILA= -cloud.google.com/go/analytics v0.23.3/go.mod h1:oZsWmFn+JlADKC2gc6/LYXYPh6gx+K14tymvQuT3sS4= -cloud.google.com/go/apigateway v1.6.5 h1:sPXnpk+6TneKIrjCjcpX5YGsAKy3PTdpIchoj8/74OE= -cloud.google.com/go/apigateway v1.6.5/go.mod h1:6wCwvYRckRQogyDDltpANi3zsCDl6kWi0b4Je+w2UiI= -cloud.google.com/go/apigateway v1.6.8 h1:pLCrbTjAsgIZx2izq7UlA8k8HVAnvuwXpLdL1llZjaA= -cloud.google.com/go/apigateway v1.6.8/go.mod h1:j383LuqwSSi7WFJwQj8zRTsU9vCiR+GkWUHlJ6GerR0= -cloud.google.com/go/apigeeconnect v1.6.5 h1:CrfIKv9Go3fh/QfQgisU3MeP90Ww7l/sVGmr3TpECo8= -cloud.google.com/go/apigeeconnect v1.6.5/go.mod h1:MEKm3AiT7s11PqTfKE3KZluZA9O91FNysvd3E6SJ6Ow= -cloud.google.com/go/apigeeconnect v1.6.8 h1:5lVElASnQcO6xQ+gLA4HxKJ1/75x/QyPoeGAIbiAQYE= -cloud.google.com/go/apigeeconnect v1.6.8/go.mod h1:+XjRq6uKsjrswBCZf+BCWY7u0gJ9mRP9c34qqGVQBAw= -cloud.google.com/go/apigeeregistry v0.8.3 h1:C+QU2K+DzDjk4g074ouwHQGkoff1h5OMQp6sblCVreQ= -cloud.google.com/go/apigeeregistry v0.8.3/go.mod h1:aInOWnqF4yMQx8kTjDqHNXjZGh/mxeNlAf52YqtASUs= -cloud.google.com/go/apigeeregistry v0.8.6 h1:C/BG5lrTisXFsoEpwKJtmpxdB934yzGRV49VxTaauW8= -cloud.google.com/go/apigeeregistry v0.8.6/go.mod h1:Pvk3LJqhxKgkTyynwYK7MuJCbkTG0/JbisSazyu77FM= -cloud.google.com/go/apikeys v0.5.0 h1:+77+/BhFuU476/s78kYiWHObxaYBHsC6Us+Gd7W9pJ4= -cloud.google.com/go/apikeys v0.5.0/go.mod h1:5aQfwY4D+ewMMWScd3hm2en3hCj+BROlyrt3ytS7KLI= -cloud.google.com/go/appengine v1.8.5 h1:l2SviT44zWQiOv8bPoMBzW0vOcMO22iO0s+nVtVhdts= -cloud.google.com/go/appengine v1.8.5/go.mod h1:uHBgNoGLTS5di7BvU25NFDuKa82v0qQLjyMJLuPQrVo= -cloud.google.com/go/appengine v1.8.8 h1:Nzc51iOiW9eqH3Nifc5/MU3qHN618+9DXudXLHiEXfE= -cloud.google.com/go/appengine v1.8.8/go.mod h1:l9QQeNodTtyhYz8Sd3cTZrocgj4y7yap5t6b9XD74HQ= -cloud.google.com/go/area120 v0.8.5 h1:vTs08KPLN/iMzTbxpu5ciL06KcsrVPMjz4IwcQyZ4uY= -cloud.google.com/go/area120 v0.8.5/go.mod h1:BcoFCbDLZjsfe4EkCnEq1LKvHSK0Ew/zk5UFu6GMyA0= -cloud.google.com/go/area120 v0.8.8 h1:Nzoz79LVCv6LkvJ+uxfBgAzJUvlFl32pQIQB5c/yKds= -cloud.google.com/go/area120 v0.8.8/go.mod h1:L/VYdKO0xpgWvRgVwH4fiGIN2wBuBGHu15bSs1FnSRw= -cloud.google.com/go/artifactregistry v1.14.7 h1:W9sVlyb1VRcUf83w7aM3yMsnp4HS4PoyGqYQNG0O5lI= -cloud.google.com/go/artifactregistry v1.14.7/go.mod h1:0AUKhzWQzfmeTvT4SjfI4zjot72EMfrkvL9g9aRjnnM= -cloud.google.com/go/artifactregistry v1.14.10 h1:2f8zwDdIU7wPM3915/Q1VMceZj0ALZgQgU57jqKVLNE= -cloud.google.com/go/artifactregistry v1.14.10/go.mod h1:i1jzotcdypXuEx6oG7+y0moY7TWR+wBaOu6VA3fGefU= -cloud.google.com/go/asset v1.17.2 h1:xgFnBP3luSbUcC9RWJvb3Zkt+y/wW6PKwPHr3ssnIP8= -cloud.google.com/go/asset v1.17.2/go.mod h1:SVbzde67ehddSoKf5uebOD1sYw8Ab/jD/9EIeWg99q4= -cloud.google.com/go/asset v1.19.2 h1:xfcoQJw7TQQ0iAV+RhtwNO80gcBLXFCVbvJlP21aJwM= -cloud.google.com/go/asset v1.19.2/go.mod h1:JJbMl9L3cWvgiBC0vRUl/uUJ1KLJD1zw4pKRsV/wQSI= -cloud.google.com/go/assuredworkloads v1.11.5 h1:gCrN3IyvqY3cP0wh2h43d99CgH3G+WYs9CeuFVKChR8= -cloud.google.com/go/assuredworkloads v1.11.5/go.mod h1:FKJ3g3ZvkL2D7qtqIGnDufFkHxwIpNM9vtmhvt+6wqk= -cloud.google.com/go/assuredworkloads v1.11.8 h1:3fASwFmEeUokum4LLGwZ5xB1Jh3QHgLkHtEqGpyJag4= -cloud.google.com/go/assuredworkloads v1.11.8/go.mod h1:VDrDAh06vxYbpTJQEcZf9ueXb2S++Bm3F2Tw+liBJBk= -cloud.google.com/go/auth v0.3.0/go.mod h1:lBv6NKTWp8E3LPzmO1TbiiRKc4drLOfHsgmlH9ogv5w= -cloud.google.com/go/auth v0.5.1/go.mod h1:vbZT8GjzDf3AVqCcQmqeeM32U9HBFc32vVVAbwDsa6s= -cloud.google.com/go/automl v1.13.5 h1:ijiJy9sYWh75WrqImXsfWc1e3HR3iO+ef9fvW03Ig/4= -cloud.google.com/go/automl v1.13.5/go.mod h1:MDw3vLem3yh+SvmSgeYUmUKqyls6NzSumDm9OJ3xJ1Y= -cloud.google.com/go/automl v1.13.8 h1:zo3dYyuUqKltYbdhIG08poncaYTwJdlgLvKYM7QiwTE= -cloud.google.com/go/automl v1.13.8/go.mod h1:8O5i0OHiqRSnucux40rSMOfnBIarGxLMTQMOjpGxbB8= -cloud.google.com/go/baremetalsolution v1.2.4 h1:LFydisRmS7hQk9P/YhekwuZGqb45TW4QavcrMToWo5A= -cloud.google.com/go/baremetalsolution v1.2.4/go.mod h1:BHCmxgpevw9IEryE99HbYEfxXkAEA3hkMJbYYsHtIuY= -cloud.google.com/go/baremetalsolution v1.2.7 h1:8MlSaPL3BdAlvE9ERayO0JtlxtA3iYa8p+K7LW6J/0Q= -cloud.google.com/go/baremetalsolution v1.2.7/go.mod h1:KvhbjdZzE1SR/GpgsE90pNWiglDY1vjzClYHB3NZseE= -cloud.google.com/go/batch v1.8.0 h1:2HK4JerwVaIcCh/lJiHwh6+uswPthiMMWhiSWLELayk= -cloud.google.com/go/batch v1.8.0/go.mod h1:k8V7f6VE2Suc0zUM4WtoibNrA6D3dqBpB+++e3vSGYc= -cloud.google.com/go/batch v1.8.8 h1:Ve5iNh24Kc3d5atz+sJ8o8HZrwxkl5fSm11Ve5Jg2f4= -cloud.google.com/go/batch v1.8.8/go.mod h1:PvTk3Rq5mf6RFcQtF9MZEsv9LG9aUjlUuqlq6IJ866o= -cloud.google.com/go/beyondcorp v1.0.4 h1:qs0J0O9Ol2h1yA0AU+r7l3hOCPzs2MjE1d6d/kaHIKo= -cloud.google.com/go/beyondcorp v1.0.4/go.mod h1:Gx8/Rk2MxrvWfn4WIhHIG1NV7IBfg14pTKv1+EArVcc= -cloud.google.com/go/beyondcorp v1.0.7 h1:rmYOeaeYiD19aiNp56okLDWGgzvz943h6P7/dkHi4Tc= -cloud.google.com/go/beyondcorp v1.0.7/go.mod h1:qiWZ0SIhhAB7wn5Vun0bNKdexl596QclVwWEUL+keK8= -cloud.google.com/go/bigquery v1.59.1 h1:CpT+/njKuKT3CEmswm6IbhNu9u35zt5dO4yPDLW+nG4= -cloud.google.com/go/bigquery v1.59.1/go.mod h1:VP1UJYgevyTwsV7desjzNzDND5p6hZB+Z8gZJN1GQUc= -cloud.google.com/go/bigquery v1.61.0 h1:w2Goy9n6gh91LVi6B2Sc+HpBl8WbWhIyzdvVvrAuEIw= -cloud.google.com/go/bigquery v1.61.0/go.mod h1:PjZUje0IocbuTOdq4DBOJLNYB0WF3pAKBHzAYyxCwFo= -cloud.google.com/go/billing v1.18.2 h1:oWUEQvuC4JvtnqLZ35zgzdbuHt4Itbftvzbe6aEyFdE= -cloud.google.com/go/billing v1.18.2/go.mod h1:PPIwVsOOQ7xzbADCwNe8nvK776QpfrOAUkvKjCUcpSE= -cloud.google.com/go/billing v1.18.6 h1:PDhxE/EhGGgM/HYKvjrGlxi9Sa0J57q3Qrp+C/JnxG0= -cloud.google.com/go/billing v1.18.6/go.mod h1:3aQtpAKmI0wPI4Dcele7cp87jg59EjOA37y7iGrRLIc= -cloud.google.com/go/binaryauthorization v1.8.1 h1:1jcyh2uIUwSZkJ/JmL8kd5SUkL/Krbv8zmYLEbAz6kY= -cloud.google.com/go/binaryauthorization v1.8.1/go.mod h1:1HVRyBerREA/nhI7yLang4Zn7vfNVA3okoAR9qYQJAQ= -cloud.google.com/go/binaryauthorization v1.8.4 h1:ZgCrxKEkyt4A0m4VjY3Jso9EBTzG2r2EihS/yI3XlnA= -cloud.google.com/go/binaryauthorization v1.8.4/go.mod h1:q0t7+U6A4mv7UAtps89kiJ8TlSAIACUJABZH7jE+7uk= -cloud.google.com/go/certificatemanager v1.7.5 h1:UMBr/twXvH3jcT5J5/YjRxf2tvwTYIfrpemTebe0txc= -cloud.google.com/go/certificatemanager v1.7.5/go.mod h1:uX+v7kWqy0Y3NG/ZhNvffh0kuqkKZIXdvlZRO7z0VtM= -cloud.google.com/go/certificatemanager v1.8.2 h1:NI7jAz5rIJxwKwcfowmqo9zCVY4mYaCcQo/fdpl2dK0= -cloud.google.com/go/certificatemanager v1.8.2/go.mod h1:x/OhbhxXrbAzPfLLN/tECrkgfnfg6qr6decH1V21/kQ= -cloud.google.com/go/channel v1.17.5 h1:/omiBnyFjm4S1ETHoOmJbL7LH7Ljcei4rYG6Sj3hc80= -cloud.google.com/go/channel v1.17.5/go.mod h1:FlpaOSINDAXgEext0KMaBq/vwpLMkkPAw9b2mApQeHc= -cloud.google.com/go/channel v1.17.8 h1:tSv4Wtk7moyJ5++exxRTefitVTxbOrqm2IcGQvMkGo0= -cloud.google.com/go/channel v1.17.8/go.mod h1:xWbsExBg6rzMyUtQa2oaX8n3sdROQuWXLNoZp8X7ssI= -cloud.google.com/go/cloudbuild v1.15.1 h1:ZB6oOmJo+MTov9n629fiCrO9YZPOg25FZvQ7gIHu5ng= -cloud.google.com/go/cloudbuild v1.15.1/go.mod h1:gIofXZSu+XD2Uy+qkOrGKEx45zd7s28u/k8f99qKals= -cloud.google.com/go/cloudbuild v1.16.2 h1:y24O8sDG1vxs3l0Zswjxow29csDnIPnorjRud6BGXmI= -cloud.google.com/go/cloudbuild v1.16.2/go.mod h1:CJuhrizzeQ79ryNUO0d227lHf5lqigvDngl4hvYwXiw= -cloud.google.com/go/clouddms v1.7.4 h1:Sr0Zo5EAcPQiCBgHWICg3VGkcdS/LLP1d9SR7qQBM/s= -cloud.google.com/go/clouddms v1.7.4/go.mod h1:RdrVqoFG9RWI5AvZ81SxJ/xvxPdtcRhFotwdE79DieY= -cloud.google.com/go/clouddms v1.7.7 h1:W+DQ0z9HCgdKvB2BacA5lb1qX/AO+LjIUBxXkM1iDvQ= -cloud.google.com/go/clouddms v1.7.7/go.mod h1:ikAo+Ekli1/xPaZvuP/9rmsgd34oEk6OndgNEdC2KRA= -cloud.google.com/go/cloudtasks v1.12.6 h1:EUt1hIZ9bLv8Iz9yWaCrqgMnIU+Tdh0yXM1MMVGhjfE= -cloud.google.com/go/cloudtasks v1.12.6/go.mod h1:b7c7fe4+TJsFZfDyzO51F7cjq7HLUlRi/KZQLQjDsaY= -cloud.google.com/go/cloudtasks v1.12.9 h1:gTNdEcNNIJV5LBilfHhgc2NOCrpRk04qvWwjbzW27oU= -cloud.google.com/go/cloudtasks v1.12.9/go.mod h1:ep1IV7Vud6LNy9JjJiYCcb/or8SO2h/He1gPQgF5Uqw= -cloud.google.com/go/compute v1.23.3/go.mod h1:VCgBUoMnIVIR0CscqQiPJLAG25E3ZRZMzcFZeQ+h8CI= -cloud.google.com/go/compute v1.23.4/go.mod h1:/EJMj55asU6kAFnuZET8zqgwgJ9FvXWXOkkfQZa4ioI= -cloud.google.com/go/compute v1.24.0 h1:phWcR2eWzRJaL/kOiJwfFsPs4BaKq1j6vnpZrc1YlVg= -cloud.google.com/go/compute v1.24.0/go.mod h1:kw1/T+h/+tK2LJK0wiPPx1intgdAM3j/g3hFDlscY40= -cloud.google.com/go/compute v1.25.1 h1:ZRpHJedLtTpKgr3RV1Fx23NuaAEN1Zfx9hw1u4aJdjU= -cloud.google.com/go/compute v1.25.1/go.mod h1:oopOIR53ly6viBYxaDhBfJwzUAxf1zE//uf3IB011ls= -cloud.google.com/go/compute v1.27.1 h1:0WbBLIPNANheCRZ4h8QhgzjN53KMutbiVBOLtPiVzBU= -cloud.google.com/go/compute v1.27.1/go.mod h1:UVWm+bWKEKoM+PW2sZycP1Jgk3NhKwR2Iy2Cnp/G40I= -cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= -cloud.google.com/go/contactcenterinsights v1.13.0 h1:6Vs/YnDG5STGjlWMEjN/xtmft7MrOTOnOZYUZtGTx0w= -cloud.google.com/go/contactcenterinsights v1.13.0/go.mod h1:ieq5d5EtHsu8vhe2y3amtZ+BE+AQwX5qAy7cpo0POsI= -cloud.google.com/go/contactcenterinsights v1.13.3 h1:Yd37VLbMokg7mlcf5azZ2cKdivibc51r1DSkIYcuwzE= -cloud.google.com/go/contactcenterinsights v1.13.3/go.mod h1:W7J0KTaHlvbL4l0ZkoTmgkKRPN3LxkdGSVQnv2CQ9js= -cloud.google.com/go/container v1.31.0 h1:MAaNH7VRNPWEhvqOypq2j+7ONJKrKzon4v9nS3nLZe0= -cloud.google.com/go/container v1.31.0/go.mod h1:7yABn5s3Iv3lmw7oMmyGbeV6tQj86njcTijkkGuvdZA= -cloud.google.com/go/container v1.37.1 h1:9g/2zHz4yHeNPNCRsghWBVoZKcGxVaIEb9T0DXAg5gc= -cloud.google.com/go/container v1.37.1/go.mod h1:8zwisvfdwqsXB/0TSxoUhTrfTrlfDV0pK9hcDtyFQ1c= -cloud.google.com/go/containeranalysis v0.11.4 h1:doJ0M1ljS4hS0D2UbHywlHGwB7sQLNrt9vFk9Zyi7vY= -cloud.google.com/go/containeranalysis v0.11.4/go.mod h1:cVZT7rXYBS9NG1rhQbWL9pWbXCKHWJPYraE8/FTSYPE= -cloud.google.com/go/containeranalysis v0.11.7 h1:X2qpMlj64GEmT7LX18qMjjTU/n5XOrZtYjUMZqKraes= -cloud.google.com/go/containeranalysis v0.11.7/go.mod h1:1xt9ZDhrB9py0gThDIg0Lq6AXVsFHKbXKYlqNAVhjcc= -cloud.google.com/go/datacatalog v1.19.3 h1:A0vKYCQdxQuV4Pi0LL9p39Vwvg4jH5yYveMv50gU5Tw= -cloud.google.com/go/datacatalog v1.19.3/go.mod h1:ra8V3UAsciBpJKQ+z9Whkxzxv7jmQg1hfODr3N3YPJ4= -cloud.google.com/go/datacatalog v1.20.2 h1:6LFlVev1D+Eoh8Ma6C3s3vgNqct97FdmW74Med4dfNs= -cloud.google.com/go/datacatalog v1.20.2/go.mod h1:OfoVR0QchMp2iwull28uaCkXsULClrVCe/Y5aBhwJpg= -cloud.google.com/go/dataflow v0.9.5 h1:RYHtcPhmE664+F0Je46p+NvFbG8z//KCXp+uEqB4jZU= -cloud.google.com/go/dataflow v0.9.5/go.mod h1:udl6oi8pfUHnL0z6UN9Lf9chGqzDMVqcYTcZ1aPnCZQ= -cloud.google.com/go/dataflow v0.9.8 h1:5ClJS5aKvoxzclKVhHtK6KBujXgIZM+oABAtP0+ECCQ= -cloud.google.com/go/dataflow v0.9.8/go.mod h1:0doO1EqzYcU/EAt/BsCZl+iOd9i/FwNGon6IgDBxAJU= -cloud.google.com/go/dataform v0.9.2 h1:5e4eqGrd0iDTCg4Q+VlAao5j2naKAA7xRurNtwmUknU= -cloud.google.com/go/dataform v0.9.2/go.mod h1:S8cQUwPNWXo7m/g3DhWHsLBoufRNn9EgFrMgne2j7cI= -cloud.google.com/go/dataform v0.9.5 h1:EhS2u65efQ2Wi3/RC+0rHxTno9IwL92ZqesBj7v+WRA= -cloud.google.com/go/dataform v0.9.5/go.mod h1:5FCHfsQNNmVvQJeI5XP7ftiOPlgHmYz4NUUhmCPrHag= -cloud.google.com/go/datafusion v1.7.5 h1:HQ/BUOP8OIGJxuztpYvNvlb+/U+/Bfs9SO8tQbh61fk= -cloud.google.com/go/datafusion v1.7.5/go.mod h1:bYH53Oa5UiqahfbNK9YuYKteeD4RbQSNMx7JF7peGHc= -cloud.google.com/go/datafusion v1.7.8 h1:RKm+n4ri+Y5XhP065FVX2Wv/G90couln8If+fCSS6j8= -cloud.google.com/go/datafusion v1.7.8/go.mod h1:VVkTWac1XVCVdf2nzlU68OvoDO7uc0E58pR1Q5zq8JQ= -cloud.google.com/go/datalabeling v0.8.5 h1:GpIFRdm0qIZNsxqURFJwHt0ZBJZ0nF/mUVEigR7PH/8= -cloud.google.com/go/datalabeling v0.8.5/go.mod h1:IABB2lxQnkdUbMnQaOl2prCOfms20mcPxDBm36lps+s= -cloud.google.com/go/datalabeling v0.8.8 h1:yZ4ki5DtBD9aO8HluxmF9kl+v5Ir6yzfQNhh3J4vHiU= -cloud.google.com/go/datalabeling v0.8.8/go.mod h1:68L3luQpu2/KIQxK+B8ChR7c8id8wT7/txJNddsHpq0= -cloud.google.com/go/dataplex v1.14.2 h1:fxIfdU8fxzR3clhOoNI7XFppvAmndxDu1AMH+qX9WKQ= -cloud.google.com/go/dataplex v1.14.2/go.mod h1:0oGOSFlEKef1cQeAHXy4GZPB/Ife0fz/PxBf+ZymA2U= -cloud.google.com/go/dataplex v1.17.0 h1:TpRuoH+tLKQOvUWHgxwnvSPgKkZYcWUmcJtcanQH7CI= -cloud.google.com/go/dataplex v1.17.0/go.mod h1:pSJPr0n+iu2/YKre2cRDwvdLrVg8EwGg483LB0AxA/g= -cloud.google.com/go/dataproc v1.12.0 h1:W47qHL3W4BPkAIbk4SWmIERwsWBaNnWm0P2sdx3YgGU= -cloud.google.com/go/dataproc v1.12.0/go.mod h1:zrF3aX0uV3ikkMz6z4uBbIKyhRITnxvr4i3IjKsKrw4= -cloud.google.com/go/dataproc/v2 v2.4.0 h1:/u81Fd+BvCLp+xjctI1DiWVJn6cn9/s3Akc8xPH02yk= -cloud.google.com/go/dataproc/v2 v2.4.0/go.mod h1:3B1Ht2aRB8VZIteGxQS/iNSJGzt9+CA0WGnDVMEm7Z4= -cloud.google.com/go/dataproc/v2 v2.5.0 h1:9+aIbMiJxrDZvGUYz6moDn8AmUV/zUZyp/B3xJlH0ms= -cloud.google.com/go/dataproc/v2 v2.5.0/go.mod h1:VV8BisKb9NpQsd/8XOriS5K0wpIlecTBrBm0ntvQ/g0= -cloud.google.com/go/dataqna v0.8.5 h1:9ybXs3nr9BzxSGC04SsvtuXaHY0qmJSLIpIAbZo9GqQ= -cloud.google.com/go/dataqna v0.8.5/go.mod h1:vgihg1mz6n7pb5q2YJF7KlXve6tCglInd6XO0JGOlWM= -cloud.google.com/go/dataqna v0.8.8 h1:r1dGgl8RJQA8rGz91lkktAvuy6YzvPXsj77WqIHoUuU= -cloud.google.com/go/dataqna v0.8.8/go.mod h1:DXb55JvGZN6EH3gvwu0JEbJvadxXOGL6grkhqP9y3QA= -cloud.google.com/go/datastore v1.15.0 h1:0P9WcsQeTWjuD1H14JIY7XQscIPQ4Laje8ti96IC5vg= -cloud.google.com/go/datastore v1.15.0/go.mod h1:GAeStMBIt9bPS7jMJA85kgkpsMkvseWWXiaHya9Jes8= -cloud.google.com/go/datastore v1.17.1 h1:6Me8ugrAOAxssGhSo8im0YSuy4YvYk4mbGvCadAH5aE= -cloud.google.com/go/datastore v1.17.1/go.mod h1:mtzZ2HcVtz90OVrEXXGDc2pO4NM1kiBQy8YV4qGe0ZM= -cloud.google.com/go/datastream v1.10.4 h1:o1QDKMo/hk0FN7vhoUQURREuA0rgKmnYapB+1M+7Qz4= -cloud.google.com/go/datastream v1.10.4/go.mod h1:7kRxPdxZxhPg3MFeCSulmAJnil8NJGGvSNdn4p1sRZo= -cloud.google.com/go/datastream v1.10.7 h1:IgjUEkJVecIPALsbJM/nGd1yuHhOfuME42vMkHGPbKI= -cloud.google.com/go/datastream v1.10.7/go.mod h1:wNlOxMpOCP/uaV+0O0PC5wlCmpHGDUhyRGQ5RBZAvSw= -cloud.google.com/go/deploy v1.17.1 h1:m27Ojwj03gvpJqCbodLYiVmE9x4/LrHGGMjzc0LBfM4= -cloud.google.com/go/deploy v1.17.1/go.mod h1:SXQyfsXrk0fBmgBHRzBjQbZhMfKZ3hMQBw5ym7MN/50= -cloud.google.com/go/deploy v1.19.1 h1:UHNCNceW1SN4nnQTautp2yJxYA65jQ5aTG3kAPE4xAk= -cloud.google.com/go/deploy v1.19.1/go.mod h1:y2DyvlK02aUlUFjDwTbEfOMTH29IGAjSniSGw+MceVM= -cloud.google.com/go/dialogflow v1.49.0 h1:KqG0oxGE71qo0lRVyAoeBozefCvsMfcDzDjoLYSY0F4= -cloud.google.com/go/dialogflow v1.49.0/go.mod h1:dhVrXKETtdPlpPhE7+2/k4Z8FRNUp6kMV3EW3oz/fe0= -cloud.google.com/go/dialogflow v1.54.1 h1:tPHEEtGY3U5w2XzwHJm0M4WsoQpfH9UTnC+R+5W0FFY= -cloud.google.com/go/dialogflow v1.54.1/go.mod h1:SDAvjPxEwb+DTRlxkCu0B5qilt0HtaV2GeoUBysvgCQ= -cloud.google.com/go/dlp v1.11.2 h1:lTipOuJaSjlYnnotPMbEhKURLC6GzCMDDzVbJAEbmYM= -cloud.google.com/go/dlp v1.11.2/go.mod h1:9Czi+8Y/FegpWzgSfkRlyz+jwW6Te9Rv26P3UfU/h/w= -cloud.google.com/go/dlp v1.14.1 h1:FofFc2f9EvWgwKNwAagq81cyM16BtxBxBpkVvnC5b4c= -cloud.google.com/go/dlp v1.14.1/go.mod h1:nY5sIxqHm2APxYUpAoq8xOMtHLjFyBYUNbYjjnBptqY= -cloud.google.com/go/documentai v1.25.0 h1:lI62GMEEPO6vXJI9hj+G9WjOvnR0hEjvjokrnex4cxA= -cloud.google.com/go/documentai v1.25.0/go.mod h1:ftLnzw5VcXkLItp6pw1mFic91tMRyfv6hHEY5br4KzY= -cloud.google.com/go/documentai v1.30.2 h1:dhg3vefzZtoZgwH8j+FpEPCSH8DzNW/wXi2SL6wpX4w= -cloud.google.com/go/documentai v1.30.2/go.mod h1:nMh79XZZ6dkXWZlh60vmyFPf9AySGM0QCYFJA39I2IU= -cloud.google.com/go/domains v0.9.5 h1:Mml/R6s3vQQvFPpi/9oX3O5dRirgjyJ8cksK8N19Y7g= -cloud.google.com/go/domains v0.9.5/go.mod h1:dBzlxgepazdFhvG7u23XMhmMKBjrkoUNaw0A8AQB55Y= -cloud.google.com/go/domains v0.9.8 h1:p/4SYTrOunrptanJqwKFff81pubajoy6mPan2zKyT+k= -cloud.google.com/go/domains v0.9.8/go.mod h1:CJzupa3+HxdkCSn6hXu0tcdcsbZS2ZNK1zfSA+FqfPM= -cloud.google.com/go/edgecontainer v1.1.5 h1:tBY32km78ScpK2aOP84JoW/+wtpx5WluyPUSEE3270U= -cloud.google.com/go/edgecontainer v1.1.5/go.mod h1:rgcjrba3DEDEQAidT4yuzaKWTbkTI5zAMu3yy6ZWS0M= -cloud.google.com/go/edgecontainer v1.2.2 h1:WT9LZrHsNNbVplz2P+a+RkOgbVGOFcPS4q85rXfkV4M= -cloud.google.com/go/edgecontainer v1.2.2/go.mod h1:PwFM/JBBTJ1pXSNNHD+NCMEhZylPOy1FCXuYCbl7ACk= -cloud.google.com/go/errorreporting v0.3.0 h1:kj1XEWMu8P0qlLhm3FwcaFsUvXChV/OraZwA70trRR0= -cloud.google.com/go/errorreporting v0.3.0/go.mod h1:xsP2yaAp+OAW4OIm60An2bbLpqIhKXdWR/tawvl7QzU= -cloud.google.com/go/essentialcontacts v1.6.6 h1:13eHn5qBnsawxI7mIrv4jRIEmQ1xg0Ztqw5ZGqtUNfA= -cloud.google.com/go/essentialcontacts v1.6.6/go.mod h1:XbqHJGaiH0v2UvtuucfOzFXN+rpL/aU5BCZLn4DYl1Q= -cloud.google.com/go/essentialcontacts v1.6.9 h1:wY9FAjLpJZ15u1/ABHFQqN4pSlCBZIzFS8ap9UjQ9ww= -cloud.google.com/go/essentialcontacts v1.6.9/go.mod h1:wS/7YcnVzn82DqBv9lOQoHZpWOdgwGbWk02QH1460dU= -cloud.google.com/go/eventarc v1.13.4 h1:ORkd6/UV5FIdA8KZQDLNZYKS7BBOrj0p01DXPmT4tE4= -cloud.google.com/go/eventarc v1.13.4/go.mod h1:zV5sFVoAa9orc/52Q+OuYUG9xL2IIZTbbuTHC6JSY8s= -cloud.google.com/go/eventarc v1.13.7 h1:fl6Us+6WkBDIpBTTyQLSfCDYl4GNPmsVJdxsxK+SNQ4= -cloud.google.com/go/eventarc v1.13.7/go.mod h1:yslFvubtw7PovgFr/Gg8GrqcOfJBAU4D5Qveds4vOzA= -cloud.google.com/go/filestore v1.8.1 h1:X5G4y/vrUo1B8Nsz93qSWTMAcM8LXbGUldq33OdcdCw= -cloud.google.com/go/filestore v1.8.1/go.mod h1:MbN9KcaM47DRTIuLfQhJEsjaocVebNtNQhSLhKCF5GM= -cloud.google.com/go/filestore v1.8.4 h1:cvwDVEraGSmlWuJfhJAx3uvWxKyD30x8QwyONlZ8voY= -cloud.google.com/go/filestore v1.8.4/go.mod h1:GnZEiebr0Eru+BALoYDsuOyqSzM4EV7n5HpCaXT0RT8= -cloud.google.com/go/firestore v1.14.0 h1:8aLcKnMPoldYU3YHgu4t2exrKhLQkqaXAGqT0ljrFVw= -cloud.google.com/go/firestore v1.14.0/go.mod h1:96MVaHLsEhbvkBEdZgfN+AS/GIkco1LRpH9Xp9YZfzQ= -cloud.google.com/go/firestore v1.15.0 h1:/k8ppuWOtNuDHt2tsRV42yI21uaGnKDEQnRFeBpbFF8= -cloud.google.com/go/firestore v1.15.0/go.mod h1:GWOxFXcv8GZUtYpWHw/w6IuYNux/BtmeVTMmjrm4yhk= -cloud.google.com/go/functions v1.16.0 h1:IWVylmK5F6hJ3R5zaRW7jI5PrWhCvtBVU4axQLmXSo4= -cloud.google.com/go/functions v1.16.0/go.mod h1:nbNpfAG7SG7Duw/o1iZ6ohvL7mc6MapWQVpqtM29n8k= -cloud.google.com/go/functions v1.16.3 h1:YMVEpuYdW5pc4yVZO7fevlDridaWVXdFEeoUVJ3omY8= -cloud.google.com/go/functions v1.16.3/go.mod h1:Uk3Bu1mv6+f27PHh+yOjMAMB0u4LRkn7dxsdHBZmPKM= -cloud.google.com/go/gaming v1.6.0 h1:PKggmegChZulPW8yvtziF8P9UOuVFwbvylbEucTNups= -cloud.google.com/go/gaming v1.9.0 h1:7vEhFnZmd931Mo7sZ6pJy7uQPDxF7m7v8xtBheG08tc= -cloud.google.com/go/gaming v1.9.0/go.mod h1:Fc7kEmCObylSWLO334NcO+O9QMDyz+TKC4v1D7X+Bc0= -cloud.google.com/go/gkebackup v1.3.5 h1:iuE8KNtTsPOc79qeWoNS8zOWoXPD9SAdOmwgxtlCmh8= -cloud.google.com/go/gkebackup v1.3.5/go.mod h1:KJ77KkNN7Wm1LdMopOelV6OodM01pMuK2/5Zt1t4Tvc= -cloud.google.com/go/gkebackup v1.5.1 h1:o6VzDCSiSF2E2PEWbxl9mMnZibs1hPCc0UkLRD1N0Do= -cloud.google.com/go/gkebackup v1.5.1/go.mod h1:FCz8M70up0yEwLXBmVJRckYoOh9x/eTo8aymJcdrMu4= -cloud.google.com/go/gkeconnect v0.8.5 h1:17d+ZSSXKqG/RwZCq3oFMIWLPI8Zw3b8+a9/BEVlwH0= -cloud.google.com/go/gkeconnect v0.8.5/go.mod h1:LC/rS7+CuJ5fgIbXv8tCD/mdfnlAadTaUufgOkmijuk= -cloud.google.com/go/gkeconnect v0.8.8 h1:sekj1nCVRFM9lRizo/ev+aCscpLQYds3tqzwvWuTix8= -cloud.google.com/go/gkeconnect v0.8.8/go.mod h1:S3UvXOu5vxZmeBU8YkpHMbcjsi9d0HDuJ+fB6ofHwKs= -cloud.google.com/go/gkehub v0.14.5 h1:RboLNFzf9wEMSo7DrKVBlf+YhK/A/jrLN454L5Tz99Q= -cloud.google.com/go/gkehub v0.14.5/go.mod h1:6bzqxM+a+vEH/h8W8ec4OJl4r36laxTs3A/fMNHJ0wA= -cloud.google.com/go/gkehub v0.14.8 h1:GFvRImZSpLg+2K08RD0bkQ/DnXNdy4BMnaUj3ZcpGEg= -cloud.google.com/go/gkehub v0.14.8/go.mod h1:Tdd33Wg3Jeehu4mIt9Fkm/ryy5wtJ8a3bjnzEnuY8UU= -cloud.google.com/go/gkemulticloud v1.1.1 h1:rsSZAGLhyjyE/bE2ToT5fqo1qSW7S+Ubsc9jFOcbhSI= -cloud.google.com/go/gkemulticloud v1.1.1/go.mod h1:C+a4vcHlWeEIf45IB5FFR5XGjTeYhF83+AYIpTy4i2Q= -cloud.google.com/go/gkemulticloud v1.2.1 h1:NKiXbkT+B3ZTDIOtUlsLrt3uT5RSEPfCyZ+N0qDGN1w= -cloud.google.com/go/gkemulticloud v1.2.1/go.mod h1:9VT+++rL2+x7o9+hc0R4CO4ywFzqlvISPZxPM93p+pw= -cloud.google.com/go/grafeas v0.2.0 h1:CYjC+xzdPvbV65gi6Dr4YowKcmLo045pm18L0DhdELM= -cloud.google.com/go/grafeas v0.3.4 h1:D4x32R/cHX3MTofKwirz015uEdVk4uAxvZkZCZkOrF4= -cloud.google.com/go/grafeas v0.3.4/go.mod h1:A5m316hcG+AulafjAbPKXBO/+I5itU4LOdKO2R/uDIc= -cloud.google.com/go/grafeas v0.3.6 h1:7bcA10EBgTsxeAVypJhz2Dv3fhrdlO7Ml8l7ZZA2IkE= -cloud.google.com/go/grafeas v0.3.6/go.mod h1:to6ECAPgRO2xeqD8ISXHc70nObJuaKZThreQOjeOH3o= -cloud.google.com/go/gsuiteaddons v1.6.5 h1:CZEbaBwmbYdhFw21Fwbo+C35HMe36fTE0FBSR4KSfWg= -cloud.google.com/go/gsuiteaddons v1.6.5/go.mod h1:Lo4P2IvO8uZ9W+RaC6s1JVxo42vgy+TX5a6hfBZ0ubs= -cloud.google.com/go/gsuiteaddons v1.6.8 h1:p+ws9HophY4UwWSAbJ6azmLlXYRv+NchybeiA6vly+E= -cloud.google.com/go/gsuiteaddons v1.6.8/go.mod h1:hxW23+rb48hDo82PVJJzWCHyOy7AyqgnZ8SnEUovIAE= -cloud.google.com/go/iam v1.1.5/go.mod h1:rB6P/Ic3mykPbFio+vo7403drjlgvoWfYpJhMXEbzv8= -cloud.google.com/go/iam v1.1.8/go.mod h1:GvE6lyMmfxXauzNq8NbgJbeVQNspG+tcdL/W8QO1+zE= -cloud.google.com/go/iap v1.9.4 h1:94zirc2r4t6KzhAMW0R6Dme005eTP6yf7g6vN4IhRrA= -cloud.google.com/go/iap v1.9.4/go.mod h1:vO4mSq0xNf/Pu6E5paORLASBwEmphXEjgCFg7aeNu1w= -cloud.google.com/go/iap v1.9.7 h1:7b0Q+gbwrSliZ7p5NLT8ngI+bg/p4vxEcYbvm64X9yA= -cloud.google.com/go/iap v1.9.7/go.mod h1:H/hF8BM9BMHRoHek60UMnJcNZpnMLdQYwc1L4OvFomk= -cloud.google.com/go/ids v1.4.5 h1:xd4U7pgl3GHV+MABnv1BF4/Vy/zBF7CYC8XngkOLzag= -cloud.google.com/go/ids v1.4.5/go.mod h1:p0ZnyzjMWxww6d2DvMGnFwCsSxDJM666Iir1bK1UuBo= -cloud.google.com/go/ids v1.4.8 h1:LkWTd5XeJba2CFOBfHHabLT15JlPM81cmBtnas593u4= -cloud.google.com/go/ids v1.4.8/go.mod h1:uW399c5bbwB5/YykcO2uQNwl3l+r6oMPEN2p9BmxCTY= -cloud.google.com/go/iot v1.7.5 h1:munTeBlbqI33iuTYgXy7S8lW2TCgi5l1hA4roSIY+EE= -cloud.google.com/go/iot v1.7.5/go.mod h1:nq3/sqTz3HGaWJi1xNiX7F41ThOzpud67vwk0YsSsqs= -cloud.google.com/go/iot v1.7.8 h1:XSC4GBFRr8H/DoJ6pav+Lap4zowdsQs/79+r+kONG50= -cloud.google.com/go/iot v1.7.8/go.mod h1:WKcw6vyfKlHKWdT3Sht8IhcK2iMydEK0Qv4Mwy3p1ms= -cloud.google.com/go/kms v1.15.7 h1:7caV9K3yIxvlQPAcaFffhlT7d1qpxjB1wHBtjWa13SM= -cloud.google.com/go/kms v1.15.7/go.mod h1:ub54lbsa6tDkUwnu4W7Yt1aAIFLnspgh0kPGToDukeI= -cloud.google.com/go/kms v1.18.1 h1:tz1oSpKokgn1+FF7mEMMmsu0FVHQebZjtKetX3fbYdo= -cloud.google.com/go/kms v1.18.1/go.mod h1:fOsmW0fzDVYXM0AOJWmpB0gFVOVgC33giwYi0kcTdBA= -cloud.google.com/go/language v1.12.3 h1:iaJZg6K4j/2PvZZVcjeO/btcWWIllVRBhuTFjGO4LXs= -cloud.google.com/go/language v1.12.3/go.mod h1:evFX9wECX6mksEva8RbRnr/4wi/vKGYnAJrTRXU8+f8= -cloud.google.com/go/language v1.12.6 h1:XL1lpjv/fnJAYkd0OjA24pz38sgdxx6Tb8y/YmN/6wA= -cloud.google.com/go/language v1.12.6/go.mod h1:zbac+SstgMxDAOY5iCMeq5mKNkEYjposny9ZpdVUhMU= -cloud.google.com/go/lifesciences v0.9.5 h1:gXvN70m2p+4zgJFzaz6gMKaxTuF9WJ0USYoMLWAOm8g= -cloud.google.com/go/lifesciences v0.9.5/go.mod h1:OdBm0n7C0Osh5yZB7j9BXyrMnTRGBJIZonUMxo5CzPw= -cloud.google.com/go/lifesciences v0.9.8 h1:doOIvlAyiwcPcJoNlpFpRLUCljl0tayLvnllF3qs3wA= -cloud.google.com/go/lifesciences v0.9.8/go.mod h1:3wKB6HF0My17uQ+bnReWumKiDksYnV3ItF4+bAA6IbQ= -cloud.google.com/go/logging v1.9.0 h1:iEIOXFO9EmSiTjDmfpbRjOxECO7R8C7b8IXUGOj7xZw= -cloud.google.com/go/logging v1.9.0/go.mod h1:1Io0vnZv4onoUnsVUQY3HZ3Igb1nBchky0A0y7BBBhE= -cloud.google.com/go/logging v1.10.0 h1:f+ZXMqyrSJ5vZ5pE/zr0xC8y/M9BLNzQeLBwfeZ+wY4= -cloud.google.com/go/logging v1.10.0/go.mod h1:EHOwcxlltJrYGqMGfghSet736KR3hX1MAj614mrMk9I= -cloud.google.com/go/longrunning v0.5.4/go.mod h1:zqNVncI0BOP8ST6XQD1+VcvuShMmq7+xFSzOL++V0dI= -cloud.google.com/go/longrunning v0.5.5 h1:GOE6pZFdSrTb4KAiKnXsJBtlE6mEyaW44oKyMILWnOg= -cloud.google.com/go/longrunning v0.5.5/go.mod h1:WV2LAxD8/rg5Z1cNW6FJ/ZpX4E4VnDnoTk0yawPBB7s= -cloud.google.com/go/longrunning v0.5.7/go.mod h1:8GClkudohy1Fxm3owmBGid8W0pSgodEMwEAztp38Xng= -cloud.google.com/go/longrunning v0.5.8 h1:QThI5BFSlYlS7K0wnABCdmKsXbG/htLc3nTPzrfOgeU= -cloud.google.com/go/longrunning v0.5.8/go.mod h1:oJDErR/mm5h44gzsfjQlxd6jyjFvuBPOxR1TLy2+cQk= -cloud.google.com/go/managedidentities v1.6.5 h1:+bpih1piZVLxla/XBqeSUzJBp8gv9plGHIMAI7DLpDM= -cloud.google.com/go/managedidentities v1.6.5/go.mod h1:fkFI2PwwyRQbjLxlm5bQ8SjtObFMW3ChBGNqaMcgZjI= -cloud.google.com/go/managedidentities v1.6.8 h1:WV00WrfhqGWKv5U4zo/Zjmni3tIqGAduK9z7rxJh5tU= -cloud.google.com/go/managedidentities v1.6.8/go.mod h1:Gl4bBPT4LV1vwWMHp+RNBWJA7P8e5bArg0YDbdERB3o= -cloud.google.com/go/maps v1.6.4 h1:EVCZAiDvog9So46460BGbCasPhi613exoaQbpilMVlk= -cloud.google.com/go/maps v1.6.4/go.mod h1:rhjqRy8NWmDJ53saCfsXQ0LKwBHfi6OSh5wkq6BaMhI= -cloud.google.com/go/maps v1.11.2 h1:wq9pTwTU5Cq7cPRV+kIRfZEj0GyteqzBRryXJK9yq/M= -cloud.google.com/go/maps v1.11.2/go.mod h1:YzCIVDLDAAZQt+sTl+hZxanOmKc4v8aFSWZfxMdKAqw= -cloud.google.com/go/mediatranslation v0.8.5 h1:c76KdIXljQHSCb/Cy47S8H4s05A4zbK3pAFGzwcczZo= -cloud.google.com/go/mediatranslation v0.8.5/go.mod h1:y7kTHYIPCIfgyLbKncgqouXJtLsU+26hZhHEEy80fSs= -cloud.google.com/go/mediatranslation v0.8.8 h1:N4ERIBaMGe7Xu+zpf26tYpY34qSN3Z2vlSNh+iZJ0H0= -cloud.google.com/go/mediatranslation v0.8.8/go.mod h1:/2BevZygMTb57aSW5xxDnFkl/ohrs8T8O2+f5qGhMsE= -cloud.google.com/go/memcache v1.10.5 h1:yeDv5qxRedFosvpMSEswrqUsJM5OdWvssPHFliNFTc4= -cloud.google.com/go/memcache v1.10.5/go.mod h1:/FcblbNd0FdMsx4natdj+2GWzTq+cjZvMa1I+9QsuMA= -cloud.google.com/go/memcache v1.10.8 h1:mGzMT2yLHc8C/kL1K/8FfuEH09Llh62iKh6R3KImADY= -cloud.google.com/go/memcache v1.10.8/go.mod h1:ryDp9chCUWXkTYYNiTEE0o/RBjGrcThZ/EOb+iW/TMo= -cloud.google.com/go/metastore v1.13.4 h1:dR7vqWXlK6IYR8Wbu9mdFfwlVjodIBhd1JRrpZftTEg= -cloud.google.com/go/metastore v1.13.4/go.mod h1:FMv9bvPInEfX9Ac1cVcRXp8EBBQnBcqH6gz3KvJ9BAE= -cloud.google.com/go/metastore v1.13.7 h1:tFs5L0Z+pT9GU08Iy2CuR0bExtg0o/ur+PbFgCRgEzw= -cloud.google.com/go/metastore v1.13.7/go.mod h1:eQA2VqSDe1ooVQs8hteKUCBYf3wRlMAJiXZ+ru3QpnU= -cloud.google.com/go/monitoring v1.18.0 h1:NfkDLQDG2UR3WYZVQE8kwSbUIEyIqJUPl+aOQdFH1T4= -cloud.google.com/go/monitoring v1.18.0/go.mod h1:c92vVBCeq/OB4Ioyo+NbN2U7tlg5ZH41PZcdvfc+Lcg= -cloud.google.com/go/monitoring v1.20.0 h1:GsIGYe6Q42EHONJtrUenZFpPIF60qLpeMhxVHIBcaPA= -cloud.google.com/go/monitoring v1.20.0/go.mod h1:5oUy5KllE4yxpztDJuzq/VVck0Q0cn/ykC98C9MXux0= -cloud.google.com/go/networkconnectivity v1.14.4 h1:GBfXFhLyPspnaBE3nI/BRjdhW8vcbpT9QjE/4kDCDdc= -cloud.google.com/go/networkconnectivity v1.14.4/go.mod h1:PU12q++/IMnDJAB+3r+tJtuCXCfwfN+C6Niyj6ji1Po= -cloud.google.com/go/networkconnectivity v1.14.7 h1:pZNeZUpQlIzKXZViX3kTthVMKYOBbTQ3qOMzs0Yob2Q= -cloud.google.com/go/networkconnectivity v1.14.7/go.mod h1:hdX86Gs4t3ZDv91Q7XFOxtWd9hcpkmZgVFoRoLDNsrU= -cloud.google.com/go/networkmanagement v1.9.4 h1:aLV5GcosBNmd6M8+a0ekB0XlLRexv4fvnJJrYnqeBcg= -cloud.google.com/go/networkmanagement v1.9.4/go.mod h1:daWJAl0KTFytFL7ar33I6R/oNBH8eEOX/rBNHrC/8TA= -cloud.google.com/go/networkmanagement v1.13.3 h1:VbQE6bU3P1892HAo9g/eNBARqHH64Omfx3+m29nDkmA= -cloud.google.com/go/networkmanagement v1.13.3/go.mod h1:UVyvulpb1cOu2DfAHkxOGJTBVOC7nxjhaCKi3HMm70I= -cloud.google.com/go/networksecurity v0.9.5 h1:+caSxBTj0E8OYVh/5wElFdjEMO1S/rZtE1152Cepchc= -cloud.google.com/go/networksecurity v0.9.5/go.mod h1:KNkjH/RsylSGyyZ8wXpue8xpCEK+bTtvof8SBfIhMG8= -cloud.google.com/go/networksecurity v0.9.8 h1:jtXSJUx3tCHZB5sV0QtTlFWWWGfFxGwRAZAOGBZARJ0= -cloud.google.com/go/networksecurity v0.9.8/go.mod h1:8wCm5we0Aqf9ORfCUunupx5ipdfGFTL+PTTkYoBIFjE= -cloud.google.com/go/notebooks v1.11.3 h1:FH48boYmrWVQ6k0Mx/WrnNafXncT5iSYxA8CNyWTgy0= -cloud.google.com/go/notebooks v1.11.3/go.mod h1:0wQyI2dQC3AZyQqWnRsp+yA+kY4gC7ZIVP4Qg3AQcgo= -cloud.google.com/go/notebooks v1.11.6 h1:7K240HF+9RDYV44DsxjmccpFZ7olN5VjSRrqunTC89c= -cloud.google.com/go/notebooks v1.11.6/go.mod h1:JoKKqNBlcs2f2K4L/Ao6FAUZI0Yw0j2cZOSRQFcHk8Q= -cloud.google.com/go/optimization v1.6.3 h1:63NZaWyN+5rZEKHPX4ACpw3BjgyeuY8+rCehiCMaGPY= -cloud.google.com/go/optimization v1.6.3/go.mod h1:8ve3svp3W6NFcAEFr4SfJxrldzhUl4VMUJmhrqVKtYA= -cloud.google.com/go/optimization v1.6.6 h1:45n/Qw2Mt1urpOA1fvUBjik5LzCyOl4gSQtFI9DFwcg= -cloud.google.com/go/optimization v1.6.6/go.mod h1:qFLRJ5h7HD9YydjM8F+uKkU++MHCvrGyakgiHSkL1KE= -cloud.google.com/go/orchestration v1.8.5 h1:YHgWMlrPttIVGItgGfuvO2KM7x+y9ivN/Yk92pMm1a4= -cloud.google.com/go/orchestration v1.8.5/go.mod h1:C1J7HesE96Ba8/hZ71ISTV2UAat0bwN+pi85ky38Yq8= -cloud.google.com/go/orchestration v1.9.3 h1:tYrt0nb6s7SuoRnZ5ej3sdn/eH5AjpVaAYRCjm7fYHk= -cloud.google.com/go/orchestration v1.9.3/go.mod h1:6cOnot26ereouYWqhm5k8fX1dysq+e71bEjYro+8RYA= -cloud.google.com/go/orgpolicy v1.12.1 h1:2JbXigqBJVp8Dx5dONUttFqewu4fP0p3pgOdIZAhpYU= -cloud.google.com/go/orgpolicy v1.12.1/go.mod h1:aibX78RDl5pcK3jA8ysDQCFkVxLj3aOQqrbBaUL2V5I= -cloud.google.com/go/orgpolicy v1.12.4 h1:Fg3GOwl6ANDmZMG4tkIvj2DUFzdTkgUwtKGwvJT3xvI= -cloud.google.com/go/orgpolicy v1.12.4/go.mod h1:lHr1a8OmY3aA+WMvNyX+ckZ47r5vp+NI1eeC0zKTQCs= -cloud.google.com/go/osconfig v1.12.5 h1:Mo5jGAxOMKH/PmDY7fgY19yFcVbvwREb5D5zMPQjFfo= -cloud.google.com/go/osconfig v1.12.5/go.mod h1:D9QFdxzfjgw3h/+ZaAb5NypM8bhOMqBzgmbhzWViiW8= -cloud.google.com/go/osconfig v1.12.8 h1:4nYxEmrxDHiORT3+YS10I0WAaI6cFshy2RE7KCpGQDY= -cloud.google.com/go/osconfig v1.12.8/go.mod h1:GF1mHXXkpBlMhuHkZo58PPtbMEVapeNvT/wLYwjR+5g= -cloud.google.com/go/oslogin v1.13.1 h1:1K4nOT5VEZNt7XkhaTXupBYos5HjzvJMfhvyD2wWdFs= -cloud.google.com/go/oslogin v1.13.1/go.mod h1:vS8Sr/jR7QvPWpCjNqy6LYZr5Zs1e8ZGW/KPn9gmhws= -cloud.google.com/go/oslogin v1.13.4 h1:w3ILkrWvJzvBZOMPdL+psn0RQfB1eAWjckJTqe7/ANo= -cloud.google.com/go/oslogin v1.13.4/go.mod h1:ae2K89lAr0zkWP7CCqdGiCBZTis1ymCM0xhmpUfaQYY= -cloud.google.com/go/phishingprotection v0.8.5 h1:DH3WFLzEoJdW/6xgsmoDqOwT1xddFi7gKu0QGZQhpGU= -cloud.google.com/go/phishingprotection v0.8.5/go.mod h1:g1smd68F7mF1hgQPuYn3z8HDbNre8L6Z0b7XMYFmX7I= -cloud.google.com/go/phishingprotection v0.8.8 h1:tT5qmQxpdQxvsglgbL+WI/XFehcj1M9X4gpqU2Bm0NU= -cloud.google.com/go/phishingprotection v0.8.8/go.mod h1:TjMWRJeTs/3TAVCuzhp6oQ+ng8FWz7PKmgJ8b2+eXkM= -cloud.google.com/go/policytroubleshooter v1.10.3 h1:c0WOzC6hz964QWNBkyKfna8A2jOIx1zzZa43Gx/P09o= -cloud.google.com/go/policytroubleshooter v1.10.3/go.mod h1:+ZqG3agHT7WPb4EBIRqUv4OyIwRTZvsVDHZ8GlZaoxk= -cloud.google.com/go/policytroubleshooter v1.10.6 h1:ahSVHd6IJ70WdLfsxIZ0tyDmM5Qtol0tlyNEfbB5lEI= -cloud.google.com/go/policytroubleshooter v1.10.6/go.mod h1:mEYX75+EvMAoJVNqpJ88hcZjPiUTmOsjlaGpDu/ZrD0= -cloud.google.com/go/privatecatalog v0.9.5 h1:UZ0assTnATXSggoxUIh61RjTQ4P9zCMk/kEMbn0nMYA= -cloud.google.com/go/privatecatalog v0.9.5/go.mod h1:fVWeBOVe7uj2n3kWRGlUQqR/pOd450J9yZoOECcQqJk= -cloud.google.com/go/privatecatalog v0.9.8 h1:5pUH09v1S1eT3Y+TviSfpLxLb1HY8JIR+I3Yjq1f20Q= -cloud.google.com/go/privatecatalog v0.9.8/go.mod h1:ki1VWJTD/fSDJibXDmrm9Mn+Tzrl3sQZq4pZh3VBU+c= -cloud.google.com/go/pubsub v1.36.1 h1:dfEPuGCHGbWUhaMCTHUFjfroILEkx55iUmKBZTP5f+Y= -cloud.google.com/go/pubsub v1.36.1/go.mod h1:iYjCa9EzWOoBiTdd4ps7QoMtMln5NwaZQpK1hbRfBDE= -cloud.google.com/go/pubsub v1.40.0 h1:0LdP+zj5XaPAGtWr2V6r88VXJlmtaB/+fde1q3TU8M0= -cloud.google.com/go/pubsub v1.40.0/go.mod h1:BVJI4sI2FyXp36KFKvFwcfDRDfR8MiLT8mMhmIhdAeA= -cloud.google.com/go/pubsublite v1.8.1 h1:pX+idpWMIH30/K7c0epN6V703xpIcMXWRjKJsz0tYGY= -cloud.google.com/go/pubsublite v1.8.1/go.mod h1:fOLdU4f5xldK4RGJrBMm+J7zMWNj/k4PxwEZXy39QS0= -cloud.google.com/go/pubsublite v1.8.2 h1:jLQozsEVr+c6tOU13vDugtnaBSUy/PD5zK6mhm+uF1Y= -cloud.google.com/go/pubsublite v1.8.2/go.mod h1:4r8GSa9NznExjuLPEJlF1VjOPOpgf3IT6k8x/YgaOPI= -cloud.google.com/go/recaptchaenterprise v1.3.1 h1:u6EznTGzIdsyOsvm+Xkw0aSuKFXQlyjGE9a4exk6iNQ= -cloud.google.com/go/recaptchaenterprise/v2 v2.9.2 h1:U3Wfq12X9cVMuTpsWDSURnXF0Z9hSPTHj+xsnXDRLsw= -cloud.google.com/go/recaptchaenterprise/v2 v2.9.2/go.mod h1:trwwGkfhCmp05Ll5MSJPXY7yvnO0p4v3orGANAFHAuU= -cloud.google.com/go/recaptchaenterprise/v2 v2.13.1 h1:SkC5VgprI3SC2al+5hQn5VYfzZ3Tq9AfKv6Nst14Gcg= -cloud.google.com/go/recaptchaenterprise/v2 v2.13.1/go.mod h1:z7FFKUnrk8oKc5WwLnuj6ae3uOjZGYY7tf4FIRjQD3Y= -cloud.google.com/go/recommendationengine v0.8.5 h1:ineqLswaCSBY0csYv5/wuXJMBlxATK6Xc5jJkpiTEdM= -cloud.google.com/go/recommendationengine v0.8.5/go.mod h1:A38rIXHGFvoPvmy6pZLozr0g59NRNREz4cx7F58HAsQ= -cloud.google.com/go/recommendationengine v0.8.8 h1:B8olyGeU4NfbATF2tL0n8RXSxO3GjiMmyywUtFZIe2M= -cloud.google.com/go/recommendationengine v0.8.8/go.mod h1:XHm+7adVfxfllhSTUbKyhdqzFyk15lbeCqaULzpT5LM= -cloud.google.com/go/recommender v1.12.1 h1:LVLYS3r3u0MSCxQSDUtLSkporEGi9OAE6hGvayrZNPs= -cloud.google.com/go/recommender v1.12.1/go.mod h1:gf95SInWNND5aPas3yjwl0I572dtudMhMIG4ni8nr+0= -cloud.google.com/go/recommender v1.12.4 h1:X6BOnfvQufYDo5YNlzmYv+hpk0HyDAdjw+u/qczeNkE= -cloud.google.com/go/recommender v1.12.4/go.mod h1:ZA02CeWOdH3Pw377pofqtdrIkN+Wh4vnZdDHl08KR/c= -cloud.google.com/go/redis v1.14.2 h1:QF0maEdVv0Fj/2roU8sX3NpiDBzP9ICYTO+5F32gQNo= -cloud.google.com/go/redis v1.14.2/go.mod h1:g0Lu7RRRz46ENdFKQ2EcQZBAJ2PtJHJLuiiRuEXwyQw= -cloud.google.com/go/redis v1.16.1 h1:ROAo4UKsHVrZbofV6q3Z3DUr26otC7Y4wxspMixfmC8= -cloud.google.com/go/redis v1.16.1/go.mod h1:KI+VIUVSXZUmbCkhCbbGitRqZGLmlz9BAhAyHgBTRE4= -cloud.google.com/go/resourcemanager v1.9.5 h1:AZWr1vWVDKGwfLsVhcN+vcwOz3xqqYxtmMa0aABCMms= -cloud.google.com/go/resourcemanager v1.9.5/go.mod h1:hep6KjelHA+ToEjOfO3garMKi/CLYwTqeAw7YiEI9x8= -cloud.google.com/go/resourcemanager v1.9.8 h1:LMFZspU5krxBIz3pXk0QTFnmdAwKN8hnq71vmHPVNKs= -cloud.google.com/go/resourcemanager v1.9.8/go.mod h1:L3cVnfsZ1Wsw4f9hBNmZ7O1/ahJRPn8Ltg03ifaqsIw= -cloud.google.com/go/resourcesettings v1.6.5 h1:BTr5MVykJwClASci/7Og4Qfx70aQ4n3epsNLj94ZYgw= -cloud.google.com/go/resourcesettings v1.6.5/go.mod h1:WBOIWZraXZOGAgoR4ukNj0o0HiSMO62H9RpFi9WjP9I= -cloud.google.com/go/resourcesettings v1.7.1 h1:wj0j3d2nWa31FQl8PbvCfVERqAzmrAnejSqH+j6Mr2s= -cloud.google.com/go/resourcesettings v1.7.1/go.mod h1:f2WI2DpFghwCHYfyht0vMX2UKqJ9FRbXixXHBT3BmFQ= -cloud.google.com/go/retail v1.16.0 h1:Fn1GuAua1c6crCGqfJ1qMxG1Xh10Tg/x5EUODEHMqkw= -cloud.google.com/go/retail v1.16.0/go.mod h1:LW7tllVveZo4ReWt68VnldZFWJRzsh9np+01J9dYWzE= -cloud.google.com/go/retail v1.17.1 h1:npaL3nMGVZr9vzIllmYVt9UQ63Tlfz/bIqme3O6dthE= -cloud.google.com/go/retail v1.17.1/go.mod h1:UXtxpeokEUhbMRgq2dJH08Z5QTZgRzYR6sGES87xDkA= -cloud.google.com/go/run v1.3.4 h1:m9WDA7DzTpczhZggwYlZcBWgCRb+kgSIisWn1sbw2rQ= -cloud.google.com/go/run v1.3.4/go.mod h1:FGieuZvQ3tj1e9GnzXqrMABSuir38AJg5xhiYq+SF3o= -cloud.google.com/go/run v1.3.8 h1:n3eQ9GeHUn9lKwY7yCNUHqVCshUj9lTv+oaBGxqGlNU= -cloud.google.com/go/run v1.3.8/go.mod h1:dFsJfGTEVGW37sCqzJ/kLMmRS2/wfwGsUMOEuv0ryL0= -cloud.google.com/go/scheduler v1.10.6 h1:5U8iXLoQ03qOB+ZXlAecU7fiE33+u3QiM9nh4cd0eTE= -cloud.google.com/go/scheduler v1.10.6/go.mod h1:pe2pNCtJ+R01E06XCDOJs1XvAMbv28ZsQEbqknxGOuE= -cloud.google.com/go/scheduler v1.10.9 h1:X8/aahnwiyTNmYWc9Dda4iEtVMbBc68X1g6wULi5FJU= -cloud.google.com/go/scheduler v1.10.9/go.mod h1:nhiBshhr2jJggklptGgj33DF+aQ3/4CWaTeazS/8Qm0= -cloud.google.com/go/secretmanager v1.11.5 h1:82fpF5vBBvu9XW4qj0FU2C6qVMtj1RM/XHwKXUEAfYY= -cloud.google.com/go/secretmanager v1.11.5/go.mod h1:eAGv+DaCHkeVyQi0BeXgAHOU0RdrMeZIASKc+S7VqH4= -cloud.google.com/go/secretmanager v1.13.2 h1:WnyajcyWf5MLq9lPyVxEyOBAhQdPcpckG3lMw8LqAHw= -cloud.google.com/go/secretmanager v1.13.2/go.mod h1:rB3lORY7QZrjACov35PX0KXMM0bKlbkL0/eFlS312wk= -cloud.google.com/go/security v1.15.5 h1:wTKJQ10j8EYgvE8Y+KhovxDRVDk2iv/OsxZ6GrLP3kE= -cloud.google.com/go/security v1.15.5/go.mod h1:KS6X2eG3ynWjqcIX976fuToN5juVkF6Ra6c7MPnldtc= -cloud.google.com/go/security v1.17.1 h1:JjKlR4fUJNyq/+lPDi2PhC4G5G3+tda8gboLdona66Y= -cloud.google.com/go/security v1.17.1/go.mod h1:i/v+U4Jxs8mTFXmB/eYIYBdRl7mFmeo3VrcFw+r6e9o= -cloud.google.com/go/securitycenter v1.24.4 h1:/5jjkZ+uGe8hZ7pvd7pO30VW/a+pT2MrrdgOqjyucKQ= -cloud.google.com/go/securitycenter v1.24.4/go.mod h1:PSccin+o1EMYKcFQzz9HMMnZ2r9+7jbc+LvPjXhpwcU= -cloud.google.com/go/securitycenter v1.31.0 h1:gjXbwJDFA4amC9bp6MR20oBkaAXNethP/Di3cON7Ad4= -cloud.google.com/go/securitycenter v1.31.0/go.mod h1:6nVpMYo9Q02wR7ql1L17R1vE2KNvcooSkyKoJWB4Ox4= -cloud.google.com/go/servicecontrol v1.10.0 h1:P1OiVugNQtWVM3hVJSzaAmye48pExx1VPX2SKT8Z4Yg= -cloud.google.com/go/servicecontrol v1.10.0/go.mod h1:pQvyvSRh7YzUF2efw7H87V92mxU8FnFDawMClGCNuAA= -cloud.google.com/go/servicedirectory v1.11.4 h1:da7HFI1229kyzIyuVEzHXip0cw0d+E0s8mjQby0WN+k= -cloud.google.com/go/servicedirectory v1.11.4/go.mod h1:Bz2T9t+/Ehg6x+Y7Ycq5xiShYLD96NfEsWNHyitj1qM= -cloud.google.com/go/servicedirectory v1.11.8 h1:AfGFD8GiLoHrPC22lThekCvn4NgB3fIuhctNoGViZlk= -cloud.google.com/go/servicedirectory v1.11.8/go.mod h1:BCapDXmWzKx42Ffd/j8q7m5GNIH0JkolKhwK2quAm94= -cloud.google.com/go/servicemanagement v1.6.0 h1:flWoX0eJy21+34I/7HPUbpr6xTHPVzws1xnecLFlUm0= -cloud.google.com/go/servicemanagement v1.6.0/go.mod h1:aWns7EeeCOtGEX4OvZUWCCJONRZeFKiptqKf1D0l/Jc= -cloud.google.com/go/serviceusage v1.5.0 h1:fl1AGgOx7E2eyBmH5ofDXT9w8xGvEaEnHYyNYGkxaqg= -cloud.google.com/go/serviceusage v1.5.0/go.mod h1:w8U1JvqUqwJNPEOTQjrMHkw3IaIFLoLsPLvsE3xueec= -cloud.google.com/go/shell v1.7.5 h1:3Fq2hzO0ZSyaqBboJrFkwwf/qMufDtqwwA6ep8EZxEI= -cloud.google.com/go/shell v1.7.5/go.mod h1:hL2++7F47/IfpfTO53KYf1EC+F56k3ThfNEXd4zcuiE= -cloud.google.com/go/shell v1.7.8 h1:kHlY2KR+4uyPK4a96nXCXXRjqwFHxOUAmEfrAF+Gc7o= -cloud.google.com/go/shell v1.7.8/go.mod h1:07qTjW9lCuFbkb2G0hzqvNELK5nwT5aSsn6Own/a5bE= -cloud.google.com/go/spanner v1.57.0 h1:fJq+ZfQUDHE+cy1li0bJA8+sy2oiSGhuGqN5nqVaZdU= -cloud.google.com/go/spanner v1.57.0/go.mod h1:aXQ5QDdhPRIqVhYmnkAdwPYvj/DRN0FguclhEWw+jOo= -cloud.google.com/go/spanner v1.64.0 h1:ltyPbHA/nRAtAhU/o742dXBCI1eNHPeaRY09Ja8B+hM= -cloud.google.com/go/spanner v1.64.0/go.mod h1:TOFx3pb2UwPsDGlE1gTehW+y6YlU4IFk+VdDHSGQS/M= -cloud.google.com/go/speech v1.21.1 h1:nuFc+Kj5B8de75nN4FdPyUbI2SiBoHZG6BLurXL56Q0= -cloud.google.com/go/speech v1.21.1/go.mod h1:E5GHZXYQlkqWQwY5xRSLHw2ci5NMQNG52FfMU1aZrIA= -cloud.google.com/go/speech v1.23.2 h1:s26zNLdGYeeNDftncc72CpxNAjRsSQa+Dmi6msioUmI= -cloud.google.com/go/speech v1.23.2/go.mod h1:U3p1TXiaFNMw/bs593/9cx6zehLkhcxx1aTMMnMgefM= -cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= -cloud.google.com/go/storage v1.35.1/go.mod h1:M6M/3V/D3KpzMTJyPOR/HU6n2Si5QdaXYEsng2xgOs8= -cloud.google.com/go/storage v1.36.0/go.mod h1:M6M/3V/D3KpzMTJyPOR/HU6n2Si5QdaXYEsng2xgOs8= -cloud.google.com/go/storagetransfer v1.10.4 h1:dy4fL3wO0VABvzM05ycMUPFHxTPbJz9Em8ikAJVqSbI= -cloud.google.com/go/storagetransfer v1.10.4/go.mod h1:vef30rZKu5HSEf/x1tK3WfWrL0XVoUQN/EPDRGPzjZs= -cloud.google.com/go/storagetransfer v1.10.7 h1:UFHrgNnef8OwipBt/eroKytztOTFIqYKMSDU+JO8lQk= -cloud.google.com/go/storagetransfer v1.10.7/go.mod h1:vc58NUgvigCZtNvmnMPir9QSsOri8yfOIpL4KvNsnnw= -cloud.google.com/go/talent v1.6.6 h1:JssV0CE3FNujuSWn7SkosOzg7qrMxVnt6txOfGcMSa4= -cloud.google.com/go/talent v1.6.6/go.mod h1:y/WQDKrhVz12WagoarpAIyKKMeKGKHWPoReZ0g8tseQ= -cloud.google.com/go/talent v1.6.9 h1:nJ2mB7GPrWjptlynT+vywqXv/XEQIgDdEw/5w3bTG5I= -cloud.google.com/go/talent v1.6.9/go.mod h1:wvqO09RhWW8EfZBPcG/2FRT9SDbi2vsVXfV+jMzJD/w= -cloud.google.com/go/texttospeech v1.7.5 h1:dxY2Q5mHCbrGa3oPR2O3PCicdnvKa1JmwGQK36EFLOw= -cloud.google.com/go/texttospeech v1.7.5/go.mod h1:tzpCuNWPwrNJnEa4Pu5taALuZL4QRRLcb+K9pbhXT6M= -cloud.google.com/go/texttospeech v1.7.8 h1:CBJ83C1GbeJNLFdp27lfO8CcO8meHKJ27wl4vDqTVd8= -cloud.google.com/go/texttospeech v1.7.8/go.mod h1:ynSE4aBS/J/hwi8U8Aa+gwtOlwwCeymOniUSrx4eYyg= -cloud.google.com/go/tpu v1.6.5 h1:C8YyYda8WtNdBoCgFwwBzZd+S6+EScHOxM/z1h0NNp8= -cloud.google.com/go/tpu v1.6.5/go.mod h1:P9DFOEBIBhuEcZhXi+wPoVy/cji+0ICFi4TtTkMHSSs= -cloud.google.com/go/tpu v1.6.8 h1:sXK26IAV5uYqjacvlZlIa1Z2O0fNnCk2nUm3xjqKIsM= -cloud.google.com/go/tpu v1.6.8/go.mod h1:+u/GrLBfe2MAf33D9cyU36dOy7XKtfar4IRrO2k5rCI= -cloud.google.com/go/trace v1.10.5 h1:0pr4lIKJ5XZFYD9GtxXEWr0KkVeigc3wlGpZco0X1oA= -cloud.google.com/go/trace v1.10.5/go.mod h1:9hjCV1nGBCtXbAE4YK7OqJ8pmPYSxPA0I67JwRd5s3M= -cloud.google.com/go/trace v1.10.8 h1:PffY+74UyMjCeKQGp0qW7kGRPsmDtx8BX4Py/2IhZjA= -cloud.google.com/go/trace v1.10.8/go.mod h1:zu8PHOoxf4f4qUl81OFdVn02fmje7v79wo57Fz7oIPo= -cloud.google.com/go/translate v1.10.1 h1:upovZ0wRMdzZvXnu+RPam41B0mRJ+coRXFP2cYFJ7ew= -cloud.google.com/go/translate v1.10.1/go.mod h1:adGZcQNom/3ogU65N9UXHOnnSvjPwA/jKQUMnsYXOyk= -cloud.google.com/go/translate v1.10.4 h1:fac6q6uquqLev8aV0X5cT9oPVUvfCwPtxkQVBayOR6E= -cloud.google.com/go/translate v1.10.4/go.mod h1:8zF+IIQKPtqi2ebyISjgZDwj095cceaj0dDX2mI9WiU= -cloud.google.com/go/video v1.20.4 h1:TXwotxkShP1OqgKsbd+b8N5hrIHavSyLGvYnLGCZ7xc= -cloud.google.com/go/video v1.20.4/go.mod h1:LyUVjyW+Bwj7dh3UJnUGZfyqjEto9DnrvTe1f/+QrW0= -cloud.google.com/go/video v1.21.1 h1:VGUgIdrwKj7IDR10bApRB8AID8LEJnNpplocDfFGGho= -cloud.google.com/go/video v1.21.1/go.mod h1:m5bJKcdJ9sKTMJO6EWmtLXhmvEWbrDSSmzpo2sxTP9c= -cloud.google.com/go/videointelligence v1.11.5 h1:mYaWH8uhUCXLJCN3gdXswKzRa2+lK0zN6/KsIubm6pE= -cloud.google.com/go/videointelligence v1.11.5/go.mod h1:/PkeQjpRponmOerPeJxNPuxvi12HlW7Em0lJO14FC3I= -cloud.google.com/go/videointelligence v1.11.8 h1:B3zIDWYh+b+O5PuQUef7fAmBEaCfISOg3UdOjIrugNo= -cloud.google.com/go/videointelligence v1.11.8/go.mod h1:pwQD5fVcMPPAcovgt+ywF1OaLD+V1EDxG7RX4Q+1r4k= -cloud.google.com/go/vision v1.2.0 h1:/CsSTkbmO9HC8iQpxbK8ATms3OQaX3YQUeTMGCxlaK4= -cloud.google.com/go/vision/v2 v2.8.0 h1:W52z1b6LdGI66MVhE70g/NFty9zCYYcjdKuycqmlhtg= -cloud.google.com/go/vision/v2 v2.8.0/go.mod h1:ocqDiA2j97pvgogdyhoxiQp2ZkDCyr0HWpicywGGRhU= -cloud.google.com/go/vision/v2 v2.8.3 h1:cL2ndZQzfffr1xw8SeHlTX3Bsp31vYyES+sLdT1bJNI= -cloud.google.com/go/vision/v2 v2.8.3/go.mod h1:MeN2uM4T5MSOULtIIJEW/Ymr6It6eSP0ZdqCGuGKFXw= -cloud.google.com/go/vmmigration v1.7.5 h1:5v9RT2vWyuw3pK2ox0HQpkoftO7Q7/8591dTxxQc79g= -cloud.google.com/go/vmmigration v1.7.5/go.mod h1:pkvO6huVnVWzkFioxSghZxIGcsstDvYiVCxQ9ZH3eYI= -cloud.google.com/go/vmmigration v1.7.8 h1:3JKqN0BxgWOLJTRsIg1gp+kZdFxiwg3FI81RwRMs6UQ= -cloud.google.com/go/vmmigration v1.7.8/go.mod h1:ARowCnYGN1+cFTdMR6FMsUSHuC2v1PmLRM35JfanA8c= -cloud.google.com/go/vmwareengine v1.1.1 h1:EGdDi9QbqThfZq3ILcDK5g+m9jTevc34AY5tACx5v7k= -cloud.google.com/go/vmwareengine v1.1.1/go.mod h1:nMpdsIVkUrSaX8UvmnBhzVzG7PPvNYc5BszcvIVudYs= -cloud.google.com/go/vmwareengine v1.1.4 h1:euh/uASKEi6kVOGU3KWq6enpJZ4v/iGLApxcV8+KxzA= -cloud.google.com/go/vmwareengine v1.1.4/go.mod h1:v+UndgfEEMePkZ8eXqzzFODipi/ls657S3MoSLI9JZ4= -cloud.google.com/go/vpcaccess v1.7.5 h1:XyL6hTLtEM/eE4F1GEge8xUN9ZCkiVWn44K/YA7z1rQ= -cloud.google.com/go/vpcaccess v1.7.5/go.mod h1:slc5ZRvvjP78c2dnL7m4l4R9GwL3wDLcpIWz6P/ziig= -cloud.google.com/go/vpcaccess v1.7.8 h1:TH/aIfHStC6OWwvnZ27Olt7PFNF7OLgaAiIq8Jzc9pM= -cloud.google.com/go/vpcaccess v1.7.8/go.mod h1:fOd55qBAQiAFPA/hYwnOWgYNjcbvRMxd0rLvvojH/nU= -cloud.google.com/go/webrisk v1.9.5 h1:251MvGuC8wisNN7+jqu9DDDZAi38KiMXxOpA/EWy4dE= -cloud.google.com/go/webrisk v1.9.5/go.mod h1:aako0Fzep1Q714cPEM5E+mtYX8/jsfegAuS8aivxy3U= -cloud.google.com/go/webrisk v1.9.8 h1:Q43FyTPv300dAYio0OlLbj164xQdvNLPPTSRuT/CGvY= -cloud.google.com/go/webrisk v1.9.8/go.mod h1:ywUL9x0E81fft6TYggLWc+HUaCkuhMBl/RHnG8q5d5M= -cloud.google.com/go/websecurityscanner v1.6.5 h1:YqWZrZYabG88TZt7364XWRJGhxmxhony2ZUyZEYMF2k= -cloud.google.com/go/websecurityscanner v1.6.5/go.mod h1:QR+DWaxAz2pWooylsBF854/Ijvuoa3FCyS1zBa1rAVQ= -cloud.google.com/go/websecurityscanner v1.6.8 h1:kWWuc1gxoziEQ66YpRD88rUsUONOEFYU4WJa4YU3P8k= -cloud.google.com/go/websecurityscanner v1.6.8/go.mod h1:VyEfLCEjX9PN6mhOzuuuIVKHQ9FLHPKsbSg+KxzTW8k= -cloud.google.com/go/workflows v1.12.4 h1:uHNmUiatTbPQ4H1pabwfzpfEYD4BBnqDHqMm2IesOh4= -cloud.google.com/go/workflows v1.12.4/go.mod h1:yQ7HUqOkdJK4duVtMeBCAOPiN1ZF1E9pAMX51vpwB/w= -cloud.google.com/go/workflows v1.12.7 h1:Izlx3tQ0R2DV67/cpOlXsJO7vBNeiq81j0z2yDO7s9s= -cloud.google.com/go/workflows v1.12.7/go.mod h1:W33pjrwjgNIDBYY5xdQfHeUxE3icFjO5x7Fh9kA4P2M= -cosmossdk.io/api v0.7.0/go.mod h1:kJFAEMLN57y0viszHDPLMmieF0471o5QAwwApa+270M= -cosmossdk.io/core v0.5.1/go.mod h1:KZtwHCLjcFuo0nmDc24Xy6CRNEL9Vl/MeimQ2aC7NLE= -cosmossdk.io/core v0.11.1 h1:h9WfBey7NAiFfIcUhDVNS503I2P2HdZLebJlUIs8LPA= -cosmossdk.io/core v0.11.1/go.mod h1:OJzxcdC+RPrgGF8NJZR2uoQr56tc7gfBKhiKeDO7hH0= -cosmossdk.io/depinject v1.0.0-alpha.3/go.mod h1:eRbcdQ7MRpIPEM5YUJh8k97nxHpYbc3sMUnEtt8HPWU= -cosmossdk.io/log v1.2.0/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= -cosmossdk.io/math v1.0.0-rc.0/go.mod h1:Ygz4wBHrgc7g0N+8+MrnTfS9LLn9aaTGa9hKopuym5k= -cosmossdk.io/math v1.1.2/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= -cosmossdk.io/store v1.1.0 h1:LnKwgYMc9BInn9PhpTFEQVbL9UK475G2H911CGGnWHk= -cosmossdk.io/store v1.1.0/go.mod h1:oZfW/4Fc/zYqu3JmQcQdUJ3fqu5vnYTn3LZFFy8P8ng= -cosmossdk.io/tools/rosetta v0.2.1 h1:ddOMatOH+pbxWbrGJKRAawdBkPYLfKXutK9IETnjYxw= -cosmossdk.io/tools/rosetta v0.2.1/go.mod h1:Pqdc1FdvkNV3LcNIkYWt2RQY6IP1ge6YWZk8MhhO9Hw= -crawshaw.io/sqlite v0.3.3-0.20220618202545-d1964889ea3c h1:wvzox0eLO6CKQAMcOqz7oH3UFqMpMmK7kwmwV+22HIs= -crawshaw.io/sqlite v0.3.3-0.20220618202545-d1964889ea3c/go.mod h1:igAO5JulrQ1DbdZdtVq48mnZUBAPOeFzer7VhDWNtW4= -dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk= -dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= -dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9 h1:VpgP7xuJadIUuKccphEpTJnWhS2jkQyMt6Y7pJCD7fY= -gioui.org v0.0.0-20210308172011-57750fc8a0a6 h1:K72hopUosKG3ntOPNG4OzzbuhxGuVf06fa2la1/H/Ho= -gioui.org v0.0.0-20210308172011-57750fc8a0a6/go.mod h1:RSH6KIUZ0p2xy5zHDxgAM4zumjgTw83q2ge/PI+yyw8= -git.sr.ht/~sbinet/gg v0.3.1 h1:LNhjNn8DerC8f9DHLz6lS0YYul/b602DUxDgGkd/Aik= -git.sr.ht/~sbinet/gg v0.3.1/go.mod h1:KGYtlADtqsqANL9ueOFkWymvzUvLMQllU5Ixo+8v3pc= -github.com/Abirdcfly/dupword v0.0.7 h1:z14n0yytA3wNO2gpCD/jVtp/acEXPGmYu0esewpBt6Q= -github.com/Abirdcfly/dupword v0.0.7/go.mod h1:K/4M1kj+Zh39d2aotRwypvasonOyAMH1c/IZJzE0dmk= -github.com/Abirdcfly/dupword v0.0.11 h1:z6v8rMETchZXUIuHxYNmlUAuKuB21PeaSymTed16wgU= -github.com/Abirdcfly/dupword v0.0.11/go.mod h1:wH8mVGuf3CP5fsBTkfWwwwKTjDnVVCxtU8d8rgeVYXA= -github.com/AdaLogics/go-fuzz-headers v0.0.0-20210715213245-6c3934b029d8 h1:V8krnnfGj4pV65YLUm3C0/8bl7V5Nry2Pwvy3ru/wLc= -github.com/AdaLogics/go-fuzz-headers v0.0.0-20210715213245-6c3934b029d8/go.mod h1:CzsSbkDixRphAF5hS6wbMKq0eI6ccJRb7/A0M6JBnwg= -github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9 h1:HD8gA2tkByhMAwYaFAX9w2l7vxvBQ5NMoxDrkhqhtn4= -github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= -github.com/Antonboom/errname v0.1.7 h1:mBBDKvEYwPl4WFFNwec1CZO096G6vzK9vvDQzAwkako= -github.com/Antonboom/errname v0.1.7/go.mod h1:g0ONh16msHIPgJSGsecu1G/dcF2hlYR/0SddnIAGavU= -github.com/Antonboom/errname v0.1.9 h1:BZDX4r3l4TBZxZ2o2LNrlGxSHran4d1u4veZdoORTT4= -github.com/Antonboom/errname v0.1.9/go.mod h1:nLTcJzevREuAsgTbG85UsuiWpMpAqbKD1HNZ29OzE58= -github.com/Antonboom/nilnil v0.1.1 h1:PHhrh5ANKFWRBh7TdYmyyq2gyT2lotnvFvvFbylF81Q= -github.com/Antonboom/nilnil v0.1.1/go.mod h1:L1jBqoWM7AOeTD+tSquifKSesRHs4ZdaxvZR+xdJEaI= -github.com/Antonboom/nilnil v0.1.3 h1:6RTbx3d2mcEu3Zwq9TowQpQMVpP75zugwOtqY1RTtcE= -github.com/Antonboom/nilnil v0.1.3/go.mod h1:iOov/7gRcXkeEU+EMGpBu2ORih3iyVEiWjeste1SJm8= -github.com/Azure/azure-sdk-for-go/sdk/azcore v0.21.1 h1:qoVeMsc9/fh/yhxVaA0obYjVH/oI/ihrOoMwsLS9KSA= -github.com/Azure/azure-sdk-for-go/sdk/azcore v0.21.1/go.mod h1:fBF9PQNqB8scdgpZ3ufzaLntG0AG7C1WjPMsiFOmfHM= -github.com/Azure/azure-sdk-for-go/sdk/internal v0.8.3 h1:E+m3SkZCN0Bf5q7YdTs5lSm2CYY3CK4spn5OmUIiQtk= -github.com/Azure/azure-sdk-for-go/sdk/internal v0.8.3/go.mod h1:KLF4gFr6DcKFZwSuH8w8yEK6DpFl3LP5rhdvAb7Yz5I= -github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v0.3.0 h1:Px2UA+2RvSSvv+RvJNuUB6n7rs5Wsel4dXLe90Um2n4= -github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v0.3.0/go.mod h1:tPaiy8S5bQ+S5sOiDlINkp7+Ef339+Nz5L5XO+cnOHo= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= -github.com/BurntSushi/toml v1.2.1 h1:9F2/+DoOYIOksmaJFPw1tGFy1eDnIJXg+UHjuD8lTak= -github.com/BurntSushi/toml v1.2.1/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= -github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802 h1:1BDTz0u9nC3//pOCMdNH+CiXJVYJh5UQNCOBG7jbELc= -github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= -github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1:URdX5+vg25ts3aCh8H5IFZybJYKWhJHYMTnf+ULtoC4= -github.com/ChainSafe/go-schnorrkel v1.0.0 h1:3aDA67lAykLaG1y3AOjs88dMxC88PgUuHRrLeDnvGIM= -github.com/ChainSafe/go-schnorrkel v1.0.0/go.mod h1:dpzHYVxLZcp8pjlV+O+UR8K0Hp/z7vcchBSbMBEhCw4= -github.com/CloudyKit/fastprinter v0.0.0-20170127035650-74b38d55f37a/go.mod h1:EFZQ978U7x8IRnstaskI3IysnWY5Ao3QgZUKOXlsAdw= -github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53 h1:sR+/8Yb4slttB4vD+b9btVEnWgL3Q00OBTzVT8B9C0c= -github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3IMCy2vIlbG1XG/0ggNQv0SvxCAIpPM5b1nCz56Xno= -github.com/CloudyKit/jet v2.1.3-0.20180809161101-62edd43e4f88+incompatible h1:rZgFj+Gtf3NMi/U5FvCvhzaxzW/TaPYgUYx3bAPz9DE= -github.com/CloudyKit/jet v2.1.3-0.20180809161101-62edd43e4f88+incompatible/go.mod h1:HPYO+50pSWkPoj9Q/eq0aRGByCL6ScRlUmiEX5Zgm+w= -github.com/CloudyKit/jet/v3 v3.0.0 h1:1PwO5w5VCtlUUl+KTOBsTGZlhjWkcybsGaAau52tOy8= -github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= -github.com/CloudyKit/jet/v6 v6.2.0 h1:EpcZ6SR9n28BUGtNJSvlBqf90IpjeFr36Tizxhn/oME= -github.com/CloudyKit/jet/v6 v6.2.0/go.mod h1:d3ypHeIRNo2+XyqnGA8s+aphtcVpjP5hPwP/Lzo7Ro4= -github.com/DATA-DOG/go-sqlmock v1.5.0 h1:Shsta01QNfFxHCfpW6YH2STWB0MudeXXEWMr20OEh60= -github.com/DATA-DOG/go-sqlmock v1.5.0/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= -github.com/DataDog/zstd v1.4.5/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= -github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24 h1:sHglBQTwgx+rWPdisA5ynNEsoARbiCBOyGcJM4/OzsM= -github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24/go.mod h1:4UJr5HIiMZrwgkSPdsjy2uOQExX/WEILpIrO9UPGuXs= -github.com/GaijinEntertainment/go-exhaustruct/v2 v2.3.0 h1:+r1rSv4gvYn0wmRjC8X7IAzX8QezqtFV9m0MUHFJgts= -github.com/GaijinEntertainment/go-exhaustruct/v2 v2.3.0/go.mod h1:b3g59n2Y+T5xmcxJL+UEG2f8cQploZm1mR/v6BW0mU0= -github.com/GoogleCloudPlatform/cloudsql-proxy v0.0.0-20190129172621-c8b1d7a94ddf h1:8F6fjL5iQP6sArGtPuXh0l6hggdcIpAm4ChjVJE4oTs= -github.com/GoogleCloudPlatform/cloudsql-proxy v0.0.0-20190129172621-c8b1d7a94ddf/go.mod h1:aJ4qN3TfrelA6NZ6AXsXRfmEVaYin3EDbSPJrKS8OXo= -github.com/GoogleCloudPlatform/grpc-gcp-go/grpcgcp v1.5.0 h1:oVLqHXhnYtUwM89y9T1fXGaK9wTkXHgNp8/ZNMQzUxE= -github.com/GoogleCloudPlatform/grpc-gcp-go/grpcgcp v1.5.0/go.mod h1:dppbR7CwXD4pgtV9t3wD1812RaLDcBjtblcDF5f1vI0= -github.com/HdrHistogram/hdrhistogram-go v1.1.2 h1:5IcZpTvzydCQeHzK4Ef/D5rrSqwxob0t8PQPMybUNFM= -github.com/HdrHistogram/hdrhistogram-go v1.1.2/go.mod h1:yDgFjdqOqDEKOvasDdhWNXYg9BVp4O+o5f6V/ehm6Oo= -github.com/Joker/hpp v1.0.0 h1:65+iuJYdRXv/XyN62C1uEmmOx3432rNG/rKlX6V7Kkc= -github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= -github.com/Joker/jade v1.0.1-0.20190614124447-d475f43051e7/go.mod h1:6E6s8o2AE4KhCrqr6GRJjdC/gNfTdxkIXvuGZZda2VM= -github.com/Joker/jade v1.1.3 h1:Qbeh12Vq6BxURXT1qZBRHsDxeURB8ztcL6f3EXSGeHk= -github.com/Joker/jade v1.1.3/go.mod h1:T+2WLyt7VH6Lp0TRxQrUYEs64nRc83wkMQrfeIQKduM= -github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible h1:1G1pk05UrOh0NlF1oeaaix1x8XzrfjIDK47TY0Zehcw= -github.com/Masterminds/semver v1.5.0 h1:H65muMkzWKEuNDnfl9d70GUjFniHKHRbFPGBuZ3QEww= -github.com/Masterminds/semver v1.5.0/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y= -github.com/Masterminds/semver/v3 v3.2.0 h1:3MEsd0SM6jqZojhjLWWeBY+Kcjy9i6MQAeY7YgDP83g= -github.com/Masterminds/semver/v3 v3.2.0/go.mod h1:qvl/7zhW3nngYb5+80sSMF+FG2BjYrf8m9wsX0PNOMQ= -github.com/Microsoft/go-winio v0.5.2/go.mod h1:WpS1mjBmmwHBEWmogvA2mj8546UReBk4v8QkMxJ6pZY= -github.com/Microsoft/hcsshim v0.9.4 h1:mnUj0ivWy6UzbB1uLFqKR6F+ZyiDc7j4iGgHTpO+5+I= -github.com/Microsoft/hcsshim v0.9.4/go.mod h1:7pLA8lDk46WKDWlVsENo92gC0XFa8rbKfyFRBqxEbCc= -github.com/OneOfOne/xxhash v1.2.2 h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE= -github.com/OpenPeeDeeP/depguard v1.1.1 h1:TSUznLjvp/4IUP+OQ0t/4jF4QUyxIcVX8YnghZdunyA= -github.com/OpenPeeDeeP/depguard v1.1.1/go.mod h1:JtAMzWkmFEzDPyAd+W0NHl1lvpQKTvT9jnRVsohBKpc= -github.com/ProtonMail/go-crypto v0.0.0-20230828082145-3c4c8a2d2371 h1:kkhsdkhsCvIsutKu5zLMgWtgh9YxGCNAw8Ad8hjwfYg= -github.com/ProtonMail/go-crypto v0.0.0-20230828082145-3c4c8a2d2371/go.mod h1:EjAoLdwvbIOoOQr3ihjnSoLZRtE8azugULFRteWMNc0= -github.com/RoaringBitmap/roaring v1.2.2 h1:RT+1qfb7a8rkOIxPnyJdvU4G8Ynmhc2YYP6MvzqEtwk= -github.com/RoaringBitmap/roaring v1.2.2/go.mod h1:plvDsJQpxOC5bw8LRteu/MLWHsHez/3y6cubLI4/1yE= -github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= -github.com/Shopify/goreferrer v0.0.0-20220729165902-8cddb4f5de06 h1:KkH3I3sJuOLP3TjA/dfr4NAY8bghDwnXiU7cTKxQqo0= -github.com/Shopify/goreferrer v0.0.0-20220729165902-8cddb4f5de06/go.mod h1:7erjKLwalezA0k99cWs5L11HWOAPNjdUZ6RxH1BXbbM= -github.com/Shopify/sarama v1.19.0 h1:9oksLxC6uxVPHPVYUmq6xhr1BOF/hHobWH2UzO67z1s= -github.com/Shopify/toxiproxy v2.1.4+incompatible h1:TKdv8HiTLgE5wdJuEML90aBgNWsokNbMijUGhmcoBJc= -github.com/VictoriaMetrics/metrics v1.23.1 h1:/j8DzeJBxSpL2qSIdqnRFLvQQhbJyJbbEi22yMm7oL0= -github.com/VictoriaMetrics/metrics v1.23.1/go.mod h1:rAr/llLpEnAdTehiNlUxKgnjcOuROSzpw0GvjpEbvFc= -github.com/aclements/go-gg v0.0.0-20170118225347-6dbb4e4fefb0 h1:E5Dzlk3akC+T2Zj1LBHgfPK1y8YWgLDnNDRmG+tpSKw= -github.com/aclements/go-gg v0.0.0-20170118225347-6dbb4e4fefb0/go.mod h1:55qNq4vcpkIuHowELi5C8e+1yUHtoLoOUR9QU5j7Tes= -github.com/aclements/go-moremath v0.0.0-20210112150236-f10218a38794 h1:xlwdaKcTNVW4PtpQb8aKA4Pjy0CdJHEqvFbAnvR5m2g= -github.com/aclements/go-moremath v0.0.0-20210112150236-f10218a38794/go.mod h1:7e+I0LQFUI9AXWxOfsQROs9xPhoJtbsyWcjJqDd4KPY= -github.com/aead/siphash v1.0.1 h1:FwHfE/T45KPKYuuSAKyyvE+oPWcaQ+CUmFW0bPlM+kg= -github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5 h1:rFw4nCn9iMW+Vajsk51NtYIcwSTkXr+JGrMd36kTDJw= -github.com/agext/levenshtein v1.2.3 h1:YB2fHEn0UJagG8T1rrWknE3ZQzWM06O8AMAatNn7lmo= -github.com/agext/levenshtein v1.2.3/go.mod h1:JEDfjyjHDjOF/1e4FlBE/PkbqA9OfWu2ki2W0IB5558= -github.com/ajg/form v1.5.1 h1:t9c7v8JUKu/XxOGBU0yjNpaMloxGEJhUkqFRq0ibGeU= -github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= -github.com/ajstarks/deck v0.0.0-20200831202436-30c9fc6549a9 h1:7kQgkwGRoLzC9K0oyXdJo7nve/bynv/KwUsxbiTlzAM= -github.com/ajstarks/deck v0.0.0-20200831202436-30c9fc6549a9/go.mod h1:JynElWSGnm/4RlzPXRlREEwqTHAN3T56Bv2ITsFT3gY= -github.com/ajstarks/deck/generate v0.0.0-20210309230005-c3f852c02e19 h1:iXUgAaqDcIUGbRoy2TdeofRG/j1zpGRSEmNK05T+bi8= -github.com/ajstarks/deck/generate v0.0.0-20210309230005-c3f852c02e19/go.mod h1:T13YZdzov6OU0A1+RfKZiZN9ca6VeKdBdyDV+BY97Tk= -github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw= -github.com/ajstarks/svgo v0.0.0-20210923152817-c3b6e2f0c527 h1:NImof/JkF93OVWZY+PINgl6fPtQyF6f+hNUtZ0QZA1c= -github.com/ajstarks/svgo v0.0.0-20210923152817-c3b6e2f0c527/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw= -github.com/ajstarks/svgo v0.0.0-20211024235047-1546f124cd8b h1:slYM766cy2nI3BwyRiyQj/Ud48djTMtMebDqepE95rw= -github.com/ajstarks/svgo v0.0.0-20211024235047-1546f124cd8b/go.mod h1:1KcenG0jGWcpt8ov532z81sp/kMMUG485J2InIOyADM= -github.com/ajwerner/btree v0.0.0-20211221152037-f427b3e689c0 h1:byYvvbfSo3+9efR4IeReh77gVs4PnNDR3AMOE9NJ7a0= -github.com/ajwerner/btree v0.0.0-20211221152037-f427b3e689c0/go.mod h1:q37NoqncT41qKc048STsifIt69LfUJ8SrWWcz/yam5k= -github.com/alecthomas/atomic v0.1.0-alpha2 h1:dqwXmax66gXvHhsOS4pGPZKqYOlTkapELkLb3MNdlH8= -github.com/alecthomas/atomic v0.1.0-alpha2/go.mod h1:zD6QGEyw49HIq19caJDc2NMXAy8rNi9ROrxtMXATfyI= -github.com/alecthomas/kingpin/v2 v2.3.2 h1:H0aULhgmSzN8xQ3nX1uxtdlTHYoPLu5AhHxWrKI6ocU= -github.com/alecthomas/kingpin/v2 v2.3.2/go.mod h1:0gyi0zQnjuFk8xrkNKamJoyUo382HRL7ATRpFZCw6tE= -github.com/alecthomas/kingpin/v2 v2.4.0 h1:f48lwail6p8zpO1bC4TxtqACaGqHYA22qkHjHpqDjYY= -github.com/alecthomas/kingpin/v2 v2.4.0/go.mod h1:0gyi0zQnjuFk8xrkNKamJoyUo382HRL7ATRpFZCw6tE= -github.com/alecthomas/participle/v2 v2.0.0-alpha7 h1:cK4vjj0VSgb3lN1nuKA5F7dw+1s1pWBe5bx7nNCnN+c= -github.com/alecthomas/participle/v2 v2.0.0-alpha7/go.mod h1:NumScqsC42o9x+dGj8/YqsIfhrIQjFEOFovxotbBirA= -github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM= -github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137 h1:s6gZFSlWYmbqAuRjVTiNNhvNRfY2Wxp9nhfyel4rklc= -github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= -github.com/alexkohler/prealloc v1.0.0 h1:Hbq0/3fJPQhNkN0dR95AVrr6R7tou91y0uHG5pOcUuw= -github.com/alexkohler/prealloc v1.0.0/go.mod h1:VetnK3dIgFBBKmg0YnD9F9x6Icjd+9cvfHR56wJVlKE= -github.com/alingse/asasalint v0.0.11 h1:SFwnQXJ49Kx/1GghOFz1XGqHYKp21Kq1nHad/0WQRnw= -github.com/alingse/asasalint v0.0.11/go.mod h1:nCaoMhw7a9kSJObvQyVzNTPBDbNpdocqrSP7t/cW5+I= -github.com/anacrolix/chansync v0.3.0 h1:lRu9tbeuw3wl+PhMu/r+JJCRu5ArFXIluOgdF0ao6/U= -github.com/anacrolix/chansync v0.3.0/go.mod h1:DZsatdsdXxD0WiwcGl0nJVwyjCKMDv+knl1q2iBjA2k= -github.com/anacrolix/dht/v2 v2.19.2-0.20221121215055-066ad8494444 h1:8V0K09lrGoeT2KRJNOtspA7q+OMxGwQqK/Ug0IiaaRE= -github.com/anacrolix/dht/v2 v2.19.2-0.20221121215055-066ad8494444/go.mod h1:MctKM1HS5YYDb3F30NGJxLE+QPuqWoT5ReW/4jt8xew= -github.com/anacrolix/envpprof v1.2.1 h1:25TJe6t/i0AfzzldiGFKCpD+s+dk8lONBcacJZB2rdE= -github.com/anacrolix/envpprof v1.2.1/go.mod h1:My7T5oSqVfEn4MD4Meczkw/f5lSIndGAKu/0SM/rkf4= -github.com/anacrolix/generics v0.0.0-20220618083756-f99e35403a60 h1:k4/h2B1gGF+PJGyGHxs8nmHHt1pzWXZWBj6jn4OBlRc= -github.com/anacrolix/generics v0.0.0-20220618083756-f99e35403a60/go.mod h1:ff2rHB/joTV03aMSSn/AZNnaIpUw0h3njetGsaXcMy8= -github.com/anacrolix/go-libutp v1.2.0 h1:sjxoB+/ARiKUR7IK/6wLWyADIBqGmu1fm0xo+8Yy7u0= -github.com/anacrolix/go-libutp v1.2.0/go.mod h1:RrJ3KcaDcf9Jqp33YL5V/5CBEc6xMc7aJL8wXfuWL50= -github.com/anacrolix/log v0.13.2-0.20221123232138-02e2764801c3 h1:qDcPnH18SanNZMeMuEjzKpB3NQGR1ahytV08KOhZhNo= -github.com/anacrolix/log v0.13.2-0.20221123232138-02e2764801c3/go.mod h1:MD4fn2pYcyhUAQg9SxoGOpTnV/VIdiKVYKZdCbDC97k= -github.com/anacrolix/missinggo v1.3.0 h1:06HlMsudotL7BAELRZs0yDZ4yVXsHXGi323QBjAVASw= -github.com/anacrolix/missinggo v1.3.0/go.mod h1:bqHm8cE8xr+15uVfMG3BFui/TxyB6//H5fwlq/TeqMc= -github.com/anacrolix/missinggo/perf v1.0.0 h1:7ZOGYziGEBytW49+KmYGTaNfnwUqP1HBsy6BqESAJVw= -github.com/anacrolix/missinggo/perf v1.0.0/go.mod h1:ljAFWkBuzkO12MQclXzZrosP5urunoLS0Cbvb4V0uMQ= -github.com/anacrolix/missinggo/v2 v2.7.0 h1:4fzOAAn/VCvfWGviLmh64MPMttrlYew81JdPO7nSHvI= -github.com/anacrolix/missinggo/v2 v2.7.0/go.mod h1:2IZIvmRTizALNYFYXsPR7ofXPzJgyBpKZ4kMqMEICkI= -github.com/anacrolix/mmsg v1.0.0 h1:btC7YLjOn29aTUAExJiVUhQOuf/8rhm+/nWCMAnL3Hg= -github.com/anacrolix/mmsg v1.0.0/go.mod h1:x8kRaJY/dCrY9Al0PEcj1mb/uFHwP6GCJ9fLl4thEPc= -github.com/anacrolix/multiless v0.3.0 h1:5Bu0DZncjE4e06b9r1Ap2tUY4Au0NToBP5RpuEngSis= -github.com/anacrolix/multiless v0.3.0/go.mod h1:TrCLEZfIDbMVfLoQt5tOoiBS/uq4y8+ojuEVVvTNPX4= -github.com/anacrolix/stm v0.4.0 h1:tOGvuFwaBjeu1u9X1eIh9TX8OEedEiEQ1se1FjhFnXY= -github.com/anacrolix/stm v0.4.0/go.mod h1:GCkwqWoAsP7RfLW+jw+Z0ovrt2OO7wRzcTtFYMYY5t8= -github.com/anacrolix/sync v0.4.0 h1:T+MdO/u87ir/ijWsTFsPYw5jVm0SMm4kVpg8t4KF38o= -github.com/anacrolix/sync v0.4.0/go.mod h1:BbecHL6jDSExojhNtgTFSBcdGerzNc64tz3DCOj/I0g= -github.com/anacrolix/torrent v1.48.0 h1:OQe1aQb8WnhDzpcI7r3yWoHzHWKyPbfhXGfO9Q/pvbY= -github.com/anacrolix/torrent v1.48.0/go.mod h1:3UtkJ8BnxXDRwvk+eT+uwiZalfFJ8YzAhvxe4QRPSJI= -github.com/anacrolix/upnp v0.1.3-0.20220123035249-922794e51c96 h1:QAVZ3pN/J4/UziniAhJR2OZ9Ox5kOY2053tBbbqUPYA= -github.com/anacrolix/upnp v0.1.3-0.20220123035249-922794e51c96/go.mod h1:Wa6n8cYIdaG35x15aH3Zy6d03f7P728QfdcDeD/IEOs= -github.com/anacrolix/utp v0.1.0 h1:FOpQOmIwYsnENnz7tAGohA+r6iXpRjrq8ssKSre2Cp4= -github.com/anacrolix/utp v0.1.0/go.mod h1:MDwc+vsGEq7RMw6lr2GKOEqjWny5hO5OZXRVNaBJ2Dk= -github.com/andybalholm/brotli v1.0.4/go.mod h1:fO7iG3H7G2nSZ7m0zPUDn85XEX2GTukHGRSepvi9Eig= -github.com/andybalholm/brotli v1.0.5 h1:8uQZIdzKmjc/iuPu7O2ioW48L81FgatrcpfFmiq/cCs= -github.com/andybalholm/brotli v1.0.5/go.mod h1:fO7iG3H7G2nSZ7m0zPUDn85XEX2GTukHGRSepvi9Eig= -github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be h1:9AeTilPcZAjCFIImctFaOjnTIavg87rW78vTPkQqLI8= -github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be/go.mod h1:ySMOLuWl6zY27l47sB3qLNK6tF2fkHG55UZxx8oIVo4= -github.com/antihax/optional v1.0.0 h1:xK2lYat7ZLaVVcIuj82J8kIro4V6kDe0AUDFboUCwcg= -github.com/apache/arrow/go/v14 v14.0.2 h1:N8OkaJEOfI3mEZt07BIkvo4sC6XDbL+48MBPWO5IONw= -github.com/apache/arrow/go/v14 v14.0.2/go.mod h1:u3fgh3EdgN/YQ8cVQRguVW3R+seMybFg8QBQ5LU+eBY= -github.com/apache/arrow/go/v15 v15.0.2 h1:60IliRbiyTWCWjERBCkO1W4Qun9svcYoZrSLcyOsMLE= -github.com/apache/arrow/go/v15 v15.0.2/go.mod h1:DGXsR3ajT524njufqf95822i+KTh+yea1jass9YXgjA= -github.com/apache/thrift v0.13.0 h1:5hryIiq9gtn+MiLVn0wP37kb/uTeRZgN08WoCsAhIhI= -github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e h1:QEF07wC0T1rKkctt1RINW/+RMTVmiwxETico2l3gxJA= -github.com/armon/circbuf v0.0.0-20190214190532-5111143e8da2 h1:7Ip0wMmLHLRJdrloDxZfhMm0xrLXZS8+COSu2bXmEQs= -github.com/armon/circbuf v0.0.0-20190214190532-5111143e8da2/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= -github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6 h1:G1bPvciwNyF7IUmKXNt9Ak3m6u9DE1rF+RmtIkBpVdA= -github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= -github.com/armon/go-metrics v0.4.1 h1:hR91U9KYmb6bLBYLQjyM+3j+rcd/UhE+G78SFnF8gJA= -github.com/armon/go-metrics v0.4.1/go.mod h1:E6amYzXo6aW1tqzoZGT755KkbgrJsSdpwZ+3JqfkOG4= -github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310 h1:BUAU3CGlLvorLI26FmByPp2eC2qla6E1Tw+scpcg/to= -github.com/armon/go-radix v1.0.0 h1:F4z6KzEeeQIMeLFa97iZU6vupzoecKdU5TX24SNppXI= -github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= -github.com/aryann/difflib v0.0.0-20170710044230-e206f873d14a h1:pv34s756C4pEXnjgPfGYgdhg/ZdajGhyOvzx8k+23nw= -github.com/ashanbrown/forbidigo v1.3.0 h1:VkYIwb/xxdireGAdJNZoo24O4lmnEWkactplBlWTShc= -github.com/ashanbrown/forbidigo v1.3.0/go.mod h1:vVW7PEdqEFqapJe95xHkTfB1+XvZXBFg8t0sG2FIxmI= -github.com/ashanbrown/forbidigo v1.5.1 h1:WXhzLjOlnuDYPYQo/eFlcFMi8X/kLfvWLYu6CSoebis= -github.com/ashanbrown/forbidigo v1.5.1/go.mod h1:Y8j9jy9ZYAEHXdu723cUlraTqbzjKF1MUyfOKL+AjcU= -github.com/ashanbrown/makezero v1.1.1 h1:iCQ87C0V0vSyO+M9E/FZYbu65auqH0lnsOkf5FcB28s= -github.com/ashanbrown/makezero v1.1.1/go.mod h1:i1bJLCRSCHOcOa9Y6MyF2FTfMZMFdHvxKHxgO5Z1axI= -github.com/aws/aws-lambda-go v1.13.3 h1:SuCy7H3NLyp+1Mrfp+m80jcbi9KYWAs9/BXwppwRDzY= -github.com/aws/aws-sdk-go v1.44.203/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI= -github.com/aws/aws-sdk-go-v2 v1.9.1 h1:ZbovGV/qo40nrOJ4q8G33AGICzaPI45FHQWJ9650pF4= -github.com/aws/aws-sdk-go-v2 v1.9.1/go.mod h1:cK/D0BBs0b/oWPIcX/Z/obahJK1TT7IPVjy53i/mX/4= -github.com/aws/aws-sdk-go-v2/config v1.1.1 h1:ZAoq32boMzcaTW9bcUacBswAmHTbvlvDJICgHFZuECo= -github.com/aws/aws-sdk-go-v2/config v1.1.1/go.mod h1:0XsVy9lBI/BCXm+2Tuvt39YmdHwS5unDQmxZOYe8F5Y= -github.com/aws/aws-sdk-go-v2/credentials v1.1.1 h1:NbvWIM1Mx6sNPTxowHgS2ewXCRp+NGTzUYb/96FZJbY= -github.com/aws/aws-sdk-go-v2/credentials v1.1.1/go.mod h1:mM2iIjwl7LULWtS6JCACyInboHirisUUdkBPoTHMOUo= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.0.2 h1:EtEU7WRaWliitZh2nmuxEXrN0Cb8EgPUFGIoTMeqbzI= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.0.2/go.mod h1:3hGg3PpiEjHnrkrlasTfxFqUsZ2GCk/fMUn4CbKgSkM= -github.com/aws/aws-sdk-go-v2/service/cloudwatch v1.8.1 h1:w/fPGB0t5rWwA43mux4e9ozFSH5zF1moQemlA131PWc= -github.com/aws/aws-sdk-go-v2/service/cloudwatch v1.8.1/go.mod h1:CM+19rL1+4dFWnOQKwDc7H1KwXTz+h61oUSHyhV0b3o= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.0.2 h1:4AH9fFjUlVktQMznF+YN33aWNXaR4VgDXyP28qokJC0= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.0.2/go.mod h1:45MfaXZ0cNbeuT0KQ1XJylq8A6+OpVV2E5kvY/Kq+u8= -github.com/aws/aws-sdk-go-v2/service/route53 v1.1.1 h1:cKr6St+CtC3/dl/rEBJvlk7A/IN5D5F02GNkGzfbtVU= -github.com/aws/aws-sdk-go-v2/service/route53 v1.1.1/go.mod h1:rLiOUrPLW/Er5kRcQ7NkwbjlijluLsrIbu/iyl35RO4= -github.com/aws/aws-sdk-go-v2/service/sso v1.1.1 h1:37QubsarExl5ZuCBlnRP+7l1tNwZPBSTqpTBrPH98RU= -github.com/aws/aws-sdk-go-v2/service/sso v1.1.1/go.mod h1:SuZJxklHxLAXgLTc1iFXbEWkXs7QRTQpCLGaKIprQW0= -github.com/aws/aws-sdk-go-v2/service/sts v1.1.1 h1:TJoIfnIFubCX0ACVeJ0w46HEH5MwjwYN4iFhuYIhfIY= -github.com/aws/aws-sdk-go-v2/service/sts v1.1.1/go.mod h1:Wi0EBZwiz/K44YliU0EKxqTCJGUfYTWXrrBwkq736bM= -github.com/aws/smithy-go v1.8.0 h1:AEwwwXQZtUwP5Mz506FeXXrKBe0jA8gVM+1gEcSRooc= -github.com/aws/smithy-go v1.8.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E= -github.com/aymerick/douceur v0.2.0 h1:Mv+mAeH1Q+n9Fr+oyamOlAkUNPWPlA8PPGR0QAaYuPk= -github.com/aymerick/douceur v0.2.0/go.mod h1:wlT5vV2O3h55X9m7iVYN0TBM0NH/MmbLnd30/FjWUq4= -github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible h1:Ppm0npCCsmuR9oQaBtRuZcmILVE74aXE+AmrJj8L2ns= -github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g= -github.com/bahlo/generic-list-go v0.2.0 h1:5sz/EEAK+ls5wF+NeqDpk5+iNdMDXrh3z3nPnH1Wvgk= -github.com/bahlo/generic-list-go v0.2.0/go.mod h1:2KvAjgMlE5NNynlg/5iLrrCCZ2+5xWbdbCW3pNTGyYg= -github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8= -github.com/benbjohnson/clock v1.3.0 h1:ip6w0uFQkncKQ979AypyG0ER7mqUSBdKLOgAle/AT8A= -github.com/benbjohnson/clock v1.3.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= -github.com/benbjohnson/immutable v0.3.0 h1:TVRhuZx2wG9SZ0LRdqlbs9S5BZ6Y24hJEHTCgWHZEIw= -github.com/benbjohnson/immutable v0.3.0/go.mod h1:uc6OHo6PN2++n98KHLxW8ef4W42ylHiQSENghE1ezxI= -github.com/bits-and-blooms/bitset v1.2.2 h1:J5gbX05GpMdBjCvQ9MteIg2KKDExr7DrgK+Yc15FvIk= -github.com/bits-and-blooms/bitset v1.2.2/go.mod h1:gIdJ4wp64HaoK2YrL1Q5/N7Y16edYb8uY+O0FJTyyDA= -github.com/bkielbasa/cyclop v1.2.0 h1:7Jmnh0yL2DjKfw28p86YTd/B4lRGcNuu12sKE35sM7A= -github.com/bkielbasa/cyclop v1.2.0/go.mod h1:qOI0yy6A7dYC4Zgsa72Ppm9kONl0RoIlPbzot9mhmeI= -github.com/blang/semver v3.5.1+incompatible h1:cQNTCjp13qL8KC3Nbxr/y2Bqb63oX6wdnnjpJbkM4JQ= -github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk= -github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM= -github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= -github.com/blizzy78/varnamelen v0.8.0 h1:oqSblyuQvFsW1hbBHh1zfwrKe3kcSj0rnXkKzsQ089M= -github.com/blizzy78/varnamelen v0.8.0/go.mod h1:V9TzQZ4fLJ1DSrjVDfl89H7aMnTvKkApdHeyESmyR7k= -github.com/bombsimon/wsl/v3 v3.3.0 h1:Mka/+kRLoQJq7g2rggtgQsjuI/K5Efd87WX96EWFxjM= -github.com/bombsimon/wsl/v3 v3.3.0/go.mod h1:st10JtZYLE4D5sC7b8xV4zTKZwAQjCH/Hy2Pm1FNZIc= -github.com/bombsimon/wsl/v3 v3.4.0 h1:RkSxjT3tmlptwfgEgTgU+KYKLI35p/tviNXNXiL2aNU= -github.com/bombsimon/wsl/v3 v3.4.0/go.mod h1:KkIB+TXkqy6MvK9BDZVbZxKNYsE1/oLRJbIFtf14qqo= -github.com/boombuler/barcode v1.0.0/go.mod h1:paBWMcWSl3LHKBqUq+rly7CNSldXjb2rDl3JlRe0mD8= -github.com/boombuler/barcode v1.0.1 h1:NDBbPmhS+EqABEs5Kg3n/5ZNjy73Pz7SIV+KCeqyXcs= -github.com/boombuler/barcode v1.0.1/go.mod h1:paBWMcWSl3LHKBqUq+rly7CNSldXjb2rDl3JlRe0mD8= -github.com/bradfitz/iter v0.0.0-20191230175014-e8f45d346db8 h1:GKTyiRCL6zVf5wWaqKnf+7Qs6GbEPfd4iMOitWzXJx8= -github.com/bradfitz/iter v0.0.0-20191230175014-e8f45d346db8/go.mod h1:spo1JLcs67NmW1aVLEgtA8Yy1elc+X8y5SRW1sFW4Og= -github.com/breml/bidichk v0.2.3 h1:qe6ggxpTfA8E75hdjWPZ581sY3a2lnl0IRxLQFelECI= -github.com/breml/bidichk v0.2.3/go.mod h1:8u2C6DnAy0g2cEq+k/A2+tr9O1s+vHGxWn0LTc70T2A= -github.com/breml/bidichk v0.2.4 h1:i3yedFWWQ7YzjdZJHnPo9d/xURinSq3OM+gyM43K4/8= -github.com/breml/bidichk v0.2.4/go.mod h1:7Zk0kRFt1LIZxtQdl9W9JwGAcLTTkOs+tN7wuEYGJ3s= -github.com/breml/errchkjson v0.3.0 h1:YdDqhfqMT+I1vIxPSas44P+9Z9HzJwCeAzjB8PxP1xw= -github.com/breml/errchkjson v0.3.0/go.mod h1:9Cogkyv9gcT8HREpzi3TiqBxCqDzo8awa92zSDFcofU= -github.com/breml/errchkjson v0.3.1 h1:hlIeXuspTyt8Y/UmP5qy1JocGNR00KQHgfaNtRAjoxQ= -github.com/breml/errchkjson v0.3.1/go.mod h1:XroxrzKjdiutFyW3nWhw34VGg7kiMsDQox73yWCGI2U= -github.com/btcsuite/btcd v0.23.0/go.mod h1:0QJIIN1wwIXF/3G/m87gIwGniDMDQqjVn4SZgnFpsYY= -github.com/btcsuite/btcd/btcec/v2 v2.2.1/go.mod h1:9/CSmJxmuvqzX9Wh2fXMWToLOHhPd11lSPuIupwTkI8= -github.com/btcsuite/btcd/btcutil v1.1.2/go.mod h1:UR7dsSJzJUfMmFiiLlIrMq1lS9jh9EdCV7FStZSnpi0= -github.com/btcsuite/btcd/btcutil v1.1.3/go.mod h1:UR7dsSJzJUfMmFiiLlIrMq1lS9jh9EdCV7FStZSnpi0= -github.com/btcsuite/btclog v0.0.0-20170628155309-84c8d2346e9f h1:bAs4lUbRJpnnkd9VhRV3jjAVU7DJVjMaK+IsvSeZvFo= -github.com/btcsuite/btcutil v0.0.0-20190425235716-9e5f4b9a998d h1:yJzD/yFppdVCf6ApMkVy8cUxV0XrxdP9rVf6D87/Mng= -github.com/btcsuite/go-socks v0.0.0-20170105172521-4720035b7bfd h1:R/opQEbFEy9JGkIguV40SvRY1uliPX8ifOvi6ICsFCw= -github.com/btcsuite/goleveldb v1.0.0 h1:Tvd0BfvqX9o823q1j2UZ/epQo09eJh6dTcRp79ilIN4= -github.com/btcsuite/snappy-go v1.0.0 h1:ZxaA6lo2EpxGddsA8JwWOcxlzRybb444sgmeJQMJGQE= -github.com/btcsuite/websocket v0.0.0-20150119174127-31079b680792 h1:R8vQdOQdZ9Y3SkEwmHoWBmX1DNXhXZqlTpq6s4tyJGc= -github.com/btcsuite/winsvc v1.0.0 h1:J9B4L7e3oqhXOcm+2IuNApwzQec85lE+QaikUcCs+dk= -github.com/bufbuild/buf v1.7.0 h1:uWRjhIXcrWkzIkA5TqXGyJbF51VW54QJsQZ3nwaes5Q= -github.com/bufbuild/buf v1.7.0/go.mod h1:Go40fMAF46PnPLC7jJgTQhAI95pmC0+VtxFKVC0qLq0= -github.com/bufbuild/buf v1.15.1 h1:v7sK2uMEsGX4Z2hvu+xiMheH3C3AKBGfxPBgdUZYDQ8= -github.com/bufbuild/buf v1.15.1/go.mod h1:TQeGKam1QMfHy/xsSnnMpxN3JK5HBb6aNvZj4m52gkE= -github.com/bufbuild/connect-go v1.0.0 h1:htSflKUT8y1jxhoPhPYTZMrsY3ipUXjjrbcZR5O2cVo= -github.com/bufbuild/connect-go v1.0.0/go.mod h1:9iNvh/NOsfhNBUH5CtvXeVUskQO1xsrEviH7ZArwZ3I= -github.com/bufbuild/connect-go v1.5.2 h1:G4EZd5gF1U1ZhhbVJXplbuUnfKpBZ5j5izqIwu2g2W8= -github.com/bufbuild/connect-go v1.5.2/go.mod h1:GmMJYR6orFqD0Y6ZgX8pwQ8j9baizDrIQMm1/a6LnHk= -github.com/bufbuild/protocompile v0.5.1/go.mod h1:G5iLmavmF4NsYtpZFvE3B/zFch2GIY8+wjsYLR/lc40= -github.com/butuzov/ireturn v0.1.1 h1:QvrO2QF2+/Cx1WA/vETCIYBKtRjc30vesdoPUNo1EbY= -github.com/butuzov/ireturn v0.1.1/go.mod h1:Wh6Zl3IMtTpaIKbmwzqi6olnM9ptYQxxVacMsOEFPoc= -github.com/bwesterb/go-ristretto v1.2.3 h1:1w53tCkGhCQ5djbat3+MH0BAQ5Kfgbt56UZQ/JMzngw= -github.com/bwesterb/go-ristretto v1.2.3/go.mod h1:fUIoIZaG73pV5biE2Blr2xEzDoMj7NFEuV9ekS419A0= -github.com/c2h5oh/datasize v0.0.0-20220606134207-859f65c6625b h1:6+ZFm0flnudZzdSE0JxlhR2hKnGPcNB35BjQf4RYQDY= -github.com/c2h5oh/datasize v0.0.0-20220606134207-859f65c6625b/go.mod h1:S/7n9copUssQ56c7aAgHqftWO4LTf4xY6CGWt8Bc+3M= -github.com/casbin/casbin/v2 v2.37.0 h1:/poEwPSovi4bTOcP752/CsTQiRz2xycyVKFG7GUhbDw= -github.com/casbin/casbin/v2 v2.37.0/go.mod h1:vByNa/Fchek0KZUgG5wEsl7iFsiviAYKRtgrQfcJqHg= -github.com/census-instrumentation/opencensus-proto v0.4.1 h1:iKLQ0xPNFxR/2hzXZMrBo8f1j86j5WHzznCCQxV/b8g= -github.com/census-instrumentation/opencensus-proto v0.4.1/go.mod h1:4T9NM4+4Vw91VeyqjLS6ao50K5bOcLKN6Q42XnYaRYw= -github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= -github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/charithe/durationcheck v0.0.9 h1:mPP4ucLrf/rKZiIG/a9IPXHGlh8p4CzgpyTy6EEutYk= -github.com/charithe/durationcheck v0.0.9/go.mod h1:SSbRIBVfMjCi/kEB6K65XEA83D6prSM8ap1UCpNKtgg= -github.com/charithe/durationcheck v0.0.10 h1:wgw73BiocdBDQPik+zcEoBG/ob8uyBHf2iyoHGPf5w4= -github.com/charithe/durationcheck v0.0.10/go.mod h1:bCWXb7gYRysD1CU3C+u4ceO49LoGOY1C1L6uouGNreQ= -github.com/chavacava/garif v0.0.0-20220630083739-93517212f375 h1:E7LT642ysztPWE0dfz43cWOvMiF42DyTRC+eZIaO4yI= -github.com/chavacava/garif v0.0.0-20220630083739-93517212f375/go.mod h1:4m1Rv7xfuwWPNKXlThldNuJvutYM6J95wNuuVmn55To= -github.com/chavacava/garif v0.0.0-20230227094218-b8c73b2037b8 h1:W9o46d2kbNL06lq7UNDPV0zYLzkrde/bjIqO02eoll0= -github.com/chavacava/garif v0.0.0-20230227094218-b8c73b2037b8/go.mod h1:gakxgyXaaPkxvLw1XQxNGK4I37ys9iBRzNUx/B7pUCo= -github.com/checkpoint-restore/go-criu/v5 v5.3.0 h1:wpFFOoomK3389ue2lAb0Boag6XPht5QYpipxmSNL4d8= -github.com/checkpoint-restore/go-criu/v5 v5.3.0/go.mod h1:E/eQpaFtUKGOOSEBZgmKAcn+zUUwWxqcaKZlF54wK8E= -github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927 h1:SKI1/fuSdodxmNNyVBR8d7X/HuLnRpvvFO0AgyQk764= -github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927/go.mod h1:h/aW8ynjgkuj+NQRlZcDbAbM1ORAbXjXX77sX7T289U= -github.com/cheggaaa/pb v1.0.27 h1:wIkZHkNfC7R6GI5w7l/PdAdzXzlrbcI3p8OAlnkTsnc= -github.com/chigopher/pathlib v0.12.0 h1:1GM7fN/IwXXmOHbd1jkMqHD2wUhYqUvafgxTwmLT/q8= -github.com/chigopher/pathlib v0.12.0/go.mod h1:EJ5UtJ/sK8Nt6q3VWN+EwZLZ3g0afJiG8NegYiQQ/gQ= -github.com/chromedp/cdproto v0.0.0-20230802225258-3cf4e6d46a89 h1:aPflPkRFkVwbW6dmcVqfgwp1i+UWGFH6VgR1Jim5Ygc= -github.com/chromedp/cdproto v0.0.0-20230802225258-3cf4e6d46a89/go.mod h1:GKljq0VrfU4D5yc+2qA6OVr8pmO/MBbPEWqWQ/oqGEs= -github.com/chromedp/chromedp v0.9.2 h1:dKtNz4kApb06KuSXoTQIyUC2TrA0fhGDwNZf3bcgfKw= -github.com/chromedp/chromedp v0.9.2/go.mod h1:LkSXJKONWTCHAfQasKFUZI+mxqS4tZqhmtGzzhLsnLs= -github.com/chromedp/sysutil v1.0.0 h1:+ZxhTpfpZlmchB58ih/LBHX52ky7w2VhQVKQMucy3Ic= -github.com/chromedp/sysutil v1.0.0/go.mod h1:kgWmDdq8fTzXYcKIBqIYvRRTnYb9aNS9moAV0xufSww= -github.com/cilium/ebpf v0.7.0 h1:1k/q3ATgxSXRdrmPfH8d7YK0GfqVsEKZAX9dQZvs56k= -github.com/cilium/ebpf v0.7.0/go.mod h1:/oI2+1shJiTGAMgl6/RgJr36Eo1jzrRcAWbcXO2usCA= -github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible h1:C29Ae4G5GtYyYMm1aztcyj/J5ckgJm2zwdDajFbx1NY= -github.com/circonus-labs/circonusllhist v0.1.3 h1:TJH+oke8D16535+jHExHj4nQvzlZrj7ug5D7I/orNUA= -github.com/clbanning/mxj v1.8.4 h1:HuhwZtbyvyOw+3Z1AowPkU87JkJUSv751ELWaiTpj8I= -github.com/clbanning/mxj v1.8.4/go.mod h1:BVjHeAH+rl9rs6f+QIpeRl0tfu10SXn1pUSa5PVGJng= -github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec h1:EdRZT3IeKQmfCSrgo8SZ8V3MEnskuJP0wCYNpe+aiXo= -github.com/client9/misspell v0.3.4 h1:ta993UF76GwbvJcIo3Y68y/M3WxlpEHPWIGDkJYwzJI= -github.com/cloudflare/circl v1.3.3/go.mod h1:5XYMA4rFBvNIrhs50XuiBJ15vF2pZn4nnUKZrLbUZFA= -github.com/cloudflare/circl v1.3.7 h1:qlCDlTPz2n9fu58M0Nh1J/JzcFpfgkFHHX3O35r5vcU= -github.com/cloudflare/circl v1.3.7/go.mod h1:sRTcRWXGLrKw6yIGJ+l7amYJFfAXbZG0kBSc8r4zxgA= -github.com/cloudflare/cloudflare-go v0.14.0 h1:gFqGlGl/5f9UGXAaKapCGUfaTCgRKKnzu2VvzMZlOFA= -github.com/cloudflare/cloudflare-go v0.14.0/go.mod h1:EnwdgGMaFOruiPZRFSgn+TsQ3hQ7C/YWzIGLeu5c304= -github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4 h1:hzAQntlaYRkVSFEfj9OTWlVV1H155FMD8BTKktLv0QI= -github.com/cncf/udpa/go v0.0.0-20220112060539-c52dc94e7fbe h1:QQ3GSy+MqSHxm/d8nCtnAiZdYFd45cYZPs8vOOIYKfk= -github.com/cncf/udpa/go v0.0.0-20220112060539-c52dc94e7fbe/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= -github.com/cncf/xds/go v0.0.0-20240423153145-555b57ec207b h1:ga8SEFjZ60pxLcmhnThWgvH2wg8376yUJmPhEH4H3kw= -github.com/cncf/xds/go v0.0.0-20240423153145-555b57ec207b/go.mod h1:W+zGtBO5Y1IgJhy4+A9GOqVhqLpfZi+vwmdNXUehLA8= -github.com/cockroachdb/apd/v3 v3.1.0 h1:MK3Ow7LH0W8zkd5GMKA1PvS9qG3bWFI95WaVNfyZJ/w= -github.com/cockroachdb/apd/v3 v3.1.0/go.mod h1:6qgPBMXjATAdD/VefbRP9NoSLKjbB4LCoA7gN4LpHs4= -github.com/cockroachdb/datadriven v1.0.0/go.mod h1:5Ib8Meh+jk1RlHIXej6Pzevx/NLlNvQB9pmSBZErGA4= -github.com/cockroachdb/datadriven v1.0.2/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= -github.com/cockroachdb/errors v1.6.1/go.mod h1:tm6FTP5G81vwJ5lC0SizQo374JNCOPrHyXGitRJoDqM= -github.com/cockroachdb/errors v1.8.1/go.mod h1:qGwQn6JmZ+oMjuLwjWzUNqblqk0xl4CVV3SQbGwK7Ac= -github.com/cockroachdb/errors v1.9.1/go.mod h1:2sxOtL2WIc096WSZqZ5h8fa17rdDq9HZOZLBCor4mBk= -github.com/cockroachdb/errors v1.10.0/go.mod h1:lknhIsEVQ9Ss/qKDBQS/UqFSvPQjOwNq2qyKAxtHRqE= -github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f/go.mod h1:i/u985jwjWRlyHXQbwatDASoW0RMlZ/3i9yJHE2xLkI= -github.com/cockroachdb/logtags v0.0.0-20211118104740-dabe8e521a4f/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= -github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677/go.mod h1:890yq1fUb9b6dGNwssgeUO5vQV9qfXnCPxAJhBQfXw0= -github.com/cockroachdb/pebble v0.0.0-20230226194802-02d779ffbc46/go.mod h1:9lRMC4XN3/BLPtIp6kAKwIaHu369NOf2rMucPzipz50= -github.com/cockroachdb/pebble v0.0.0-20230525220056-bb4fc9527b3b/go.mod h1:TkdVsGYRqtULUppt2RbC+YaKtTHnHoWa2apfFrSKABw= -github.com/cockroachdb/redact v1.0.8/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/cockroachdb/redact v1.1.3/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2 h1:IKgmqgMQlVJIZj19CdocBeSfSaiCbEBZGKODaixqtHM= -github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2/go.mod h1:8BT+cPK6xvFOcRlk0R8eg+OTkcqI6baNH4xAkpiYVvQ= -github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd h1:qMd81Ts1T2OTKmB4acZcyKaMtRnY5Y44NuXGX2GFJ1w= -github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0 h1:sDMmm+q/3+BukdIpxwO365v/Rbspp2Nt5XntgQRXq8Q= -github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= -github.com/coinbase/rosetta-sdk-go/types v1.0.0 h1:jpVIwLcPoOeCR6o1tU+Xv7r5bMONNbHU7MuEHboiFuA= -github.com/coinbase/rosetta-sdk-go/types v1.0.0/go.mod h1:eq7W2TMRH22GTW0N0beDnN931DW0/WOI1R2sdHNHG4c= -github.com/cometbft/cometbft v0.37.5/go.mod h1:QC+mU0lBhKn8r9qvmnq53Dmf3DWBt4VtkcKw2C81wxY= -github.com/cometbft/cometbft v0.38.10 h1:2ePuglchT+j0Iao+cfmt/nw5U7K2lnGDzXSUPGVdXaU= -github.com/cometbft/cometbft v0.38.10/go.mod h1:jHPx9vQpWzPHEAiYI/7EDKaB1NXhK6o3SArrrY8ExKc= -github.com/cometbft/cometbft-db v0.7.0/go.mod h1:yiKJIm2WKrt6x8Cyxtq9YTEcIMPcEe4XPxhgX59Fzf0= -github.com/cometbft/cometbft-db v0.8.0/go.mod h1:6ASCP4pfhmrCBpfk01/9E1SI29nD3HfVHrY4PG8x5c0= -github.com/cometbft/cometbft-db v0.9.1/go.mod h1:iliyWaoV0mRwBJoizElCwwRA9Tf7jZJOURcRZF9m60U= -github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= -github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= -github.com/consensys/gnark-crypto v0.4.1-0.20210426202927-39ac3d4b3f1f h1:C43yEtQ6NIf4ftFXD/V55gnGFgPbMQobd//YlnLjUJ8= -github.com/consensys/gnark-crypto v0.4.1-0.20210426202927-39ac3d4b3f1f/go.mod h1:815PAHg3wvysy0SyIqanF8gZ0Y1wjk/hrDHD/iT88+Q= -github.com/containerd/aufs v1.0.0 h1:2oeJiwX5HstO7shSrPZjrohJZLzK36wvpdmzDRkL/LY= -github.com/containerd/aufs v1.0.0/go.mod h1:kL5kd6KM5TzQjR79jljyi4olc1Vrx6XBlcyj3gNv2PU= -github.com/containerd/btrfs v1.0.0 h1:osn1exbzdub9L5SouXO5swW4ea/xVdJZ3wokxN5GrnA= -github.com/containerd/btrfs v1.0.0/go.mod h1:zMcX3qkXTAi9GI50+0HOeuV8LU2ryCE/V2vG/ZBiTss= -github.com/containerd/cgroups v1.0.3 h1:ADZftAkglvCiD44c77s5YmMqaP2pzVCFZvBmAlBdAP4= -github.com/containerd/cgroups v1.0.3/go.mod h1:/ofk34relqNjSGyqPrmEULrO4Sc8LJhvJmWbUCUKqj8= -github.com/containerd/console v1.0.3 h1:lIr7SlA5PxZyMV30bDW0MGbiOPXwc63yRuCP0ARubLw= -github.com/containerd/console v1.0.3/go.mod h1:7LqA/THxQ86k76b8c/EMSiaJ3h1eZkMkXar0TQ1gf3U= -github.com/containerd/containerd v1.6.8 h1:h4dOFDwzHmqFEP754PgfgTeVXFnLiRc6kiqC7tplDJs= -github.com/containerd/containerd v1.6.8/go.mod h1:By6p5KqPK0/7/CgO/A6t/Gz+CUYUu2zf1hUaaymVXB0= -github.com/containerd/fifo v1.0.0 h1:6PirWBr9/L7GDamKr+XM0IeUFXu5mf3M/BPpH9gaLBU= -github.com/containerd/fifo v1.0.0/go.mod h1:ocF/ME1SX5b1AOlWi9r677YJmCPSwwWnQ9O123vzpE4= -github.com/containerd/fuse-overlayfs-snapshotter v1.0.2 h1:Xy9Tkx0tk/SsMfLDFc69wzqSrxQHYEFELHBO/Z8XO3M= -github.com/containerd/fuse-overlayfs-snapshotter v1.0.2/go.mod h1:nRZceC8a7dRm3Ao6cJAwuJWPFiBPaibHiFntRUnzhwU= -github.com/containerd/go-cni v1.1.6 h1:el5WPymG5nRRLQF1EfB97FWob4Tdc8INg8RZMaXWZlo= -github.com/containerd/go-cni v1.1.6/go.mod h1:BWtoWl5ghVymxu6MBjg79W9NZrCRyHIdUtk4cauMe34= -github.com/containerd/go-runc v1.0.0 h1:oU+lLv1ULm5taqgV/CJivypVODI4SUz1znWjv3nNYS0= -github.com/containerd/go-runc v1.0.0/go.mod h1:cNU0ZbCgCQVZK4lgG3P+9tn9/PaJNmoDXPpoJhDR+Ok= -github.com/containerd/imgcrypt v1.1.4 h1:iKTstFebwy3Ak5UF0RHSeuCTahC5OIrPJa6vjMAM81s= -github.com/containerd/imgcrypt v1.1.4/go.mod h1:LorQnPtzL/T0IyCeftcsMEO7AqxUDbdO8j/tSUpgxvo= -github.com/containerd/nri v0.1.0 h1:6QioHRlThlKh2RkRTR4kIT3PKAcrLo3gIWnjkM4dQmQ= -github.com/containerd/nri v0.1.0/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY= -github.com/containerd/stargz-snapshotter v0.11.3 h1:D3PoF563XmOBdtfx2G6AkhbHueqwIVPBFn2mrsWLa3w= -github.com/containerd/stargz-snapshotter v0.11.3/go.mod h1:2j2EAUyvrLU4D9unYlTIwGhDKQIk74KJ9E71lJsQCVM= -github.com/containerd/stargz-snapshotter/estargz v0.11.3 h1:k2kN16Px6LYuv++qFqK+JTcYqc8bEVxzGpf8/gFBL5M= -github.com/containerd/stargz-snapshotter/estargz v0.11.3/go.mod h1:7vRJIcImfY8bpifnMjt+HTJoQxASq7T28MYbP15/Nf0= -github.com/containerd/stargz-snapshotter/estargz v0.12.1 h1:+7nYmHJb0tEkcRaAW+MHqoKaJYZmkikupxCqVtmPuY0= -github.com/containerd/stargz-snapshotter/estargz v0.12.1/go.mod h1:12VUuCq3qPq4y8yUW+l5w3+oXV3cx2Po3KSe/SmPGqw= -github.com/containerd/ttrpc v1.1.0 h1:GbtyLRxb0gOLR0TYQWt3O6B0NvT8tMdorEHqIQo/lWI= -github.com/containerd/ttrpc v1.1.0/go.mod h1:XX4ZTnoOId4HklF4edwc4DcqskFZuvXB1Evzy5KFQpQ= -github.com/containerd/typeurl v1.0.2 h1:Chlt8zIieDbzQFzXzAeBEF92KhExuE4p9p92/QmY7aY= -github.com/containerd/typeurl v1.0.2/go.mod h1:9trJWW2sRlGub4wZJRTW83VtbOLS6hwcDZXTn6oPz9s= -github.com/containerd/zfs v1.0.0 h1:cXLJbx+4Jj7rNsTiqVfm6i+RNLx6FFA2fMmDlEf+Wm8= -github.com/containerd/zfs v1.0.0/go.mod h1:m+m51S1DvAP6r3FcmYCp54bQ34pyOwTieQDNRIRHsFY= -github.com/containernetworking/cni v1.1.1 h1:ky20T7c0MvKvbMOwS/FrlbNwjEoqJEUUYfsL4b0mc4k= -github.com/containernetworking/cni v1.1.1/go.mod h1:sDpYKmGVENF3s6uvMvGgldDWeG8dMxakj/u+i9ht9vw= -github.com/containernetworking/plugins v1.1.1 h1:+AGfFigZ5TiQH00vhR8qPeSatj53eNGz0C1d3wVYlHE= -github.com/containernetworking/plugins v1.1.1/go.mod h1:Sr5TH/eBsGLXK/h71HeLfX19sZPp3ry5uHSkI4LPxV8= -github.com/containers/ocicrypt v1.1.3 h1:uMxn2wTb4nDR7GqG3rnZSfpJXqWURfzZ7nKydzIeKpA= -github.com/containers/ocicrypt v1.1.3/go.mod h1:xpdkbVAuaH3WzbEabUd5yDsl9SwJA5pABH85425Es2g= -github.com/coreos/bbolt v1.3.2 h1:wZwiHHUieZCquLkDL0B8UhzreNWsPHooDAG3q34zk0s= -github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= -github.com/coreos/etcd v3.3.10+incompatible h1:jFneRYjIvLMLhDLCzuTuU4rSJUjRplcJQ7pD7MnhC04= -github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-etcd v2.0.0+incompatible h1:bXhRBIXoTm9BYHS3gE0TtQuyNZyeEMux2sDi4oo5YOo= -github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk= -github.com/coreos/go-semver v0.3.0 h1:wkHLiw0WNATZnSG7epLsujiMCgPAc9xhjJ4tgnAxmfM= -github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= -github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7 h1:u9SHYsPQNyt5tgDm3YN7+9dYrpK96E5wFilTFWIDZOM= -github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e h1:Wf6HqHfScWJN9/ZjdUKyjop4mf3Qdd+1TvvltAvM3m8= -github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= -github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= -github.com/coreos/go-systemd/v22 v22.3.3-0.20220203105225-a9a7ef127534/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= -github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs= -github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf h1:CAKfRE2YtTUIjjh1bkBtyYFaUT/WmOqsJjgtihT0vMI= -github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f h1:lBNOc5arjvs8E5mO2tbpBpLoyyu8B6e44T7hJy6potg= -github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= -github.com/cosmos/cosmos-db v1.0.0-rc.1 h1:SjnT8B6WKMW9WEIX32qMhnEEKcI7ZP0+G1Sa9HD3nmY= -github.com/cosmos/cosmos-db v1.0.0-rc.1/go.mod h1:Dnmk3flSf5lkwCqvvjNpoxjpXzhxnCAFzKHlbaForso= -github.com/cosmos/cosmos-db v1.0.0/go.mod h1:iBvi1TtqaedwLdcrZVYRSSCb6eSy61NLj4UNmdIgs0U= -github.com/cosmos/cosmos-proto v1.0.0-beta.3/go.mod h1:t8IASdLaAq+bbHbjq4p960BvcTqtwuAxid3b/2rOD6I= -github.com/cosmos/cosmos-sdk/db v1.0.0-beta.1.0.20220726092710-f848e4300a8a h1:2humuGPw3O5riJVFq/E2FRjF57UrO97W1qJcGVmK+6k= -github.com/cosmos/cosmos-sdk/db v1.0.0-beta.1.0.20220726092710-f848e4300a8a/go.mod h1:c8IO23vgNxueCCJlSI9awQtcxsvc+buzaeThB85qfBU= -github.com/cosmos/gogoproto v1.4.1/go.mod h1:Ac9lzL4vFpBMcptJROQ6dQ4M3pOEK5Z/l0Q9p+LoCr4= -github.com/cosmos/gogoproto v1.4.3/go.mod h1:0hLIG5TR7IvV1fme1HCFKjfzW9X2x0Mo+RooWXCnOWU= -github.com/cosmos/gogoproto v1.4.6/go.mod h1:VS/ASYmPgv6zkPKLjR9EB91lwbLHOzaGCirmKKhncfI= -github.com/cosmos/gogoproto v1.4.10/go.mod h1:3aAZzeRWpAwr+SS/LLkICX2/kDFyaYVzckBDzygIxek= -github.com/cosmos/gogoproto v1.4.11/go.mod h1:/g39Mh8m17X8Q/GDEs5zYTSNaNnInBSohtaxzQnYq1Y= -github.com/cosmos/gogoproto v1.5.0/go.mod h1:iUM31aofn3ymidYG6bUR5ZFrk+Om8p5s754eMUcyp8I= -github.com/cosmos/gorocksdb v1.2.0 h1:d0l3jJG8M4hBouIZq0mDUHZ+zjOx044J3nGRskwTb4Y= -github.com/cosmos/gorocksdb v1.2.0/go.mod h1:aaKvKItm514hKfNJpUJXnnOWeBnk2GL4+Qw9NHizILw= -github.com/cosmos/iavl v0.20.1/go.mod h1:WO7FyvaZJoH65+HFOsDir7xU9FWk2w9cHXNW1XHcl7A= -github.com/cosmos/ibc-go/v7 v7.7.0/go.mod h1:zzFhtp9g9RrN/UxXWrdUu5VyonBALCAHujXQCzrZSu8= -github.com/cosmos/rosetta-sdk-go v0.10.0 h1:E5RhTruuoA7KTIXUcMicL76cffyeoyvNybzUGSKFTcM= -github.com/cosmos/rosetta-sdk-go v0.10.0/go.mod h1:SImAZkb96YbwvoRkzSMQB6noNJXFgWl/ENIznEoYQI4= -github.com/cpuguy83/go-md2man v1.0.10 h1:BSKMNlYxDvnunlTymqtgONjNnaRV1sTpcovwwjF22jk= -github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= -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/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/creachadair/command v0.0.0-20220916173946-56a74cdd66b6 h1:uKuolOJonQOb/2+z/wFSJeVREP6fSoigr/X4Wlfhwwg= -github.com/creachadair/command v0.0.0-20220916173946-56a74cdd66b6/go.mod h1:jN7ZJM5YSVtD3SHmkAdN/cOC1dXiqg2Y9K5Sr5a8Nxw= -github.com/creachadair/taskgroup v0.3.2 h1:zlfutDS+5XG40AOxcHDSThxKzns8Tnr9jnr6VqkYlkM= -github.com/creachadair/taskgroup v0.3.2/go.mod h1:wieWwecHVzsidg2CsUnFinW1faVN4+kq+TDlRJQ0Wbk= -github.com/creachadair/taskgroup v0.4.2 h1:jsBLdAJE42asreGss2xZGZ8fJra7WtwnHWeJFxv2Li8= -github.com/creachadair/taskgroup v0.4.2/go.mod h1:qiXUOSrbwAY3u0JPGTzObbE3yf9hcXHDKBZ2ZjpCbgM= -github.com/creack/pty v1.1.9 h1:uDmaGzcdjhF4i/plgjmEsriH11Y0o7RKapEf/LDaM3w= -github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= -github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY= -github.com/creack/pty v1.1.18/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= -github.com/cristalhq/acmd v0.8.1 h1:mtFp/cbeJNY5jokF9zPz5mRllGHropRrOkOVxeGS6FI= -github.com/cristalhq/acmd v0.8.1/go.mod h1:LG5oa43pE/BbxtfMoImHCQN++0Su7dzipdgBjMCBVDQ= -github.com/cristalhq/acmd v0.11.1 h1:DJ4fh2Pv0nPKmqT646IU/0Vh5FNdGblxvF+3/W3NAUI= -github.com/cristalhq/acmd v0.11.1/go.mod h1:LG5oa43pE/BbxtfMoImHCQN++0Su7dzipdgBjMCBVDQ= -github.com/cucumber/common/gherkin/go/v22 v22.0.0 h1:4K8NqptbvdOrjL9DEea6HFjSpbdT9+Q5kgLpmmsHYl0= -github.com/cucumber/common/gherkin/go/v22 v22.0.0/go.mod h1:3mJT10B2GGn3MvVPd3FwR7m2u4tLhSRhWUqJU4KN4Fg= -github.com/cucumber/common/messages/go/v17 v17.1.1 h1:RNqopvIFyLWnKv0LfATh34SWBhXeoFTJnSrgm9cT/Ts= -github.com/cucumber/common/messages/go/v17 v17.1.1/go.mod h1:bpGxb57tDE385Rb2EohgUadLkAbhoC4IyCFi89u/JQI= -github.com/curioswitch/go-reassign v0.2.0 h1:G9UZyOcpk/d7Gd6mqYgd8XYWFMw/znxwGDUstnC9DIo= -github.com/curioswitch/go-reassign v0.2.0/go.mod h1:x6OpXuWvgfQaMGks2BZybTngWjT84hqJfKoO8Tt/Roc= -github.com/cyphar/filepath-securejoin v0.2.3/go.mod h1:aPGpWjXOXUn2NCNjFvBE6aRxGGx79pTxQpKOJNYHHl4= -github.com/cyphar/filepath-securejoin v0.2.4 h1:Ugdm7cg7i6ZK6x3xDF1oEu1nfkyfH53EtKeQYTC3kyg= -github.com/cyphar/filepath-securejoin v0.2.4/go.mod h1:aPGpWjXOXUn2NCNjFvBE6aRxGGx79pTxQpKOJNYHHl4= -github.com/daixiang0/gci v0.8.1 h1:T4xpSC+hmsi4CSyuYfIJdMZAr9o7xZmHpQVygMghGZ4= -github.com/daixiang0/gci v0.8.1/go.mod h1:EpVfrztufwVgQRXjnX4zuNinEpLj5OmMjtu/+MB0V0c= -github.com/daixiang0/gci v0.10.1 h1:eheNA3ljF6SxnPD/vE4lCBusVHmV3Rs3dkKvFrJ7MR0= -github.com/daixiang0/gci v0.10.1/go.mod h1:xtHP9N7AHdNvtRNfcx9gwTDfw7FRJx4bZUsiEfiNNAI= -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/dcrec/secp256k1/v4 v4.1.0/go.mod h1:DZGJHZMqrU4JJqFAWUS2UO1+lbSKsdiOoYi9Zzey7Fc= -github.com/decred/dcrd/lru v1.0.0 h1:Kbsb1SFDsIlaupWPwsPp+dkxiBY1frcS07PCPgotKz8= -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/denis-tingaikin/go-header v0.4.3 h1:tEaZKAlqql6SKCY++utLmkPLd6K8IBM20Ha7UVm+mtU= -github.com/denis-tingaikin/go-header v0.4.3/go.mod h1:0wOCWuN71D5qIgE2nz9KrKmuYBAC2Mra5RassOIQ2/c= -github.com/denisenkom/go-mssqldb v0.12.0 h1:VtrkII767ttSPNRfFekePK3sctr+joXgO58stqQbtUA= -github.com/denisenkom/go-mssqldb v0.12.0/go.mod h1:iiK0YP1ZeepvmBQk/QpLEhhTNJgfzrpArPY/aFvc9yU= -github.com/dgraph-io/badger v1.6.0 h1:DshxFxZWXUcO0xX476VJC07Xsr6ZCBVRHKZ93Oh7Evo= -github.com/dgraph-io/badger v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4= -github.com/dgraph-io/badger/v2 v2.2007.4 h1:TRWBQg8UrlUhaFdco01nO2uXwzKS7zd+HVdwV/GHc4o= -github.com/dgraph-io/badger/v2 v2.2007.4/go.mod h1:vSw/ax2qojzbN6eXHIx6KPKtCSHJN/Uz0X0VPruTIhk= -github.com/dgraph-io/badger/v3 v3.2103.2 h1:dpyM5eCJAtQCBcMCZcT4UBZchuTJgCywerHHgmxfxM8= -github.com/dgraph-io/badger/v3 v3.2103.2/go.mod h1:RHo4/GmYcKKh5Lxu63wLEMHJ70Pac2JqZRYGhlyAo2M= -github.com/dgraph-io/ristretto v0.0.3-0.20200630154024-f66de99634de/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= -github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM= -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/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954 h1:RMLoZVzv4GliuWafOuPuQDKSm1SJph7uCRnnS61JAn4= -github.com/dimchansky/utfbom v1.1.1 h1:vV6w1AhK4VMnhBno/TPVCoK9U/LP0PkLCS9tbxHdi/U= -github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE= -github.com/djherbis/atime v1.1.0 h1:rgwVbP/5by8BvvjBNrbh64Qz33idKT3pSnMSJsxhi0g= -github.com/djherbis/atime v1.1.0/go.mod h1:28OF6Y8s3NQWwacXc5eZTsEsiMzp7LF8MbXE+XJPdBE= -github.com/docker/cli v20.10.17+incompatible h1:eO2KS7ZFeov5UJeaDmIs1NFEDRf32PaqRpvoEkKBy5M= -github.com/docker/cli v20.10.17+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= -github.com/docker/cli v23.0.1+incompatible h1:LRyWITpGzl2C9e9uGxzisptnxAn1zfZKXy13Ul2Q5oM= -github.com/docker/cli v23.0.1+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= -github.com/docker/distribution v2.8.1+incompatible h1:Q50tZOPR6T/hjNsyc9g8/syEs6bk8XXApsHjKukMl68= -github.com/docker/distribution v2.8.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/docker v20.10.19+incompatible h1:lzEmjivyNHFHMNAFLXORMBXyGIhw/UP4DvJwvyKYq64= -github.com/docker/docker v20.10.19+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/docker v23.0.1+incompatible h1:vjgvJZxprTTE1A37nm+CLNAdwu6xZekyoiVlUZEINcY= -github.com/docker/docker v23.0.1+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/docker v24.0.9+incompatible h1:HPGzNmwfLZWdxHqK9/II92pyi1EpYKsAqcl4G0Of9v0= -github.com/docker/docker v24.0.9+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/docker-credential-helpers v0.6.4 h1:axCks+yV+2MR3/kZhAmy07yC56WZ2Pwu/fKWtKuZB0o= -github.com/docker/docker-credential-helpers v0.6.4/go.mod h1:ofX3UI0Gz1TteYBjtgs07O36Pyasyp66D2uKT7H8W1c= -github.com/docker/docker-credential-helpers v0.7.0 h1:xtCHsjxogADNZcdv1pKUHXryefjlVRqWqIhk/uXJp0A= -github.com/docker/docker-credential-helpers v0.7.0/go.mod h1:rETQfLdHNT3foU5kuNkFR1R1V12OJRRO5lzt2D1b5X0= -github.com/docker/go-events v0.0.0-20190806004212-e31b211e4f1c h1:+pKlWGMw7gf6bQ+oDZB4KHQFypsfjYlq/C4rfL7D3g8= -github.com/docker/go-events v0.0.0-20190806004212-e31b211e4f1c/go.mod h1:Uw6UezgYA44ePAFQYUehOuCzmy5zmg/+nl2ZfMWGkpA= -github.com/docker/go-metrics v0.0.1 h1:AgB/0SvBxihN0X8OR4SjsblXkbMvalQ8cjmtKQ2rQV8= -github.com/docker/go-metrics v0.0.1/go.mod h1:cG1hvH2utMXtqgqqYE9plW6lDxS3/5ayHzueweSI3Vw= -github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= -github.com/dop251/goja_nodejs v0.0.0-20210225215109-d91c329300e7 h1:tYwu/z8Y0NkkzGEh3z21mSWggMg4LwLRFucLS7TjARg= -github.com/eapache/go-resiliency v1.1.0 h1:1NtRmCAqadE2FN4ZcN6g90TP3uk8cg9rn9eNK2197aU= -github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21 h1:YEetp8/yCZMuEPMUDHG0CW/brkkEp8mzqk2+ODEitlw= -github.com/eapache/queue v1.1.0 h1:YOEu7KNc61ntiQlcEeUIoDTJ2o8mQznoNvUhiigpIqc= -github.com/eknkc/amber v0.0.0-20171010120322-cdade1c07385 h1:clC1lXBpe2kTj2VHdaIu9ajZQe4kcEY9j0NsnDDBZ3o= -github.com/eknkc/amber v0.0.0-20171010120322-cdade1c07385/go.mod h1:0vRUJqYpeSZifjYj7uP3BG/gKcuzL9xWVV/Y+cK33KM= -github.com/elazarl/goproxy v0.0.0-20230808193330-2592e75ae04a h1:mATvB/9r/3gvcejNsXKSkQ6lcIaNec2nyfOdlTBR2lU= -github.com/elazarl/goproxy v0.0.0-20230808193330-2592e75ae04a/go.mod h1:Ro8st/ElPeALwNFlcTpWmkr6IoMFfkjXAvTHpevnDsM= -github.com/emicklei/dot v1.4.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= -github.com/emicklei/go-restful v2.9.5+incompatible h1:spTtZBk5DYEvbxMVutUuTyh1Ao2r4iyvLdACqsl/Ljk= -github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= -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.12.0 h1:4X+VP1GHd1Mhj6IB5mMeGbLCleqxjletLK6K0rbxyZI= -github.com/envoyproxy/go-control-plane v0.12.0/go.mod h1:ZBTaoJ23lqITozF0M6G4/IragXCQKCnYbmlmtHvwRG0= -github.com/envoyproxy/go-control-plane v0.12.1-0.20240621013728-1eb8caab5155 h1:IgJPqnrlY2Mr4pYB6oaMKvFvwJ9H+X6CCY5x1vCTcpc= -github.com/envoyproxy/go-control-plane v0.12.1-0.20240621013728-1eb8caab5155/go.mod h1:5Wkq+JduFtdAXihLmeTJf+tRYIT4KBc2vPXDhwVo1pA= -github.com/envoyproxy/protoc-gen-validate v1.0.4 h1:gVPz/FMfvh57HdSJQyvBtF00j8JU4zdyUgIUNhlgg0A= -github.com/envoyproxy/protoc-gen-validate v1.0.4/go.mod h1:qys6tmnRsYrQqIhm2bvKZH4Blx/1gTIZ2UKVY1M+Yew= -github.com/esimonov/ifshort v1.0.4 h1:6SID4yGWfRae/M7hkVDVVyppy8q/v9OuxNdmjLQStBA= -github.com/esimonov/ifshort v1.0.4/go.mod h1:Pe8zjlRrJ80+q2CxHLfEOfTwxCZ4O+MuhcHcfgNWTk0= -github.com/etcd-io/bbolt v1.3.3 h1:gSJmxrs37LgTqR/oyJBWok6k6SvXEUerFTbltIhXkBM= -github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= -github.com/ettle/strcase v0.1.1 h1:htFueZyVeE1XNnMEfbqp5r67qAN/4r6ya1ysq8Q+Zcw= -github.com/ettle/strcase v0.1.1/go.mod h1:hzDLsPC7/lwKyBOywSHEP89nt2pDgdy+No1NBA9o9VY= -github.com/evmos/cosmos-sdk v0.47.13-evmos h1:Vm02nr60JUEwCSHRwXXws0G9xM5pnvl5vj5MsImHS/w= -github.com/evmos/cosmos-sdk v0.47.13-evmos/go.mod h1:pYMzhTfKFn9AJB5X64Epwe9NgYk0y3v7XN8Ks5xqWoo= -github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c h1:8ISkoahWXwZR41ois5lSJBSVw4D0OV19Ht/JSTzvSv0= -github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c/go.mod h1:Yg+htXGokKKdzcwhuNDwVvN+uBxDGXJ7G/VN1d8fa64= -github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 h1:JWuenKqqX8nojtoVVWjGfOF9635RETekkoH6Cc9SX0A= -github.com/facebookgo/stack v0.0.0-20160209184415-751773369052/go.mod h1:UbMTZqLaRiH3MsBH8va0n7s1pQYcu3uTb8G4tygF4Zg= -github.com/facebookgo/subset v0.0.0-20200203212716-c811ad88dec4 h1:7HZCaLC5+BZpmbhCOZJ293Lz68O7PYrF2EzeiFMwCLk= -github.com/facebookgo/subset v0.0.0-20200203212716-c811ad88dec4/go.mod h1:5tD+neXqOorC30/tWg0LCSkrqj/AR6gu8yY8/fpw1q0= -github.com/fasthttp-contrib/websocket v0.0.0-20160511215533-1f3b11f56072 h1:DddqAaWDpywytcG8w/qoQ5sAN8X12d3Z3koB0C3Rxsc= -github.com/fasthttp-contrib/websocket v0.0.0-20160511215533-1f3b11f56072/go.mod h1:duJ4Jxv5lDcvg4QuQr0oowTf7dz4/CR8NtyCooz9HL8= -github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU= -github.com/fatih/color v1.14.1 h1:qfhVLaG5s+nCROl1zJsZRxFeYrHLqWroPOQ8BWiNb4w= -github.com/fatih/color v1.14.1/go.mod h1:2oHN61fhTpgcxD3TSWCgKDiH1+x4OiDVVGH8WlgGZGg= -github.com/fatih/structs v1.1.0 h1:Q7juDM0QtcnhCpeyLGQKyg4TOIghuNXrkL32pHAUMxo= -github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= -github.com/fatih/structtag v1.2.0 h1:/OdNE99OxoI/PqaW/SuSK9uxxT3f/tcSZgon/ssNSx4= -github.com/fatih/structtag v1.2.0/go.mod h1:mBJUNpUnHmRKrKlQQlmCrh5PuhftFbNv8Ys4/aAZl94= -github.com/felixge/fgprof v0.9.3 h1:VvyZxILNuCiUCSXtPtYmmtGvb65nqXh2QFWc0Wpf2/g= -github.com/felixge/fgprof v0.9.3/go.mod h1:RdbpDgzqYVh/T9fPELJyV7EYJuHB55UTEULNun8eiPw= -github.com/felixge/httpsnoop v1.0.2/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= -github.com/felixge/httpsnoop v1.0.3/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= -github.com/firefart/nonamedreturns v1.0.4 h1:abzI1p7mAEPYuR4A+VLKn4eNDOycjYo2phmY9sfv40Y= -github.com/firefart/nonamedreturns v1.0.4/go.mod h1:TDhe/tjI1BXo48CmYbUduTV7BdIga8MAO/xbKdcVsGI= -github.com/fjl/gencodec v0.0.0-20220412091415-8bb9e558978c h1:CndMRAH4JIwxbW8KYq6Q+cGWcGHz0FjGR3QqcInWcW0= -github.com/fjl/gencodec v0.0.0-20220412091415-8bb9e558978c/go.mod h1:AzA8Lj6YtixmJWL+wkKoBGsLWy9gFrAzi4g+5bCKwpY= -github.com/flosch/pongo2 v0.0.0-20190707114632-bbf5a6c351f4 h1:GY1+t5Dr9OKADM64SYnQjw/w99HMYvQ0A8/JoUkxVmc= -github.com/flosch/pongo2 v0.0.0-20190707114632-bbf5a6c351f4/go.mod h1:T9YF2M40nIgbVgp3rreNmTged+9HrbNTIQf1PsaIiTA= -github.com/flosch/pongo2/v4 v4.0.2 h1:gv+5Pe3vaSVmiJvh/BZa82b7/00YUGm0PIyVVLop0Hw= -github.com/flosch/pongo2/v4 v4.0.2/go.mod h1:B5ObFANs/36VwxxlgKpdchIJHMvHB562PW+BWPhwZD8= -github.com/fogleman/gg v1.2.1-0.20190220221249-0403632d5b90/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k= -github.com/fogleman/gg v1.3.0 h1:/7zJX8F6AaYQc57WQCyN9cAIz+4bCJGO9B+dyW29am8= -github.com/fogleman/gg v1.3.0/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k= -github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db h1:gb2Z18BhTPJPpLQWj4T+rfKHYCHxRHCtRxhKKjRidVw= -github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8 h1:a9ENSRDFBUPkJ5lCgVZh26+ZbGyoVJG7yb5SSzF5H54= -github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k= -github.com/fsnotify/fsnotify v1.5.4/go.mod h1:OVB6XrOHzAwXMpEM7uPOzcehqUV2UqJxmVXmkdnm1bU= -github.com/fzipp/gocyclo v0.6.0 h1:lsblElZG7d3ALtGMx9fmxeTKZaLLpU8mET09yN4BBLo= -github.com/fzipp/gocyclo v0.6.0/go.mod h1:rXPyn8fnlpa0R2csP/31uerbiVBugk5whMdlyaLkLoA= -github.com/garslo/gogen v0.0.0-20170306192744-1d203ffc1f61 h1:IZqZOB2fydHte3kUgxrzK5E1fW7RQGeDwE8F/ZZnUYc= -github.com/garslo/gogen v0.0.0-20170306192744-1d203ffc1f61/go.mod h1:Q0X6pkwTILDlzrGEckF6HKjXe48EgsY/l7K7vhY4MW8= -github.com/gavv/httpexpect v2.0.0+incompatible h1:1X9kcRshkSKEjNJJxX9Y9mQ5BRfbxU5kORdjhlA1yX8= -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/go.mod h1:Kgon4Mby+FJ7ZWHFUAZgVaIa8sxHtnRJRLTXZr51aKQ= -github.com/getsentry/sentry-go v0.21.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= -github.com/ghemawat/stream v0.0.0-20171120220530-696b145b53b9 h1:r5GgOLGbza2wVHRzK7aAj6lWZjfbAwiu/RDCVOKjRyM= -github.com/ghemawat/stream v0.0.0-20171120220530-696b145b53b9/go.mod h1:106OIgooyS7OzLDOpUGgm9fA3bQENb/cFSyyBmMoJDs= -github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= -github.com/gliderlabs/ssh v0.3.5 h1:OcaySEmAQJgyYcArR+gGGTHCyE7nvhEMTlYY+Dp8CpY= -github.com/gliderlabs/ssh v0.3.5/go.mod h1:8XB4KraRrX39qHhT6yxPsHedjA08I/uBVwj4xC+/+z4= -github.com/go-check/check v0.0.0-20180628173108-788fd7840127 h1:0gkP6mzaMqkmpcJYCFOLkIBwI7xFExG03bbkOkCvUPI= -github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= -github.com/go-chi/chi/v5 v5.0.7 h1:rDTPXLDHGATaeHvVlLcR4Qe0zftYethFucbjVQ1PxU8= -github.com/go-chi/chi/v5 v5.0.7/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= -github.com/go-chi/chi/v5 v5.0.8 h1:lD+NLqFcAi1ovnVZpsnObHGW4xb4J8lNmoYVfECH1Y0= -github.com/go-chi/chi/v5 v5.0.8/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= -github.com/go-critic/go-critic v0.6.5 h1:fDaR/5GWURljXwF8Eh31T2GZNz9X4jeboS912mWF8Uo= -github.com/go-critic/go-critic v0.6.5/go.mod h1:ezfP/Lh7MA6dBNn4c6ab5ALv3sKnZVLx37tr00uuaOY= -github.com/go-critic/go-critic v0.7.0 h1:tqbKzB8pqi0NsRZ+1pyU4aweAF7A7QN0Pi4Q02+rYnQ= -github.com/go-critic/go-critic v0.7.0/go.mod h1:moYzd7GdVXE2C2hYTwd7h0CPcqlUeclsyBRwMa38v64= -github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= -github.com/go-fonts/dejavu v0.1.0 h1:JSajPXURYqpr+Cu8U9bt8K+XcACIHWqWrvWCKyeFmVQ= -github.com/go-fonts/dejavu v0.1.0/go.mod h1:4Wt4I4OU2Nq9asgDCteaAaWZOV24E+0/Pwo0gppep4g= -github.com/go-fonts/latin-modern v0.2.0 h1:5/Tv1Ek/QCr20C6ZOz15vw3g7GELYL98KWr8Hgo+3vk= -github.com/go-fonts/latin-modern v0.2.0/go.mod h1:rQVLdDMK+mK1xscDwsqM5J8U2jrRa3T0ecnM9pNujks= -github.com/go-fonts/liberation v0.1.1/go.mod h1:K6qoJYypsmfVjWg8KOVDQhLc8UDgIK2HYqyqAO9z7GY= -github.com/go-fonts/liberation v0.2.0 h1:jAkAWJP4S+OsrPLZM4/eC9iW7CtHy+HBXrEwZXWo5VM= -github.com/go-fonts/liberation v0.2.0/go.mod h1:K6qoJYypsmfVjWg8KOVDQhLc8UDgIK2HYqyqAO9z7GY= -github.com/go-fonts/stix v0.1.0 h1:UlZlgrvvmT/58o573ot7NFw0vZasZ5I6bcIft/oMdgg= -github.com/go-fonts/stix v0.1.0/go.mod h1:w/c1f0ldAUlJmLBvlbkvVXLAD+tAMqobIIQpmnUIzUY= -github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 h1:+zs/tPmkDkHx3U66DAb0lQFJrpS6731Oaa12ikc+DiI= -github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376/go.mod h1:an3vInlBmSxCcxctByoQdvwPiA7DTK7jaaFDBTtu0ic= -github.com/go-git/go-billy/v5 v5.5.0 h1:yEY4yhzCDuMGSv83oGxiBotRzhwhNr8VZyphhiu+mTU= -github.com/go-git/go-billy/v5 v5.5.0/go.mod h1:hmexnoNsr2SJU1Ju67OaNz5ASJY3+sHgFRpCtpDCKow= -github.com/go-git/go-git-fixtures/v4 v4.3.2-0.20231010084843-55a94097c399 h1:eMje31YglSBqCdIqdhKBW8lokaMrL3uTkpGYlE2OOT4= -github.com/go-git/go-git-fixtures/v4 v4.3.2-0.20231010084843-55a94097c399/go.mod h1:1OCfN199q1Jm3HZlxleg+Dw/mwps2Wbk9frAWm+4FII= -github.com/go-git/go-git/v5 v5.11.0 h1:XIZc1p+8YzypNr34itUfSvYJcv+eYdTnTvOZ2vD3cA4= -github.com/go-git/go-git/v5 v5.11.0/go.mod h1:6GFcX2P3NM7FPBfpePbpLd21XxsgdAt+lKqXmCUiUCY= -github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1 h1:QbL/5oDUmRBzO9/Z7Seo6zf912W/a6Sr4Eu0G/3Jho0= -github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4 h1:WtGNWLvXpe6ZudgnXrq0barxBImvnnJoMEhXAzcbM0I= -github.com/go-kit/log v0.2.0/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= -github.com/go-latex/latex v0.0.0-20210118124228-b3d85cf34e07/go.mod h1:CO1AlKB2CSIqUrmQPqA0gdRIlnLEY0gK5JGjh37zN5U= -github.com/go-latex/latex v0.0.0-20210823091927-c0d11ff05a81 h1:6zl3BbBhdnMkpSj2YY30qV3gDcVBGtFgVsV3+/i+mKQ= -github.com/go-latex/latex v0.0.0-20210823091927-c0d11ff05a81/go.mod h1:SX0U8uGpxhq9o2S/CELCSUxEWWAuoCUcVCQWv7G2OCk= -github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= -github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= -github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= -github.com/go-martini/martini v0.0.0-20170121215854-22fa46961aab h1:xveKWz2iaueeTaUgdetzel+U7exyigDYBryyVfV/rZk= -github.com/go-martini/martini v0.0.0-20170121215854-22fa46961aab/go.mod h1:/P9AEU963A2AYjv4d1V5eVL1CQbEJq6aCNHDDjibzu8= -github.com/go-pdf/fpdf v0.5.0 h1:GHpcYsiDV2hdo77VTOuTF9k1sN8F8IY7NjnCo9x+NPY= -github.com/go-pdf/fpdf v0.5.0/go.mod h1:HzcnA+A23uwogo0tp9yU+l3V+KXhiESpt1PMayhOh5M= -github.com/go-pdf/fpdf v0.6.0 h1:MlgtGIfsdMEEQJr2le6b/HNr1ZlQwxyWr77r2aj2U/8= -github.com/go-pdf/fpdf v0.6.0/go.mod h1:HzcnA+A23uwogo0tp9yU+l3V+KXhiESpt1PMayhOh5M= -github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= -github.com/go-playground/assert/v2 v2.2.0 h1:JvknZsQTYeFEAhQwI4qEt9cyV5ONwRHC+lYKSsYSR8s= -github.com/go-playground/locales v0.14.0/go.mod h1:sawfccIbzZTqEDETgFXqTho0QybSa7l++s0DH+LDiLs= -github.com/go-playground/universal-translator v0.18.0/go.mod h1:UvRDBj+xPUEGrFYl+lu/H90nyDXpg0fqeB/AQUGNTVA= -github.com/go-playground/validator/v10 v10.11.1/go.mod h1:i+3WkQ1FvaUjjxh1kSvIA4dMGDBiPU55YFDl0WbKdWU= -github.com/go-redis/redis/v8 v8.11.5 h1:AcZZR7igkdvfVmQTPnu9WE37LRrO/YrBH5zWyjDC0oI= -github.com/go-redis/redis/v8 v8.11.5/go.mod h1:gREzHqY1hg6oD9ngVRbLStwAWKhA0FEgq8Jd4h5lpwo= -github.com/go-sql-driver/mysql v1.4.0 h1:7LxgVwFb2hIQtMm87NdgAVfXjnt4OePseqT1tKx+opk= -github.com/go-sql-driver/mysql v1.4.1/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= -github.com/go-sql-driver/mysql v1.6.0 h1:BCTh4TKNUYmOmMUcQ3IipzF5prigylS7XXjEkfCHuOE= -github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= -github.com/go-sql-driver/mysql v1.7.0 h1:ueSltNNllEqE3qcWBTD0iQd3IpL/6U+mJxLkazJ7YPc= -github.com/go-sql-driver/mysql v1.7.0/go.mod h1:OXbVy3sEdcQ2Doequ6Z5BW6fXNQTmx+9S1MCJN5yJMI= -github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0 h1:p104kn46Q8WdvHunIJ9dAyjPVtrBPhSr3KT2yUst43I= -github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= -github.com/go-toolsmith/astcast v1.0.0 h1:JojxlmI6STnFVG9yOImLeGREv8W2ocNUM+iOhR6jE7g= -github.com/go-toolsmith/astcast v1.0.0/go.mod h1:mt2OdQTeAQcY4DQgPSArJjHCcOwlX+Wl/kwN+LbLGQ4= -github.com/go-toolsmith/astcast v1.1.0 h1:+JN9xZV1A+Re+95pgnMgDboWNVnIMMQXwfBwLRPgSC8= -github.com/go-toolsmith/astcast v1.1.0/go.mod h1:qdcuFWeGGS2xX5bLM/c3U9lewg7+Zu4mr+xPwZIB4ZU= -github.com/go-toolsmith/astcopy v1.0.2 h1:YnWf5Rnh1hUudj11kei53kI57quN/VH6Hp1n+erozn0= -github.com/go-toolsmith/astcopy v1.0.2/go.mod h1:4TcEdbElGc9twQEYpVo/aieIXfHhiuLh4aLAck6dO7Y= -github.com/go-toolsmith/astcopy v1.1.0 h1:YGwBN0WM+ekI/6SS6+52zLDEf8Yvp3n2seZITCUBt5s= -github.com/go-toolsmith/astcopy v1.1.0/go.mod h1:hXM6gan18VA1T/daUEHCFcYiW8Ai1tIwIzHY6srfEAw= -github.com/go-toolsmith/astequal v1.0.0/go.mod h1:H+xSiq0+LtiDC11+h1G32h7Of5O3CYFJ99GVbS5lDKY= -github.com/go-toolsmith/astequal v1.0.2/go.mod h1:9Ai4UglvtR+4up+bAD4+hCj7iTo4m/OXVTSLnCyTAx4= -github.com/go-toolsmith/astequal v1.0.3 h1:+LVdyRatFS+XO78SGV4I3TCEA0AC7fKEGma+fH+674o= -github.com/go-toolsmith/astequal v1.0.3/go.mod h1:9Ai4UglvtR+4up+bAD4+hCj7iTo4m/OXVTSLnCyTAx4= -github.com/go-toolsmith/astequal v1.1.0 h1:kHKm1AWqClYn15R0K1KKE4RG614D46n+nqUQ06E1dTw= -github.com/go-toolsmith/astequal v1.1.0/go.mod h1:sedf7VIdCL22LD8qIvv7Nn9MuWJruQA/ysswh64lffQ= -github.com/go-toolsmith/astfmt v1.0.0 h1:A0vDDXt+vsvLEdbMFJAUBI/uTbRw1ffOPnxsILnFL6k= -github.com/go-toolsmith/astfmt v1.0.0/go.mod h1:cnWmsOAuq4jJY6Ct5YWlVLmcmLMn1JUPuQIHCY7CJDw= -github.com/go-toolsmith/astfmt v1.1.0 h1:iJVPDPp6/7AaeLJEruMsBUlOYCmvg0MoCfJprsOmcco= -github.com/go-toolsmith/astfmt v1.1.0/go.mod h1:OrcLlRwu0CuiIBp/8b5PYF9ktGVZUjlNMV634mhwuQ4= -github.com/go-toolsmith/astp v1.0.0 h1:alXE75TXgcmupDsMK1fRAy0YUzLzqPVvBKoyWV+KPXg= -github.com/go-toolsmith/astp v1.0.0/go.mod h1:RSyrtpVlfTFGDYRbrjyWP1pYu//tSFcvdYrA8meBmLI= -github.com/go-toolsmith/astp v1.1.0 h1:dXPuCl6u2llURjdPLLDxJeZInAeZ0/eZwFJmqZMnpQA= -github.com/go-toolsmith/astp v1.1.0/go.mod h1:0T1xFGz9hicKs8Z5MfAqSUitoUYS30pDMsRVIDHs8CA= -github.com/go-toolsmith/pkgload v1.0.2-0.20220101231613-e814995d17c5 h1:eD9POs68PHkwrx7hAB78z1cb6PfGq/jyWn3wJywsH1o= -github.com/go-toolsmith/pkgload v1.0.2-0.20220101231613-e814995d17c5/go.mod h1:3NAwwmD4uY/yggRxoEjk/S00MIV3A+H7rrE3i87eYxM= -github.com/go-toolsmith/pkgload v1.2.2 h1:0CtmHq/02QhxcF7E9N5LIFcYFsMR5rdovfqTtRKkgIk= -github.com/go-toolsmith/pkgload v1.2.2/go.mod h1:R2hxLNRKuAsiXCo2i5J6ZQPhnPMOVtU+f0arbFPWCus= -github.com/go-toolsmith/strparse v1.0.0 h1:Vcw78DnpCAKlM20kSbAyO4mPfJn/lyYA4BJUDxe2Jb4= -github.com/go-toolsmith/strparse v1.0.0/go.mod h1:YI2nUKP9YGZnL/L1/DLFBfixrcjslWct4wyljWhSRy8= -github.com/go-toolsmith/strparse v1.1.0 h1:GAioeZUK9TGxnLS+qfdqNbA4z0SSm5zVNtCQiyP2Bvw= -github.com/go-toolsmith/strparse v1.1.0/go.mod h1:7ksGy58fsaQkGQlY8WVoBFNyEPMGuJin1rfoPS4lBSQ= -github.com/go-toolsmith/typep v1.0.2 h1:8xdsa1+FSIH/RhEkgnD1j2CJOy5mNllW1Q9tRiYwvlk= -github.com/go-toolsmith/typep v1.0.2/go.mod h1:JSQCQMUPdRlMZFswiq3TGpNp1GMktqkR2Ns5AIQkATU= -github.com/go-toolsmith/typep v1.1.0 h1:fIRYDyF+JywLfqzyhdiHzRop/GQDxxNhLGQ6gFUNHus= -github.com/go-toolsmith/typep v1.1.0/go.mod h1:fVIw+7zjdsMxDA3ITWnH1yOiw1rnTQKCsF/sk2H/qig= -github.com/go-xmlfmt/xmlfmt v0.0.0-20191208150333-d5b6f63a941b h1:khEcpUM4yFcxg4/FHQWkvVRmgijNXRfzkIDHh23ggEo= -github.com/go-xmlfmt/xmlfmt v0.0.0-20191208150333-d5b6f63a941b/go.mod h1:aUCEOzzezBEjDBbFBoSiya/gduyIiWYRP6CnSFIV8AM= -github.com/go-xmlfmt/xmlfmt v1.1.2 h1:Nea7b4icn8s57fTx1M5AI4qQT5HEM3rVUO8MuE6g80U= -github.com/go-xmlfmt/xmlfmt v1.1.2/go.mod h1:aUCEOzzezBEjDBbFBoSiya/gduyIiWYRP6CnSFIV8AM= -github.com/go-zookeeper/zk v1.0.2 h1:4mx0EYENAdX/B/rbunjlt5+4RTA/a9SMHBRuSKdGxPM= -github.com/go-zookeeper/zk v1.0.2/go.mod h1:nOB03cncLtlp4t+UAkGSV+9beXP/akpekBwL+UX1Qcw= -github.com/gobwas/glob v0.2.3 h1:A4xDbljILXROh+kObIiy5kIaPYD8e96x1tgBhUI5J+Y= -github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8= -github.com/goccy/go-json v0.9.11/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= -github.com/godbus/dbus/v5 v5.0.4 h1:9349emZab16e7zQvpmsbtjc18ykshndd8y2PG3sgJbA= -github.com/godbus/dbus/v5 v5.0.6 h1:mkgN1ofwASrYnJ5W6U/BxG15eXXXjirgZc7CLqkcaro= -github.com/godbus/dbus/v5 v5.0.6/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= -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.3.0+incompatible h1:CaSVZxm5B+7o45rtab4jC2G37WGYX1zQfuU2i6DSvnc= -github.com/gofrs/uuid v4.3.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= -github.com/gofrs/uuid v4.4.0+incompatible h1:3qXRTX8/NbyulANqlc0lchS1gqAVxRgsuW1YrTJupqA= -github.com/gofrs/uuid v4.4.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= -github.com/gofrs/uuid/v5 v5.0.0 h1:p544++a97kEL+svbcFbCQVM9KFu0Yo25UoISXGNNH9M= -github.com/gofrs/uuid/v5 v5.0.0/go.mod h1:CDOjlDMVAtN56jqyRUZh58JT31Tiw7/oQyEXZV+9bD8= -github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= -github.com/gogo/status v1.1.0 h1:+eIkrewn5q6b30y+g/BJINVVdi2xH7je5MPJ3ZPK3JA= -github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= -github.com/golang-jwt/jwt v3.2.2+incompatible h1:IfV12K8xAKAnZqdXVzCZ+TOjboZ2keLg81eXfW3O+oY= -github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= -github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe h1:lXe2qZdvpiX5WZkZR4hgp4KJVfY3nMkvmwbVkpv1rVY= -github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0= -github.com/golang-sql/sqlexp v0.0.0-20170517235910-f1bb20e5a188 h1:+eHOFJl1BaXrQxKX+T06f78590z4qA2ZzBTqahsKSE4= -github.com/golang-sql/sqlexp v0.0.0-20170517235910-f1bb20e5a188/go.mod h1:vXjM/+wXQnTPR4KqTKDgJukSZ6amVRtWMPEjE6sQoK8= -github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0 h1:DACJavvAHhabrF08vX0COfcOBJRhZ8lUbR+ZWIs0Y5g= -github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= -github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= -github.com/golang/glog v1.1.2/go.mod h1:zR+okUeTbrL6EL3xHUDxZuEtGv04p5shwip1+mL/rLQ= -github.com/golang/glog v1.2.0/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= -github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/golangci/check v0.0.0-20180506172741-cfe4005ccda2 h1:23T5iq8rbUYlhpt5DB4XJkc6BU31uODLD1o1gKvZmD0= -github.com/golangci/check v0.0.0-20180506172741-cfe4005ccda2/go.mod h1:k9Qvh+8juN+UKMCS/3jFtGICgW8O96FVaZsaxdzDkR4= -github.com/golangci/dupl v0.0.0-20180902072040-3e9179ac440a h1:w8hkcTqaFpzKqonE9uMCefW1WDie15eSP/4MssdenaM= -github.com/golangci/dupl v0.0.0-20180902072040-3e9179ac440a/go.mod h1:ryS0uhF+x9jgbj/N71xsEqODy9BN81/GonCZiOzirOk= -github.com/golangci/go-misc v0.0.0-20220329215616-d24fe342adfe h1:6RGUuS7EGotKx6J5HIP8ZtyMdiDscjMLfRBSPuzVVeo= -github.com/golangci/go-misc v0.0.0-20220329215616-d24fe342adfe/go.mod h1:gjqyPShc/m8pEMpk0a3SeagVb0kaqvhscv+i9jI5ZhQ= -github.com/golangci/gofmt v0.0.0-20220901101216-f2edd75033f2 h1:amWTbTGqOZ71ruzrdA+Nx5WA3tV1N0goTspwmKCQvBY= -github.com/golangci/gofmt v0.0.0-20220901101216-f2edd75033f2/go.mod h1:9wOXstvyDRshQ9LggQuzBCGysxs3b6Uo/1MvYCR2NMs= -github.com/golangci/golangci-lint v1.50.1 h1:C829clMcZXEORakZlwpk7M4iDw2XiwxxKaG504SZ9zY= -github.com/golangci/golangci-lint v1.50.1/go.mod h1:AQjHBopYS//oB8xs0y0M/dtxdKHkdhl0RvmjUct0/4w= -github.com/golangci/golangci-lint v1.52.0 h1:T7w3tuF1goz64qGV+ML4MgysSl/yUfA3UZJK92oE48A= -github.com/golangci/golangci-lint v1.52.0/go.mod h1:wlTh+d/oVlgZC2yCe6nlxrxNAnuhEQC0Zdygoh72Uak= -github.com/golangci/lint-1 v0.0.0-20191013205115-297bf364a8e0 h1:MfyDlzVjl1hoaPzPD4Gpb/QgoRfSBR0jdhwGyAWwMSA= -github.com/golangci/lint-1 v0.0.0-20191013205115-297bf364a8e0/go.mod h1:66R6K6P6VWk9I95jvqGxkqJxVWGFy9XlDwLwVz1RCFg= -github.com/golangci/maligned v0.0.0-20180506175553-b1d89398deca h1:kNY3/svz5T29MYHubXix4aDDuE3RWHkPvopM/EDv/MA= -github.com/golangci/maligned v0.0.0-20180506175553-b1d89398deca/go.mod h1:tvlJhZqDe4LMs4ZHD0oMUlt9G2LWuDGoisJTBzLMV9o= -github.com/golangci/misspell v0.3.5 h1:pLzmVdl3VxTOncgzHcvLOKirdvcx/TydsClUQXTehjo= -github.com/golangci/misspell v0.3.5/go.mod h1:dEbvlSfYbMQDtrpRMQU675gSDLDNa8sCPPChZ7PhiVA= -github.com/golangci/misspell v0.4.0 h1:KtVB/hTK4bbL/S6bs64rYyk8adjmh1BygbBiaAiX+a0= -github.com/golangci/misspell v0.4.0/go.mod h1:W6O/bwV6lGDxUCChm2ykw9NQdd5bYd1Xkjo88UcWyJc= -github.com/golangci/revgrep v0.0.0-20220804021717-745bb2f7c2e6 h1:DIPQnGy2Gv2FSA4B/hh8Q7xx3B7AIDk3DAMeHclH1vQ= -github.com/golangci/revgrep v0.0.0-20220804021717-745bb2f7c2e6/go.mod h1:0AKcRCkMoKvUvlf89F6O7H2LYdhr1zBh736mBItOdRs= -github.com/golangci/unconvert v0.0.0-20180507085042-28b1c447d1f4 h1:zwtduBRr5SSWhqsYNgcuWO2kFlpdOZbP0+yRjmvPGys= -github.com/golangci/unconvert v0.0.0-20180507085042-28b1c447d1f4/go.mod h1:Izgrg8RkN3rCIMLGE9CyYmU9pY2Jer6DgANEnZ/L/cQ= -github.com/gomodule/redigo v1.7.1-0.20190724094224-574c33c3df38 h1:y0Wmhvml7cGnzPa9nocn/fMraMH/lMDdeG+rkx4VgYY= -github.com/gomodule/redigo v1.7.1-0.20190724094224-574c33c3df38/go.mod h1:B4C85qUVwatsJoIUNIfCRsp7qO0iAmpGFZ4EELWSbC4= -github.com/gonum/blas v0.0.0-20181208220705-f22b278b28ac h1:Q0Jsdxl5jbxouNs1TQYt0gxesYMU4VXRbsTlgDloZ50= -github.com/gonum/blas v0.0.0-20181208220705-f22b278b28ac/go.mod h1:P32wAyui1PQ58Oce/KYkOqQv8cVw1zAapXOl+dRFGbc= -github.com/gonum/floats v0.0.0-20181209220543-c233463c7e82 h1:EvokxLQsaaQjcWVWSV38221VAK7qc2zhaO17bKys/18= -github.com/gonum/floats v0.0.0-20181209220543-c233463c7e82/go.mod h1:PxC8OnwL11+aosOB5+iEPoV3picfs8tUpkVd0pDo+Kg= -github.com/gonum/internal v0.0.0-20181124074243-f884aa714029 h1:8jtTdc+Nfj9AR+0soOeia9UZSvYBvETVHZrugUowJ7M= -github.com/gonum/internal v0.0.0-20181124074243-f884aa714029/go.mod h1:Pu4dmpkhSyOzRwuXkOgAvijx4o+4YMUJJo9OvPYMkks= -github.com/gonum/lapack v0.0.0-20181123203213-e4cdc5a0bff9 h1:7qnwS9+oeSiOIsiUMajT+0R7HR6hw5NegnKPmn/94oI= -github.com/gonum/lapack v0.0.0-20181123203213-e4cdc5a0bff9/go.mod h1:XA3DeT6rxh2EAE789SSiSJNqxPaC0aE9J8NTOI0Jo/A= -github.com/gonum/matrix v0.0.0-20181209220409-c518dec07be9 h1:V2IgdyerlBa/MxaEFRbV5juy/C3MGdj4ePi+g6ePIp4= -github.com/gonum/matrix v0.0.0-20181209220409-c518dec07be9/go.mod h1:0EXg4mc1CNP0HCqCz+K4ts155PXIlUywf0wqN+GfPZw= -github.com/google/flatbuffers v1.12.1/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= -github.com/google/flatbuffers v2.0.0+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= -github.com/google/go-containerregistry v0.13.0 h1:y1C7Z3e149OJbOPDBxLYR8ITPz8dTKqQwjErKVHJC8k= -github.com/google/go-containerregistry v0.13.0/go.mod h1:J9FQ+eSS4a1aC2GNZxvNpbWhgp0487v+cgiilB4FqDo= -github.com/google/go-pkcs11 v0.2.1-0.20230907215043-c6f79328ddf9 h1:OF1IPgv+F4NmqmJ98KTjdN97Vs1JxDPB3vbmYzV2dpk= -github.com/google/go-pkcs11 v0.2.1-0.20230907215043-c6f79328ddf9/go.mod h1:6eQoGcuNJpa7jnd5pMGdkSaQpNDYvPlXWMcjXXThLlY= -github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= -github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8= -github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU= -github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/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-20230228050547-1710fef4ab10/go.mod h1:79YE0hCXdHag9sBkw2o+N/YnZtTkXi0UT9Nnixa5eYk= -github.com/google/pprof v0.0.0-20240827171923-fa2c70bbbfe5/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= -github.com/google/renameio v0.1.0 h1:GOZbcHa3HfsPKPlmyPyN2KEohoMXOhdMbHrvbpl2QaA= -github.com/google/safehtml v0.0.2 h1:ZOt2VXg4x24bW0m2jtzAOkhoXV0iM8vNKc0paByCZqM= -github.com/google/safehtml v0.0.2/go.mod h1:L4KWwDsUJdECRAEpZoBn3O64bQaywRscowZjJAzjHnU= -github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 h1:El6M4kTTCOh6aBiKaUGG7oYTSPP8MxqL4YI3kZKwcP4= -github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= -github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/googleapis/gax-go v0.0.0-20161107002406-da06d194a00e h1:CYRpN206UTHUinz3VJoLaBdy1gEGeJNsqT0mvswDcMw= -github.com/googleapis/gax-go v0.0.0-20161107002406-da06d194a00e/go.mod h1:SFVmujtThgffbyetf+mdk2eWhX2bMyUtNHzFKcPA9HY= -github.com/googleapis/gax-go/v2 v2.12.0/go.mod h1:y+aIqrI5eb1YGMVJfuV3185Ts/D7qKpsEkdD5+I6QGU= -github.com/googleapis/gax-go/v2 v2.12.1/go.mod h1:61M8vcyyXR2kqKFxKrfA22jaA8JGF7Dc8App1U3H6jc= -github.com/googleapis/gax-go/v2 v2.12.3/go.mod h1:AKloxT6GtNbaLm8QTNSidHUVsHYcBHwWRvkNFJUQcS4= -github.com/googleapis/gax-go/v2 v2.12.4/go.mod h1:KYEYLorsnIGDi/rPC8b5TdlB9kbKoFubselGIoBMCwI= -github.com/googleapis/go-type-adapters v1.0.0 h1:9XdMn+d/G57qq1s8dNc5IesGCXHf6V2HZ2JwRxfA2tA= -github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= -github.com/googleapis/google-cloud-go-testing v0.0.0-20210719221736-1c9a4c676720 h1:zC34cGQu69FG7qzJ3WiKW244WfhDC3xxYMeNOX2gtUQ= -github.com/googleapis/google-cloud-go-testing v0.0.0-20210719221736-1c9a4c676720/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= -github.com/gookit/color v1.5.1 h1:Vjg2VEcdHpwq+oY63s/ksHrgJYCTo0bwWvmmYWdE9fQ= -github.com/gookit/color v1.5.1/go.mod h1:wZFzea4X8qN6vHOSP2apMb4/+w/orMznEzYsIHPaqKM= -github.com/gookit/color v1.5.2 h1:uLnfXcaFjlrDnQDT+NCBcfhrXqYTx/rcCa6xn01Y8yI= -github.com/gookit/color v1.5.2/go.mod h1:w8h4bGiHeeBpvQVePTutdbERIUf3oJE5lZ8HM0UgXyg= -github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1 h1:EGx4pi6eqNxGaHF6qqu48+N2wcFQ5qg5FXgOdqsJ5d8= -github.com/gordonklaus/ineffassign v0.0.0-20210914165742-4cc7213b9bc8 h1:PVRE9d4AQKmbelZ7emNig1+NT27DUmKZn5qXxfio54U= -github.com/gordonklaus/ineffassign v0.0.0-20210914165742-4cc7213b9bc8/go.mod h1:Qcp2HIAYhR7mNUVSIxZww3Guk4it82ghYcEXIAk+QT0= -github.com/gordonklaus/ineffassign v0.0.0-20230107090616-13ace0543b28 h1:9alfqbrhuD+9fLZ4iaAVwhlp5PEhmnBt7yvK2Oy5C1U= -github.com/gordonklaus/ineffassign v0.0.0-20230107090616-13ace0543b28/go.mod h1:Qcp2HIAYhR7mNUVSIxZww3Guk4it82ghYcEXIAk+QT0= -github.com/gorilla/context v1.1.1 h1:AWwleXJkX/nhcU9bZSnZoi3h/qGYqQAGhq6zZe/aQW8= -github.com/gorilla/css v1.0.0 h1:BQqNyPTi50JCFMTw/b67hByjMVXZRwGha6wxVGkeihY= -github.com/gorilla/css v1.0.0/go.mod h1:Dn721qIggHpt4+EFCcTLTU/vk5ySda2ReITrtgBl60c= -github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= -github.com/gorilla/securecookie v1.1.1 h1:miw7JPhV+b/lAHSXz4qd/nN9jRiAFV5FwjeKyCS8BvQ= -github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4= -github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= -github.com/gostaticanalysis/analysisutil v0.0.0-20190318220348-4088753ea4d3/go.mod h1:eEOZF4jCKGi+aprrirO9e7WKB3beBRtWgqGunKl6pKE= -github.com/gostaticanalysis/analysisutil v0.0.3/go.mod h1:eEOZF4jCKGi+aprrirO9e7WKB3beBRtWgqGunKl6pKE= -github.com/gostaticanalysis/analysisutil v0.1.0/go.mod h1:dMhHRU9KTiDcuLGdy87/2gTR8WruwYZrKdRq9m1O6uw= -github.com/gostaticanalysis/analysisutil v0.7.1 h1:ZMCjoue3DtDWQ5WyU16YbjbQEQ3VuzwxALrpYd+HeKk= -github.com/gostaticanalysis/analysisutil v0.7.1/go.mod h1:v21E3hY37WKMGSnbsw2S/ojApNWb6C1//mXO48CXbVc= -github.com/gostaticanalysis/comment v1.3.0/go.mod h1:xMicKDx7XRXYdVwY9f9wQpDJVnqWxw9wCauCMKp+IBI= -github.com/gostaticanalysis/comment v1.4.1/go.mod h1:ih6ZxzTHLdadaiSnF5WY3dxUoXfXAlTaRzuaNDlSado= -github.com/gostaticanalysis/comment v1.4.2 h1:hlnx5+S2fY9Zo9ePo4AhgYsYHbM2+eAv8m/s1JiCd6Q= -github.com/gostaticanalysis/comment v1.4.2/go.mod h1:KLUTGDv6HOCotCH8h2erHKmpci2ZoR8VPu34YA2uzdM= -github.com/gostaticanalysis/forcetypeassert v0.1.0 h1:6eUflI3DiGusXGK6X7cCcIgVCpZ2CiZ1Q7jl6ZxNV70= -github.com/gostaticanalysis/forcetypeassert v0.1.0/go.mod h1:qZEedyP/sY1lTGV1uJ3VhWZ2mqag3IkWsDHVbplHXak= -github.com/gostaticanalysis/nilerr v0.1.1 h1:ThE+hJP0fEp4zWLkWHWcRyI2Od0p7DlgYG3Uqrmrcpk= -github.com/gostaticanalysis/nilerr v0.1.1/go.mod h1:wZYb6YI5YAxxq0i1+VJbY0s2YONW0HU0GPE3+5PWN4A= -github.com/gostaticanalysis/testutil v0.3.1-0.20210208050101-bfb5c8eec0e4/go.mod h1:D+FIZ+7OahH3ePw/izIEeH5I06eKs1IKI4Xr64/Am3M= -github.com/gostaticanalysis/testutil v0.4.0 h1:nhdCmubdmDF6VEatUNjgUZBJKWRqugoISdUv3PPQgHY= -github.com/gostaticanalysis/testutil v0.4.0/go.mod h1:bLIoPefWXrRi/ssLFWX1dx7Repi5x3CuviD3dgAZaBU= -github.com/gotestyourself/gotestyourself v2.2.0+incompatible h1:AQwinXlbQR2HvPjQZOmDhRqsv5mZf+Jb1RnSLxcqZcI= -github.com/gotestyourself/gotestyourself v2.2.0+incompatible/go.mod h1:zZKM6oeNM8k+FRljX1mnzVYeS8wiGgQyvST1/GafPbY= -github.com/graph-gophers/graphql-go v1.3.0 h1:Eb9x/q6MFpCLz7jBCiP/WTxjSDrYLR1QY41SORZyNJ0= -github.com/graph-gophers/graphql-go v1.3.0/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= -github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= -github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= -github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92BcuyuQ/YW4NSIpoGtfXNho= -github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.11.3 h1:lLT7ZLSzGLI08vc9cpd+tYmNWjdKDqyr/2L+f6U12Fk= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.11.3/go.mod h1:o//XUCC/F+yRGJoPO/VU0GSB0f8Nhgmxx0VIRUvaC0w= -github.com/gtank/merlin v0.1.1 h1:eQ90iG7K9pOhtereWsmyRJ6RAwcP4tHTDBHXNg+u5is= -github.com/gtank/merlin v0.1.1/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= -github.com/gtank/ristretto255 v0.1.2 h1:JEqUCPA1NvLq5DwYtuzigd7ss8fwbYay9fi4/5uMzcc= -github.com/gtank/ristretto255 v0.1.2/go.mod h1:Ph5OpO6c7xKUGROZfWVLiJf9icMDwUeIvY4OmlYW69o= -github.com/guptarohit/asciigraph v0.5.5 h1:ccFnUF8xYIOUPPY3tmdvRyHqmn1MYI9iv1pLKX+/ZkQ= -github.com/guptarohit/asciigraph v0.5.5/go.mod h1:dYl5wwK4gNsnFf9Zp+l06rFiDZ5YtXM6x7SRWZ3KGag= -github.com/hanwen/go-fuse/v2 v2.1.1-0.20220112183258-f57e95bda82d h1:ibbzF2InxMOS+lLCphY9PHNKPURDUBNKaG6ErSq8gJQ= -github.com/hanwen/go-fuse/v2 v2.1.1-0.20220112183258-f57e95bda82d/go.mod h1:B1nGE/6RBFyBRC1RRnf23UpwCdyJ31eukw34oAKukAc= -github.com/hashicorp/consul/api v1.25.1 h1:CqrdhYzc8XZuPnhIYZWH45toM0LB9ZeYr/gvpLVI3PE= -github.com/hashicorp/consul/api v1.25.1/go.mod h1:iiLVwR/htV7mas/sy0O+XSuEnrdBUUydemjxcUrAt4g= -github.com/hashicorp/consul/api v1.28.2 h1:mXfkRHrpHN4YY3RqL09nXU1eHKLNiuAN4kHvDQ16k/8= -github.com/hashicorp/consul/api v1.28.2/go.mod h1:KyzqzgMEya+IZPcD65YFoOVAgPpbfERu4I/tzG6/ueE= -github.com/hashicorp/consul/sdk v0.3.0 h1:UOxjlb4xVNF93jak1mzzoBatyFju9nrkxpVwIp/QqxQ= -github.com/hashicorp/consul/sdk v0.14.1 h1:ZiwE2bKb+zro68sWzZ1SgHF3kRMBZ94TwOCFRF4ylPs= -github.com/hashicorp/consul/sdk v0.14.1/go.mod h1:vFt03juSzocLRFo59NkeQHHmQa6+g7oU0pfzdI1mUhg= -github.com/hashicorp/consul/sdk v0.16.0 h1:SE9m0W6DEfgIVCJX7xU+iv/hUl4m/nxqMTnCdMxDpJ8= -github.com/hashicorp/consul/sdk v0.16.0/go.mod h1:7pxqqhqoaPqnBnzXD1StKed62LqJeClzVsUEy85Zr0A= -github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY2I= -github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= -github.com/hashicorp/go-getter v1.7.1/go.mod h1:W7TalhMmbPmsSMdNjD0ZskARur/9GJ17cfHTRtXV744= -github.com/hashicorp/go-msgpack v0.5.3 h1:zKjpN5BK/P5lMYrLmBHdBULWbJ0XpYR+7NGzqkZzoD4= -github.com/hashicorp/go-msgpack v0.5.5 h1:i9R9JSrqIz0QVLz3sz+i3YJdT7TTSLcfLLzJi9aZTuI= -github.com/hashicorp/go-msgpack v0.5.5/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= -github.com/hashicorp/go-multierror v1.1.0/go.mod h1:spPvp8C1qA32ftKqdAHm4hHTbPw+vmowP0z+KUhOZdA= -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-retryablehttp v0.5.3 h1:QlWt0KvWT0lq8MFppF9tsJGF+ynG7ztc2KIPhzRGk7s= -github.com/hashicorp/go-retryablehttp v0.7.0 h1:eu1EI/mbirUgP5C8hVsTNaGZreBDlYiwC1FZWkvQPQ4= -github.com/hashicorp/go-retryablehttp v0.7.0/go.mod h1:vAew36LZh98gCBJNLH42IQ1ER/9wtLZZ8meHqQvEYWY= -github.com/hashicorp/go-rootcerts v1.0.2 h1:jzhAVGtqPKbwpyCPELlgNWhE1znq+qwJtW5Oi2viEzc= -github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8= -github.com/hashicorp/go-sockaddr v1.0.0 h1:GeH6tui99pF4NJgfnhp+L6+FfobzVW3Ah46sLo0ICXs= -github.com/hashicorp/go-sockaddr v1.0.2 h1:ztczhD1jLxIRjVejw8gFomI1BQZOe2WoVOu0SyteCQc= -github.com/hashicorp/go-sockaddr v1.0.2/go.mod h1:rB4wwRAUzs07qva3c5SdrY/NEtAUjGlgmH/UkBUC97A= -github.com/hashicorp/go-syslog v1.0.0 h1:KaodqZuhUoZereWVIYmpUgZysurB1kBLX2j0MwMrUAE= -github.com/hashicorp/go-version v1.2.1/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= -github.com/hashicorp/go.net v0.0.1 h1:sNCoNyDEvN1xa+X0baata4RdcpKwcMS6DH+xwfqPgjw= -github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= -github.com/hashicorp/logutils v1.0.0 h1:dLEQVugN8vlakKOUE3ihGLTZJRB4j+M2cdTm/ORI65Y= -github.com/hashicorp/mdns v1.0.0 h1:WhIgCr5a7AaVH6jPUwjtRuuE7/RDufnUvzIr48smyxs= -github.com/hashicorp/mdns v1.0.4 h1:sY0CMhFmjIPDMlTB+HfymFHCaYLhgifZ0QhjaYKD/UQ= -github.com/hashicorp/mdns v1.0.4/go.mod h1:mtBihi+LeNXGtG8L9dX59gAEa12BDtBQSp4v/YAJqrc= -github.com/hashicorp/memberlist v0.1.3 h1:EmmoJme1matNzb+hMpDuR/0sbJSUisxyqBGG676r31M= -github.com/hashicorp/memberlist v0.5.0 h1:EtYPN8DpAURiapus508I4n9CzHs2W+8NZGbmmR/prTM= -github.com/hashicorp/memberlist v0.5.0/go.mod h1:yvyXLpo0QaGE59Y7hDTsTzDD25JYBZ4mHgHUZ8lrOI0= -github.com/hashicorp/serf v0.10.1 h1:Z1H2J60yRKvfDYAOZLd2MU0ND4AH/WDz7xYHDWQsIPY= -github.com/hashicorp/serf v0.10.1/go.mod h1:yL2t6BqATOLGc5HF7qbFkTfXoPIY0WZdWHfEvMqbG+4= -github.com/hexops/gotextdiff v1.0.3 h1:gitA9+qJrrTCsiCl7+kh75nPqQt1cx4ZkudSTLoUqJM= -github.com/hexops/gotextdiff v1.0.3/go.mod h1:pSWU5MAI3yDq+fZBTazCSJysOMbxWL1BSow5/V2vxeg= -github.com/hpcloud/tail v1.0.0 h1:nfCOvKYfkgYP8hkirhJocXT2+zOD8yUNjXaWfTlyFKI= -github.com/huandu/xstrings v1.3.2 h1:L18LIDzqlW6xN2rEkpdV8+oL/IXWJ1APd+vsdYy4Wdw= -github.com/huandu/xstrings v1.3.2/go.mod h1:y5/lhBue+AyNmUVz9RLU9xbLR0o4KIIExikq4ovT0aE= -github.com/hudl/fargo v1.4.0 h1:ZDDILMbB37UlAVLlWcJ2Iz1XuahZZTDZfdCKeclfq2s= -github.com/hudl/fargo v1.4.0/go.mod h1:9Ai6uvFy5fQNq6VPKtg+Ceq1+eTY4nKUlR2JElEOcDo= -github.com/hydrogen18/memlistener v0.0.0-20141126152155-54553eb933fb/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= -github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= -github.com/hydrogen18/memlistener v1.0.0 h1:JR7eDj8HD6eXrc5fWLbSUnfcQFL06PYvCc0DKQnWfaU= -github.com/hydrogen18/memlistener v1.0.0/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= -github.com/iancoleman/strcase v0.2.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho= -github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639 h1:mV02weKRL81bEnm8A0HT1/CAelMQDBuQIfLw8n+d6xI= -github.com/ianlancetaylor/demangle v0.0.0-20210905161508-09a460cdf81d/go.mod h1:aYm2/VgdVmcIU8iMfdMvDMsRAQjcfZSKFby6HOFvi/w= -github.com/ianlancetaylor/demangle v0.0.0-20240312041847-bd984b5ce465 h1:KwWnWVWCNtNq/ewIX7HIKnELmEx2nDP42yskD/pi7QE= -github.com/ianlancetaylor/demangle v0.0.0-20240312041847-bd984b5ce465/go.mod h1:gx7rwoVhcfuVKG5uya9Hs3Sxj7EIvldVofAWIUtGouw= -github.com/imdario/mergo v0.3.13 h1:lFzP57bqS/wsqKssCGmtLAb8A0wKjLGrve2q3PPVcBk= -github.com/imdario/mergo v0.3.13/go.mod h1:4lJ1jqUDcsbIECGy0RUJAXNIhg+6ocWgb1ALK2O4oXg= -github.com/imkira/go-interpol v1.1.0 h1:KIiKr0VSG2CUW1hl1jpiyuzuJeKUUpC8iM1AIE7N1Vk= -github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= -github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= -github.com/influxdata/influxdb v1.8.3 h1:WEypI1BQFTT4teLM+1qkEcvUi0dAvopAI/ir0vAiBg8= -github.com/influxdata/influxdb v1.8.3/go.mod h1:JugdFhsvvI8gadxOI6noqNeeBHvWNTbfYGtiAn+2jhI= -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-20200827194710-b269163b24ab h1:HqW4xhhynfjrtEiiSGcQUd6vrK23iMam1FO8rI7mwig= -github.com/influxdata/influxdb1-client v0.0.0-20200827194710-b269163b24ab/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= -github.com/influxdata/line-protocol v0.0.0-20210311194329-9aa0e372d097 h1:vilfsDSy7TDxedi9gyBkMvAirat/oRcL0lFdJBf6tdM= -github.com/influxdata/line-protocol v0.0.0-20210311194329-9aa0e372d097/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= -github.com/informalsystems/tm-load-test v1.3.0 h1:FGjKy7vBw6mXNakt+wmNWKggQZRsKkEYpaFk/zR64VA= -github.com/informalsystems/tm-load-test v1.3.0/go.mod h1:OQ5AQ9TbT5hKWBNIwsMjn6Bf4O0U4b1kRc+0qZlQJKw= -github.com/intel/goresctrl v0.2.0 h1:JyZjdMQu9Kl/wLXe9xA6s1X+tF6BWsQPFGJMEeCfWzE= -github.com/intel/goresctrl v0.2.0/go.mod h1:+CZdzouYFn5EsxgqAQTEzMfwKwuc0fVdMrT9FCCAVRQ= -github.com/iris-contrib/blackfriday v2.0.0+incompatible h1:o5sHQHHm0ToHUlAJSTjW9UWicjJSDDauOOQ2AHuIVp4= -github.com/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= -github.com/iris-contrib/go.uuid v2.0.0+incompatible h1:XZubAYg61/JwnJNbZilGjf3b3pB80+OQg2qf6c8BfWE= -github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= -github.com/iris-contrib/httpexpect/v2 v2.12.1 h1:3cTZSyBBen/kfjCtgNFoUKi1u0FVXNaAjyRJOo6AVS4= -github.com/iris-contrib/httpexpect/v2 v2.12.1/go.mod h1:7+RB6W5oNClX7PTwJgJnsQP3ZuUUYB3u61KCqeSgZ88= -github.com/iris-contrib/i18n v0.0.0-20171121225848-987a633949d0 h1:Kyp9KiXwsyZRTeoNjgVCrWks7D8ht9+kg6yCjh8K97o= -github.com/iris-contrib/i18n v0.0.0-20171121225848-987a633949d0/go.mod h1:pMCz62A0xJL6I+umB2YTlFRwWXaDFA0jy+5HzGiJjqI= -github.com/iris-contrib/jade v1.1.3/go.mod h1:H/geBymxJhShH5kecoiOCSssPX7QWYH7UaeZTSWddIk= -github.com/iris-contrib/jade v1.1.4 h1:WoYdfyJFfZIUgqNAeOyRfTNQZOksSlZ6+FnXR3AEpX0= -github.com/iris-contrib/jade v1.1.4/go.mod h1:EDqR+ur9piDl6DUgs6qRrlfzmlx/D5UybogqrXvJTBE= -github.com/iris-contrib/pongo2 v0.0.1 h1:zGP7pW51oi5eQZMIlGA3I+FHY9/HOQWDB+572yin0to= -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/iris-contrib/schema v0.0.6 h1:CPSBLyx2e91H2yJzPuhGuifVRnZBBJ3pCOMbOvPZaTw= -github.com/iris-contrib/schema v0.0.6/go.mod h1:iYszG0IOsuIsfzjymw1kMzTL8YQcCWlm65f3wX8J5iA= -github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOlocH6Fxy8MmwDt+yVQYULKfN0RoTN8A= -github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo= -github.com/jdxcode/netrc v0.0.0-20210204082910-926c7f70242a h1:d4+I1YEKVmWZrgkt6jpXBnLgV2ZjO0YxEtLDdfIZfH4= -github.com/jdxcode/netrc v0.0.0-20210204082910-926c7f70242a/go.mod h1:Zi/ZFkEqFHTm7qkjyNJjaWH4LQA9LQhGJyF0lTYGpxw= -github.com/jdxcode/netrc v0.0.0-20221124155335-4616370d1a84 h1:2uT3aivO7NVpUPGcQX7RbHijHMyWix/yCnIrCWc+5co= -github.com/jdxcode/netrc v0.0.0-20221124155335-4616370d1a84/go.mod h1:Zi/ZFkEqFHTm7qkjyNJjaWH4LQA9LQhGJyF0lTYGpxw= -github.com/jedisct1/go-minisign v0.0.0-20190909160543-45766022959e h1:UvSe12bq+Uj2hWd8aOlwPmoZ+CITRFrdit+sDGfAg8U= -github.com/jedisct1/go-minisign v0.0.0-20190909160543-45766022959e/go.mod h1:G1CVv03EnqU1wYL2dFwXxW2An0az9JTl/ZsqXQeBlkU= -github.com/jessevdk/go-flags v1.4.0 h1:4IU2WS7AumrZ/40jfhf4QVDMsQwqA7VEHozFRrGARJA= -github.com/jgautheron/goconst v1.5.1 h1:HxVbL1MhydKs8R8n/HE5NPvzfaYmQJA3o879lE4+WcM= -github.com/jgautheron/goconst v1.5.1/go.mod h1:aAosetZ5zaeC/2EfMeRswtxUFBpe2Hr7HzkgX4fanO4= -github.com/jhump/gopoet v0.0.0-20190322174617-17282ff210b3/go.mod h1:me9yfT6IJSlOL3FCfrg+L6yzUEZ+5jW6WHt4Sk+UPUI= -github.com/jhump/gopoet v0.1.0 h1:gYjOPnzHd2nzB37xYQZxj4EIQNpBrBskRqQQ3q4ZgSg= -github.com/jhump/gopoet v0.1.0/go.mod h1:me9yfT6IJSlOL3FCfrg+L6yzUEZ+5jW6WHt4Sk+UPUI= -github.com/jhump/goprotoc v0.5.0 h1:Y1UgUX+txUznfqcGdDef8ZOVlyQvnV0pKWZH08RmZuo= -github.com/jhump/goprotoc v0.5.0/go.mod h1:VrbvcYrQOrTi3i0Vf+m+oqQWk9l72mjkJCYo7UvLHRQ= -github.com/jhump/protocompile v0.0.0-20220216033700-d705409f108f h1:BNuUg9k2EiJmlMwjoef3e8vZLHplbVw6DrjGFjLL+Yo= -github.com/jhump/protocompile v0.0.0-20220216033700-d705409f108f/go.mod h1:qr2b5kx4HbFS7/g4uYO5qv9ei8303JMsC7ESbYiqr2Q= -github.com/jhump/protoreflect v1.11.0/go.mod h1:U7aMIjN0NWq9swDP7xDdoMfRHb35uiuTd3Z9nFXJf5E= -github.com/jhump/protoreflect v1.12.1-0.20220721211354-060cc04fc18b/go.mod h1:JytZfP5d0r8pVNLZvai7U/MCuTWITgrI4tTg7puQFKI= -github.com/jingyugao/rowserrcheck v1.1.1 h1:zibz55j/MJtLsjP1OF4bSdgXxwL1b+Vn7Tjzq7gFzUs= -github.com/jingyugao/rowserrcheck v1.1.1/go.mod h1:4yvlZSDb3IyDTUZJUmpZfm2Hwok+Dtp+nu2qOq+er9c= -github.com/jinzhu/copier v0.3.5 h1:GlvfUwHk62RokgqVNvYsku0TATCF7bAHVwEXoBh3iJg= -github.com/jinzhu/copier v0.3.5/go.mod h1:DfbEm0FYsaqBcKcFuvmOZb218JkPGtvSHsKg8S8hyyg= -github.com/jirfag/go-printf-func-name v0.0.0-20200119135958-7558a9eaa5af h1:KA9BjwUk7KlCh6S9EAGWBt1oExIUv9WyNCiRz5amv48= -github.com/jirfag/go-printf-func-name v0.0.0-20200119135958-7558a9eaa5af/go.mod h1:HEWGJkRDzjJY2sqdDwxccsGicWEf9BQOZsq2tV+xzM0= -github.com/jmoiron/sqlx v1.2.0 h1:41Ip0zITnmWNR/vHV+S4m+VoUivnWY5E4OJfLZjCJMA= -github.com/jmoiron/sqlx v1.2.0/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks= -github.com/jmoiron/sqlx v1.3.5 h1:vFFPA71p1o5gAeqtEAwLU4dnX2napprKtHr7PYIcN3g= -github.com/jmoiron/sqlx v1.3.5/go.mod h1:nRVWtLre0KfCLJvgxzCsLVMogSvQ1zNJtpYr2Ccp0mQ= -github.com/jonboulle/clockwork v0.1.0 h1:VKV+ZcuP6l3yW9doeqz6ziZGgcynBVQO+obU0+0hcPo= -github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= -github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= -github.com/jpillora/backoff v1.0.0 h1:uvFg412JmmHBHw7iwprIxkPMI+sGQ4kzOWsMeHnm2EA= -github.com/jrick/logrotate v1.0.0 h1:lQ1bL/n9mBNeIXoTUoYRlK4dHuNJVofX9oWqBtPnSzI= -github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/jstemmer/go-junit-report v0.9.1 h1:6QPYqodiu3GuPL+7mfx+NwDdp2eTkp9IfEUpgAwUN0o= -github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo= -github.com/juju/errors v0.0.0-20181118221551-089d3ea4e4d5 h1:rhqTjzJlm7EbkELJDKMTU7udov+Se0xZkWmugr6zGok= -github.com/juju/errors v0.0.0-20181118221551-089d3ea4e4d5/go.mod h1:W54LbzXuIE0boCoNJfwqpmkKJ1O4TCTZMetAt6jGk7Q= -github.com/juju/loggo v0.0.0-20180524022052-584905176618 h1:MK144iBQF9hTSwBW/9eJm034bVoG30IshVm688T2hi8= -github.com/juju/loggo v0.0.0-20180524022052-584905176618/go.mod h1:vgyd7OREkbtVEN/8IXZe5Ooef3LQePvuBm9UWj6ZL8U= -github.com/juju/testing v0.0.0-20180920084828-472a3e8b2073 h1:WQM1NildKThwdP7qWrNAFGzp4ijNLw8RlgENkaI4MJs= -github.com/juju/testing v0.0.0-20180920084828-472a3e8b2073/go.mod h1:63prj8cnj0tU0S9OHjGJn+b1h0ZghCndfnbQolrYTwA= -github.com/julienschmidt/httprouter v1.3.0 h1:U0609e9tgbseu3rBINet9P48AI/D3oJs4dN7jwJOQ1U= -github.com/julz/importas v0.1.0 h1:F78HnrsjY3cR7j0etXy5+TU1Zuy7Xt08X/1aJnH5xXY= -github.com/julz/importas v0.1.0/go.mod h1:oSFU2R4XK/P7kNBrnL/FEQlDGN1/6WoxXEjSSXO0DV0= -github.com/jung-kurt/gofpdf v1.0.0/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= -github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5 h1:PJr+ZMXIecYc1Ey2zucXdR73SMBtgjPgwa31099IMv0= -github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= -github.com/junk1tm/musttag v0.5.0 h1:bV1DTdi38Hi4pG4OVWa7Kap0hi0o7EczuK6wQt9zPOM= -github.com/junk1tm/musttag v0.5.0/go.mod h1:PcR7BA+oREQYvHwgjIDmw3exJeds5JzRcvEJTfjrA0M= -github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88 h1:uC1QfSlInpQF+M0ao65imhwqKnz3Q2z/d8PWZRMQvDM= -github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= -github.com/karalabe/usb v0.0.2 h1:M6QQBNxF+CQ8OFvxrT90BA0qBOXymndZnk5q235mFc4= -github.com/karalabe/usb v0.0.2/go.mod h1:Od972xHfMJowv7NGVDiWVxk2zxnWgjLlJzE+F4F7AGU= -github.com/kataras/blocks v0.0.7 h1:cF3RDY/vxnSRezc7vLFlQFTYXG/yAr1o7WImJuZbzC4= -github.com/kataras/blocks v0.0.7/go.mod h1:UJIU97CluDo0f+zEjbnbkeMRlvYORtmc1304EeyXf4I= -github.com/kataras/golog v0.0.9/go.mod h1:12HJgwBIZFNGL0EJnMRhmvGA0PQGx8VFwrZtM4CqbAk= -github.com/kataras/golog v0.0.10/go.mod h1:yJ8YKCmyL+nWjERB90Qwn+bdyBZsaQwU3bTVFgkFIp8= -github.com/kataras/golog v0.1.8 h1:isP8th4PJH2SrbkciKnylaND9xoTtfxv++NB+DF0l9g= -github.com/kataras/golog v0.1.8/go.mod h1:rGPAin4hYROfk1qT9wZP6VY2rsb4zzc37QpdPjdkqVw= -github.com/kataras/iris/v12 v12.0.1/go.mod h1:udK4vLQKkdDqMGJJVd/msuMtN6hpYJhg/lSzuxjhO+U= -github.com/kataras/iris/v12 v12.1.8/go.mod h1:LMYy4VlP67TQ3Zgriz8RE2h2kMZV2SgMYbq3UhfoFmE= -github.com/kataras/iris/v12 v12.2.0 h1:WzDY5nGuW/LgVaFS5BtTkW3crdSKJ/FEgWnxPnIVVLI= -github.com/kataras/iris/v12 v12.2.0/go.mod h1:BLzBpEunc41GbE68OUaQlqX4jzi791mx5HU04uPb90Y= -github.com/kataras/jwt v0.1.8 h1:u71baOsYD22HWeSOg32tCHbczPjdCk7V4MMeJqTtmGk= -github.com/kataras/jwt v0.1.8/go.mod h1:Q5j2IkcIHnfwy+oNY3TVWuEBJNw0ADgCcXK9CaZwV4o= -github.com/kataras/neffos v0.0.10/go.mod h1:ZYmJC07hQPW67eKuzlfY7SO3bC0mw83A3j6im82hfqw= -github.com/kataras/neffos v0.0.14/go.mod h1:8lqADm8PnbeFfL7CLXh1WHw53dG27MC3pgi2R1rmoTE= -github.com/kataras/neffos v0.0.21 h1:UwN/F44jlqdtgFI29y3VhA7IlJ4JbK3UjCbTDg1pYoo= -github.com/kataras/neffos v0.0.21/go.mod h1:FeGka8lu8cjD2H+0OpBvW8c6xXawy3fj5VX6xcIJ1Fg= -github.com/kataras/pio v0.0.0-20190103105442-ea782b38602d/go.mod h1:NV88laa9UiiDuX9AhMbDPkGYSPugBOV6yTZB1l2K9Z0= -github.com/kataras/pio v0.0.2/go.mod h1:hAoW0t9UmXi4R5Oyq5Z4irTbaTsOemSrDGUtaTl7Dro= -github.com/kataras/pio v0.0.11 h1:kqreJ5KOEXGMwHAWHDwIl+mjfNCPhAwZPa8gK7MKlyw= -github.com/kataras/pio v0.0.11/go.mod h1:38hH6SWH6m4DKSYmRhlrCJ5WItwWgCVrTNU62XZyUvI= -github.com/kataras/sitemap v0.0.5/go.mod h1:KY2eugMKiPwsJgx7+U103YZehfvNGOXURubcGyk0Bz8= -github.com/kataras/sitemap v0.0.6 h1:w71CRMMKYMJh6LR2wTgnk5hSgjVNB9KL60n5e2KHvLY= -github.com/kataras/sitemap v0.0.6/go.mod h1:dW4dOCNs896OR1HmG+dMLdT7JjDk7mYBzoIRwuj5jA4= -github.com/kataras/tunnel v0.0.4 h1:sCAqWuJV7nPzGrlb0os3j49lk2JhILT0rID38NHNLpA= -github.com/kataras/tunnel v0.0.4/go.mod h1:9FkU4LaeifdMWqZu7o20ojmW4B7hdhv2CMLwfnHGpYw= -github.com/kevinburke/ssh_config v1.2.0 h1:x584FjTGwHzMwvHx18PXxbBVzfnxogHaAReU4gf13a4= -github.com/kevinburke/ssh_config v1.2.0/go.mod h1:CT57kijsi8u/K/BOFA39wgDQJ9CxiF4nAY/ojJ6r6mM= -github.com/kisielk/errcheck v1.6.2 h1:uGQ9xI8/pgc9iOoCe7kWQgRE6SBTrCGmTSf0LrEtY7c= -github.com/kisielk/errcheck v1.6.2/go.mod h1:nXw/i/MfnvRHqXa7XXmQMUB0oNFGuBrNI8d8NLy0LPw= -github.com/kisielk/errcheck v1.6.3 h1:dEKh+GLHcWm2oN34nMvDzn1sqI0i0WxPvrgiJA5JuM8= -github.com/kisielk/errcheck v1.6.3/go.mod h1:nXw/i/MfnvRHqXa7XXmQMUB0oNFGuBrNI8d8NLy0LPw= -github.com/kisielk/gotool v1.0.0 h1:AV2c/EiW3KqPNT9ZKl07ehoAGi4C5/01Cfbblndcapg= -github.com/kkHAIKE/contextcheck v1.1.3 h1:l4pNvrb8JSwRd51ojtcOxOeHJzHek+MtOyXbaR0uvmw= -github.com/kkHAIKE/contextcheck v1.1.3/go.mod h1:PG/cwd6c0705/LM0KTr1acO2gORUxkSVWyLJOFW5qoo= -github.com/kkHAIKE/contextcheck v1.1.4 h1:B6zAaLhOEEcjvUgIYEqystmnFk1Oemn8bvJhbt0GMb8= -github.com/kkHAIKE/contextcheck v1.1.4/go.mod h1:1+i/gWqokIa+dm31mqGLZhZJ7Uh44DJGZVmr6QRBNJg= -github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23 h1:FOOIBWrEkLgmlgGfMuZT83xIwfPDxEI2OHu6xUmJMFE= -github.com/klauspost/compress v1.8.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.9.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.9.7/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= -github.com/klauspost/compress v1.15.0/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= -github.com/klauspost/compress v1.15.9/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU= -github.com/klauspost/compress v1.15.15/go.mod h1:ZcK2JAFqKOpnBlxcLsJzYfrS9X1akm9fHZNnD9+Vo/4= -github.com/klauspost/compress v1.16.0/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= -github.com/klauspost/compress v1.16.5/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= -github.com/klauspost/compress v1.17.2/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= -github.com/klauspost/cpuid v1.2.1 h1:vJi+O/nMdFt0vqm8NZBI6wzALWdA2X+egi0ogNyrC/w= -github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= -github.com/klauspost/pgzip v1.2.5 h1:qnWYvvKqedOF2ulHpMG72XQol4ILEJ8k2wwRl/Km8oE= -github.com/klauspost/pgzip v1.2.5/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs= -github.com/konsorten/go-windows-terminal-sequences v1.0.3 h1:CE8S1cTafDpPvMhIxNJKvHsGVBgn1xWYf1NbHQhywc8= -github.com/kr/fs v0.1.0 h1:Jskdu9ieNAYnjxsi0LbQp1ulIKZV1LAFgK1tWhpZgl8= -github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= -github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515 h1:T+h1c/A9Gawja4Y9mFVWj2vyii2bbUNDw3kt9VxK2EY= -github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= -github.com/kr/pty v1.1.1 h1:VkoXIwSboBpnk99O/KFauAEILuNHv5DVFKZMBN/gUgw= -github.com/kulti/thelper v0.6.3 h1:ElhKf+AlItIu+xGnI990no4cE2+XaSu1ULymV2Yulxs= -github.com/kulti/thelper v0.6.3/go.mod h1:DsqKShOvP40epevkFrvIwkCMNYxMeTNjdWL4dqWHZ6I= -github.com/kunwardeep/paralleltest v1.0.6 h1:FCKYMF1OF2+RveWlABsdnmsvJrei5aoyZoaGS+Ugg8g= -github.com/kunwardeep/paralleltest v1.0.6/go.mod h1:Y0Y0XISdZM5IKm3TREQMZ6iteqn1YuwCsJO/0kL9Zes= -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/kyoh86/exportloopref v0.1.8 h1:5Ry/at+eFdkX9Vsdw3qU4YkvGtzuVfzT4X7S77LoN/M= -github.com/kyoh86/exportloopref v0.1.8/go.mod h1:1tUcJeiioIs7VWe5gcOObrux3lb66+sBqGZrRkMwPgg= -github.com/kyoh86/exportloopref v0.1.11 h1:1Z0bcmTypkL3Q4k+IDHMWTcnCliEZcaPiIe0/ymEyhQ= -github.com/kyoh86/exportloopref v0.1.11/go.mod h1:qkV4UF1zGl6EkF1ox8L5t9SwyeBAZ3qLMd6up458uqA= -github.com/labstack/echo/v4 v4.1.11/go.mod h1:i541M3Fj6f76NZtHSj7TXnyM8n2gaodfvfxNnFqi74g= -github.com/labstack/echo/v4 v4.5.0/go.mod h1:czIriw4a0C1dFun+ObrXp7ok03xON0N1awStJ6ArI7Y= -github.com/labstack/echo/v4 v4.10.0 h1:5CiyngihEO4HXsz3vVsJn7f8xAlWwRr3aY6Ih280ZKA= -github.com/labstack/echo/v4 v4.10.0/go.mod h1:S/T/5fy/GigaXnHTkh0ZGe4LpkkQysvRjFMSUTkDRNQ= -github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= -github.com/labstack/gommon v0.4.0 h1:y7cvthEAEbU0yHOf4axH8ZG2NH8knB9iNSoTO8dyIk8= -github.com/labstack/gommon v0.4.0/go.mod h1:uW6kP17uPlLJsD3ijUYn3/M5bAxtlZhMI6m3MFxTMTM= -github.com/ldez/gomoddirectives v0.2.3 h1:y7MBaisZVDYmKvt9/l1mjNCiSA1BVn34U0ObUcJwlhA= -github.com/ldez/gomoddirectives v0.2.3/go.mod h1:cpgBogWITnCfRq2qGoDkKMEVSaarhdBr6g8G04uz6d0= -github.com/ldez/tagliatelle v0.3.1 h1:3BqVVlReVUZwafJUwQ+oxbx2BEX2vUG4Yu/NOfMiKiM= -github.com/ldez/tagliatelle v0.3.1/go.mod h1:8s6WJQwEYHbKZDsp/LjArytKOG8qaMrKQQ3mFukHs88= -github.com/ldez/tagliatelle v0.4.0 h1:sylp7d9kh6AdXN2DpVGHBRb5guTVAgOxqNGhbqc4b1c= -github.com/ldez/tagliatelle v0.4.0/go.mod h1:mNtTfrHy2haaBAw+VT7IBV6VXBThS7TCreYWbBcJ87I= -github.com/ledgerwatch/interfaces v0.0.0-20230210062155-539b8171d9f0 h1:AbXB1b7L84dXxc0em6As+KkjbjEdIebsF07WVLemEXI= -github.com/ledgerwatch/interfaces v0.0.0-20230210062155-539b8171d9f0/go.mod h1:ugQv1QllJzBny3cKZKxUrSnykkjkBgm27eQM6dnGAcc= -github.com/ledgerwatch/log/v3 v3.7.0 h1:aFPEZdwZx4jzA3+/Pf8wNDN5tCI0cIolq/kfvgcM+og= -github.com/ledgerwatch/log/v3 v3.7.0/go.mod h1:J2Jl6zV/58LeA6LTaVVnCGyf1/cYYSEOOLHY4ZN8S2A= -github.com/ledgerwatch/secp256k1 v1.0.0 h1:Usvz87YoTG0uePIV8woOof5cQnLXGYa162rFf3YnwaQ= -github.com/ledgerwatch/secp256k1 v1.0.0/go.mod h1:SPmqJFciiF/Q0mPt2jVs2dTr/1TZBTIA+kPMmKgBAak= -github.com/ledgerwatch/trackerslist v1.0.0 h1:6gnQu93WCTL4jPcdmc8UEmw56Cb8IFQHLGnevfIeLwo= -github.com/ledgerwatch/trackerslist v1.0.0/go.mod h1:pCC+eEw8izNcnBBiSwvIq8kKsxDLInAafSW275jqFrg= -github.com/ledongthuc/pdf v0.0.0-20220302134840-0c2507a12d80 h1:6Yzfa6GP0rIo/kULo2bwGEkFvCePZ3qHDDTC3/J9Swo= -github.com/ledongthuc/pdf v0.0.0-20220302134840-0c2507a12d80/go.mod h1:imJHygn/1yfhB7XSJJKlFZKl/J+dCPAknuiaGOshXAs= -github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY= -github.com/leonklingele/grouper v1.1.0 h1:tC2y/ygPbMFSBOs3DcyaEMKnnwH7eYKzohOtRrf0SAg= -github.com/leonklingele/grouper v1.1.0/go.mod h1:uk3I3uDfi9B6PeUjsCKi6ndcf63Uy7snXgR4yDYQVDY= -github.com/leonklingele/grouper v1.1.1 h1:suWXRU57D4/Enn6pXR0QVqqWWrnJ9Osrz+5rjt8ivzU= -github.com/leonklingele/grouper v1.1.1/go.mod h1:uk3I3uDfi9B6PeUjsCKi6ndcf63Uy7snXgR4yDYQVDY= -github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/libp2p/go-buffer-pool v0.1.0 h1:oK4mSFcQz7cTQIfqbe4MIj9gLW+mnanjyFtc6cdF0Y8= -github.com/libp2p/go-buffer-pool v0.1.0/go.mod h1:N+vh8gMqimBzdKkSMVuydVDq+UV5QTWy5HSiZacSbPg= -github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743 h1:143Bb8f8DuGWck/xpNUOckBVYfFbBTnLevfRZ1aVVqo= -github.com/lightstep/lightstep-tracer-go v0.18.1 h1:vi1F1IQ8N7hNWytK9DpJsUfQhGuNSc19z330K6vl4zk= -github.com/linxGnu/grocksdb v1.7.15/go.mod h1:pY55D0o+r8yUYLq70QmhdudxYvoDb9F+9puf4m3/W+U= -github.com/linxGnu/grocksdb v1.7.16/go.mod h1:JkS7pl5qWpGpuVb3bPqTz8nC12X3YtPZT+Xq7+QfQo4= -github.com/linxGnu/grocksdb v1.8.12/go.mod h1:xZCIb5Muw+nhbDK4Y5UJuOrin5MceOuiXkVUR7vp4WY= -github.com/linxGnu/grocksdb v1.8.14/go.mod h1:QYiYypR2d4v63Wj1adOOfzglnoII0gLj3PNh4fZkcFA= -github.com/lispad/go-generics-tools v1.1.0 h1:mbSgcxdFVmpoyso1X/MJHXbSbSL3dD+qhRryyxk+/XY= -github.com/lispad/go-generics-tools v1.1.0/go.mod h1:2csd1EJljo/gy5qG4khXol7ivCPptNjG5Uv2X8MgK84= -github.com/lufeee/execinquery v1.2.1 h1:hf0Ems4SHcUGBxpGN7Jz78z1ppVkP/837ZlETPCEtOM= -github.com/lufeee/execinquery v1.2.1/go.mod h1:EC7DrEKView09ocscGHC+apXMIaorh4xqSxS/dy8SbM= -github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0 h1:6E+4a0GO5zZEnZ81pIr0yLvtUWk2if982qA3F3QD6H4= -github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0/go.mod h1:zJYVVT2jmtg6P3p1VtQj7WsuWi/y4VnjVBn7F8KPB3I= -github.com/lyft/protoc-gen-star/v2 v2.0.3 h1:/3+/2sWyXeMLzKd1bX+ixWKgEMsULrIivpDsuaF441o= -github.com/lyft/protoc-gen-star/v2 v2.0.3/go.mod h1:amey7yeodaJhXSbf/TlLvWiqQfLOSpEk//mLlc+axEk= -github.com/lyft/protoc-gen-validate v0.0.13 h1:KNt/RhmQTOLr7Aj8PsJ7mTronaFyx80mRTT9qF261dA= -github.com/magefile/mage v1.14.0 h1:6QDX3g6z1YvJ4olPhT1wksUcSa/V0a1B+pJb73fBjyo= -github.com/magefile/mage v1.14.0/go.mod h1:z5UZb/iS3GoOSn0JgWuiw7dxlurVYTu+/jHXqQg881A= -github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= -github.com/magiconair/properties v1.8.6/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= -github.com/mailgun/raymond/v2 v2.0.48 h1:5dmlB680ZkFG2RN/0lvTAghrSxIESeu9/2aeDqACtjw= -github.com/mailgun/raymond/v2 v2.0.48/go.mod h1:lsgvL50kgt1ylcFJYZiULi5fjPBkkhNfj4KA0W54Z18= -github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= -github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= -github.com/maratori/testableexamples v1.0.0 h1:dU5alXRrD8WKSjOUnmJZuzdxWOEQ57+7s93SLMxb2vI= -github.com/maratori/testableexamples v1.0.0/go.mod h1:4rhjL1n20TUTT4vdh3RDqSizKLyXp7K2u6HgraZCGzE= -github.com/maratori/testpackage v1.1.0 h1:GJY4wlzQhuBusMF1oahQCBtUV/AQ/k69IZ68vxaac2Q= -github.com/maratori/testpackage v1.1.0/go.mod h1:PeAhzU8qkCwdGEMTEupsHJNlQu2gZopMC6RjbhmHeDc= -github.com/maratori/testpackage v1.1.1 h1:S58XVV5AD7HADMmD0fNnziNHqKvSdDuEKdPD1rNTU04= -github.com/maratori/testpackage v1.1.1/go.mod h1:s4gRK/ym6AMrqpOa/kEbQTV4Q4jb7WeLZzVhVVVOQMc= -github.com/matoous/godox v0.0.0-20210227103229-6504466cf951 h1:pWxk9e//NbPwfxat7RXkts09K+dEBJWakUWwICVqYbA= -github.com/matoous/godox v0.0.0-20210227103229-6504466cf951/go.mod h1:1BELzlh859Sh1c6+90blK8lbYy0kwQf1bYlBhBysy1s= -github.com/matoous/godox v0.0.0-20230222163458-006bad1f9d26 h1:gWg6ZQ4JhDfJPqlo2srm/LN17lpybq15AryXIRcWYLE= -github.com/matoous/godox v0.0.0-20230222163458-006bad1f9d26/go.mod h1:1BELzlh859Sh1c6+90blK8lbYy0kwQf1bYlBhBysy1s= -github.com/matryer/is v1.4.0 h1:sosSmIWwkYITGrxZ25ULNDeKiMNzFSr4V/eqBQP0PeE= -github.com/matryer/is v1.4.0/go.mod h1:8I/i5uYgLzgsgEloJE1U6xx5HkBQpAZvepWuujKwMRU= -github.com/matryer/moq v0.3.0 h1:4j0goF/XK3pMTc7fJB3fveuTJoQNdavRX/78vlK3Xb4= -github.com/matryer/moq v0.3.0/go.mod h1:RJ75ZZZD71hejp39j4crZLsEDszGk6iH4v4YsWFKH4s= -github.com/matryer/try v0.0.0-20161228173917-9ac251b645a2 h1:JAEbJn3j/FrhdWA9jW8B5ajsLIjeuEHLi8xE4fk997o= -github.com/matryer/try v0.0.0-20161228173917-9ac251b645a2/go.mod h1:0KeJpeMD6o+O4hW7qJOT7vyQPKrWmj26uf5wMc/IiIs= -github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-colorable v0.1.6/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-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.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE= -github.com/mattn/go-isatty v0.0.17/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= -github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= -github.com/mattn/go-sqlite3 v1.14.5/go.mod h1:WVKg1VTActs4Qso6iwGbiFih2UIHo0ENGwNd0Lj+XmI= -github.com/mattn/go-sqlite3 v1.14.9 h1:10HX2Td0ocZpYEjhilsuo6WWtUqttj2Kb0KtD86/KYA= -github.com/mattn/go-sqlite3 v1.14.9/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= -github.com/mattn/goveralls v0.0.2 h1:7eJB6EqsPhRVxvwEXGnqdO2sJI0PTsrWoTMXEk9/OQc= -github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= -github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -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/mbilski/exhaustivestruct v1.2.0 h1:wCBmUnSYufAHO6J4AVWY6ff+oxWxsVFrwgOdMUQePUo= -github.com/mbilski/exhaustivestruct v1.2.0/go.mod h1:OeTBVxQWoEmB2J2JCHmXWPJ0aksxSUOUy+nvtVEfzXc= -github.com/mediocregopher/mediocre-go-lib v0.0.0-20181029021733-cb65787f37ed h1:3dQJqqDouawQgl3gBE1PNHKFkJYGEuFb1DbSlaxdosE= -github.com/mediocregopher/mediocre-go-lib v0.0.0-20181029021733-cb65787f37ed/go.mod h1:dSsfyI2zABAdhcbvkXqgxOxrCsbYeHCPgrZkku60dSg= -github.com/mediocregopher/radix/v3 v3.3.0/go.mod h1:EmfVyvspXz1uZEyPBMyGK+kjWiKQGvsUt6O3Pj+LDCQ= -github.com/mediocregopher/radix/v3 v3.4.2/go.mod h1:8FL3F6UQRXHXIBSPUs5h0RybMF8i4n7wVopoX3x7Bv8= -github.com/mediocregopher/radix/v3 v3.8.1 h1:rOkHflVuulFKlwsLY01/M2cM2tWCjDoETcMqKbAWu1M= -github.com/mediocregopher/radix/v3 v3.8.1/go.mod h1:8FL3F6UQRXHXIBSPUs5h0RybMF8i4n7wVopoX3x7Bv8= -github.com/mgechev/dots v0.0.0-20210922191527-e955255bf517 h1:zpIH83+oKzcpryru8ceC6BxnoG8TBrhgAvRg8obzup0= -github.com/mgechev/dots v0.0.0-20210922191527-e955255bf517/go.mod h1:KQ7+USdGKfpPjXk4Ga+5XxQM4Lm4e3gAogrreFAYpOg= -github.com/mgechev/revive v1.2.4 h1:+2Hd/S8oO2H0Ikq2+egtNwQsVhAeELHjxjIUFX5ajLI= -github.com/mgechev/revive v1.2.4/go.mod h1:iAWlQishqCuj4yhV24FTnKSXGpbAA+0SckXB8GQMX/Q= -github.com/mgechev/revive v1.3.1 h1:OlQkcH40IB2cGuprTPcjB0iIUddgVZgGmDX3IAMR8D4= -github.com/mgechev/revive v1.3.1/go.mod h1:YlD6TTWl2B8A103R9KWJSPVI9DrEf+oqr15q21Ld+5I= -github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc= -github.com/microcosm-cc/bluemonday v1.0.23 h1:SMZe2IGa0NuHvnVNAZ+6B38gsTbi5e4sViiWJyDDqFY= -github.com/microcosm-cc/bluemonday v1.0.23/go.mod h1:mN70sk7UkkF8TUr2IGBpNN0jAgStuPzlK76QuruE/z4= -github.com/miekg/dns v1.1.26/go.mod h1:bPDLeHnStXmXAq1m/Ch/hvfNHr14JKNPMBo3VZKjuso= -github.com/miekg/dns v1.1.41/go.mod h1:p6aan82bvRIyn+zDIv9xYNUpwa73JcSh9BKwknJysuI= -github.com/miekg/dns v1.1.43 h1:JKfpVSCB84vrAmHzyrsxB5NAr5kLoMXZArPSw7Qlgyg= -github.com/miekg/dns v1.1.43/go.mod h1:+evo5L0630/F6ca/Z9+GAqzhjGyn8/c+TBaOyfEl0V4= -github.com/miekg/pkcs11 v1.1.1 h1:Ugu9pdy6vAYku5DEpVWVFPYnzV+bxB+iRdbuFSu7TvU= -github.com/miekg/pkcs11 v1.1.1/go.mod h1:XsNlhZGX73bx86s2hdc/FuaLm2CPZJemRLMA+WTFxgs= -github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 h1:QRUSJEgZn2Snx0EmT/QLXibWjSUDjKWvXIT19NBVp94= -github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= -github.com/mistifyio/go-zfs v2.1.2-0.20190413222219-f784269be439+incompatible h1:aKW/4cBs+yK6gpqU3K/oIwk9Q/XICqd3zOX/UFuvqmk= -github.com/mistifyio/go-zfs v2.1.2-0.20190413222219-f784269be439+incompatible/go.mod h1:8AuVvqP/mXw1px98n46wfvcGfQ4ci2FwoAjKYxuo3Z4= -github.com/mitchellh/cli v1.0.0 h1:iGBIsUe3+HZ/AD/Vd7DErOt5sU9fa8Uj7A2s1aggv1Y= -github.com/mitchellh/cli v1.1.0 h1:tEElEatulEHDeedTxwckzyYMA5c86fbmNIUL1hBIiTg= -github.com/mitchellh/cli v1.1.0/go.mod h1:xcISNoH86gajksDmfB23e/pu+B+GeFRMYmoHXxx3xhI= -github.com/mitchellh/go-ps v1.0.0 h1:i6ampVEEF4wQFF+bkYfwYgY+F/uYJDktmvLPf7qIgjc= -github.com/mitchellh/go-ps v1.0.0/go.mod h1:J4lOc8z8yJs6vUwklHw2XEIiT4z4C40KtWVN3nvg8Pg= -github.com/mitchellh/go-wordwrap v1.0.1 h1:TLuKupo69TCn6TQSyGxwI1EblZZEsQ0vMlAFQflz0v0= -github.com/mitchellh/go-wordwrap v1.0.1/go.mod h1:R62XHJLzvMFRBbcrT7m7WgmE1eOyTSsCt+hzestvNj0= -github.com/mitchellh/gox v0.4.0 h1:lfGJxY7ToLJQjHHwi0EX6uYBdK78egf954SQl13PQJc= -github.com/mitchellh/hashstructure/v2 v2.0.2 h1:vGKWl0YJqUNxE8d+h8f6NJLcCJrgbhC4NcD46KavDd4= -github.com/mitchellh/hashstructure/v2 v2.0.2/go.mod h1:MG3aRVU/N29oo/V/IhBX8GR/zz4kQkprJgF2EVszyDE= -github.com/mitchellh/iochan v1.0.0 h1:C+X3KsSTLFVBr/tK1eYN/vs4rJcvsiLU338UhYPJWeY= -github.com/mmcloughlin/avo v0.5.0 h1:nAco9/aI9Lg2kiuROBY6BhCI/z0t5jEvJfjWbL8qXLU= -github.com/mmcloughlin/avo v0.5.0/go.mod h1:ChHFdoV7ql95Wi7vuq2YT1bwCJqiWdZrQ1im3VujLYM= -github.com/moby/buildkit v0.10.4 h1:FvC+buO8isGpUFZ1abdSLdGHZVqg9sqI4BbFL8tlzP4= -github.com/moby/buildkit v0.10.4/go.mod h1:Yajz9vt1Zw5q9Pp4pdb3TCSUXJBIroIQGQ3TTs/sLug= -github.com/moby/locker v1.0.1 h1:fOXqR41zeveg4fFODix+1Ch4mj/gT0NE1XJbp/epuBg= -github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQppc= -github.com/moby/spdystream v0.2.0 h1:cjW1zVyyoiM0T7b6UoySUFqzXMoqRckQtXwGPiBhOM8= -github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= -github.com/moby/sys/mount v0.3.0 h1:bXZYMmq7DBQPwHRxH/MG+u9+XF90ZOwoXpHTOznMGp0= -github.com/moby/sys/mount v0.3.0/go.mod h1:U2Z3ur2rXPFrFmy4q6WMwWrBOAQGYtYTRVM8BIvzbwk= -github.com/moby/sys/mountinfo v0.5.0 h1:2Ks8/r6lopsxWi9m58nlwjaeSzUX9iiL1vj5qB/9ObI= -github.com/moby/sys/mountinfo v0.5.0/go.mod h1:3bMD3Rg+zkqx8MRYPi7Pyb0Ie97QEBmdxbhnCLlSvSU= -github.com/moby/sys/mountinfo v0.6.0 h1:gUDhXQx58YNrpHlK4nSL+7y2pxFZkUcXqzFDKWdC0Oo= -github.com/moby/sys/mountinfo v0.6.0/go.mod h1:3bMD3Rg+zkqx8MRYPi7Pyb0Ie97QEBmdxbhnCLlSvSU= -github.com/moby/sys/signal v0.6.0 h1:aDpY94H8VlhTGa9sNYUFCFsMZIUh5wm0B6XkIoJj/iY= -github.com/moby/sys/signal v0.6.0/go.mod h1:GQ6ObYZfqacOwTtlXvcmh9A26dVRul/hbOZn88Kg8Tg= -github.com/moby/sys/symlink v0.2.0 h1:tk1rOM+Ljp0nFmfOIBtlV3rTDlWOwFRhjEeAhZB0nZc= -github.com/moby/sys/symlink v0.2.0/go.mod h1:7uZVF2dqJjG/NsClqul95CqKOBRQyYSNnJ6BMgR/gFs= -github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae h1:O4SWKdcHVCvYqyDV+9CJA1fcDN2L11Bule0iFy3YlAI= -github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae/go.mod h1:E2VnQOmVuvZB6UYnnDB0qG5Nq/1tD9acaOpo6xmt0Kw= -github.com/moby/term v0.0.0-20221205130635-1aeaba878587 h1:HfkjXDfhgVaN5rmueG8cL8KKeFNecRCXFhaJ2qZ5SKA= -github.com/moby/term v0.0.0-20221205130635-1aeaba878587/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y= -github.com/moricho/tparallel v0.2.1 h1:95FytivzT6rYzdJLdtfn6m1bfFJylOJK41+lgv/EHf4= -github.com/moricho/tparallel v0.2.1/go.mod h1:fXEIZxG2vdfl0ZF8b42f5a78EhjjD5mX8qUplsoSU4k= -github.com/moricho/tparallel v0.3.0 h1:8dDx3S3e+jA+xiQXC7O3dvfRTe/J+FYlTDDW01Y7z/Q= -github.com/moricho/tparallel v0.3.0/go.mod h1:leENX2cUv7Sv2qDgdi0D0fCftN8fRC67Bcn8pqzeYNI= -github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= -github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= -github.com/moul/http2curl v1.0.0 h1:dRMWoAtb+ePxMlLkrCbAqh4TlPHXvoGUSQ323/9Zahs= -github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= -github.com/mozilla/tls-observatory v0.0.0-20210609171429-7bc42856d2e5 h1:0KqC6/sLy7fDpBdybhVkkv4Yz+PmB7c9Dz9z3dLW804= -github.com/mozilla/tls-observatory v0.0.0-20210609171429-7bc42856d2e5/go.mod h1:FUqVoUPHSEdDR0MnFM3Dh8AU0pZHLXUD127SAJGER/s= -github.com/mrunalp/fileutils v0.5.0/go.mod h1:M1WthSahJixYnrXQl/DFQuteStB1weuxD2QJNHXfbSQ= -github.com/mrunalp/fileutils v0.5.1 h1:F+S7ZlNKnrwHfSwdlgNSkKo67ReVf8o9fel6C3dkm/Q= -github.com/mrunalp/fileutils v0.5.1/go.mod h1:M1WthSahJixYnrXQl/DFQuteStB1weuxD2QJNHXfbSQ= -github.com/mschoch/smat v0.2.0 h1:8imxQsjDm8yFEAVBe7azKmKSgzSkZXDuKkSq9374khM= -github.com/mschoch/smat v0.2.0/go.mod h1:kc9mz7DoBKqDyiRL7VZN8KvXQMWeTaVnttLRXOlotKw= -github.com/mwitkow/grpc-proxy v0.0.0-20181017164139-0f1106ef9c76 h1:0xuRacu/Zr+jX+KyLLPPktbwXqyOvnOPUQmMLzX1jxU= -github.com/nakabonne/nestif v0.3.1 h1:wm28nZjhQY5HyYPx+weN3Q65k6ilSBxDb8v5S81B81U= -github.com/nakabonne/nestif v0.3.1/go.mod h1:9EtoZochLn5iUprVDmDjqGKPofoUEBL8U4Ngq6aY7OE= -github.com/naoina/go-stringutil v0.1.0 h1:rCUeRUHjBjGTSHl0VC00jUPLz8/F9dDzYI70Hzifhks= -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.2 h1:+RB5hMpXUUA2dfxuhBTEkMOrYmM+gKIZYS1KjSostMI= -github.com/nats-io/jwt/v2 v2.0.3 h1:i/O6cmIsjpcQyWDYNcq2JyZ3/VTF8SJ4JWluI5OhpvI= -github.com/nats-io/jwt/v2 v2.0.3/go.mod h1:VRP+deawSXyhNjXmxPCHskrR6Mq50BqpEI5SEcNiGlY= -github.com/nats-io/jwt/v2 v2.3.0 h1:z2mA1a7tIf5ShggOFlR1oBPgd6hGqcDYsISxZByUzdI= -github.com/nats-io/jwt/v2 v2.3.0/go.mod h1:0tqz9Hlu6bCBFLWAASKhE5vUA4c24L9KPUUgvwumE/k= -github.com/nats-io/nats-server/v2 v2.5.0 h1:wsnVaaXH9VRSg+A2MVg5Q727/CqxnmPLGFQ3YZYKTQg= -github.com/nats-io/nats-server/v2 v2.5.0/go.mod h1:Kj86UtrXAL6LwYRA6H4RqzkHhK0Vcv2ZnKD5WbQ1t3g= -github.com/nats-io/nats.go v1.8.1/go.mod h1:BrFz9vVn0fU3AcH9Vn4Kd7W0NpJ651tD5omQ3M8LwxM= -github.com/nats-io/nats.go v1.31.0 h1:/WFBHEc/dOKBF6qf1TZhrdEfTmOZ5JzdJ+Y3m6Y/p7E= -github.com/nats-io/nats.go v1.31.0/go.mod h1:di3Bm5MLsoB4Bx61CBTsxuarI36WbhAwOm8QrW39+i8= -github.com/nats-io/nats.go v1.34.0 h1:fnxnPCNiwIG5w08rlMcEKTUw4AV/nKyGCOJE8TdhSPk= -github.com/nats-io/nats.go v1.34.0/go.mod h1:Ubdu4Nh9exXdSz0RVWRFBbRfrbSxOYd26oF0wkWclB8= -github.com/nats-io/nkeys v0.0.2/go.mod h1:dab7URMsZm6Z/jp9Z5UGa87Uutgc2mVpXLC4B7TDb/4= -github.com/nats-io/nkeys v0.4.6 h1:IzVe95ru2CT6ta874rt9saQRkWfe2nFj1NtvYSLqMzY= -github.com/nats-io/nkeys v0.4.6/go.mod h1:4DxZNzenSVd1cYQoAa8948QY3QDjrHfcfVADymtkpts= -github.com/nats-io/nkeys v0.4.7 h1:RwNJbbIdYCoClSDNY7QVKZlyb/wfT6ugvFCiKy6vDvI= -github.com/nats-io/nkeys v0.4.7/go.mod h1:kqXRgRDPlGy7nGaEDMuYzmiJCIAAWDK0IMBtDmGD0nc= -github.com/nats-io/nuid v1.0.1 h1:5iA8DT8V7q8WK2EScv2padNa/rTESc1KdnPw4TC2paw= -github.com/nbutton23/zxcvbn-go v0.0.0-20210217022336-fa2cb2858354 h1:4kuARK6Y6FxaNu/BnU2OAaLF86eTVhP2hjTB6iMvItA= -github.com/nbutton23/zxcvbn-go v0.0.0-20210217022336-fa2cb2858354/go.mod h1:KSVJerMDfblTH7p5MZaTt+8zaT2iEk3AkVb9PQdZuE8= -github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e h1:fD57ERR4JtEqsWbfPhv4DMiApHyliiK5xCTNVSPiaAs= -github.com/nishanths/exhaustive v0.8.3 h1:pw5O09vwg8ZaditDp/nQRqVnrMczSJDxRDJMowvhsrM= -github.com/nishanths/exhaustive v0.8.3/go.mod h1:qj+zJJUgJ76tR92+25+03oYUhzF4R7/2Wk7fGTfCHmg= -github.com/nishanths/exhaustive v0.9.5 h1:TzssWan6orBiLYVqewCG8faud9qlFntJE30ACpzmGME= -github.com/nishanths/exhaustive v0.9.5/go.mod h1:IbwrGdVMizvDcIxPYGVdQn5BqWJaOwpCvg4RGb8r/TA= -github.com/nishanths/predeclared v0.2.2 h1:V2EPdZPliZymNAn79T8RkNApBjMmVKh5XRpLm/w98Vk= -github.com/nishanths/predeclared v0.2.2/go.mod h1:RROzoN6TnGQupbC+lqggsOlcgysk3LMK/HI84Mp280c= -github.com/nunnatsa/ginkgolinter v0.9.0 h1:Sm0zX5QfjJzkeCjEp+t6d3Ha0jwvoDjleP9XCsrEzOA= -github.com/nunnatsa/ginkgolinter v0.9.0/go.mod h1:FHaMLURXP7qImeH6bvxWJUpyH+2tuqe5j4rW1gxJRmI= -github.com/oasisprotocol/curve25519-voi v0.0.0-20220708102147-0a8a51822cae/go.mod h1:hVoHR2EVESiICEMbg137etN/Lx+lSrHPTD39Z/uE+2s= -github.com/oklog/oklog v0.3.2 h1:wVfs8F+in6nTBMkA7CbRw+zZMIB7nNM825cM1wuzoTk= -github.com/oklog/run v1.0.0 h1:Ru7dDtJNOyC66gQ5dQmaCa0qIsAUFY3sFpK1Xk8igrw= -github.com/oklog/ulid v1.3.1 h1:EGfNDEx6MqHz8B3uNV6QAib1UR2Lm97sHi3ocA6ESJ4= -github.com/oklog/ulid/v2 v2.1.0 h1:+9lhoxAP56we25tyYETBBY1YLA2SaoLvUFgrP2miPJU= -github.com/oklog/ulid/v2 v2.1.0/go.mod h1:rcEKHmBBKfef9DhnvX7y1HZBYxjXb0cP5ExxNsTT1QQ= -github.com/onsi/ginkgo v1.10.3/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.13.0/go.mod h1:+REjRxOmWfHCjfv9TTWB1jD1Frx4XydAD3zm1lskyM0= -github.com/onsi/ginkgo/v2 v2.19.0/go.mod h1:rlwLi9PilAFJ8jCg9UE1QP6VBpd6/xj3SRC0d6TU0To= -github.com/onsi/ginkgo/v2 v2.20.2 h1:7NVCeyIWROIAheY21RLS+3j2bb52W0W82tkberYytp4= -github.com/onsi/ginkgo/v2 v2.20.2/go.mod h1:K9gyxPIlb+aIvnZ8bd9Ak+YP18w3APlR+5coaZoE2ag= -github.com/onsi/gomega v1.20.0/go.mod h1:DtrZpjmvpn2mPm4YWQa0/ALMDj9v4YxLgojwPeREyVo= -github.com/onsi/gomega v1.26.0/go.mod h1:r+zV744Re+DiYCIPRlYOTxn0YkOLcAnW8k1xXdMPGhM= -github.com/onsi/gomega v1.34.1 h1:EUMJIKUjM8sKjYbtxQI9A4z2o+rruxnzNvpknOXie6k= -github.com/onsi/gomega v1.34.1/go.mod h1:kU1QgUvBDLXBJq618Xvm2LUX6rSAfRaFRTcdOeDLwwY= -github.com/op/go-logging v0.0.0-20160315200505-970db520ece7 h1:lDH9UUVJtmYCjyT0CI4q8xvlXPxeZ0gYCVvWbmPlp88= -github.com/opencontainers/runc v1.1.3/go.mod h1:1J5XiS+vdZ3wCyZybsuxXZWGrgSr8fFJHLXuG2PsnNg= -github.com/opencontainers/runtime-spec v1.0.3-0.20210326190908-1c3f411f0417 h1:3snG66yBm59tKhhSPQrQ/0bCrv1LQbKt40LnUPiUxdc= -github.com/opencontainers/runtime-spec v1.0.3-0.20210326190908-1c3f411f0417/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= -github.com/opencontainers/selinux v1.10.0 h1:rAiKF8hTcgLI3w0DHm6i0ylVVcOrlgR1kK99DRLDhyU= -github.com/opencontainers/selinux v1.10.0/go.mod h1:2i0OySw99QjzBBQByd1Gr9gSjvuho1lHsJxIJ3gGbJI= -github.com/opencontainers/selinux v1.10.1 h1:09LIPVRP3uuZGQvgR+SgMSNBd1Eb3vlRbGqQpoHsF8w= -github.com/opencontainers/selinux v1.10.1/go.mod h1:2i0OySw99QjzBBQByd1Gr9gSjvuho1lHsJxIJ3gGbJI= -github.com/opentracing-contrib/go-observer v0.0.0-20170622124052-a52f23424492 h1:lM6RxxfUMrYL/f8bWEUqdXrANWtrL7Nndbm9iFN0DlU= -github.com/opentracing/basictracer-go v1.0.0 h1:YyUAhaEfjoWXclZVJ9sGoNct7j4TVk7lZWlQw5UXuoo= -github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+1B0VhjKrZUs= -github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc= -github.com/openzipkin-contrib/zipkin-go-opentracing v0.4.5 h1:ZCnq+JUrvXcDVhX/xRolRBZifmabN1HcS1wrPSvxhrU= -github.com/openzipkin/zipkin-go v0.2.5 h1:UwtQQx2pyPIgWYHRg+epgdx1/HnBQTgN3/oIYEJTQzU= -github.com/openzipkin/zipkin-go v0.2.5/go.mod h1:KpXfKdgRDnnhsxw4pNIH9Md5lyFqKUa4YDFlwRYAMyE= -github.com/orisano/pixelmatch v0.0.0-20220722002657-fb0b55479cde h1:x0TT0RDC7UhAVbbWWBzr41ElhJx5tXPWkIHA2HWPRuw= -github.com/orisano/pixelmatch v0.0.0-20220722002657-fb0b55479cde/go.mod h1:nZgzbfBr3hhjoZnS66nKrHmduYNpc34ny7RK4z5/HM0= -github.com/ory/dockertest/v3 v3.9.1 h1:v4dkG+dlu76goxMiTT2j8zV7s4oPPEppKT8K8p2f1kY= -github.com/ory/dockertest/v3 v3.9.1/go.mod h1:42Ir9hmvaAPm0Mgibk6mBPi7SFvTXxEcnztDYOJ//uM= -github.com/ory/dockertest/v3 v3.10.0 h1:4K3z2VMe8Woe++invjaTB7VRyQXQy5UY+loujO4aNE4= -github.com/ory/dockertest/v3 v3.10.0/go.mod h1:nr57ZbRWMqfsdGdFNLHz5jjNdDb7VVFnzAeW1n5N1Lg= -github.com/otiai10/copy v1.2.0 h1:HvG945u96iNadPoG2/Ja2+AUJeW5YuFQMixq9yirC+k= -github.com/otiai10/copy v1.2.0/go.mod h1:rrF5dJ5F0t/EWSYODDu4j9/vEeYHMkc8jt0zJChqQWw= -github.com/otiai10/curr v0.0.0-20150429015615-9b4961190c95/go.mod h1:9qAhocn7zKJG+0mI8eUu6xqkFDYS2kb2saOteoSB3cE= -github.com/otiai10/curr v1.0.0 h1:TJIWdbX0B+kpNagQrjgq8bCMrbhiuX73M2XwgtDMoOI= -github.com/otiai10/curr v1.0.0/go.mod h1:LskTG5wDwr8Rs+nNQ+1LlxRjAtTZZjtJW4rMXl6j4vs= -github.com/otiai10/mint v1.3.0/go.mod h1:F5AjcsTsWUqX+Na9fpHb52P8pcRX2CI6A3ctIT91xUo= -github.com/otiai10/mint v1.3.1 h1:BCmzIS3n71sGfHB5NMNDB3lHYPz8fWSkCAErHed//qc= -github.com/otiai10/mint v1.3.1/go.mod h1:/yxELlJQ0ufhjUwhshSj+wFjZ78CnZ48/1wtmBH1OTc= -github.com/pact-foundation/pact-go v1.0.4 h1:OYkFijGHoZAYbOIb1LWXrwKQbMMRUv1oQ89blD2Mh2Q= -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/pborman/uuid v1.2.0 h1:J7Q5mO4ysT1dv8hyrUGHb9+ooztCXu1D8MY8DZYsu3g= -github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= -github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= -github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= -github.com/pelletier/go-toml/v2 v2.0.5/go.mod h1:OMHamSCAODeSsVrwwvcJOaoN0LIUIaFVNZzmWyNfXas= -github.com/performancecopilot/speed v3.0.0+incompatible h1:2WnRzIquHa5QxaJKShDkLM+sc0JPuwhXzK8OYOyt3Vg= -github.com/performancecopilot/speed/v4 v4.0.0 h1:VxEDCmdkfbQYDlcr/GC9YoN9PQ6p8ulk9xVsepYy9ZY= -github.com/performancecopilot/speed/v4 v4.0.0/go.mod h1:qxrSyuDGrTOWfV+uKRFhfxw6h/4HXRGUiZiufxo49BM= -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/petermattis/goid v0.0.0-20230317030725-371a4b8eda08/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= -github.com/phayes/checkstyle v0.0.0-20170904204023-bfd46e6a821d h1:CdDQnGF8Nq9ocOS/xlSptM1N3BbrA6/kmaep5ggwaIA= -github.com/phayes/checkstyle v0.0.0-20170904204023-bfd46e6a821d/go.mod h1:3OzsM7FXDQlpCiw2j81fOmAwQLnZnLGXVKUzeKQXIAw= -github.com/phpdave11/gofpdf v1.4.2 h1:KPKiIbfwbvC/wOncwhrpRdXVj2CZTCFlw4wnoyjtHfQ= -github.com/phpdave11/gofpdf v1.4.2/go.mod h1:zpO6xFn9yxo3YLyMvW8HcKWVdbNqgIfOOp2dXMnm1mY= -github.com/phpdave11/gofpdi v1.0.12/go.mod h1:vBmVV0Do6hSBHC8uKUQ71JGW+ZGQq74llk/7bXwjDoI= -github.com/phpdave11/gofpdi v1.0.13 h1:o61duiW8M9sMlkVXWlvP92sZJtGKENvW3VExs6dZukQ= -github.com/phpdave11/gofpdi v1.0.13/go.mod h1:vBmVV0Do6hSBHC8uKUQ71JGW+ZGQq74llk/7bXwjDoI= -github.com/pierrec/lz4 v2.0.5+incompatible h1:2xWsjqPFWcplujydGg4WmhC/6fZqK42wMM8aXeqhl0I= -github.com/pierrec/lz4/v4 v4.1.18 h1:xaKrnTkyoqfh1YItXl56+6KJNVYWlEEPuAQW9xsplYQ= -github.com/pierrec/lz4/v4 v4.1.18/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4= -github.com/pion/datachannel v1.5.2 h1:piB93s8LGmbECrpO84DnkIVWasRMk3IimbcXkTQLE6E= -github.com/pion/datachannel v1.5.2/go.mod h1:FTGQWaHrdCwIJ1rw6xBIfZVkslikjShim5yr05XFuCQ= -github.com/pion/dtls/v2 v2.1.5 h1:jlh2vtIyUBShchoTDqpCCqiYCyRFJ/lvf/gQ8TALs+c= -github.com/pion/dtls/v2 v2.1.5/go.mod h1:BqCE7xPZbPSubGasRoDFJeTsyJtdD1FanJYL0JGheqY= -github.com/pion/ice/v2 v2.2.6 h1:R/vaLlI1J2gCx141L5PEwtuGAGcyS6e7E0hDeJFq5Ig= -github.com/pion/ice/v2 v2.2.6/go.mod h1:SWuHiOGP17lGromHTFadUe1EuPgFh/oCU6FCMZHooVE= -github.com/pion/interceptor v0.1.11 h1:00U6OlqxA3FFB50HSg25J/8cWi7P6FbSzw4eFn24Bvs= -github.com/pion/interceptor v0.1.11/go.mod h1:tbtKjZY14awXd7Bq0mmWvgtHB5MDaRN7HV3OZ/uy7s8= -github.com/pion/logging v0.2.2 h1:M9+AIj/+pxNsDfAT64+MAVgJO0rsyLnoJKCqf//DoeY= -github.com/pion/logging v0.2.2/go.mod h1:k0/tDVsRCX2Mb2ZEmTqNa7CWsQPc+YYCB7Q+5pahoms= -github.com/pion/mdns v0.0.5 h1:Q2oj/JB3NqfzY9xGZ1fPzZzK7sDSD8rZPOvcIQ10BCw= -github.com/pion/mdns v0.0.5/go.mod h1:UgssrvdD3mxpi8tMxAXbsppL3vJ4Jipw1mTCW+al01g= -github.com/pion/randutil v0.1.0 h1:CFG1UdESneORglEsnimhUjf33Rwjubwj6xfiOXBa3mA= -github.com/pion/randutil v0.1.0/go.mod h1:XcJrSMMbbMRhASFVOlj/5hQial/Y8oH/HVo7TBZq+j8= -github.com/pion/rtcp v1.2.9 h1:1ujStwg++IOLIEoOiIQ2s+qBuJ1VN81KW+9pMPsif+U= -github.com/pion/rtcp v1.2.9/go.mod h1:qVPhiCzAm4D/rxb6XzKeyZiQK69yJpbUDJSF7TgrqNo= -github.com/pion/rtp v1.7.13 h1:qcHwlmtiI50t1XivvoawdCGTP4Uiypzfrsap+bijcoA= -github.com/pion/rtp v1.7.13/go.mod h1:bDb5n+BFZxXx0Ea7E5qe+klMuqiBrP+w8XSjiWtCUko= -github.com/pion/sctp v1.8.2 h1:yBBCIrUMJ4yFICL3RIvR4eh/H2BTTvlligmSTy+3kiA= -github.com/pion/sctp v1.8.2/go.mod h1:xFe9cLMZ5Vj6eOzpyiKjT9SwGM4KpK/8Jbw5//jc+0s= -github.com/pion/sdp/v3 v3.0.5 h1:ouvI7IgGl+V4CrqskVtr3AaTrPvPisEOxwgpdktctkU= -github.com/pion/sdp/v3 v3.0.5/go.mod h1:iiFWFpQO8Fy3S5ldclBkpXqmWy02ns78NOKoLLL0YQw= -github.com/pion/srtp/v2 v2.0.9 h1:JJq3jClmDFBPX/F5roEb0U19jSU7eUhyDqR/NZ34EKQ= -github.com/pion/srtp/v2 v2.0.9/go.mod h1:5TtM9yw6lsH0ppNCehB/EjEUli7VkUgKSPJqWVqbhQ4= -github.com/pion/stun v0.3.5 h1:uLUCBCkQby4S1cf6CGuR9QrVOKcvUwFeemaC865QHDg= -github.com/pion/stun v0.3.5/go.mod h1:gDMim+47EeEtfWogA37n6qXZS88L5V6LqFcf+DZA2UA= -github.com/pion/transport v0.13.1 h1:/UH5yLeQtwm2VZIPjxwnNFxjS4DFhyLfS4GlfuKUzfA= -github.com/pion/transport v0.13.1/go.mod h1:EBxbqzyv+ZrmDb82XswEE0BjfQFtuw1Nu6sjnjWCsGg= -github.com/pion/turn/v2 v2.0.8 h1:KEstL92OUN3k5k8qxsXHpr7WWfrdp7iJZHx99ud8muw= -github.com/pion/turn/v2 v2.0.8/go.mod h1:+y7xl719J8bAEVpSXBXvTxStjJv3hbz9YFflvkpcGPw= -github.com/pion/udp v0.1.1 h1:8UAPvyqmsxK8oOjloDk4wUt63TzFe9WEJkg5lChlj7o= -github.com/pion/udp v0.1.1/go.mod h1:6AFo+CMdKQm7UiA0eUPA8/eVCTx8jBIITLZHc9DWX5M= -github.com/pion/webrtc/v3 v3.1.42 h1:wJEQFIXVanptnQcHOLTuIo4AtGB2+mG2x4OhIhnITOA= -github.com/pion/webrtc/v3 v3.1.42/go.mod h1:ffD9DulDrPxyWvDPUIPAOSAWx9GUlOExiJPf7cCcMLA= -github.com/pjbgf/sha1cd v0.3.0 h1:4D5XXmUUBUl/xQ6IjCkEAbqXskkq/4O7LmGn0AqMDs4= -github.com/pjbgf/sha1cd v0.3.0/go.mod h1:nZ1rrWOcGJ5uZgEEVL1VUM9iRQiZvWdbZjkKyFzPPsI= -github.com/pkg/browser v0.0.0-20210911075715-681adbf594b8 h1:KoWmjvw+nsYOo29YJK9vDA65RGE3NrOnUtO7a+RF9HU= -github.com/pkg/browser v0.0.0-20210911075715-681adbf594b8/go.mod h1:HKlIX3XHQyzLZPlr7++PzdhaXEj94dEiJgZDTsxEqUI= -github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e h1:aoZm08cpOy4WuID//EZDgcC4zIxODThtZNPirFr42+A= -github.com/pkg/profile v1.6.0 h1:hUDfIISABYI59DyeB3OTay/HxSRwTQ8rB/H83k6r5dM= -github.com/pkg/profile v1.6.0/go.mod h1:qBsxPvzyUincmltOk6iyRVxHYg4adc0OFOv72ZdLa18= -github.com/pkg/profile v1.7.0 h1:hnbDkaNWPCLMO9wGLdBFTIZvzDrDfBM2072E1S9gJkA= -github.com/pkg/profile v1.7.0/go.mod h1:8Uer0jas47ZQMJ7VD+OHknK4YDY07LPUC6dEvqDjvNo= -github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI= -github.com/pkg/sftp v1.13.1/go.mod h1:3HaPG6Dq1ILlpPZRO0HVMrsydcdLt6HRDccSgb87qRg= -github.com/pkg/sftp v1.13.6 h1:JFZT4XbOU7l77xGSpOdW+pwIMqP044IyjXX6FGyEKFo= -github.com/pkg/sftp v1.13.6/go.mod h1:tz1ryNURKu77RL+GuCzmoJYxQczL3wLNNpPWagdg4Qk= -github.com/planetscale/vtprotobuf v0.6.1-0.20240319094008-0393e58bdf10 h1:GFCKgmp0tecUJ0sJuv4pzYCqS9+RGSn52M3FUwPs+uo= -github.com/planetscale/vtprotobuf v0.6.1-0.20240319094008-0393e58bdf10/go.mod h1:t/avpk3KcrXxUnYOhZhMXJlSEyie6gQbtLq5NM3loB8= -github.com/pointlander/compress v1.1.1-0.20190518213731-ff44bd196cc3 h1:hUmXhbljNFtrH5hzV9kiRoddZ5nfPTq3K0Sb2hYYiqE= -github.com/pointlander/compress v1.1.1-0.20190518213731-ff44bd196cc3/go.mod h1:q5NXNGzqj5uPnVuhGkZfmgHqNUhf15VLi6L9kW0VEc0= -github.com/pointlander/jetset v1.0.1-0.20190518214125-eee7eff80bd4 h1:RHHRCZeaNyBXdYPMjZNH8/XHDBH38TZzw8izrW7dmBE= -github.com/pointlander/jetset v1.0.1-0.20190518214125-eee7eff80bd4/go.mod h1:RdR1j20Aj5pB6+fw6Y9Ur7lMHpegTEjY1vc19hEZL40= -github.com/pointlander/peg v1.0.1 h1:mgA/GQE8TeS9MdkU6Xn6iEzBmQUQCNuWD7rHCK6Mjs0= -github.com/pointlander/peg v1.0.1/go.mod h1:5hsGDQR2oZI4QoWz0/Kdg3VSVEC31iJw/b7WjqCBGRI= -github.com/polyfloyd/go-errorlint v1.0.5 h1:AHB5JRCjlmelh9RrLxT9sgzpalIwwq4hqE8EkwIwKdY= -github.com/polyfloyd/go-errorlint v1.0.5/go.mod h1:APVvOesVSAnne5SClsPxPdfvZTVDojXh1/G3qb5wjGI= -github.com/polyfloyd/go-errorlint v1.4.5 h1:70YWmMy4FgRHehGNOUask3HtSFSOLKgmDn7ryNe7LqI= -github.com/polyfloyd/go-errorlint v1.4.5/go.mod h1:sIZEbFoDOCnTYYZoVkjc4hTnM459tuWA9H/EkdXwsKk= -github.com/posener/complete v1.1.1 h1:ccV59UEOTzVDnDUEFdT95ZzHVZ+5+158q8+SJb2QV5w= -github.com/posener/complete v1.2.3 h1:NP0eAhjcjImqslEwo/1hq7gpajME0fTLTezBKDqfXqo= -github.com/posener/complete v1.2.3/go.mod h1:WZIdtGGp+qx0sLrYKtIRAruyNpv6hFCicSgv7Sy7s/s= -github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c h1:ncq/mPwQF4JjgDlrVEn3C11VoGHZN7m8qihwgMEtzYw= -github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE= -github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= -github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= -github.com/prometheus/client_golang v1.12.0/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= -github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= -github.com/prometheus/client_golang v1.12.2/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= -github.com/prometheus/client_golang v1.14.0/go.mod h1:8vpkKitgIVNcqrRBWh1C4TIUQgYNtG/XQE4E/Zae36Y= -github.com/prometheus/client_golang v1.15.1/go.mod h1:e9yaBhRPU2pPNsZwE+JdQl0KEt1N9XgF6zxWmaC0xOk= -github.com/prometheus/client_model v0.2.1-0.20210607210712-147c58e9608a/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= -github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= -github.com/prometheus/client_model v0.4.0/go.mod h1:oMQmHW1/JoDwqLtg57MGgP/Fb1CJEYF2imWWhWtMkYU= -github.com/prometheus/client_model v0.5.0/go.mod h1:dTiFglRmd66nLR9Pv9f0mZi7B7fk5Pm3gvsjB5tr+kI= -github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= -github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc= -github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= -github.com/prometheus/common v0.34.0/go.mod h1:gB3sOl7P0TvJabZpLY5uQMpUqRCPPCyRLCZYc7JZTNE= -github.com/prometheus/common v0.37.0/go.mod h1:phzohg0JFMnBEFGxTDbfu3QyL5GI8gTQJFhYO5B3mfA= -github.com/prometheus/common v0.42.0/go.mod h1:xBwqVerjNdUDjgODMpudtOMwlOwf2SaTr1yjz4b7Zbc= -github.com/prometheus/common v0.48.0/go.mod h1:0/KsvlIEfPQCQ5I2iNSAWKPZziNCvRs5EC6ILDTlAPc= -github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= -github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= -github.com/prometheus/procfs v0.8.0/go.mod h1:z7EfXMXOkbkqb9IINtpCn86r/to3BnA0uaxHdg830/4= -github.com/prometheus/procfs v0.9.0/go.mod h1:+pB4zwohETzFnmlpe6yd2lSc+0/46IYZRB/chUwxUZY= -github.com/prometheus/procfs v0.10.1/go.mod h1:nwNm2aOCAYw8uTR/9bWRREkZFxAUcWzPHWJq+XBB/FM= -github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= -github.com/quasilyte/go-ruleguard v0.3.1-0.20210203134552-1b5a410e1cc8/go.mod h1:KsAh3x0e7Fkpgs+Q9pNLS5XpFSvYCEVl5gP9Pp1xp30= -github.com/quasilyte/go-ruleguard v0.3.18 h1:sd+abO1PEI9fkYennwzHn9kl3nqP6M5vE7FiOzZ+5CE= -github.com/quasilyte/go-ruleguard v0.3.18/go.mod h1:lOIzcYlgxrQ2sGJ735EHXmf/e9MJ516j16K/Ifcttvs= -github.com/quasilyte/go-ruleguard v0.4.0 h1:DyM6r+TKL+xbKB4Nm7Afd1IQh9kEUKQs2pboWGKtvQo= -github.com/quasilyte/go-ruleguard v0.4.0/go.mod h1:Eu76Z/R8IXtViWUIHkE3p8gdH3/PKk1eh3YGfaEof10= -github.com/quasilyte/go-ruleguard/dsl v0.3.0/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU= -github.com/quasilyte/go-ruleguard/dsl v0.3.21 h1:vNkC6fC6qMLzCOGbnIHOd5ixUGgTbp3Z4fGnUgULlDA= -github.com/quasilyte/go-ruleguard/dsl v0.3.21/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU= -github.com/quasilyte/go-ruleguard/dsl v0.3.22 h1:wd8zkOhSNr+I+8Qeciml08ivDt1pSXe60+5DqOpCjPE= -github.com/quasilyte/go-ruleguard/dsl v0.3.22/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU= -github.com/quasilyte/go-ruleguard/rules v0.0.0-20201231183845-9e62ed36efe1/go.mod h1:7JTjp89EGyU1d6XfBiXihJNG37wB2VRkd125Q1u7Plc= -github.com/quasilyte/go-ruleguard/rules v0.0.0-20211022131956-028d6511ab71 h1:CNooiryw5aisadVfzneSZPswRWvnVW8hF1bS/vo8ReI= -github.com/quasilyte/go-ruleguard/rules v0.0.0-20211022131956-028d6511ab71/go.mod h1:4cgAphtvu7Ftv7vOT2ZOYhC6CvBxZixcasr8qIOTA50= -github.com/quasilyte/gogrep v0.0.0-20220828223005-86e4605de09f h1:6Gtn2i04RD0gVyYf2/IUMTIs+qYleBt4zxDqkLTcu4U= -github.com/quasilyte/gogrep v0.0.0-20220828223005-86e4605de09f/go.mod h1:Cm9lpz9NZjEoL1tgZ2OgeUKPIxL1meE7eo60Z6Sk+Ng= -github.com/quasilyte/gogrep v0.5.0 h1:eTKODPXbI8ffJMN+W2aE0+oL0z/nh8/5eNdiO34SOAo= -github.com/quasilyte/gogrep v0.5.0/go.mod h1:Cm9lpz9NZjEoL1tgZ2OgeUKPIxL1meE7eo60Z6Sk+Ng= -github.com/quasilyte/regex/syntax v0.0.0-20200407221936-30656e2c4a95 h1:L8QM9bvf68pVdQ3bCFZMDmnt9yqcMBro1pC7F+IPYMY= -github.com/quasilyte/regex/syntax v0.0.0-20200407221936-30656e2c4a95/go.mod h1:rlzQ04UMyJXu/aOvhd8qT+hvDrFpiwqp8MRXDY9szc0= -github.com/quasilyte/regex/syntax v0.0.0-20210819130434-b3f0c404a727 h1:TCg2WBOl980XxGFEZSS6KlBGIV0diGdySzxATTWoqaU= -github.com/quasilyte/regex/syntax v0.0.0-20210819130434-b3f0c404a727/go.mod h1:rlzQ04UMyJXu/aOvhd8qT+hvDrFpiwqp8MRXDY9szc0= -github.com/quasilyte/stdinfo v0.0.0-20220114132959-f7386bf02567 h1:M8mH9eK4OUR4lu7Gd+PU1fV2/qnDNfzT635KRSObncs= -github.com/quasilyte/stdinfo v0.0.0-20220114132959-f7386bf02567/go.mod h1:DWNGW8A4Y+GyBgPuaQJuWiy0XYftx4Xm/y5Jqk9I6VQ= -github.com/rakyll/statik v0.1.7 h1:OF3QCZUuyPxuGEP7B4ypUa7sB/iHtqOTDYZXGM8KOdQ= -github.com/rakyll/statik v0.1.7/go.mod h1:AlZONWzMtEnMs7W4e/1LURLiI49pIMmp6V9Unghqrcc= -github.com/regen-network/gocuke v0.6.2 h1:pHviZ0kKAq2U2hN2q3smKNxct6hS0mGByFMHGnWA97M= -github.com/regen-network/gocuke v0.6.2/go.mod h1:zYaqIHZobHyd0xOrHGPQjbhGJsuZ1oElx150u2o1xuk= -github.com/remyoudompheng/go-dbus v0.0.0-20121104212943-b7232d34b1d5 h1:CvqZS4QYHBRvx7AeFdimd16HCbLlYsvQMcKDACpJW/c= -github.com/remyoudompheng/go-dbus v0.0.0-20121104212943-b7232d34b1d5/go.mod h1:+u151txRmLpwxBmpYn9z3d1sdJdjRPQpsXuYeY9jNls= -github.com/remyoudompheng/go-liblzma v0.0.0-20190506200333-81bf2d431b96 h1:J8J/cgLDRuqXJnwIrRDBvtl+LLsdg7De74znW/BRRq4= -github.com/remyoudompheng/go-liblzma v0.0.0-20190506200333-81bf2d431b96/go.mod h1:90HvCY7+oHHUKkbeMCiHt1WuFR2/hPJ9QrljDG+v6ls= -github.com/remyoudompheng/go-misc v0.0.0-20190427085024-2d6ac652a50e h1:eTWZyPUnHcuGRDiryS/l2I7FfKjbU3IBx3IjqHPxuKU= -github.com/remyoudompheng/go-misc v0.0.0-20190427085024-2d6ac652a50e/go.mod h1:80FQABjoFzZ2M5uEa6FUaJYEmqU2UOKojlFVak1UAwI= -github.com/rogpeppe/fastuuid v1.2.0 h1:Ppwyp6VYCF1nvBTXL3trRso7mXMlRrw9ooo375wvi2s= -github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= -github.com/rogpeppe/go-internal v1.8.0/go.mod h1:WmiCO8CzOY8rg0OYDC4/i/2WRWAB6poM+XZ2dLUbcbE= -github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o= -github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= -github.com/rs/cors v1.8.2/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= -github.com/rs/cors v1.8.3/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= -github.com/rs/dnscache v0.0.0-20211102005908-e0241e321417 h1:Lt9DzQALzHoDwMBGJ6v8ObDPR0dzr2a6sXTB1Fq7IHs= -github.com/rs/dnscache v0.0.0-20211102005908-e0241e321417/go.mod h1:qe5TWALJ8/a1Lqznoc5BDHpYX/8HU60Hm2AwRmqzxqA= -github.com/rs/xid v1.3.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= -github.com/rs/xid v1.4.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= -github.com/rs/xid v1.5.0 h1:mKX4bl4iPYJtEIxp6CYiUuLQ/8DYMoz0PUdtGgMFRVc= -github.com/rs/zerolog v1.27.0/go.mod h1:7frBqO0oezxmnO7GF86FY++uy8I0Tk/If5ni1G9Qc0U= -github.com/rs/zerolog v1.29.0/go.mod h1:NILgTygv/Uej1ra5XxGf82ZFSLk58MFGAUS2o6usyD0= -github.com/rs/zerolog v1.30.0/go.mod h1:/tk+P47gFdPXq4QYjvCmT5/Gsug2nagsFWBWhAiSi1w= -github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= -github.com/russross/blackfriday v1.6.0 h1:KqfZb0pUVN2lYqZUYRddxF4OR8ZMURnJIG5Y3VRLtww= -github.com/russross/blackfriday v1.6.0/go.mod h1:ti0ldHuxg49ri4ksnFxlkCfN+hvslNlmVHqNRXXJNAY= -github.com/ruudk/golang-pdf417 v0.0.0-20181029194003-1af4ab5afa58/go.mod h1:6lfFZQK844Gfx8o5WFuvpxWRwnSoipWe/p622j1v06w= -github.com/ruudk/golang-pdf417 v0.0.0-20201230142125-a7e3863a1245 h1:K1Xf3bKttbF+koVGaX5xngRIZ5bVjbmPnaxE/dR08uY= -github.com/ruudk/golang-pdf417 v0.0.0-20201230142125-a7e3863a1245/go.mod h1:pQAZKsJ8yyVxGRWYNEm9oFB8ieLgKFnamEyDmSA0BRk= -github.com/ryancurrah/gomodguard v1.2.4 h1:CpMSDKan0LtNGGhPrvupAoLeObRFjND8/tU1rEOtBp4= -github.com/ryancurrah/gomodguard v1.2.4/go.mod h1:+Kem4VjWwvFpUJRJSwa16s1tBJe+vbv02+naTow2f6M= -github.com/ryancurrah/gomodguard v1.3.0 h1:q15RT/pd6UggBXVBuLps8BXRvl5GPBcwVA7BJHMLuTw= -github.com/ryancurrah/gomodguard v1.3.0/go.mod h1:ggBxb3luypPEzqVtq33ee7YSN35V28XeGnid8dnni50= -github.com/ryanrolds/sqlclosecheck v0.3.0 h1:AZx+Bixh8zdUBxUA1NxbxVAS78vTPq4rCb8OUZI9xFw= -github.com/ryanrolds/sqlclosecheck v0.3.0/go.mod h1:1gREqxyTGR3lVtpngyFo3hZAgk0KCtEdgEkHwDbigdA= -github.com/ryanrolds/sqlclosecheck v0.4.0 h1:i8SX60Rppc1wRuyQjMciLqIzV3xnoHB7/tXbr6RGYNI= -github.com/ryanrolds/sqlclosecheck v0.4.0/go.mod h1:TBRRjzL31JONc9i4XMinicuo+s+E8yKZ5FN8X3G6CKQ= -github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f h1:UFr9zpz4xgTnIE5yIMtWAMngCdZ9p/+q6lTbgelo80M= -github.com/ryanuber/columnize v2.1.0+incompatible h1:j1Wcmh8OrK4Q7GXY+V7SVSY8nUWQxHW5TkBe7YUl+2s= -github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/sagikazarmark/crypt v0.17.0 h1:ZA/7pXyjkHoK4bW4mIdnCLvL8hd+Nrbiw7Dqk7D4qUk= -github.com/sagikazarmark/crypt v0.17.0/go.mod h1:SMtHTvdmsZMuY/bpZoqokSoChIrcJ/epOxZN58PbZDg= -github.com/sagikazarmark/crypt v0.19.0 h1:WMyLTjHBo64UvNcWqpzY3pbZTYgnemZU8FBZigKc42E= -github.com/sagikazarmark/crypt v0.19.0/go.mod h1:c6vimRziqqERhtSe0MhIvzE1w54FrCHtrXb5NH/ja78= -github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da h1:p3Vo3i64TCLY7gIfzeQaUJ+kppEO5WQG3cL8iE8tGHU= -github.com/sanity-io/litter v1.5.5 h1:iE+sBxPBzoK6uaEP5Lt3fHNgpKcHXc/A2HGETy0uJQo= -github.com/sanity-io/litter v1.5.5/go.mod h1:9gzJgR2i4ZpjZHsKvUXIRQVk7P+yM3e+jAF7bU2UI5U= -github.com/sanposhiho/wastedassign/v2 v2.0.6 h1:+6/hQIHKNJAUixEj6EmOngGIisyeI+T3335lYTyxRoA= -github.com/sanposhiho/wastedassign/v2 v2.0.6/go.mod h1:KyZ0MWTwxxBmfwn33zh3k1dmsbF2ud9pAAGfoLfjhtI= -github.com/sanposhiho/wastedassign/v2 v2.0.7 h1:J+6nrY4VW+gC9xFzUc+XjPD3g3wF3je/NsJFwFK7Uxc= -github.com/sanposhiho/wastedassign/v2 v2.0.7/go.mod h1:KyZ0MWTwxxBmfwn33zh3k1dmsbF2ud9pAAGfoLfjhtI= -github.com/sashamelentyev/interfacebloat v1.1.0 h1:xdRdJp0irL086OyW1H/RTZTr1h/tMEOsumirXcOJqAw= -github.com/sashamelentyev/interfacebloat v1.1.0/go.mod h1:+Y9yU5YdTkrNvoX0xHc84dxiN1iBi9+G8zZIhPVoNjQ= -github.com/sashamelentyev/usestdlibvars v1.20.0 h1:K6CXjqqtSYSsuyRDDC7Sjn6vTMLiSJa4ZmDkiokoqtw= -github.com/sashamelentyev/usestdlibvars v1.20.0/go.mod h1:0GaP+ecfZMXShS0A94CJn6aEuPRILv8h/VuWI9n1ygg= -github.com/sashamelentyev/usestdlibvars v1.23.0 h1:01h+/2Kd+NblNItNeux0veSL5cBF1jbEOPrEhDzGYq0= -github.com/sashamelentyev/usestdlibvars v1.23.0/go.mod h1:YPwr/Y1LATzHI93CqoPUN/2BzGQ/6N/cl/KwgR0B/aU= -github.com/satori/go.uuid v1.2.0 h1:0uYX9dsZ2yD7q2RtLRtPSdGDWzjeM3TbMJP9utgA0ww= -github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= -github.com/schollz/closestmatch v2.1.0+incompatible h1:Uel2GXEpJqOWBrlyI+oY9LTiyyjYS17cCYRqP13/SHk= -github.com/schollz/closestmatch v2.1.0+incompatible/go.mod h1:RtP1ddjLong6gTkbtmuhtR2uUrrJOpYzYRvbcPAid+g= -github.com/sclevine/agouti v3.0.0+incompatible h1:8IBJS6PWz3uTlMP3YBIR5f+KAldcGuOeFkFbUWfBgK4= -github.com/sclevine/agouti v3.0.0+incompatible/go.mod h1:b4WX9W9L1sfQKXeJf1mUTLZKJ48R1S7H23Ji7oFO5Bw= -github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 h1:nn5Wsu0esKSJiIVhscUtVbo7ada43DJhG55ua/hjS5I= -github.com/seccomp/libseccomp-golang v0.9.2-0.20220502022130-f33da4d89646 h1:RpforrEYXWkmGwJHIGnLZ3tTWStkjVVstwzNGqxX2Ds= -github.com/seccomp/libseccomp-golang v0.9.2-0.20220502022130-f33da4d89646/go.mod h1:JA8cRccbGaA1s33RQf7Y1+q9gHmZX1yB/z9WDN1C6fg= -github.com/securego/gosec/v2 v2.13.1 h1:7mU32qn2dyC81MH9L2kefnQyRMUarfDER3iQyMHcjYM= -github.com/securego/gosec/v2 v2.13.1/go.mod h1:EO1sImBMBWFjOTFzMWfTRrZW6M15gm60ljzrmy/wtHo= -github.com/securego/gosec/v2 v2.15.0 h1:v4Ym7FF58/jlykYmmhZ7mTm7FQvN/setNm++0fgIAtw= -github.com/securego/gosec/v2 v2.15.0/go.mod h1:VOjTrZOkUtSDt2QLSJmQBMWnvwiQPEjg0l+5juIqGk8= -github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= -github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= -github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= -github.com/sergi/go-diff v1.2.0 h1:XU+rvMAioB0UC3q1MFrIQy4Vo5/4VsRDQQXHsEya6xQ= -github.com/sergi/go-diff v1.2.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= -github.com/serialx/hashring v0.0.0-20190422032157-8b2912629002 h1:ka9QPuQg2u4LGipiZGsgkg3rJCo4iIUCy75FddM0GRQ= -github.com/serialx/hashring v0.0.0-20190422032157-8b2912629002/go.mod h1:/yeG0My1xr/u+HZrFQ1tOQQQQrOawfyMUH13ai5brBc= -github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c h1:W65qqJCIOVP4jpqPQ0YvHYKwcMEMVWIzWC5iNQQfBTU= -github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c/go.mod h1:/PevMnwAxekIXwN8qQyfc5gl2NlkB3CQlkizAbOkeBs= -github.com/shirou/gopsutil/v3 v3.23.2 h1:PAWSuiAszn7IhPMBtXsbSCafej7PqUOvY6YywlQUExU= -github.com/shirou/gopsutil/v3 v3.23.2/go.mod h1:gv0aQw33GLo3pG8SiWKiQrbDzbRY1K80RyZJ7V4Th1M= -github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e h1:MZM7FHLqUHYI0Y/mQAt3d2aYa0SiNms/hFqC9qJYolM= -github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk= -github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041 h1:llrF3Fs4018ePo4+G/HV/uQUqEI1HMDjCeOf2V6puPc= -github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041/go.mod h1:N5mDOmsrJOB+vfqUK+7DmDyjhSLIIBnXo9lvZJj3MWQ= -github.com/shurcooL/sanitized_anchor_name v1.0.0 h1:PdmoCO6wvbs+7yrJyMORt4/BmY5IYyJwS/kOiWx8mHo= -github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sivchari/containedctx v1.0.2 h1:0hLQKpgC53OVF1VT7CeoFHk9YKstur1XOgfYIc1yrHI= -github.com/sivchari/containedctx v1.0.2/go.mod h1:PwZOeqm4/DLoJOqMSIJs3aKqXRX4YO+uXww087KZ7Bw= -github.com/sivchari/nosnakecase v1.7.0 h1:7QkpWIRMe8x25gckkFd2A5Pi6Ymo0qgr4JrhGt95do8= -github.com/sivchari/nosnakecase v1.7.0/go.mod h1:CwDzrzPea40/GB6uynrNLiorAlgFRvRbFSgJx2Gs+QY= -github.com/sivchari/tenv v1.7.0 h1:d4laZMBK6jpe5PWepxlV9S+LC0yXqvYHiq8E6ceoVVE= -github.com/sivchari/tenv v1.7.0/go.mod h1:64yStXKSOxDfX47NlhVwND4dHwfZDdbp2Lyl018Icvg= -github.com/sivchari/tenv v1.7.1 h1:PSpuD4bu6fSmtWMxSGWcvqUUgIn7k3yOJhOIzVWn8Ak= -github.com/sivchari/tenv v1.7.1/go.mod h1:64yStXKSOxDfX47NlhVwND4dHwfZDdbp2Lyl018Icvg= -github.com/skeema/knownhosts v1.2.1 h1:SHWdIUa82uGZz+F+47k8SY4QhhI291cXCpopT1lK2AQ= -github.com/skeema/knownhosts v1.2.1/go.mod h1:xYbVRSPxqBZFrdmDyMmsOs+uX1UZC3nTN3ThzgDxUwo= -github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d h1:zE9ykElWQ6/NYmHa3jpm/yHnI4xSofP+UP6SpjHcSeM= -github.com/smartystreets/goconvey v1.6.4 h1:fv0U8FUIMPNf1L9lnHLvLhgicrIVChEkdzIKYqbNC9s= -github.com/snikch/goodman v0.0.0-20171125024755-10e37e294daa h1:YJfZp12Z3AFhSBeXOlv4BO55RMwPn2NoQeDsrdWnBtY= -github.com/snikch/goodman v0.0.0-20171125024755-10e37e294daa/go.mod h1:oJyF+mSPHbB5mVY2iO9KV3pTt/QbIkGaO8gQ2WrDbP4= -github.com/soheilhy/cmux v0.1.4 h1:0HKaf1o97UwFjHH9o5XsHUOF+tqmdA7KEzXLpiyaw0E= -github.com/sonatard/noctx v0.0.1 h1:VC1Qhl6Oxx9vvWo3UDgrGXYCeKCe3Wbw7qAWL6FrmTY= -github.com/sonatard/noctx v0.0.1/go.mod h1:9D2D/EoULe8Yy2joDHJj7bv3sZoq9AaSb8B4lqBjiZI= -github.com/sonatard/noctx v0.0.2 h1:L7Dz4De2zDQhW8S0t+KUjY0MAQJd6SgVwhzNIc4ok00= -github.com/sonatard/noctx v0.0.2/go.mod h1:kzFz+CzWSjQ2OzIm46uJZoXuBpa2+0y3T36U18dWqIo= -github.com/sony/gobreaker v0.4.1 h1:oMnRNZXX5j85zso6xCPRNPtmAycat+WcoKbklScLDgQ= -github.com/sourcegraph/go-diff v0.6.1 h1:hmA1LzxW0n1c3Q4YbrFgg4P99GSnebYa3x8gr0HZqLQ= -github.com/sourcegraph/go-diff v0.6.1/go.mod h1:iBszgVvyxdc8SFZ7gm69go2KDdt3ag071iBaWPF6cjs= -github.com/sourcegraph/go-diff v0.7.0 h1:9uLlrd5T46OXs5qpp8L/MTltk0zikUGi0sNNyCpA8G0= -github.com/sourcegraph/go-diff v0.7.0/go.mod h1:iBszgVvyxdc8SFZ7gm69go2KDdt3ag071iBaWPF6cjs= -github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72 h1:qLC7fQah7D6K1B0ujays3HV9gkFtllcxhzImRR7ArPQ= -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/afero v1.4.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I= -github.com/spf13/afero v1.8.2/go.mod h1:CtAatgMJh6bJEIs48Ay/FOnkljP3WeGUG0MC1RfAqwo= -github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cast v1.5.0/go.mod h1:SpXXQ5YoyJw6s3/6cMTQuxvgRl3PCJiyaX9p6b155UU= -github.com/spf13/cast v1.5.1/go.mod h1:b9PdjNptOpzXr7Rq1q9gJML/2cdGQAo69NKzQ10KN48= -github.com/spf13/cast v1.6.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= -github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= -github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE= -github.com/spf13/cobra v1.6.0/go.mod h1:IOw/AERYS7UzyrGinqmz6HLUo219MORXGxhbaJUqzrY= -github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= -github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= -github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk= -github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo= -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/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE= -github.com/spf13/viper v1.13.0/go.mod h1:Icm2xNL3/8uyh/wFuB1jI7TiTNKp8632Nwegu+zgdYw= -github.com/spf13/viper v1.18.1/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk= -github.com/ssgreg/nlreturn/v2 v2.2.1 h1:X4XDI7jstt3ySqGU86YGAURbxw3oTDPK9sPEi6YEwQ0= -github.com/ssgreg/nlreturn/v2 v2.2.1/go.mod h1:E/iiPB78hV7Szg2YfRgyIrk1AD6JVMTRkkxBiELzh2I= -github.com/stbenjam/no-sprintf-host-port v0.1.1 h1:tYugd/yrm1O0dV+ThCbaKZh195Dfm07ysF0U6JQXczc= -github.com/stbenjam/no-sprintf-host-port v0.1.1/go.mod h1:TLhvtIvONRzdmkFiio4O8LHsN9N74I+PhRquPsxpL0I= -github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980 h1:lIOOHPEbXzO3vnmx2gok1Tfs31Q8GQqKLc8vVqyQq/I= -github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980/go.mod h1:AO3tvPzVZ/ayst6UlUKUv6rcPQInYe3IknH3jYhAKu8= -github.com/streadway/amqp v1.0.0 h1:kuuDrUJFZL1QYL9hUNuCxNObNzB0bV/ZG5jV3RWAQgo= -github.com/streadway/amqp v1.0.0/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= -github.com/streadway/handy v0.0.0-20200128134331-0f66f006fb2e h1:mOtuXaRAbVZsxAHVdPR3IjfmN8T1h2iczJLynhLybf8= -github.com/streadway/handy v0.0.0-20200128134331-0f66f006fb2e/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= -github.com/stretchr/testify v1.1.4/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= -github.com/stretchr/testify v1.7.5/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= -github.com/subosito/gotenv v1.4.1/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= -github.com/supranational/blst v0.3.8-0.20220526154634-513d2456b344 h1:m+8fKfQwCAy1QjzINvKe/pYtLjo2dl59x2w9YSEJxuY= -github.com/supranational/blst v0.3.8-0.20220526154634-513d2456b344/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= -github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635 h1:kdXcSzyDtseVEc4yCz2qF8ZrQvIDBJLl4S1c3GCXmoI= -github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww= -github.com/t-yuki/gocover-cobertura v0.0.0-20180217150009-aaee18c8195c h1:+aPplBwWcHBo6q9xrfWdMrT9o4kltkmmvpemgIjep/8= -github.com/t-yuki/gocover-cobertura v0.0.0-20180217150009-aaee18c8195c/go.mod h1:SbErYREK7xXdsRiigaQiQkI9McGRzYMvlKYaP3Nimdk= -github.com/tchap/go-patricia v2.2.6+incompatible h1:JvoDL7JSoIP2HDE8AbDH3zC8QBPxmzYe32HHy5yQ+Ck= -github.com/tchap/go-patricia v2.2.6+incompatible/go.mod h1:bmLyhP68RS6kStMGxByiQ23RP/odRBOTVjwp2cDyi6I= -github.com/tdakkota/asciicheck v0.1.1 h1:PKzG7JUTUmVspQTDqtkX9eSiLGossXTybutHwTXuO0A= -github.com/tdakkota/asciicheck v0.1.1/go.mod h1:yHp0ai0Z9gUljN3o0xMhYJnH/IcvkdTBOX2fmJ93JEM= -github.com/tdakkota/asciicheck v0.2.0 h1:o8jvnUANo0qXtnslk2d3nMKTFNlOnJjRrNcj0j9qkHM= -github.com/tdakkota/asciicheck v0.2.0/go.mod h1:Qb7Y9EgjCLJGup51gDHFzbI08/gbGhL/UVhYIPWG2rg= -github.com/tdewolff/minify/v2 v2.12.4 h1:kejsHQMM17n6/gwdw53qsi6lg0TGddZADVyQOz1KMdE= -github.com/tdewolff/minify/v2 v2.12.4/go.mod h1:h+SRvSIX3kwgwTFOpSckvSxgax3uy8kZTSF1Ojrr3bk= -github.com/tdewolff/parse/v2 v2.6.4 h1:KCkDvNUMof10e3QExio9OPZJT8SbdKojLBumw8YZycQ= -github.com/tdewolff/parse/v2 v2.6.4/go.mod h1:woz0cgbLwFdtbjJu8PIKxhW05KplTFQkOdX78o+Jgrs= -github.com/tdewolff/test v1.0.7 h1:8Vs0142DmPFW/bQeHRP3MV19m1gvndjUb1sn8yy74LM= -github.com/tdewolff/test v1.0.7/go.mod h1:6DAvZliBAAnD7rhVgwaM7DE5/d9NMOAJ09SqYqeK4QE= -github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c h1:g+WoO5jjkqGAzHWCjJB1zZfXPIAaDpzXIEJ0eS6B5Ok= -github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c/go.mod h1:ahpPrc7HpcfEWDQRZEmnXMzHY03mLDYMCxeDzy46i+8= -github.com/tenntenn/modver v1.0.1 h1:2klLppGhDgzJrScMpkj9Ujy3rXPUspSjAcev9tSEBgA= -github.com/tenntenn/modver v1.0.1/go.mod h1:bePIyQPb7UeioSRkw3Q0XeMhYZSMx9B8ePqg6SAMGH0= -github.com/tenntenn/text/transform v0.0.0-20200319021203-7eef512accb3 h1:f+jULpRQGxTSkNYKJ51yaw6ChIqO+Je8UqsTKN/cDag= -github.com/tenntenn/text/transform v0.0.0-20200319021203-7eef512accb3/go.mod h1:ON8b8w4BN/kE1EOhwT0o+d62W65a6aPw1nouo9LMgyY= -github.com/tetafro/godot v1.4.11 h1:BVoBIqAf/2QdbFmSwAWnaIqDivZdOV0ZRwEm6jivLKw= -github.com/tetafro/godot v1.4.11/go.mod h1:LR3CJpxDVGlYOWn3ZZg1PgNZdTUvzsZWu8xaEohUpn8= -github.com/timakin/bodyclose v0.0.0-20210704033933-f49887972144 h1:kl4KhGNsJIbDHS9/4U9yQo1UcPQM0kOMJHn29EoH/Ro= -github.com/timakin/bodyclose v0.0.0-20210704033933-f49887972144/go.mod h1:Qimiffbc6q9tBWlVV6x0P9sat/ao1xEkREYPPj9hphk= -github.com/timakin/bodyclose v0.0.0-20221125081123-e39cf3fc478e h1:MV6KaVu/hzByHP0UvJ4HcMGE/8a6A4Rggc/0wx2AvJo= -github.com/timakin/bodyclose v0.0.0-20221125081123-e39cf3fc478e/go.mod h1:27bSVNWSBOHm+qRp1T9qzaIpsWEP6TbUnei/43HK+PQ= -github.com/timonwong/loggercheck v0.9.3 h1:ecACo9fNiHxX4/Bc02rW2+kaJIAMAes7qJ7JKxt0EZI= -github.com/timonwong/loggercheck v0.9.3/go.mod h1:wUqnk9yAOIKtGA39l1KLE9Iz0QiTocu/YZoOf+OzFdw= -github.com/timonwong/loggercheck v0.9.4 h1:HKKhqrjcVj8sxL7K77beXh0adEm6DLjV/QOGeMXEVi4= -github.com/timonwong/loggercheck v0.9.4/go.mod h1:caz4zlPcgvpEkXgVnAJGowHAMW2NwHaNlpS8xDbVhTg= -github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8 h1:ndzgwNDnKIqyCvHTXaCqh9KlOWKvBry6nuXMJmonVsE= -github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5 h1:LnC5Kc/wtumK+WB441p7ynQJzVuNRJiqddSIE3IlSEQ= -github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/tomarrell/wrapcheck/v2 v2.7.0 h1:J/F8DbSKJC83bAvC6FoZaRjZiZ/iKoueSdrEkmGeacA= -github.com/tomarrell/wrapcheck/v2 v2.7.0/go.mod h1:ao7l5p0aOlUNJKI0qVwB4Yjlqutd0IvAB9Rdwyilxvg= -github.com/tomarrell/wrapcheck/v2 v2.8.1 h1:HxSqDSN0sAt0yJYsrcYVoEeyM4aI9yAm3KQpIXDJRhQ= -github.com/tomarrell/wrapcheck/v2 v2.8.1/go.mod h1:/n2Q3NZ4XFT50ho6Hbxg+RV1uyo2Uow/Vdm9NQcl5SE= -github.com/tommy-muehle/go-mnd/v2 v2.5.1 h1:NowYhSdyE/1zwK9QCLeRb6USWdoif80Ie+v+yU8u1Zw= -github.com/tommy-muehle/go-mnd/v2 v2.5.1/go.mod h1:WsUAkMJMYww6l/ufffCD3m+P7LEvr8TnZn9lwVDlgzw= -github.com/tonistiigi/fsutil v0.0.0-20220115021204-b19f7f9cb274 h1:wbyZxD6IPFp0sl5uscMOJRsz5UKGFiNiD16e+MVfKZY= -github.com/tonistiigi/fsutil v0.0.0-20220115021204-b19f7f9cb274/go.mod h1:oPAfvw32vlUJSjyDcQ3Bu0nb2ON2B+G0dtVN/SZNJiA= -github.com/tonistiigi/go-actions-cache v0.0.0-20220404170428-0bdeb6e1eac7 h1:8eY6m1mjgyB8XySUR7WvebTM8D/Vs86jLJzD/Tw7zkc= -github.com/tonistiigi/go-actions-cache v0.0.0-20220404170428-0bdeb6e1eac7/go.mod h1:qqvyZqkfwkoJuPU/bw61bItaoO0SJ8YSW0vSVRRvsRg= -github.com/tonistiigi/go-archvariant v1.0.0 h1:5LC1eDWiBNflnTF1prCiX09yfNHIxDC/aukdhCdTyb0= -github.com/tonistiigi/go-archvariant v1.0.0/go.mod h1:TxFmO5VS6vMq2kvs3ht04iPXtu2rUT/erOnGFYfk5Ho= -github.com/tonistiigi/units v0.0.0-20180711220420-6950e57a87ea h1:SXhTLE6pb6eld/v/cCndK0AMpt1wiVFb/YYmqB3/QG0= -github.com/tonistiigi/units v0.0.0-20180711220420-6950e57a87ea/go.mod h1:WPnis/6cRcDZSUvVmezrxJPkiO87ThFYsoUiMwWNDJk= -github.com/tonistiigi/vt100 v0.0.0-20210615222946-8066bb97264f h1:DLpt6B5oaaS8jyXHa9VA4rrZloBVPVXeCtrOsrFauxc= -github.com/tonistiigi/vt100 v0.0.0-20210615222946-8066bb97264f/go.mod h1:ulncasL3N9uLrVann0m+CDlJKWsIAP34MPcOJF6VRvc= -github.com/torquem-ch/mdbx-go v0.27.5 h1:bbhXQGFCmoxbRDXKYEJwxSOOTeBKwoD4pFBUpK9+V1g= -github.com/torquem-ch/mdbx-go v0.27.5/go.mod h1:T2fsoJDVppxfAPTLd1svUgH1kpPmeXdPESmroSHcL1E= -github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926 h1:G3dpKMzFDjgEh2q1Z7zUUtKa8ViPtH+ocF0bE0g00O8= -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 v1.2.7 h1:qYhyWUUd6WbiM+C6JZAUkIJt/1WrjzNHY9+KCIjVqTo= -github.com/ugorji/go v1.2.7/go.mod h1:nF9osbDWLy6bDVv/Rtoh6QgnvNDpmCalQV5urGCCS6M= -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/ugorji/go/codec v1.2.7/go.mod h1:WGN1fab3R1fzQlVQTkfxVtIBhWDRqOviHU95kRgeqEY= -github.com/ultraware/funlen v0.0.3 h1:5ylVWm8wsNwH5aWo9438pwvsK0QiqVuUrt9bn7S/iLA= -github.com/ultraware/funlen v0.0.3/go.mod h1:Dp4UiAus7Wdb9KUZsYWZEWiRzGuM2kXM1lPbfaF6xhA= -github.com/ultraware/whitespace v0.0.5 h1:hh+/cpIcopyMYbZNVov9iSxvJU3OYQg78Sfaqzi/CzI= -github.com/ultraware/whitespace v0.0.5/go.mod h1:aVMh/gQve5Maj9hQ/hg+F75lr/X5A89uZnzAmWSineA= -github.com/urfave/cli v1.22.4 h1:u7tSpNPPswAFymm8IehJhy4uJMlUuU/GmqSkvJ1InXA= -github.com/urfave/cli v1.22.4/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= -github.com/urfave/negroni v1.0.0 h1:kIimOitoypq34K7TG7DUaJ9kq/N4Ofuwi1sjz0KipXc= -github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= -github.com/uudashr/gocognit v1.0.6 h1:2Cgi6MweCsdB6kpcVQp7EW4U23iBFQWfTXiWlyp842Y= -github.com/uudashr/gocognit v1.0.6/go.mod h1:nAIUuVBnYU7pcninia3BHOvQkpQCeO76Uscky5BOwcY= -github.com/valyala/bytebufferpool v1.0.0 h1:GqA5TC/0021Y/b9FG4Oi9Mr3q7XYx6KllzawFIhcdPw= -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/fasthttp v1.40.0 h1:CRq/00MfruPGFLTQKY8b+8SfdK60TxNztjRMnH0t1Yc= -github.com/valyala/fasthttp v1.40.0/go.mod h1:t/G+3rLek+CyY9bnIE+YlMRddxVAAGjhxndDB4i4C0I= -github.com/valyala/fastrand v1.1.0 h1:f+5HkLW4rsgzdNoleUOB69hyT9IlD2ZQh9GyDMfb5G8= -github.com/valyala/fastrand v1.1.0/go.mod h1:HWqCzkrkg6QXT8V2EXWvXCoow7vLwOFN002oeRzjapQ= -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/fasttemplate v1.2.2 h1:lxLXG0uE3Qnshl9QyaK6XJxMXlQZELvChBOCmQD0Loo= -github.com/valyala/fasttemplate v1.2.2/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= -github.com/valyala/histogram v1.2.0 h1:wyYGAZZt3CpwUiIb9AU/Zbllg1llXyrtApRS815OLoQ= -github.com/valyala/histogram v1.2.0/go.mod h1:Hb4kBwb4UxsaNbbbh+RRz8ZR6pdodR57tzWUS3BUzXY= -github.com/valyala/quicktemplate v1.7.0 h1:LUPTJmlVcb46OOUY3IeD9DojFpAVbsG+5WFTcjMJzCM= -github.com/valyala/quicktemplate v1.7.0/go.mod h1:sqKJnoaOF88V07vkO+9FL8fb9uZg/VPSJnLYn+LmLk8= -github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= -github.com/valyala/tcplisten v1.0.0 h1:rBHj/Xf+E1tRGZyWIWwJDiRY0zc1Js+CV5DqwacVSA8= -github.com/valyala/tcplisten v1.0.0/go.mod h1:T0xQ8SeCZGxckz9qRXTfG43PvQ/mcWh7FwZEA7Ioqkc= -github.com/vbatts/tar-split v0.11.2 h1:Via6XqJr0hceW4wff3QRzD5gAk/tatMw/4ZA7cTlIME= -github.com/vbatts/tar-split v0.11.2/go.mod h1:vV3ZuO2yWSVsz+pfFzDG/upWH1JhjOiEaWq6kXyQ3VI= -github.com/vektra/mockery/v2 v2.14.0 h1:KZ1p5Hrn8tiY+LErRMr14HHle6khxo+JKOXLBW/yfqs= -github.com/vektra/mockery/v2 v2.14.0/go.mod h1:bnD1T8tExSgPD1ripLkDbr60JA9VtQeu12P3wgLZd7M= -github.com/vektra/mockery/v2 v2.23.1 h1:N59FENM2d/gWE6Ns5JPuf9a7jqQWeheGefZqvuvb1dM= -github.com/vektra/mockery/v2 v2.23.1/go.mod h1:Zh3Kv1ckKs6FokhlVLcCu6UTyzfS3M8mpROz1lBNp+w= -github.com/vishvananda/netlink v1.1.0 h1:1iyaYNBLmP6L0220aDnYQpo1QEV4t4hJ+xEEhhJH8j0= -github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE= -github.com/vishvananda/netlink v1.1.1-0.20210330154013-f5de75959ad5 h1:+UB2BJA852UkGH42H+Oee69djmxS3ANzl2b/JtT1YiA= -github.com/vishvananda/netlink v1.1.1-0.20210330154013-f5de75959ad5/go.mod h1:twkDnbuQxJYemMlGd4JFIcuhgX83tXhKS2B/PRMpOho= -github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df h1:OviZH7qLw/7ZovXvuNyL3XQl8UFofeikI1NW1Gypu7k= -github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df/go.mod h1:JP3t17pCcGlemwknint6hfoeCVQrEMVwxRLRjXpq+BU= -github.com/vishvananda/netns v0.0.0-20200728191858-db3c7e526aae/go.mod h1:DD4vA1DwXk04H54A1oHXtwZmA0grkVMdPxx/VGLCah0= -github.com/vishvananda/netns v0.0.0-20210104183010-2eb08e3e575f h1:p4VB7kIXpOQvVn1ZaTIVp+3vuYAXFe3OJEvjbUYJLaA= -github.com/vishvananda/netns v0.0.0-20210104183010-2eb08e3e575f/go.mod h1:DD4vA1DwXk04H54A1oHXtwZmA0grkVMdPxx/VGLCah0= -github.com/vmihailenco/msgpack/v5 v5.3.5 h1:5gO0H1iULLWGhs2H5tbAHIZTV8/cYafcFOr9znI5mJU= -github.com/vmihailenco/msgpack/v5 v5.3.5/go.mod h1:7xyJ9e+0+9SaZT0Wt1RGleJXzli6Q/V5KbhBonMG9jc= -github.com/vmihailenco/tagparser/v2 v2.0.0 h1:y09buUbR+b5aycVFQs/g70pqKVZNBmxwAhO7/IwNM9g= -github.com/vmihailenco/tagparser/v2 v2.0.0/go.mod h1:Wri+At7QHww0WTrCBeu4J6bNtoV6mEfg5OIWRZA9qds= -github.com/xanzy/ssh-agent v0.3.3 h1:+/15pJfg/RsTxqYcX6fHqOXZwwMP+2VyYWJeWM2qQFM= -github.com/xanzy/ssh-agent v0.3.3/go.mod h1:6dzNDKs0J9rVPHPhaGCukekBHKqfl+L3KghI1Bc68Uw= -github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb h1:zGWFAtiMcyryUHoUjUJX0/lt1H2+i2Ka2n+D3DImSNo= -github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 h1:EzJWgHovont7NscjpAxXsDA8S8BMYve8Y5+7cuRE7R0= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0 h1:LhYJRs+L4fBtjZUfuSZIKGeVu0QRy8e5Xi7D17UxZ74= -github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= -github.com/xhit/go-str2duration v1.2.0 h1:BcV5u025cITWxEQKGWr1URRzrcXtu7uk8+luz3Yuhwc= -github.com/xhit/go-str2duration v1.2.0/go.mod h1:3cPSlfZlUHVlneIVfePFWcJZsuwf+P1v2SRTV4cUmp4= -github.com/xhit/go-str2duration/v2 v2.1.0 h1:lxklc02Drh6ynqX+DdPyp5pCKLUQpRT8bp8Ydu2Bstc= -github.com/xhit/go-str2duration/v2 v2.1.0/go.mod h1:ohY8p+0f07DiV6Em5LKB0s2YpLtXVyJfNt1+BlmyAsU= -github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2 h1:eY9dn8+vbi4tKz5Qo6v2eYzo7kUS51QINcR5jNpbZS8= -github.com/xo/terminfo v0.0.0-20210125001918-ca9a967f8778 h1:QldyIu/L63oPpyvQmHgvgickp1Yw510KJOqX7H24mg8= -github.com/xo/terminfo v0.0.0-20210125001918-ca9a967f8778/go.mod h1:2MuV+tbUrU1zIOPMxZ5EncGwgmMJsa+9ucAQZXxsObs= -github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77 h1:ESFSdwYZvkeru3RtdrYueztKhOBCSAAzS4Gf+k0tEow= -github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= -github.com/yagipy/maintidx v1.0.0 h1:h5NvIsCz+nRDapQ0exNv4aJ0yXSI0420omVANTv3GJM= -github.com/yagipy/maintidx v1.0.0/go.mod h1:0qNf/I/CCZXSMhsRsrEPDZ+DkekpKLXAJfsTACwgXLk= -github.com/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0 h1:6fRhSjgLCkTD3JnJxvaJ4Sj+TYblw757bqYgZaOq5ZY= -github.com/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0/go.mod h1:/LWChgwKmvncFJFHJ7Gvn9wZArjbV5/FppcK2fKk/tI= -github.com/yeya24/promlinter v0.2.0 h1:xFKDQ82orCU5jQujdaD8stOHiv8UN68BSdn2a8u8Y3o= -github.com/yeya24/promlinter v0.2.0/go.mod h1:u54lkmBOZrpEbQQ6gox2zWKKLKu2SGe+2KOiextY+IA= -github.com/yosssi/ace v0.0.5 h1:tUkIP/BLdKqrlrPwcmH0shwEEhTRHoGnc1wFIWmaBUA= -github.com/yosssi/ace v0.0.5/go.mod h1:ALfIzm2vT7t5ZE7uoIZqF3TQ7SAOyupFZnkrF5id+K0= -github.com/yudai/gojsondiff v1.0.0 h1:27cbfqXLVEJ1o8I6v3y9lg8Ydm53EKqHXAOMxEGlCOA= -github.com/yudai/gojsondiff v1.0.0/go.mod h1:AY32+k2cwILAkW1fbgxQ5mUmMiZFgLIV+FBNExI05xg= -github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82 h1:BHyfKlQyqbsFN5p3IfnEUduWvb9is428/nNb5L3U01M= -github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDfVJdfcVVdX+jpBxNmX4rDAzaS45IcYoM= -github.com/yudai/pp v2.0.1+incompatible h1:Q4//iY4pNF6yPLZIigmvcl7k/bPgrcTPIFIcmawg5bI= -github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc= -github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -github.com/yuin/goldmark v1.4.13 h1:fVcFKWvrslecOb/tg+Cc05dkeYx540o0FuFt3nUVDoE= -github.com/yusufpapurcu/wmi v1.2.2 h1:KBNDSne4vP5mbSWnJbO+51IMOXJB67QiYCSBrubbPRg= -github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= -github.com/zeebo/xxh3 v1.0.2 h1:xZmwmqxHZA8AI603jOQ0tMqmBr9lPeFwGg6d+xy9DC0= -github.com/zeebo/xxh3 v1.0.2/go.mod h1:5NWz9Sef7zIDm2JHfFlcQvNekmcEl9ekUZQQKCYaDcA= -gitlab.com/bosi/decorder v0.2.3 h1:gX4/RgK16ijY8V+BRQHAySfQAb354T7/xQpDB2n10P0= -gitlab.com/bosi/decorder v0.2.3/go.mod h1:9K1RB5+VPNQYtXtTDAzd2OEftsZb1oV0IrJrzChSdGE= -go.einride.tech/aip v0.66.0 h1:XfV+NQX6L7EOYK11yoHHFtndeaWh3KbD9/cN/6iWEt8= -go.einride.tech/aip v0.66.0/go.mod h1:qAhMsfT7plxBX+Oy7Huol6YUvZ0ZzdUz26yZsQwfl1M= -go.einride.tech/aip v0.67.1 h1:d/4TW92OxXBngkSOwWS2CH5rez869KpKMaN44mdxkFI= -go.einride.tech/aip v0.67.1/go.mod h1:ZGX4/zKw8dcgzdLsrvpOOGxfxI2QSk12SlP7d6c0/XI= -go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4= -go.etcd.io/bbolt v1.3.7/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw= -go.etcd.io/bbolt v1.3.8/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw= -go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738 h1:VcrIfasaLFkyjk6KNlXQSzO+B0fZcnECiDrKJsfxka0= -go.etcd.io/etcd/api/v3 v3.5.10 h1:szRajuUUbLyppkhs9K6BRtjY37l66XQQmw7oZRANE4k= -go.etcd.io/etcd/api/v3 v3.5.10/go.mod h1:TidfmT4Uycad3NM/o25fG3J07odo4GBB9hoxaodFCtI= -go.etcd.io/etcd/api/v3 v3.5.12 h1:W4sw5ZoU2Juc9gBWuLk5U6fHfNVyY1WC5g9uiXZio/c= -go.etcd.io/etcd/api/v3 v3.5.12/go.mod h1:Ot+o0SWSyT6uHhA56al1oCED0JImsRiU9Dc26+C2a+4= -go.etcd.io/etcd/client/pkg/v3 v3.5.10 h1:kfYIdQftBnbAq8pUWFXfpuuxFSKzlmM5cSn76JByiT0= -go.etcd.io/etcd/client/pkg/v3 v3.5.10/go.mod h1:DYivfIviIuQ8+/lCq4vcxuseg2P2XbHygkKwFo9fc8U= -go.etcd.io/etcd/client/pkg/v3 v3.5.12 h1:EYDL6pWwyOsylrQyLp2w+HkQ46ATiOvoEdMarindU2A= -go.etcd.io/etcd/client/pkg/v3 v3.5.12/go.mod h1:seTzl2d9APP8R5Y2hFL3NVlD6qC/dOT+3kvrqPyTas4= -go.etcd.io/etcd/client/v2 v2.305.10 h1:MrmRktzv/XF8CvtQt+P6wLUlURaNpSDJHFZhe//2QE4= -go.etcd.io/etcd/client/v2 v2.305.10/go.mod h1:m3CKZi69HzilhVqtPDcjhSGp+kA1OmbNn0qamH80xjA= -go.etcd.io/etcd/client/v2 v2.305.12 h1:0m4ovXYo1CHaA/Mp3X/Fak5sRNIWf01wk/X1/G3sGKI= -go.etcd.io/etcd/client/v2 v2.305.12/go.mod h1:aQ/yhsxMu+Oht1FOupSr60oBvcS9cKXHrzBpDsPTf9E= -go.etcd.io/etcd/client/v3 v3.5.10 h1:W9TXNZ+oB3MCd/8UjxHTWK5J9Nquw9fQBLJd5ne5/Ao= -go.etcd.io/etcd/client/v3 v3.5.10/go.mod h1:RVeBnDz2PUEZqTpgqwAtUd8nAPf5kjyFyND7P1VkOKc= -go.etcd.io/etcd/client/v3 v3.5.12 h1:v5lCPXn1pf1Uu3M4laUE2hp/geOTc5uPcYYsNe1lDxg= -go.etcd.io/etcd/client/v3 v3.5.12/go.mod h1:tSbBCakoWmmddL+BKVAJHa9km+O/E+bumDe9mSbPiqw= -go.etcd.io/gofail v0.1.0 h1:XItAMIhOojXFQMgrxjnd2EIIHun/d5qL0Pf7FzVTkFg= -go.etcd.io/gofail v0.1.0/go.mod h1:VZBCXYGZhHAinaBiiqYvuDynvahNsAyLFwB3kEHKz1M= -go.mozilla.org/pkcs7 v0.0.0-20200128120323-432b2356ecb1 h1:A/5uWzF44DlIgdm/PQFwfMkW0JX+cIcQi/SwLAmZP5M= -go.mozilla.org/pkcs7 v0.0.0-20200128120323-432b2356ecb1/go.mod h1:SNgMg+EgDFwmvSmLRTNKC5fegJjB7v23qTQ0XLGUNHk= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.36.3/go.mod h1:Dts42MGkzZne2yCru741+bFiTMWkIj/LLRizad7b9tw= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.46.1/go.mod h1:4UoMYEZOC0yN/sPGH76KPkkU7zgiEWYWL9vwmbnTJPE= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0/go.mod h1:r9vWsPS/3AQItv3OSlEJ/E4mbrhUbbw18meOjArPtKQ= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.48.0/go.mod h1:tIKj3DbO8N9Y2xo52og3irLsPI4GW02DSMtrVgNMgxg= -go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.29.0 h1:Wjp9vsVSIEyvdiaECfqxY9xBqQ7JaSCGtvHgR4doXZk= -go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.29.0/go.mod h1:vHItvsnJtp7ES++nFLLFBzUWny7fJQSvTlxFcqQGUr4= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.46.1/go.mod h1:sEGXWArGqc3tVa+ekntsN65DmVbVeW+7lTKTjZF3/Fo= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.47.0/go.mod h1:SK2UL73Zy1quvRPonmOmRDiWk1KBV3LyIeeIxcEApWw= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.48.0/go.mod h1:rdENBZMT2OE6Ne/KLwpiXudnAsbdrdBaqBvTN8M8BgA= -go.opentelemetry.io/otel v1.11.0/go.mod h1:H2KtuEphyMvlhZ+F7tg9GRhAOe60moNx61Ex+WmiKkk= -go.opentelemetry.io/otel v1.14.0/go.mod h1:o4buv+dJzx8rohcUeRmWUZhqupFvzWis188WlggnNeU= -go.opentelemetry.io/otel v1.21.0/go.mod h1:QZzNPQPm1zLX4gZK4cMi+71eaorMSGT3A4znnUvNNEo= -go.opentelemetry.io/otel v1.22.0/go.mod h1:eoV4iAi3Ea8LkAEI9+GFT44O6T/D0GWAVFyZVCC6pMI= -go.opentelemetry.io/otel v1.23.0/go.mod h1:YCycw9ZeKhcJFrb34iVSkyT0iczq/zYDtZYFufObyB0= -go.opentelemetry.io/otel/exporters/jaeger v1.4.1 h1:VHCK+2yTZDqDaVXj7JH2Z/khptuydo6C0ttBh2bxAbc= -go.opentelemetry.io/otel/exporters/jaeger v1.4.1/go.mod h1:ZW7vkOu9nC1CxsD8bHNHCia5JUbwP39vxgd1q4Z5rCI= -go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.4.1 h1:imIM3vRDMyZK1ypQlQlO+brE22I9lRhJsBDXpDWjlz8= -go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.4.1/go.mod h1:VpP4/RMn8bv8gNo9uK7/IMY4mtWLELsS+JIP0inH0h4= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.4.1 h1:WPpPsAAs8I2rA47v5u0558meKmmwm1Dj99ZbqCV8sZ8= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.4.1/go.mod h1:o5RW5o2pKpJLD5dNTCmjF1DorYwMeFJmb/rKr5sLaa8= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.4.1 h1:AxqDiGk8CorEXStMDZF5Hz9vo9Z7ZZ+I5m8JRl/ko40= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.4.1/go.mod h1:c6E4V3/U+miqjs/8l950wggHGL1qzlp0Ypj9xoGrPqo= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.4.1 h1:8qOago/OqoFclMUUj/184tZyRdDZFpcejSjbk5Jrl6Y= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.4.1/go.mod h1:VwYo0Hak6Efuy0TXsZs8o1hnV3dHDPNtDbycG0hI8+M= -go.opentelemetry.io/otel/internal/metric v0.27.0 h1:9dAVGAfFiiEq5NVB9FUJ5et+btbDQAUIJehJ+ikyryk= -go.opentelemetry.io/otel/internal/metric v0.27.0/go.mod h1:n1CVxRqKqYZtqyTh9U/onvKapPGv7y/rpyOTI+LFNzw= -go.opentelemetry.io/otel/metric v1.21.0/go.mod h1:o1p3CA8nNHW8j5yuQLdc1eeqEaPfzug24uvsyIEJRWM= -go.opentelemetry.io/otel/metric v1.22.0/go.mod h1:evJGjVpZv0mQ5QBRJoBF64yMuOf4xCWdXjK8pzFvliY= -go.opentelemetry.io/otel/metric v1.23.0/go.mod h1:MqUW2X2a6Q8RN96E2/nqNoT+z9BSms20Jb7Bbp+HiTo= -go.opentelemetry.io/otel/sdk v1.14.0/go.mod h1:bwIC5TjrNG6QDCHNWvW4HLHtUQ4I+VQDsnjhvyZCALM= -go.opentelemetry.io/otel/sdk v1.21.0/go.mod h1:Nna6Yv7PWTdgJHVRD9hIYywQBRx7pbox6nwBnZIxl/E= -go.opentelemetry.io/otel/trace v1.11.0/go.mod h1:nyYjis9jy0gytE9LXGU+/m1sHTKbRY0fX0hulNNDP1U= -go.opentelemetry.io/otel/trace v1.14.0/go.mod h1:8avnQLK+CG77yNLUae4ea2JDQ6iT+gozhnZjy/rw9G8= -go.opentelemetry.io/otel/trace v1.21.0/go.mod h1:LGbsEB0f9LGjN+OZaQQ26sohbOmiMR+BaslueVtS/qQ= -go.opentelemetry.io/otel/trace v1.22.0/go.mod h1:RbbHXVqKES9QhzZq/fE5UnOSILqRt40a21sPw2He1xo= -go.opentelemetry.io/otel/trace v1.23.0/go.mod h1:GSGTbIClEsuZrGIzoEHqsVfxgn5UkggkflQwDScNUsk= -go.opentelemetry.io/proto/otlp v0.7.0 h1:rwOQPCuKAKmwGKq2aVNnYIibI6wnV7EvzgfTCzcdGg8= -go.opentelemetry.io/proto/otlp v1.0.0 h1:T0TX0tmXU8a3CbNXzEKGeU5mIVOdf0oykP+u2lIVU/I= -go.opentelemetry.io/proto/otlp v1.0.0/go.mod h1:Sy6pihPLfYHkr3NkUbEhGHFhINUSI/v80hjKIs5JXpM= -go.uber.org/atomic v1.9.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= -go.uber.org/atomic v1.10.0 h1:9qC72Qh0+3MqyJbAn8YU5xVq1frD8bn3JtD2oXtafVQ= -go.uber.org/atomic v1.10.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= -go.uber.org/goleak v1.1.10 h1:z+mqJhf6ss6BSfSM671tgKyZBFPTTJM+HLxnhPC3wu0= -go.uber.org/goleak v1.1.11/go.mod h1:cwTWslyiVhfpKIDGSZEM2HlOvcqm+tG4zioyIeLoqMQ= -go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= -go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= -go.uber.org/multierr v1.8.0/go.mod h1:7EAYxJLBy9rStEaz58O2t4Uvip6FSURkq8/ppBp95ak= -go.uber.org/multierr v1.9.0/go.mod h1:X2jQV1h+kxSjClGpnseKVIxpmcjrj7MNnI0bnlfKTVQ= -go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee h1:0mgffUl7nfd+FpvXMVz4IDEaUSmT1ysygQC7qYo7sG4= -go.uber.org/zap v1.21.0/go.mod h1:wjWOCqI0f2ZZrJF/UufIOkiC8ii6tm1iqIsLo76RfJw= -go.uber.org/zap v1.22.0/go.mod h1:H4siCOZOrAolnUPJEkfaSjDqyP+BDS0DdDWzwcgt3+U= -go.uber.org/zap v1.23.0 h1:OjGQ5KQDEUawVHxNwQgPpiypGHOxo2mNZsOqTak4fFY= -go.uber.org/zap v1.23.0/go.mod h1:D+nX8jyLsMHMYrln8A0rJjFt/T/9/bGgIhAqxv5URuY= -go.uber.org/zap v1.24.0 h1:FiJd5l1UOLj0wCgbSE0rwwXHzEdAZS6hiiSnxJN/D60= -go.uber.org/zap v1.24.0/go.mod h1:2kMP+WWQ8aoFoedH3T2sq6iJ2yDWpHbP0f6MQbS9Gkg= -golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= -golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY= -golang.org/x/crypto v0.0.0-20191227163750-53104e6ec876/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= -golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= -golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.0.0-20220321153916-2c7772ba3064/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.1.0/go.mod h1:RecgLatLF4+eUMCP1PoPZQb+cVrJcOPbHkTkbkB9sbw= -golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4= -golang.org/x/crypto v0.4.0/go.mod h1:3quD/ATkf6oY+rnes5c3ExXTbLc8mueNue5/DoinL80= -golang.org/x/crypto v0.12.0/go.mod h1:NF0Gs7EO5K4qLn+Ylc+fih8BSTeIjAP05siRnAh98yw= -golang.org/x/crypto v0.16.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= -golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= -golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDfU= -golang.org/x/crypto v0.21.0/go.mod h1:0BP7YvVV9gBbVKyeTG0Gyn+gZm94bibOW5BjDEYAOMs= -golang.org/x/crypto v0.22.0/go.mod h1:vr6Su+7cTlO45qkww3VDJlzDn0ctJvRgYbC2NvXHt+M= -golang.org/x/crypto v0.23.0/go.mod h1:CKFgDieR+mRhux2Lsu27y0fO304Db0wZe70UKqHu0v8= -golang.org/x/crypto v0.24.0/go.mod h1:Z1PMYSOR5nyMcyAVAIQSKCDwalqy85Aqn1x3Ws4L5DM= -golang.org/x/crypto v0.25.0/go.mod h1:T+wALwcMOSE0kXgUAnPAHqTLW+XHgcELELW8VaDgm/M= -golang.org/x/crypto v0.26.0/go.mod h1:GY7jblb9wI+FOo5y8/S2oY4zWP07AkOJ4+jxCqdqn54= -golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb h1:xIApU0ow1zwMa2uL1VDNeQlNVFTWMQxZUZCMDy0Q4Us= -golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc= -golang.org/x/exp/typeparams v0.0.0-20220428152302-39d4317da171/go.mod h1:AbB0pIl9nAr9wVwH+Z2ZpaocVmF5I4GyWCDIsVjR0bk= -golang.org/x/exp/typeparams v0.0.0-20220827204233-334a2380cb91 h1:Ic/qN6TEifvObMGQy72k0n1LlJr7DjWWEi+MOsDOiSk= -golang.org/x/exp/typeparams v0.0.0-20220827204233-334a2380cb91/go.mod h1:AbB0pIl9nAr9wVwH+Z2ZpaocVmF5I4GyWCDIsVjR0bk= -golang.org/x/exp/typeparams v0.0.0-20230203172020-98cc5a0785f9/go.mod h1:AbB0pIl9nAr9wVwH+Z2ZpaocVmF5I4GyWCDIsVjR0bk= -golang.org/x/exp/typeparams v0.0.0-20230307190834-24139beb5833 h1:jWGQJV4niP+CCmFW9ekjA9Zx8vYORzOUH2/Nl5WPuLQ= -golang.org/x/exp/typeparams v0.0.0-20230307190834-24139beb5833/go.mod h1:AbB0pIl9nAr9wVwH+Z2ZpaocVmF5I4GyWCDIsVjR0bk= -golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs= -golang.org/x/image v0.0.0-20190802002840-cff245a6509b h1:+qEpEAPhDZ1o0x3tHzZTQDArnOixOzGD9HUJfcg0mb4= -golang.org/x/image v0.0.0-20190910094157-69e4b8554b2a/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= -golang.org/x/image v0.0.0-20200119044424-58c23975cae1/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= -golang.org/x/image v0.0.0-20200430140353-33d19683fad8/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= -golang.org/x/image v0.0.0-20200618115811-c13761719519/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= -golang.org/x/image v0.0.0-20201208152932-35266b937fa6/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= -golang.org/x/image v0.0.0-20210216034530-4410531fe030/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= -golang.org/x/image v0.0.0-20210607152325-775e3b0c77b9/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM= -golang.org/x/image v0.0.0-20210628002857-a66eb6448b8d h1:RNPAfi2nHY7C2srAV8A49jpsYr0ADedCk1wq6fTMTvs= -golang.org/x/image v0.0.0-20210628002857-a66eb6448b8d/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM= -golang.org/x/image v0.0.0-20211028202545-6944b10bf410/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM= -golang.org/x/image v0.0.0-20220302094943-723b81ca9867 h1:TcHcE0vrmgzNH1v3ppjcMGbhG5+9fMuvOmUYwNEF4q4= -golang.org/x/image v0.0.0-20220302094943-723b81ca9867/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM= -golang.org/x/lint v0.0.0-20210508222113-6edffad5e616 h1:VLliZ0d+/avPrXXH+OakdXhpJuEoBZuwh1m2j7U6Iug= -golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028 h1:4+4C/Iv2U4fMZBiMCc98MG1In4gJY5YRhtpDNeDeHWs= -golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= -golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= -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/mod v0.9.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.11.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.20.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= -golang.org/x/net v0.0.0-20190327091125-710a502c58a2/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= -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-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8= -golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -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-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -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.4.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.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= -golang.org/x/net v0.9.0/go.mod h1:d48xBJpPfHeWQsugry2m+kC02ZBRGRgulfHnEXEuWns= -golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= -golang.org/x/net v0.18.0/go.mod h1:/czyP5RqHAH4odGYxBJ1qz0+CE5WZ+2j1YgoEo8F2jQ= -golang.org/x/net v0.19.0/go.mod h1:CfAk/cbD4CthTvqiEl8NpboMuiuOYsAr/7NOjZJtv1U= -golang.org/x/net v0.20.0/go.mod h1:z8BVo6PvndSri0LbOE3hAn0apkU+1YvI6E70E9jsnvY= -golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44= -golang.org/x/net v0.22.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg= -golang.org/x/net v0.23.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg= -golang.org/x/net v0.24.0/go.mod h1:2Q7sJY5mzlzWjKtYUEXSlBWCdyaioyXzRB2RtU8KVE8= -golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM= -golang.org/x/net v0.26.0/go.mod h1:5YKkiSynbBIh3p6iOc/vibscux0x38BZDkn8sCUPxHE= -golang.org/x/net v0.27.0/go.mod h1:dDi0PyhWNoiUOrAS8uXv/vnScO4wnHQO4mj9fn/RytE= -golang.org/x/oauth2 v0.0.0-20170207211851-4464e7848382/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= -golang.org/x/oauth2 v0.5.0/go.mod h1:9/XBHVqLaWO3/BRHs5jbpYCnOZVjj5V0ndyaAM7KB4I= -golang.org/x/oauth2 v0.8.0/go.mod h1:yr7u4HXZRm1R1kBWqr/xKNqewf0plRYoB7sla+BCIXE= -golang.org/x/oauth2 v0.15.0/go.mod h1:q48ptWNTY5XWf+JNten23lcvHpLJ0ZSxF5ttTHKVCAM= -golang.org/x/oauth2 v0.16.0/go.mod h1:hqZ+0LWXsiVoZpeld6jVt06P3adbS2Uu911W1SsJv2o= -golang.org/x/oauth2 v0.17.0/go.mod h1:OzPDGQiuQMguemayvdylqddI7qcD9lnSDb+1FiwQ5HA= -golang.org/x/oauth2 v0.18.0/go.mod h1:Wf7knwG0MPoWIMMBgFlEaSUDaKskp0dCfrlJRJXbBi8= -golang.org/x/oauth2 v0.19.0/go.mod h1:vYi7skDa1x015PmRRYZ7+s1cWyPgrPiSYRe4rnsexc8= -golang.org/x/oauth2 v0.20.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= -golang.org/x/perf v0.0.0-20230113213139-801c7ef9e5c5 h1:ObuXPmIgI4ZMyQLIz48cJYgSyWdjUXc2SZAdyJMwEAU= -golang.org/x/perf v0.0.0-20230113213139-801c7ef9e5c5/go.mod h1:UBKtEnL8aqnd+0JHqZ+2qoMDwtuy6cYhhKNoHLBiTQc= -golang.org/x/sync v0.0.0-20220819030929-7fc1605a5dde/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= -golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= -golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= -golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= -golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/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-20190606203320-7fc4e5ec1444/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-20190922100055-0a153f010e69/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191115151921-52ab43148777/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200217220822-9197077df867/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200728102440-3e129f6d46b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210304124612-50617c2ba197/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210616045830-e2b7044e8c71/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210906170528-6f6e22806c34/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210909193231-528a39cd75f3/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-20211103235746-7861aae1554b/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211105183446-c75c47738b0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211116061358-0a5406a5449c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220325203850-36772127a21f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220702020025-31831981b65f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/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.7.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.9.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/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.16.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.17.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.19.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.22.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.23.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.24.0 h1:Twjiwq9dn6R1fQcyiK+wQyHWfaz/BJB+YIpzU/Cv3Xg= -golang.org/x/sys v0.24.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/telemetry v0.0.0-20240228155512-f48c80bd79b2 h1:IRJeR9r1pYWsHKTRe/IInb7lYvbBVIqOgsX/u0mbOWY= -golang.org/x/telemetry v0.0.0-20240228155512-f48c80bd79b2/go.mod h1:TeRTkGYfJXctD9OcfyVLyj2J3IxLnKwHJR8f4D8a3YE= -golang.org/x/telemetry v0.0.0-20240521205824-bda55230c457 h1:zf5N6UOrA487eEFacMePxjXAJctxKmyjKUsjA11Uzuk= -golang.org/x/telemetry v0.0.0-20240521205824-bda55230c457/go.mod h1:pRgIJT+bRLFKnoM1ldnzKoxTIn14Yxz928LQRYYgIN0= -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/term v0.18.0/go.mod h1:ILwASektA3OnRv7amZ1xhE/KTR+u50pbXfZ03+6Nx58= -golang.org/x/term v0.22.0/go.mod h1:F3qCibpT5AMpCRfhfT53vVJwhLtIVHhB9XDjfFvnMI4= -golang.org/x/term v0.23.0/go.mod h1:DgV24QBUrK6jhZXl+20l6UWznPlwAHm1Q1mGHtydmSk= -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/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= -golang.org/x/text v0.12.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= -golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= -golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= -golang.org/x/text v0.15.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= -golang.org/x/text v0.16.0/go.mod h1:GhwF1Be+LQoKShO3cGOHzqOgRrGaYc9AvblQOmPVHnI= -golang.org/x/text v0.17.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY= -golang.org/x/time v0.0.0-20201208040808-7e3f01d25324/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/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-20190206041539-40960b6deb8e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190307163923-6a08e3108db3/go.mod h1:25r3+/G6/xytQM8iWZKq3Hn0kr0rgFKPUNVEL/dr3z4= -golang.org/x/tools v0.0.0-20190311215038-5c2858a9cfe5/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190321232350-e250d351ecad/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190322203728-c1a832b0ad89/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190327201419-c70d86f8b7cf/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190907020128-2ca718005c18/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20190910044552-dd2b5c81c578/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20190916130336-e45ffcd953cc/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20190927191325-030b2cf1153e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20200117220505-0cba7a3a9ee9/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200324003944-a576cf524670/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8= -golang.org/x/tools v0.0.0-20200329025819-fd4102a86c65/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8= -golang.org/x/tools v0.0.0-20200414032229-332987a829c3/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200622203043-20e05c1c8ffa/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200624225443-88f3c62a19ff/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200625211823-6506e20df31f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200724022722-7017fd6b1305/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= -golang.org/x/tools v0.0.0-20200812195022-5ae4c3c160a0/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= -golang.org/x/tools v0.0.0-20200820010801-b793a1359eac/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= -golang.org/x/tools v0.0.0-20200831203904-5a2aa26beb65/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE= -golang.org/x/tools v0.0.0-20201001104356-43ebab892c4c/go.mod h1:z6u4i615ZeAfBE4XtMziQW1fSVJXACjjbWkB/mvPzlU= -golang.org/x/tools v0.0.0-20201002184944-ecd9fd270d5d/go.mod h1:z6u4i615ZeAfBE4XtMziQW1fSVJXACjjbWkB/mvPzlU= -golang.org/x/tools v0.0.0-20201023174141-c8cfbd0f21e6/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20201230224404-63754364767c/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.1.1-0.20210205202024-ef80cdb6ec6d/go.mod h1:9bzcO0MWcOuT0tm1iBGzDVPshzfwoVvREIui8C+MHqU= -golang.org/x/tools v0.1.1-0.20210302220138-2ac05c832e1a/go.mod h1:9bzcO0MWcOuT0tm1iBGzDVPshzfwoVvREIui8C+MHqU= -golang.org/x/tools v0.1.9-0.20211228192929-ee1ca4ffc4da/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= -golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= -golang.org/x/tools v0.1.10/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= -golang.org/x/tools v0.1.11/go.mod h1:SgwaegtQh8clINPpECJMqnxLv9I09HLqnW3RMqW0CA4= -golang.org/x/tools v0.2.0/go.mod h1:y4OqIKeOV/fWJetJ8bXPU1sEVniLMIyDAZWeHdV+NTA= -golang.org/x/tools v0.3.0/go.mod h1:/rWhSS2+zyEVwoJf8YAX6L2f0ntZ7Kn/mGgAWcipA5k= -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.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58= -golang.org/x/tools v0.21.0/go.mod h1:aiJjzUbINMkxbQROHiO6hDPo2LHcIPhhQsa9DLh0yGk= -golang.org/x/tools v0.24.0/go.mod h1:YhNqVBIfWHdzvTLs0d8LCuMhkKUgSUKldakyV7W/WDQ= -gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= -gonum.org/v1/gonum v0.8.2 h1:CCXrcPKiGGotvnN6jfUsKk4rRqm7q09/YbKb5xCEvtM= -gonum.org/v1/gonum v0.8.2/go.mod h1:oe/vMfY3deqTw+1EZJhuvEW2iwGF1bW9wwu7XCu0+v0= -gonum.org/v1/gonum v0.9.3 h1:DnoIG+QAMaF5NvxnGe/oKsgKcAc6PcUyl8q0VetfQ8s= -gonum.org/v1/gonum v0.9.3/go.mod h1:TZumC3NeyVQskjXqmyWt4S3bINhy7B4eYwW69EbyX+0= -gonum.org/v1/gonum v0.11.0/go.mod h1:fSG4YDCxxUZQJ7rKsQrj0gMOg00Il0Z96/qMA4bVQhA= -gonum.org/v1/gonum v0.12.0 h1:xKuo6hzt+gMav00meVPUlXwSdoEJP46BR+wdxQEFK2o= -gonum.org/v1/gonum v0.12.0/go.mod h1:73TDxJfAAHeA8Mk9mf8NlIppyhQNo5GLTcYeqgo2lvY= -gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0 h1:OE9mWmgKkjJyEmDAAtGMPjXu+YNeGvK9VTSHY6+Qihc= -gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw= -gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b/go.mod h1:Wt8AAjI+ypCyYX3nZBvf6cAIx93T+c/OS2HFAYskSZc= -gonum.org/v1/plot v0.9.0/go.mod h1:3Pcqqmp6RHvJI72kgb8fThyUnav364FOsdDo2aGW5lY= -gonum.org/v1/plot v0.10.0 h1:ymLukg4XJlQnYUJCp+coQq5M7BsUJFk6XQE4HPflwdw= -gonum.org/v1/plot v0.10.0/go.mod h1:JWIHJ7U20drSQb/aDpTetJzfC1KlAPldJLpkSy88dvQ= -gonum.org/v1/plot v0.10.1 h1:dnifSs43YJuNMDzB7v8wV64O4ABBHReuAVAoBxqBqS4= -gonum.org/v1/plot v0.10.1/go.mod h1:VZW5OlhkL1mysU9vaqNHnsy86inf6Ot+jB3r+BczCEo= -google.golang.org/api v0.0.0-20170206182103-3d017632ea10/go.mod h1:4mhQ8q/RsB7i+udVvVy5NUi08OU8ZlA0gRVgrF7VFY0= -google.golang.org/api v0.152.0/go.mod h1:3qNJX5eOmhiWYc67jRA/3GsDw97UFb5ivv7Y2PrriAY= -google.golang.org/api v0.153.0/go.mod h1:3qNJX5eOmhiWYc67jRA/3GsDw97UFb5ivv7Y2PrriAY= -google.golang.org/api v0.155.0/go.mod h1:GI5qK5f40kCpHfPn6+YzGAByIKWv8ujFnmoWm7Igduk= -google.golang.org/api v0.160.0/go.mod h1:0mu0TpK33qnydLvWqbImq2b1eQ5FHRSDCBzAxX9ZHyw= -google.golang.org/api v0.162.0/go.mod h1:6SulDkfoBIg4NFmCuZ39XeeAgSHCPecfSUuDyYlAHs0= -google.golang.org/api v0.164.0/go.mod h1:2OatzO7ZDQsoS7IFf3rvsE17/TldiU3F/zxFHeqUB5o= -google.golang.org/api v0.166.0/go.mod h1:4FcBc686KFi7QI/U51/2GKKevfZMpM17sCdibqe/bSA= -google.golang.org/api v0.171.0/go.mod h1:Hnq5AHm4OTMt2BUVjael2CWZFD6vksJdWCWiUAmjC9o= -google.golang.org/api v0.178.0/go.mod h1:84/k2v8DFpDRebpGcooklv/lais3MEfqpaBLA12gl2U= -google.golang.org/api v0.183.0/go.mod h1:q43adC5/pHoSZTx5h2mSmdF7NcyfW9JuDyIOJAgS9ZQ= -google.golang.org/api v0.184.0/go.mod h1:CeDTtUEiYENAf8PPG5VZW2yNp2VM3VWbCeTioAZBTBA= -google.golang.org/appengine v1.6.8 h1:IhEN5q69dyKagZPYMSdIjS2HqprW324FRQZJcGqPAsM= -google.golang.org/appengine v1.6.8/go.mod h1:1jJ3jBArFh5pcgW8gCtRJnepW8FzD1V44FJffLiz/Ds= -google.golang.org/genproto v0.0.0-20180518175338-11a468237815/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= -google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20230202175211-008b39050e57/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= -google.golang.org/genproto v0.0.0-20230227214838-9b19f0bdc514/go.mod h1:TvhZT5f700eVlTNwND1xoEZQeWTB2RY/65kplwl/bFA= -google.golang.org/genproto v0.0.0-20230306155012-7f2fa6fef1f4/go.mod h1:NWraEVixdDnqcqQ30jipen1STv2r/n24Wb7twVTGR4s= -google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97/go.mod h1:t1VqOqqvce95G3hIDCT5FeO3YUc6Q4Oe24L/+rNMxRk= -google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:J7XzRzVy1+IPwWHZUzoD0IccYZIrXILAQpc+Qy9CMhY= -google.golang.org/genproto v0.0.0-20240116215550-a9fa1716bcac/go.mod h1:+Rvu7ElI+aLzyDQhpHMFMMltsD6m7nqpuWDd2CwJw3k= -google.golang.org/genproto v0.0.0-20240123012728-ef4313101c80/go.mod h1:cc8bqMqtv9gMOr0zHg2Vzff5ULhhL2IXP4sbcn32Dro= -google.golang.org/genproto v0.0.0-20240125205218-1f4bbc51befe/go.mod h1:cc8bqMqtv9gMOr0zHg2Vzff5ULhhL2IXP4sbcn32Dro= -google.golang.org/genproto v0.0.0-20240205150955-31a09d347014/go.mod h1:xEgQu1e4stdSSsxPDK8Azkrk/ECl5HvdPf6nbZrTS5M= -google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9/go.mod h1:mqHbVIp48Muh7Ywss/AD6I5kNVKZMmAa/QEW58Gxp2s= -google.golang.org/genproto v0.0.0-20240401170217-c3f982113cda/go.mod h1:g2LLCvCeCSir/JJSWosk19BR4NVxGqHUC6rxIRsd7Aw= -google.golang.org/genproto v0.0.0-20240528184218-531527333157/go.mod h1:ubQlAQnzejB8uZzszhrTCU2Fyp6Vi7ZE5nn0c3W8+qQ= -google.golang.org/genproto v0.0.0-20240617180043-68d350f18fd4/go.mod h1:EvuUDCulqGgV80RvP1BHuom+smhX4qtlhnNatHuroGQ= -google.golang.org/genproto/googleapis/api v0.0.0-20230920204549-e6e6cdab5c13/go.mod h1:RdyHbowztCGQySiCvQPgWQWgWhGnouTdCflKoDBt32U= -google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:0xJLfVdJqpAPl8tDg1ujOCGzx6LFLttXT5NhllGOXY4= -google.golang.org/genproto/googleapis/api v0.0.0-20240123012728-ef4313101c80/go.mod h1:4jWUdICTdgc3Ibxmr8nAJiiLHwQBY0UI0XZcEMaFKaA= -google.golang.org/genproto/googleapis/api v0.0.0-20240125205218-1f4bbc51befe/go.mod h1:4jWUdICTdgc3Ibxmr8nAJiiLHwQBY0UI0XZcEMaFKaA= -google.golang.org/genproto/googleapis/api v0.0.0-20240205150955-31a09d347014/go.mod h1:rbHMSEDyoYX62nRVLOCc4Qt1HbsdytAYoVwgjiOhF3I= -google.golang.org/genproto/googleapis/api v0.0.0-20240213162025-012b6fc9bca9/go.mod h1:PVreiBMirk8ypES6aw9d4p6iiBNSIfZEBqr3UGoAi2E= -google.golang.org/genproto/googleapis/api v0.0.0-20240221002015-b0ce06bbee7c/go.mod h1:5iCWqnniDlqZHrd3neWVTOwvh/v6s3232omMecelax8= -google.golang.org/genproto/googleapis/api v0.0.0-20240311132316-a219d84964c2/go.mod h1:O1cOfN1Cy6QEYr7VxtjOyP5AdAuR0aJ/MYZaaof623Y= -google.golang.org/genproto/googleapis/api v0.0.0-20240318140521-94a12d6c2237/go.mod h1:Z5Iiy3jtmioajWHDGFk7CeugTyHtPvMHA4UTmUkyalE= -google.golang.org/genproto/googleapis/api v0.0.0-20240506185236-b8a5c65736ae/go.mod h1:FfiGhwUm6CJviekPrc0oJ+7h29e+DmWU6UtjX0ZvI7Y= -google.golang.org/genproto/googleapis/api v0.0.0-20240610135401-a8a62080eff3/go.mod h1:kdrSS/OiLkPrNUpzD4aHgCq2rVuC/YRxok32HXZ4vRE= -google.golang.org/genproto/googleapis/api v0.0.0-20240617180043-68d350f18fd4/go.mod h1:px9SlOOZBg1wM1zdnr8jEL4CNGUBZ+ZKYtNPApNQc4c= -google.golang.org/genproto/googleapis/bytestream v0.0.0-20240304161311-37d4d3c04a78 h1:YqFWYZXim8bG9v68xU8WjTZmYKb5M5dMeSOWIp6jogI= -google.golang.org/genproto/googleapis/bytestream v0.0.0-20240304161311-37d4d3c04a78/go.mod h1:vh/N7795ftP0AkN1w8XKqN4w1OdUKXW5Eummda+ofv8= -google.golang.org/genproto/googleapis/bytestream v0.0.0-20240617180043-68d350f18fd4 h1:Rie8vnNXn/RjOgFacUrolQKaHsN10UPAXBb3IkfDdE4= -google.golang.org/genproto/googleapis/bytestream v0.0.0-20240617180043-68d350f18fd4/go.mod h1:/oe3+SiHAwz6s+M25PyTygWm3lnrhmGqIuIfkoUocqk= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c/go.mod h1:4cYg8o5yUbm77w8ZX00LhMVNl/YVBFJRYWDc0uYWMs0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:oQ5rr10WTTMvP4A36n8JpR1OrO1BEiV4f78CneXZxkA= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231120223509-83a465c0220f/go.mod h1:L9KNLi232K1/xB6f7AlSX692koaRnKaWSR0stBki0Yc= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240116215550-a9fa1716bcac/go.mod h1:daQN87bsDqDoe316QbbvX60nMoJQa4r6Ds0ZuoAe5yA= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240123012728-ef4313101c80/go.mod h1:PAREbraiVEVGVdTZsVWjSbbTtSyGbAgIIvni8a8CD5s= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240125205218-1f4bbc51befe/go.mod h1:PAREbraiVEVGVdTZsVWjSbbTtSyGbAgIIvni8a8CD5s= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240205150955-31a09d347014/go.mod h1:SaPjaZGWb0lPqs6Ittu0spdfrOArqji4ZdeP5IC/9N4= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240213162025-012b6fc9bca9/go.mod h1:YUWgXUFRPfoYK1IHMuxH5K6nPEXSCzIMljnQ59lLRCk= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240221002015-b0ce06bbee7c/go.mod h1:H4O17MA/PE9BsGx3w+a+W2VOLLD1Qf7oJneAoU6WktY= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240304161311-37d4d3c04a78/go.mod h1:UCOku4NytXMJuLQE5VuqA5lX3PcHCBo8pxNyvkf4xBs= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240314234333-6e1732d8331c/go.mod h1:WtryC6hu0hhx87FDGxWCDptyssuo68sk10vYjF+T9fY= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240415180920-8c6c420018be/go.mod h1:WtryC6hu0hhx87FDGxWCDptyssuo68sk10vYjF+T9fY= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240429193739-8cf5692501f6/go.mod h1:WtryC6hu0hhx87FDGxWCDptyssuo68sk10vYjF+T9fY= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240521202816-d264139d666e/go.mod h1:EfXuqaE1J41VCDicxHzUDm+8rk+7ZdXzHV0IhO/I6s0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240528184218-531527333157/go.mod h1:EfXuqaE1J41VCDicxHzUDm+8rk+7ZdXzHV0IhO/I6s0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240610135401-a8a62080eff3/go.mod h1:EfXuqaE1J41VCDicxHzUDm+8rk+7ZdXzHV0IhO/I6s0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240617180043-68d350f18fd4/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240624140628-dc46fd24d27d/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY= -google.golang.org/grpc v0.0.0-20170208002647-2a6bf6142e96/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= -google.golang.org/grpc v1.12.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= -google.golang.org/grpc v1.53.0/go.mod h1:OnIrk0ipVdj4N5d9IUoFUx72/VlD7+jUsHwZgwSMQpw= -google.golang.org/grpc v1.55.0/go.mod h1:iYEXKGkEBhg1PjZQvoYEVPTDkHo1/bjTnfwTeGONTY8= -google.golang.org/grpc v1.58.3/go.mod h1:tgX3ZQDlNJGU96V6yHh1T/JeoBQ2TXdr43YbYSsCJk0= -google.golang.org/grpc v1.59.0/go.mod h1:aUPDwccQo6OTjy7Hct4AfBPD1GptF4fyUjIkQ9YtF98= -google.golang.org/grpc v1.60.0/go.mod h1:OlCHIeLYqSSsLi6i49B5QGdzaMZK9+M7LXN2FKz4eGM= -google.golang.org/grpc v1.61.0/go.mod h1:VUbo7IFqmF1QtCAstipjG0GIoq49KvMe9+h1jFLBNJs= -google.golang.org/grpc v1.61.1/go.mod h1:VUbo7IFqmF1QtCAstipjG0GIoq49KvMe9+h1jFLBNJs= -google.golang.org/grpc v1.62.0/go.mod h1:IWTG0VlJLCh1SkC58F7np9ka9mx/WNkjl4PGJaiq+QE= -google.golang.org/grpc v1.62.1/go.mod h1:IWTG0VlJLCh1SkC58F7np9ka9mx/WNkjl4PGJaiq+QE= -google.golang.org/grpc v1.63.2/go.mod h1:WAX/8DgncnokcFUldAxq7GeB5DXHDbMF+lLvDomNkRA= -google.golang.org/grpc v1.64.0/go.mod h1:oxjF8E3FBnjp+/gVFYdWacaLDx9na1aqy9oovLpxQYg= -google.golang.org/grpc v1.64.1/go.mod h1:hiQF4LFZelK2WKaP6W0L92zGHtiQdZxk8CrSdvyjeP0= -google.golang.org/grpc v1.66.0/go.mod h1:s3/l6xSSCURdVfAnL+TqCNMyTDAGN6+lZeVxnZR128Y= -google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0 h1:M1YKkFIboKNieVO5DLUEVzQfGwJD30Nv2jfUgzb5UcE= -google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.2.0 h1:TLkBREm4nIsEcexnCjgQd5GQWaHcqMzwQV0TX9pq8S0= -google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.2.0/go.mod h1:DNq5QpG7LJqD2AamLZ7zvKE0DEpVl2BSEVjFycAAjRY= -google.golang.org/protobuf v1.27.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.28.2-0.20230222093303-bc1253ad3743/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.29.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.32.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= -google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= -google.golang.org/protobuf v1.34.1/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= -gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc= -gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/cheggaaa/pb.v1 v1.0.27 h1:kJdccidYzt3CaHD1crCFTS1hxyhSi059NhOFUf03YFo= -gopkg.in/errgo.v2 v2.1.0 h1:0vLT13EuvQ0hNvakwLuFZ/jYrLp5F3kcWHXdRggjCE8= -gopkg.in/fsnotify.v1 v1.4.7 h1:xOHLXZwVvI9hhs+cLKq5+I5onOuwQLhQwiu63xxlHs4= -gopkg.in/gcfg.v1 v1.2.3 h1:m8OOJ4ccYHnx2f4gQwpno8nAX5OGOh7RLaaz0pj3Ogs= -gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= -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 h1:xcEWjVhvbDy+nHP67nPDDpbYrY+ILlfndk4bRioVHaU= -gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= -gopkg.in/resty.v1 v1.12.0 h1:CuXP0Pjfw9rOuY6EP+UvtNvt5DSqHpIxILZKT/quCZI= -gopkg.in/square/go-jose.v2 v2.5.1 h1:7odma5RETjNHWJnR32wx8t+Io4djHE1PqxCFx3iiZ2w= -gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI= -gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME= -gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= -gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= -gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= -gotest.tools/v3 v3.2.0/go.mod h1:Mcr9QNxkg0uMvy/YElmo4SpXgJKWgQvYrT7Kw5RzJ1A= -gotest.tools/v3 v3.4.0/go.mod h1:CtbdzLSsqVhDgMtKsx03ird5YTGB3ar27v0u/yKBW5g= -gotest.tools/v3 v3.5.0/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= -honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= -honnef.co/go/tools v0.3.3 h1:oDx7VAwstgpYpb3wv0oxiZlxY+foCpRAwY7Vk6XpAgA= -honnef.co/go/tools v0.3.3/go.mod h1:jzwdWgg7Jdq75wlfblQxO4neNaFFSvgc1tD5Wv8U0Yw= -honnef.co/go/tools v0.4.3 h1:o/n5/K5gXqk8Gozvs2cnL0F2S1/g1vcGCAx2vETjITw= -honnef.co/go/tools v0.4.3/go.mod h1:36ZgoUOrqOk1GxwHhyryEkq8FQWkUO2xGuSMhUCcdvA= -k8s.io/api v0.22.5 h1:xk7C+rMjF/EGELiD560jdmwzrB788mfcHiNbMQLIVI8= -k8s.io/api v0.22.5/go.mod h1:mEhXyLaSD1qTOf40rRiKXkc+2iCem09rWLlFwhCEiAs= -k8s.io/apimachinery v0.22.5 h1:cIPwldOYm1Slq9VLBRPtEYpyhjIm1C6aAMAoENuvN9s= -k8s.io/apimachinery v0.22.5/go.mod h1:xziclGKwuuJ2RM5/rSFQSYAj0zdbci3DH8kj+WvyN0U= -k8s.io/apiserver v0.22.5 h1:71krQxCUz218ecb+nPhfDsNB6QgP1/4EMvi1a2uYBlg= -k8s.io/apiserver v0.22.5/go.mod h1:s2WbtgZAkTKt679sYtSudEQrTGWUSQAPe6MupLnlmaQ= -k8s.io/client-go v0.22.5 h1:I8Zn/UqIdi2r02aZmhaJ1hqMxcpfJ3t5VqvHtctHYFo= -k8s.io/client-go v0.22.5/go.mod h1:cs6yf/61q2T1SdQL5Rdcjg9J1ElXSwbjSrW2vFImM4Y= -k8s.io/component-base v0.22.5 h1:U0eHqZm7mAFE42hFwYhY6ze/MmVaW00JpMrzVsQmzYE= -k8s.io/component-base v0.22.5/go.mod h1:VK3I+TjuF9eaa+Ln67dKxhGar5ynVbwnGrUiNF4MqCI= -k8s.io/cri-api v0.23.1 h1:0DHL/hpTf4Fp+QkUXFefWcp1fhjXr9OlNdY9X99c+O8= -k8s.io/cri-api v0.23.1/go.mod h1:REJE3PSU0h/LOV1APBrupxrEJqnoxZC8KWzkBUHwrK4= -k8s.io/klog/v2 v2.30.0 h1:bUO6drIvCIsvZ/XFgfxoGFQU/a4Qkh0iAlvUR7vlHJw= -k8s.io/klog/v2 v2.30.0/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= -k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b h1:wxEMGetGMur3J1xuGLQY7GEQYg9bZxKn3tKo5k/eYcs= -k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= -moul.io/http2curl/v2 v2.3.0 h1:9r3JfDzWPcbIklMOs2TnIFzDYvfAZvjeavG6EzP7jYs= -moul.io/http2curl/v2 v2.3.0/go.mod h1:RW4hyBjTWSYDOxapodpNEtX0g5Eb16sxklBqmd2RHcE= -mvdan.cc/gofumpt v0.4.0 h1:JVf4NN1mIpHogBj7ABpgOyZc65/UUOkKQFkoURsz4MM= -mvdan.cc/gofumpt v0.4.0/go.mod h1:PljLOHDeZqgS8opHRKLzp2It2VBuSdteAgqUfzMTxlQ= -mvdan.cc/interfacer v0.0.0-20180901003855-c20040233aed h1:WX1yoOaKQfddO/mLzdV4wptyWgoH/6hwLs7QHTixo0I= -mvdan.cc/interfacer v0.0.0-20180901003855-c20040233aed/go.mod h1:Xkxe497xwlCKkIaQYRfC7CSLworTXY9RMqwhhCm+8Nc= -mvdan.cc/lint v0.0.0-20170908181259-adc824a0674b h1:DxJ5nJdkhDlLok9K6qO+5290kphDJbHOQO1DFFFTeBo= -mvdan.cc/lint v0.0.0-20170908181259-adc824a0674b/go.mod h1:2odslEg/xrtNQqCYg2/jCoyKnw3vv5biOc3JnIcYfL4= -mvdan.cc/unparam v0.0.0-20220706161116-678bad134442 h1:seuXWbRB1qPrS3NQnHmFKLJLtskWyueeIzmLXghMGgk= -mvdan.cc/unparam v0.0.0-20220706161116-678bad134442/go.mod h1:F/Cxw/6mVrNKqrR2YjFf5CaW0Bw4RL8RfbEf4GRggJk= -mvdan.cc/unparam v0.0.0-20221223090309-7455f1af531d h1:3rvTIIM22r9pvXk+q3swxUQAQOxksVMGK7sml4nG57w= -mvdan.cc/unparam v0.0.0-20221223090309-7455f1af531d/go.mod h1:IeHQjmn6TOD+e4Z3RFiZMMsLVL+A96Nvptar8Fj71is= -rsc.io/binaryregexp v0.2.0 h1:HfqmD5MEmC0zvwBuF187nq9mdnXjXsSivRiXN7SmRkE= -rsc.io/pdf v0.1.1 h1:k1MczvYDUvJBe93bYd7wrZLLUEcLZAuF824/I4e5Xr4= -rsc.io/quote/v3 v3.1.0 h1:9JKUTTIUgS6kzR9mK1YuGKv6Nl+DijDNIc0ghT58FaY= -rsc.io/sampler v1.3.0 h1:7uVkIFmeBqHfdjD+gZwtXXI+RODJ2Wc4O7MPEh/QiW4= -sigs.k8s.io/structured-merge-diff/v4 v4.1.2 h1:Hr/htKFmJEbtMgS/UD0N+gtgctAqz81t3nu+sPzynno= -sigs.k8s.io/structured-merge-diff/v4 v4.1.2/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4= -sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8= -sourcegraph.com/sourcegraph/appdash v0.0.0-20190731080439-ebfcffb1b5c0 h1:ucqkfpjg9WzSUubAO62csmucvxl4/JeW3F4I4909XkM= diff --git a/ibc/module_test.go b/ibc/module_test.go index ec54c361..e196aabe 100644 --- a/ibc/module_test.go +++ b/ibc/module_test.go @@ -1,4 +1,4 @@ -package ibc +package ibc_test import ( "testing" @@ -13,6 +13,7 @@ import ( channeltypes "github.com/cosmos/ibc-go/v8/modules/core/04-channel/types" porttypes "github.com/cosmos/ibc-go/v8/modules/core/05-port/types" "github.com/cosmos/ibc-go/v8/modules/core/exported" + evmosibc "github.com/evmos/os/ibc" ) var _ porttypes.IBCModule = &MockIBCModule{} @@ -183,7 +184,7 @@ func TestModule(t *testing.T) { mockModule.On("OnAcknowledgementPacket").Return(nil) mockModule.On("OnTimeoutPacket").Return(nil) - module := NewModule(mockModule) + module := evmosibc.NewModule(mockModule) // mock calls for abstraction _, err := module.OnChanOpenInit(sdk.Context{}, channeltypes.ORDERED, nil, transfertypes.PortID, "channel-0", &capabilitytypes.Capability{}, channeltypes.Counterparty{}, "") diff --git a/ibc/testing/app.go b/ibc/testing/app.go index 7915d314..9bc2e61a 100644 --- a/ibc/testing/app.go +++ b/ibc/testing/app.go @@ -83,7 +83,7 @@ func SetupWithGenesisValSet(t *testing.T, valSet *cmttypes.ValidatorSet, genAccs // add bonded amount to bonded pool module account balances = append(balances, banktypes.Balance{ Address: authtypes.NewModuleAddress(stakingtypes.BondedPoolName).String(), - Coins: sdk.Coins{sdk.NewCoin(constants.ExampleAttoDenom, bondAmt)}, + Coins: sdk.Coins{sdk.NewCoin(stakingParams.BondDenom, bondAmt)}, }) // update total supply diff --git a/ibc/testing/chain.go b/ibc/testing/chain.go index 03a7e82b..aa6e51af 100644 --- a/ibc/testing/chain.go +++ b/ibc/testing/chain.go @@ -20,7 +20,7 @@ import ( "github.com/stretchr/testify/require" ) -// ChainIDPrefix defines the default chain ID prefix for Evmos test chains +// ChainIDPrefix defines the default chain ID prefix for evmOS test chains var ( ChainIDPrefix = constants.ExampleChainID ChainIDSuffix = "" diff --git a/ibc/utils_test.go b/ibc/utils_test.go index c0576bec..f4e9e284 100644 --- a/ibc/utils_test.go +++ b/ibc/utils_test.go @@ -1,4 +1,4 @@ -package ibc +package ibc_test import ( "testing" @@ -8,7 +8,9 @@ import ( transfertypes "github.com/cosmos/ibc-go/v8/modules/apps/transfer/types" channeltypes "github.com/cosmos/ibc-go/v8/modules/core/04-channel/types" ibctesting "github.com/cosmos/ibc-go/v8/testing" + evmosibc "github.com/evmos/os/ibc" precompilestestutil "github.com/evmos/os/precompiles/testutil" + testconstants "github.com/evmos/os/testutil/constants" "github.com/stretchr/testify/require" ) @@ -90,7 +92,7 @@ func TestGetTransferSenderRecipient(t *testing.T) { } for _, tc := range testCases { - sender, recipient, _, _, err := GetTransferSenderRecipient(tc.data) + sender, recipient, _, _, err := evmosibc.GetTransferSenderRecipient(tc.data) if tc.expError { require.Error(t, err, tc.name) } else { @@ -165,7 +167,7 @@ func TestGetTransferAmount(t *testing.T) { } for _, tc := range testCases { - amt, err := GetTransferAmount(tc.packet) + amt, err := evmosibc.GetTransferAmount(tc.packet) if tc.expError { require.Error(t, err, tc.name) } else { @@ -229,12 +231,14 @@ func TestGetReceivedCoin(t *testing.T) { } for _, tc := range testCases { - coin := GetReceivedCoin(tc.srcPort, tc.srcChannel, tc.dstPort, tc.dstChannel, tc.rawDenom, tc.rawAmount) + coin := evmosibc.GetReceivedCoin(tc.srcPort, tc.srcChannel, tc.dstPort, tc.dstChannel, tc.rawDenom, tc.rawAmount) require.Equal(t, tc.expCoin, coin) } } func TestGetSentCoin(t *testing.T) { + baseDenom := testconstants.ExampleAttoDenom + testCases := []struct { name string rawDenom string @@ -243,9 +247,9 @@ func TestGetSentCoin(t *testing.T) { }{ { "get unwrapped aevmos coin", - "aevmos", + baseDenom, "10", - sdk.Coin{Denom: "aevmos", Amount: math.NewInt(10)}, + sdk.Coin{Denom: baseDenom, Amount: math.NewInt(10)}, }, { "get ibc wrapped aevmos coin", @@ -274,7 +278,7 @@ func TestGetSentCoin(t *testing.T) { } for _, tc := range testCases { - coin := GetSentCoin(tc.rawDenom, tc.rawAmount) + coin := evmosibc.GetSentCoin(tc.rawDenom, tc.rawAmount) require.Equal(t, tc.expCoin, coin) } } @@ -318,7 +322,7 @@ func TestDeriveDecimalsFromDenom(t *testing.T) { } for _, tc := range testCases { - dec, err := DeriveDecimalsFromDenom(tc.baseDenom) + dec, err := evmosibc.DeriveDecimalsFromDenom(tc.baseDenom) if tc.expFail { require.Error(t, err, tc.expErrMsg) require.Contains(t, err.Error(), tc.expErrMsg) @@ -359,7 +363,7 @@ func TestIsBaseDenomFromSourceChain(t *testing.T) { for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - result := IsBaseDenomFromSourceChain(tt.denom) + result := evmosibc.IsBaseDenomFromSourceChain(tt.denom) require.Equal(t, tt.expected, result) }) } diff --git a/precompiles/bank/IBank.sol b/precompiles/bank/IBank.sol index 626775df..7c85d727 100644 --- a/precompiles/bank/IBank.sol +++ b/precompiles/bank/IBank.sol @@ -2,17 +2,17 @@ pragma solidity >=0.8.18; /// @dev The IBank contract's address. -address constant IBANK_PRECOMPILE_ADDRESS = 0x0000000000000000000000000000000000000804; +address constant IBANK_PRECOMPILE_ADDRESS = 0x0000000000000000000000000000000000000804; /// @dev The IBank contract's instance. IBank constant IBANK_CONTRACT = IBank(IBANK_PRECOMPILE_ADDRESS); /// @dev Balance specifies the ERC20 contract address and the amount of tokens. struct Balance { - /// contractAddress defines the ERC20 contract address. - address contractAddress; - /// amount of tokens - uint256 amount; + /// contractAddress defines the ERC20 contract address. + address contractAddress; + /// amount of tokens + uint256 amount; } /** @@ -21,19 +21,22 @@ struct Balance { * @dev Interface for querying balances and supply from the Bank module. */ interface IBank { - /// @dev Balances defines a method for retrieving all the native token balances - /// for a given account. - /// @param account the address of the account to query balances for - /// @return balances the array of native token balances - function balances(address account) external view returns (Balance[] memory balances); + /// @dev balances defines a method for retrieving all the native token balances + /// for a given account. + /// @param account the address of the account to query balances for. + /// @return balances the array of native token balances. + function balances( + address account + ) external view returns (Balance[] memory balances); - /// @dev TotalSupply defines a method for retrieving the total supply of all - /// native tokens. - /// @return totalSupply the supply as an array of native token balances - function totalSupply() external view returns (Balance[] memory totalSupply); + /// @dev totalSupply defines a method for retrieving the total supply of all + /// native tokens. + /// @return totalSupply the supply as an array of native token balances + function totalSupply() external view returns (Balance[] memory totalSupply); - - /// @dev supplyOf defines a method for retrieving the total supply of a particular native coin. - /// @return totalSupply the supply as a uint256 - function supplyOf(address erc20Address) external view returns (uint256 totalSupply); + /// @dev supplyOf defines a method for retrieving the total supply of a particular native coin. + /// @return totalSupply the supply as a uint256 + function supplyOf( + address erc20Address + ) external view returns (uint256 totalSupply); } diff --git a/precompiles/bank/bank.go b/precompiles/bank/bank.go index 337caf3d..3fdb2987 100644 --- a/precompiles/bank/bank.go +++ b/precompiles/bank/bank.go @@ -1,5 +1,9 @@ // Copyright Tharsis Labs Ltd.(Evmos) // SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +// +// The bank package contains the implementation of the x/bank module precompile. +// The precompiles returns all bank's information in the original decimals +// representation stored in the module. package bank @@ -9,6 +13,7 @@ import ( storetypes "cosmossdk.io/store/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" + "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" cmn "github.com/evmos/os/precompiles/common" erc20keeper "github.com/evmos/os/x/erc20/keeper" @@ -17,8 +22,8 @@ import ( ) const ( - // GasBalanceOf defines the gas cost for a single ERC-20 balanceOf query - GasBalanceOf = 2_851 + // GasBalances defines the gas cost for a single ERC-20 balanceOf query + GasBalances = 2_851 // GasTotalSupply defines the gas cost for a single ERC-20 totalSupply query GasTotalSupply = 2_477 @@ -41,7 +46,7 @@ type Precompile struct { erc20Keeper erc20keeper.Keeper } -// NewPrecompile creates a new bank Precompile instance as a +// NewPrecompile creates a new bank Precompile instance implementing the // PrecompiledContract interface. func NewPrecompile( bankKeeper bankkeeper.Keeper, @@ -85,11 +90,9 @@ func (p Precompile) RequiredGas(input []byte) uint64 { return 0 } - // NOTE: Charge the amount of gas required for a single ERC-20 - // balanceOf or totalSupply query switch method.Name { case BalancesMethod: - return GasBalanceOf + return GasBalances case TotalSupplyMethod: return GasTotalSupply case SupplyOfMethod: @@ -141,6 +144,6 @@ func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz [ // IsTransaction checks if the given method name corresponds to a transaction or query. // It returns false since all bank methods are queries. -func (Precompile) IsTransaction(_ string) bool { +func (Precompile) IsTransaction(_ *abi.Method) bool { return false } diff --git a/precompiles/bank/integration_test.go b/precompiles/bank/integration_test.go index 75810db3..062d0ed1 100644 --- a/precompiles/bank/integration_test.go +++ b/precompiles/bank/integration_test.go @@ -11,7 +11,6 @@ import ( "github.com/evmos/os/precompiles/bank" "github.com/evmos/os/precompiles/bank/testdata" "github.com/evmos/os/precompiles/testutil" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/os/factory" "github.com/evmos/os/testutil/integration/os/grpc" "github.com/evmos/os/testutil/integration/os/keyring" @@ -164,7 +163,7 @@ var _ = Describe("Bank Extension -", func() { err = is.precompile.UnpackIntoInterface(&balances, bank.BalancesMethod, ethRes.Ret) Expect(err).ToNot(HaveOccurred(), "failed to unpack balances") - balanceAfter, err := is.grpcHandler.GetBalance(receiver.Bytes(), is.tokenDenom) + balanceAfter, err := is.grpcHandler.GetBalanceFromBank(receiver.Bytes(), is.tokenDenom) Expect(err).ToNot(HaveOccurred(), "failed to get balance") Expect(math.NewInt(balances[0].Amount.Int64())).To(Equal(balanceAfter.Balance.Amount)) @@ -187,7 +186,7 @@ var _ = Describe("Bank Extension -", func() { err = is.precompile.UnpackIntoInterface(&balances, bank.BalancesMethod, ethRes.Ret) Expect(err).ToNot(HaveOccurred(), "failed to unpack balances") - balanceAfter, err := is.grpcHandler.GetBalance(receiver.Bytes(), testconstants.ExampleAttoDenom) + balanceAfter, err := is.grpcHandler.GetBalanceFromBank(receiver.Bytes(), is.network.GetBaseDenom()) Expect(err).ToNot(HaveOccurred(), "failed to get balance") Expect(math.NewInt(balances[0].Amount.Int64())).To(Equal(balanceAfter.Balance.Amount)) @@ -218,7 +217,7 @@ var _ = Describe("Bank Extension -", func() { err = is.precompile.UnpackIntoInterface(&balances, bank.BalancesMethod, ethRes.Ret) Expect(err).ToNot(HaveOccurred(), "failed to unpack balances") - gasUsed := Max(bank.GasBalanceOf, len(balances)*bank.GasBalanceOf) + gasUsed := Max(bank.GasBalances, len(balances)*bank.GasBalances) // Here increasing the GasBalanceOf will increase the use of gas so they will never be equal Expect(gasUsed).To(BeNumerically("<=", ethRes.GasUsed)) }) @@ -307,7 +306,7 @@ var _ = Describe("Bank Extension -", func() { err = is.precompile.UnpackIntoInterface(&balances, bank.BalancesMethod, ethRes.Ret) Expect(err).ToNot(HaveOccurred(), "failed to unpack balances") - balanceAfter, err := is.grpcHandler.GetBalance(receiver.Bytes(), is.tokenDenom) + balanceAfter, err := is.grpcHandler.GetBalanceFromBank(receiver.Bytes(), is.tokenDenom) Expect(err).ToNot(HaveOccurred(), "failed to get balance") Expect(math.NewInt(balances[0].Amount.Int64())).To(Equal(balanceAfter.Balance.Amount)) @@ -330,7 +329,7 @@ var _ = Describe("Bank Extension -", func() { err = is.precompile.UnpackIntoInterface(&balances, bank.BalancesMethod, ethRes.Ret) Expect(err).ToNot(HaveOccurred(), "failed to unpack balances") - balanceAfter, err := is.grpcHandler.GetBalance(receiver.Bytes(), testconstants.ExampleAttoDenom) + balanceAfter, err := is.grpcHandler.GetBalanceFromBank(receiver.Bytes(), is.network.GetBaseDenom()) Expect(err).ToNot(HaveOccurred(), "failed to get balance") Expect(math.NewInt(balances[0].Amount.Int64())).To(Equal(balanceAfter.Balance.Amount)) @@ -361,7 +360,7 @@ var _ = Describe("Bank Extension -", func() { err = is.precompile.UnpackIntoInterface(&balances, bank.BalancesMethod, ethRes.Ret) Expect(err).ToNot(HaveOccurred(), "failed to unpack balances") - gasUsed := Max(bank.GasBalanceOf, len(balances)*bank.GasBalanceOf) + gasUsed := Max(bank.GasBalances, len(balances)*bank.GasBalances) // Here increasing the GasBalanceOf will increase the use of gas so they will never be equal Expect(gasUsed).To(BeNumerically("<=", ethRes.GasUsed)) }) diff --git a/precompiles/bank/query.go b/precompiles/bank/query.go index 2c76f432..dd2f8dc2 100644 --- a/precompiles/bank/query.go +++ b/precompiles/bank/query.go @@ -4,6 +4,7 @@ package bank import ( + "fmt" "math/big" sdk "github.com/cosmos/cosmos-sdk/types" @@ -23,8 +24,10 @@ const ( SupplyOfMethod = "supplyOf" ) -// Balances returns all the native token balances (address, amount) for a given -// account. This method charges the account the corresponding value of an ERC-20 +// Balances returns given account's balances of all tokens registered in the x/bank module +// and the corresponding ERC20 address (address, amount). The amount returned for each token +// has the original decimals precision stored in the x/bank. +// This method charges the account the corresponding value of an ERC-20 // balanceOf call for each token returned. func (p Precompile) Balances( ctx sdk.Context, @@ -34,7 +37,7 @@ func (p Precompile) Balances( ) ([]byte, error) { account, err := ParseBalancesArgs(args) if err != nil { - return nil, err + return nil, fmt.Errorf("error calling account balances in bank precompile: %s", err) } i := 0 @@ -46,7 +49,7 @@ func (p Precompile) Balances( // NOTE: we already charged for a single balanceOf request so we don't // need to charge on the first iteration if i > 0 { - ctx.GasMeter().ConsumeGas(GasBalanceOf, "ERC-20 extension balances method") + ctx.GasMeter().ConsumeGas(GasBalances, "ERC-20 extension balances method") } contractAddress, err := p.erc20Keeper.GetCoinAddress(ctx, coin.Denom) @@ -65,7 +68,9 @@ func (p Precompile) Balances( return method.Outputs.Pack(balances) } -// TotalSupply returns the total supply of all the native tokens. +// TotalSupply returns the total supply of all tokens registered in the x/bank +// module. The amount returned for each token has the original +// decimals precision stored in the x/bank. // This method charges the account the corresponding value of a ERC-20 totalSupply // call for each token returned. func (p Precompile) TotalSupply( @@ -102,7 +107,11 @@ func (p Precompile) TotalSupply( return method.Outputs.Pack(totalSupply) } -// SupplyOf returns the total native supply of a given registered erc20 token. +// SupplyOf returns the total supply of a given registered erc20 token +// from the x/bank module. If the ERC20 token doesn't have a registered +// TokenPair, the method returns a supply of zero. +// The amount returned with this query has the original decimals precision +// stored in the x/bank. func (p Precompile) SupplyOf( ctx sdk.Context, _ *vm.Contract, @@ -111,7 +120,7 @@ func (p Precompile) SupplyOf( ) ([]byte, error) { erc20ContractAddress, err := ParseSupplyOfArgs(args) if err != nil { - return nil, err + return nil, fmt.Errorf("error getting the supply in bank precompile: %s", err) } tokenPairID := p.erc20Keeper.GetERC20Map(ctx, erc20ContractAddress) diff --git a/precompiles/bank/query_test.go b/precompiles/bank/query_test.go index 39a49a90..f3a4399c 100644 --- a/precompiles/bank/query_test.go +++ b/precompiles/bank/query_test.go @@ -103,8 +103,6 @@ func (s *PrecompileTestSuite) TestBalances() { } for _, tc := range testcases { - tc := tc - s.Run(tc.name, func() { ctx = s.SetupTest() // reset the chain each test @@ -162,8 +160,6 @@ func (s *PrecompileTestSuite) TestTotalSupply() { } for _, tc := range testcases { - tc := tc - s.Run(tc.name, func() { ctx = s.SetupTest() tc.malleate() @@ -259,8 +255,6 @@ func (s *PrecompileTestSuite) TestSupplyOf() { } for _, tc := range testcases { - tc := tc - s.Run(tc.name, func() { ctx := s.SetupTest() diff --git a/precompiles/bank/types.go b/precompiles/bank/types.go index a6655d90..fad7b906 100644 --- a/precompiles/bank/types.go +++ b/precompiles/bank/types.go @@ -12,7 +12,7 @@ import ( cmn "github.com/evmos/os/precompiles/common" ) -// Balance contains the amount for a corresponding ERC-20 contract address +// Balance contains the amount for a corresponding ERC-20 contract address. type Balance struct { ContractAddress common.Address Amount *big.Int diff --git a/precompiles/common/precompile.go b/precompiles/common/precompile.go index 050516fc..7ae08613 100644 --- a/precompiles/common/precompile.go +++ b/precompiles/common/precompile.go @@ -75,7 +75,7 @@ func (p Precompile) RunSetup( evm *vm.EVM, contract *vm.Contract, readOnly bool, - isTransaction func(name string) bool, + isTransaction func(name *abi.Method) bool, ) (ctx sdk.Context, stateDB *statedb.StateDB, s snapshot, method *abi.Method, gasConfig storetypes.Gas, args []interface{}, err error) { //nolint:revive stateDB, ok := evm.StateDB.(*statedb.StateDB) if !ok { @@ -126,7 +126,7 @@ func (p Precompile) RunSetup( } // return error if trying to write to state during a read-only call - if readOnly && isTransaction(method.Name) { + if readOnly && isTransaction(method) { return sdk.Context{}, nil, s, nil, uint64(0), nil, vm.ErrWriteProtection } diff --git a/precompiles/distribution/distribution.go b/precompiles/distribution/distribution.go index 87a392fb..e4ac2cdf 100644 --- a/precompiles/distribution/distribution.go +++ b/precompiles/distribution/distribution.go @@ -11,6 +11,7 @@ import ( authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" distributionkeeper "github.com/cosmos/cosmos-sdk/x/distribution/keeper" stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" + "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" cmn "github.com/evmos/os/precompiles/common" "github.com/evmos/os/x/evm/core/vm" @@ -80,7 +81,7 @@ func (p Precompile) RequiredGas(input []byte) uint64 { return 0 } - return p.Precompile.RequiredGas(input, p.IsTransaction(method.Name)) + return p.Precompile.RequiredGas(input, p.IsTransaction(method)) } // Run executes the precompiled contract distribution methods defined in the ABI. @@ -150,8 +151,8 @@ func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz [ // - SetWithdrawAddress // - WithdrawDelegatorRewards // - WithdrawValidatorCommission -func (Precompile) IsTransaction(methodName string) bool { - switch methodName { +func (Precompile) IsTransaction(method *abi.Method) bool { + switch method.Name { case ClaimRewardsMethod, SetWithdrawAddressMethod, WithdrawDelegatorRewardsMethod, diff --git a/precompiles/distribution/distribution_test.go b/precompiles/distribution/distribution_test.go index bb1017f0..d7505c3b 100644 --- a/precompiles/distribution/distribution_test.go +++ b/precompiles/distribution/distribution_test.go @@ -10,6 +10,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/distribution/types" + "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" gethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/evmos/os/precompiles/distribution" @@ -20,44 +21,44 @@ import ( func (s *PrecompileTestSuite) TestIsTransaction() { testCases := []struct { name string - method string + method abi.Method isTx bool }{ { distribution.SetWithdrawAddressMethod, - s.precompile.Methods[distribution.SetWithdrawAddressMethod].Name, + s.precompile.Methods[distribution.SetWithdrawAddressMethod], true, }, { distribution.WithdrawDelegatorRewardsMethod, - s.precompile.Methods[distribution.WithdrawDelegatorRewardsMethod].Name, + s.precompile.Methods[distribution.WithdrawDelegatorRewardsMethod], true, }, { distribution.WithdrawValidatorCommissionMethod, - s.precompile.Methods[distribution.WithdrawValidatorCommissionMethod].Name, + s.precompile.Methods[distribution.WithdrawValidatorCommissionMethod], true, }, { distribution.FundCommunityPoolMethod, - s.precompile.Methods[distribution.FundCommunityPoolMethod].Name, + s.precompile.Methods[distribution.FundCommunityPoolMethod], true, }, { distribution.ValidatorDistributionInfoMethod, - s.precompile.Methods[distribution.ValidatorDistributionInfoMethod].Name, + s.precompile.Methods[distribution.ValidatorDistributionInfoMethod], false, }, { "invalid", - "invalid", + abi.Method{}, false, }, } for _, tc := range testCases { s.Run(tc.name, func() { - s.Require().Equal(s.precompile.IsTransaction(tc.method), tc.isTx) + s.Require().Equal(s.precompile.IsTransaction(&tc.method), tc.isTx) }) } } @@ -209,12 +210,11 @@ func (s *PrecompileTestSuite) TestRun() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { // setup basic test suite s.SetupTest() ctx = s.network.GetContext() - baseFee := s.network.App.FeeMarketKeeper.GetBaseFee(ctx) + baseFee := s.network.App.EVMKeeper.GetBaseFee(ctx) // malleate testcase caller, input := tc.malleate() @@ -225,7 +225,7 @@ func (s *PrecompileTestSuite) TestRun() { contractAddr := contract.Address() // Build and sign Ethereum transaction txArgs := evmtypes.EvmTxArgs{ - ChainID: s.network.App.EVMKeeper.ChainID(), + ChainID: evmtypes.GetEthChainConfig().ChainID, Nonce: 0, To: &contractAddr, Amount: nil, @@ -243,7 +243,7 @@ func (s *PrecompileTestSuite) TestRun() { // Instantiate config proposerAddress := ctx.BlockHeader().ProposerAddress - cfg, err := s.network.App.EVMKeeper.EVMConfig(ctx, proposerAddress, s.network.App.EVMKeeper.ChainID()) + cfg, err := s.network.App.EVMKeeper.EVMConfig(ctx, proposerAddress) s.Require().NoError(err, "failed to instantiate EVM config") ethChainID := s.network.GetEIP155ChainID() diff --git a/precompiles/distribution/integration_test.go b/precompiles/distribution/integration_test.go index 43decdb2..3470806a 100644 --- a/precompiles/distribution/integration_test.go +++ b/precompiles/distribution/integration_test.go @@ -202,7 +202,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { It("should withdraw delegation rewards", func() { // get initial balance - queryRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + queryRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") initialBalance := queryRes.Balance @@ -242,7 +242,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(rewards[0].Amount).To(Equal(expRewardPerValidator.TruncateInt().BigInt())) // check that the rewards were added to the balance - queryRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + queryRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") fees := gasPrice.Mul(math.NewInt(res.GasUsed)) expFinal := initialBalance.Amount.Add(expRewardPerValidator.TruncateInt()).Sub(fees) @@ -250,7 +250,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { }) It("should withdraw rewards successfully to the new withdrawer address", func() { - balRes, err := s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) withdrawerInitialBalance := balRes.Balance // Set new withdrawer address @@ -260,7 +260,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(s.network.NextBlock()).To(BeNil()) // get initial balance - queryRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + queryRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") initialBalance := queryRes.Balance @@ -297,14 +297,14 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(rewards[0].Amount).To(Equal(expRewardsAmt.BigInt())) // check that the delegator final balance is initialBalance - fee - queryRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + queryRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") fees := gasPrice.Mul(math.NewInt(res.GasUsed)) expDelgatorFinal := initialBalance.Amount.Sub(fees) Expect(queryRes.Balance.Amount).To(Equal(expDelgatorFinal), "expected delegator final balance to be equal to initial balance - fees") // check that the rewards were added to the withdrawer balance - queryRes, err = s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + queryRes, err = s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") expWithdrawerFinal := withdrawerInitialBalance.Amount.Add(expRewardsAmt) @@ -327,7 +327,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { // persist state change Expect(s.network.NextBlock()).To(BeNil()) - balRes, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) initialWithdrawerBalance := balRes.Balance Expect(initialWithdrawerBalance.Amount).To(Equal(math.ZeroInt())) @@ -339,7 +339,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(s.network.NextBlock()).To(BeNil()) // get tx sender initial balance - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") initialBalance := balRes.Balance @@ -375,7 +375,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(rewards[0].Amount).To(Equal(expRewardsAmt.BigInt())) // check tx sender balance is reduced by fees paid - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) finalBalance := balRes.Balance fees := gasPrice.MulRaw(res.GasUsed) @@ -383,7 +383,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(finalBalance.Amount).To(Equal(expFinal), "expected final balance to be equal to initial balance - fees") // check that the rewards were added to the withdrawer balance - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalWithdrawerBalance := balRes.Balance Expect(finalWithdrawerBalance.Amount).To(Equal(expRewardsAmt)) @@ -447,7 +447,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { It("should withdraw validator commission", func() { // initial balance should be the initial amount minus the staked amount used to create the validator - queryRes, err := s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + queryRes, err := s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") initialBalance := queryRes.Balance @@ -481,7 +481,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(s.network.NextBlock()).To(BeNil()) - queryRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + queryRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") finalBalance := queryRes.Balance @@ -507,7 +507,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { // persist state change Expect(s.network.NextBlock()).To(BeNil()) - balRes, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) initialWithdrawerBalance := balRes.Balance Expect(initialWithdrawerBalance.Amount).To(Equal(math.ZeroInt())) @@ -519,7 +519,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(s.network.NextBlock()).To(BeNil()) // get validator initial balance - balRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") initialBalance := balRes.Balance @@ -552,7 +552,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(comm[0].Denom).To(Equal(s.bondDenom)) Expect(comm[0].Amount).To(Equal(expCommAmt.BigInt())) - balRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") finalBalance := balRes.Balance @@ -561,7 +561,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(finalBalance.Amount).To(Equal(expFinal), "expected final balance to be equal to the final balance after withdrawing commission") // check that the commission was added to the withdrawer balance - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalWithdrawerBalance := balRes.Balance Expect(finalWithdrawerBalance.Amount).To(Equal(expCommAmt)) @@ -603,7 +603,7 @@ var _ = Describe("Calling distribution precompile from EOA", func() { }) It("should claim all rewards from all validators", func() { - queryRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + queryRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") initialBalance := queryRes.Balance @@ -614,10 +614,10 @@ var _ = Describe("Calling distribution precompile from EOA", func() { txArgs.GasLimit = 250_000 // get base fee to use in tx to then calculate fee paid - bfQuery, err := s.grpcHandler.GetBaseFee() + bfQuery, err := s.grpcHandler.GetEvmBaseFee() Expect(err).To(BeNil(), "error while calling BaseFee") - gasPrice := bfQuery.BaseFee - txArgs.GasPrice = gasPrice.BigInt() + gasPrice := bfQuery.BaseFee.BigInt() + txArgs.GasPrice = gasPrice claimRewardsCheck := passCheck.WithExpEvents(distribution.EventTypeClaimRewards) @@ -633,14 +633,14 @@ var _ = Describe("Calling distribution precompile from EOA", func() { Expect(s.network.NextBlock()).To(BeNil(), "error on NextBlock") // check that the rewards were added to the balance - queryRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + queryRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") // get the fee paid and calculate the expFinalBalance - fee := gasPrice.Mul(math.NewInt(txRes.GasUsed)) + fee := gasPrice.Mul(math.NewInt(txRes.GasUsed).BigInt(), gasPrice) accruedRewardsAmt := accruedRewards.AmountOf(s.bondDenom).TruncateInt() // expected balance is initial + rewards - fee - expBalanceAmt := initialBalance.Amount.Add(accruedRewardsAmt).Sub(fee) + expBalanceAmt := initialBalance.Amount.Add(accruedRewardsAmt).Sub(math.NewIntFromBigInt(fee)) finalBalance := queryRes.Balance Expect(finalBalance.Amount).To(Equal(expBalanceAmt), "expected final balance to be equal to initial balance + rewards - fees") @@ -1113,7 +1113,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere _, err = testutils.WaitToAccrueRewards(s.network, s.grpcHandler, s.keyring.GetAccAddr(0).String(), minExpRewardOrCommission) Expect(err).To(BeNil()) - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) initialBalance = balRes.Balance @@ -1124,7 +1124,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere }) It("should not withdraw rewards when sending from a different address", func() { - balRes, err := s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) differentAddrInitialBalance := balRes.Balance @@ -1142,21 +1142,21 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil(), "error on NextBlock: %v", err) // balance should be equal as initial balance or less (because of fees) - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) finalBalance := balRes.Balance fees := gasPrice.Mul(math.NewInt(res.GasUsed)) Expect(finalBalance.Amount).To(Equal(initialBalance.Amount.Sub(fees))) // differentAddr balance should remain unchanged - balRes, err = s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) differentAddrFinalBalance := balRes.Balance Expect(differentAddrFinalBalance.Amount).To(Equal(differentAddrInitialBalance.Amount)) }) It("should withdraw rewards successfully", func() { - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) initBalanceAmt := balRes.Balance.Amount @@ -1181,7 +1181,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil(), "error on NextBlock: %v", err) // balance should increase - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) fees := gasPrice.Mul(math.NewInt(res.GasUsed)) @@ -1190,7 +1190,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere }) DescribeTable("should withdraw rewards successfully to the new withdrawer address", func(tc testCase) { - balRes, err := s.grpcHandler.GetBalance(tc.withdrawer.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(tc.withdrawer.Bytes(), s.bondDenom) Expect(err).To(BeNil()) withdrawerInitialBalance := balRes.Balance @@ -1201,7 +1201,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil()) // get delegator initial balance - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) delegatorInitialBalance := balRes.Balance @@ -1235,13 +1235,13 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(rewards[0].Amount).To(Equal(expRewardsAmt.BigInt())) // should increase withdrawer balance by rewards - balRes, err = s.grpcHandler.GetBalance(tc.withdrawer.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(tc.withdrawer.Bytes(), s.bondDenom) Expect(err).To(BeNil()) Expect(balRes.Balance.Amount).To(Equal(withdrawerInitialBalance.Amount.Add(expRewardsAmt)), "expected final balance to be greater than initial balance after withdrawing rewards") // check that the delegator final balance is initialBalance - fee - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil(), "error while calling GetBalance") fees := gasPrice.Mul(math.NewInt(res.GasUsed)) @@ -1274,7 +1274,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere DescribeTable("withdraw delegation rewards with internal transfers to delegator - should withdraw rewards successfully to the withdrawer address", func(tc testCase) { - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) if tc.withdrawer != nil { // Set new withdrawer address @@ -1282,12 +1282,12 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(err).To(BeNil()) // persist state change Expect(s.network.NextBlock()).To(BeNil()) - balRes, err = s.grpcHandler.GetBalance(tc.withdrawer.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(tc.withdrawer.Bytes(), s.bondDenom) Expect(err).To(BeNil()) } withdrawerInitialBalance := balRes.Balance - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) delInitialBalance := balRes.Balance @@ -1322,7 +1322,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere } } // contract balance be updated according to the transferred amount - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBalance := balRes.Balance Expect(contractFinalBalance.Amount).To(Equal(contractInitialBalance.Sub(contractTransferredAmt))) @@ -1332,14 +1332,14 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere expDelFinalBalance = delInitialBalance.Amount.Sub(fees).Add(contractTransferredAmt) expWithdrawerFinalBalance := withdrawerInitialBalance.Amount.Add(expRewards) // withdrawer balance should have the rewards - balRes, err = s.grpcHandler.GetBalance(tc.withdrawer.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(tc.withdrawer.Bytes(), s.bondDenom) Expect(err).To(BeNil()) withdrawerFinalBalance := balRes.Balance Expect(withdrawerFinalBalance.Amount).To(Equal(expWithdrawerFinalBalance), "expected final balance to be greater than initial balance after withdrawing rewards") } // delegator balance should have the transferred amt - fees + rewards (when is the withdrawer) - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) delFinalBalance := balRes.Balance Expect(delFinalBalance.Amount).To(Equal(expDelFinalBalance), "expected final balance to be greater than initial balance after withdrawing rewards") @@ -1390,10 +1390,10 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(err).To(BeNil()) initRewards := qRes.Rewards.AmountOf(s.bondDenom).TruncateInt() - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) delInitBalance := balRes.Balance - balRes, err = s.grpcHandler.GetBalance(tc.withdrawer.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(tc.withdrawer.Bytes(), s.bondDenom) Expect(err).To(BeNil()) withdrawerInitBalance := balRes.Balance @@ -1416,20 +1416,20 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere // check balances contractTransferredAmt := math.NewInt(15) // contract balance be updated according to the transferred amount - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBalance := balRes.Balance Expect(contractFinalBalance.Amount).To(Equal(contractInitialBalance.Sub(contractTransferredAmt))) // delegator balance should be initial_balance - fees - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) delFinalBalance := balRes.Balance Expect(delFinalBalance.Amount).To(Equal(delInitBalance.Amount.Sub(fees))) // withdrawer balance should increase by the transferred amount only // the rewards withdrawal should revert - balRes, err = s.grpcHandler.GetBalance(tc.withdrawer.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(tc.withdrawer.Bytes(), s.bondDenom) Expect(err).To(BeNil()) withdrawerFinalBalance := balRes.Balance Expect(withdrawerFinalBalance.Amount).To(Equal(withdrawerInitBalance.Amount.Add(contractTransferredAmt)), "expected final balance to be greater than initial balance after withdrawing rewards") @@ -1497,7 +1497,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere // contract's accrued rewards amt accruedRewardsAmt = rwRes.AmountOf(s.bondDenom).TruncateInt() - balRes, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) initialBalance = balRes.Balance @@ -1520,7 +1520,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil(), "error on NextBlock: %v", err) // balance should increase - balRes, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalBalance := balRes.Balance Expect(finalBalance.Amount).To(Equal(initialBalance.Amount.Add(accruedRewardsAmt)), "expected final balance to be greater than initial balance after withdrawing rewards") @@ -1529,7 +1529,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere It("should withdraw rewards successfully without origin check to a withdrawer address", func() { withdrawerAddr, _ := testutiltx.NewAccAddressAndKey() - balRes, err := s.grpcHandler.GetBalance(withdrawerAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(withdrawerAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) initialWithdrawerBalance := balRes.Balance Expect(initialWithdrawerBalance.Amount).To(Equal(math.ZeroInt())) @@ -1570,13 +1570,13 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil(), "error on NextBlock: %v", err) // withdrawer balance should increase with the rewards amt - balRes, err = s.grpcHandler.GetBalance(withdrawerAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(withdrawerAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalWithdrawerBalance := balRes.Balance Expect(finalWithdrawerBalance.Amount).To(Equal(accruedRewardsAmt), "expected final balance to be greater than initial balance after withdrawing rewards") // delegator balance (contract) should remain unchanged - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalDelegatorBalance := balRes.Balance Expect(finalDelegatorBalance.Amount.Equal(initialBalance.Amount)).To(BeTrue(), "expected delegator final balance remain unchanged after withdrawing rewards to withdrawer") @@ -1640,7 +1640,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere // contract's accrued rewards amt accruedRewardsAmt = rwRes.AmountOf(s.bondDenom).TruncateInt() - balRes, err := s.grpcHandler.GetBalance(delContractAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(delContractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) initialBalance = balRes.Balance @@ -1651,13 +1651,13 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere }) It("should NOT allow to withdraw rewards", func() { - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) txSenderInitialBalance := balRes.Balance - balRes, err = s.grpcHandler.GetBalance(delContractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(delContractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) delInitialBalance := balRes.Balance - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) callerContractInitialBal := balRes.Balance @@ -1679,19 +1679,19 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere fees := gasPrice.MulRaw(res.GasUsed) // check balances // tx signer final balance should be the initial balance - fees - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) txSignerFinalBalance := balRes.Balance Expect(txSignerFinalBalance.Amount).To(Equal(txSenderInitialBalance.Amount.Sub(fees))) // caller contract balance should remain unchanged - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBalance := balRes.Balance Expect(contractFinalBalance).To(Equal(callerContractInitialBal)) // delegator balance should remain unchanged - balRes, err = s.grpcHandler.GetBalance(delContractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(delContractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) delFinalBalance := balRes.Balance Expect(delFinalBalance).To(Equal(delInitialBalance)) @@ -1707,7 +1707,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere It("should withdraw rewards successfully without origin check to a withdrawer address", func() { withdrawerAddr, _ := testutiltx.NewAccAddressAndKey() - balRes, err := s.grpcHandler.GetBalance(withdrawerAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(withdrawerAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) initialWithdrawerBalance := balRes.Balance Expect(initialWithdrawerBalance.Amount).To(Equal(math.ZeroInt())) @@ -1748,13 +1748,13 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil(), "error on NextBlock: %v", err) // withdrawer balance should increase with the rewards amt - balRes, err = s.grpcHandler.GetBalance(withdrawerAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(withdrawerAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalWithdrawerBalance := balRes.Balance Expect(finalWithdrawerBalance.Amount.Equal(expRewards)).To(BeTrue(), "expected final balance to be greater than initial balance after withdrawing rewards") // delegator balance (contract) should remain unchanged - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalDelegatorBalance := balRes.Balance Expect(finalDelegatorBalance.Amount.Equal(initialBalance.Amount)).To(BeTrue(), "expected delegator final balance remain unchanged after withdrawing rewards to withdrawer") @@ -1779,12 +1779,12 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(err).To(BeNil()) accruedCommissionAmt = res.AmountOf(s.bondDenom).TruncateInt() - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) initialBalance = balRes.Balance // get validators initial balance - balRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil()) valInitialBalance = balRes.Balance @@ -1807,7 +1807,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil()) // balance should be equal as initial balance or less (because of fees) - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) finalBalance := balRes.Balance @@ -1815,7 +1815,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(finalBalance.Amount).To(Equal(initialBalance.Amount.Sub(fees))) // validator's balance should remain unchanged - balRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil()) valFinalBalance := balRes.Balance Expect(valFinalBalance.Amount).To(Equal(valInitialBalance.Amount)) @@ -1837,7 +1837,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) Expect(s.network.NextBlock()).To(BeNil()) - balRes, err := s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil()) valFinalBalance := balRes.Balance fees := gasPrice.Mul(math.NewInt(res.GasUsed)) @@ -1846,7 +1846,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere }) It("should withdraw commission successfully to withdrawer address (contract)", func() { - balRes, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) initialWithdrawerBalance := balRes.Balance Expect(initialWithdrawerBalance.Amount).To(Equal(math.ZeroInt())) @@ -1862,7 +1862,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere accruedCommissionAmt = qRes.Commission.Commission.AmountOf(s.bondDenom).TruncateInt() // validator acc balance before the tx - balRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil()) initialBalance := balRes.Balance @@ -1882,12 +1882,12 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) Expect(s.network.NextBlock()).To(BeNil()) - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalWithdrawerBalance := balRes.Balance Expect(finalWithdrawerBalance.Amount).To(Equal(initialWithdrawerBalance.Amount.Add(accruedCommissionAmt)), "expected final balance to be equal to initial balance + validator commission") - balRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil()) finalBalance := balRes.Balance fees := gasPrice.MulRaw(res.GasUsed) @@ -1911,7 +1911,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere DescribeTable("withdraw validator commission with state changes in withdrawer - should withdraw commission successfully to the withdrawer address", func(tc testCase) { withdrawerAddr := s.validatorsKeys[0].Addr - balRes, err := s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil()) if tc.withdrawer != nil { withdrawerAddr = *tc.withdrawer @@ -1920,13 +1920,13 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(err).To(BeNil()) // persist state change Expect(s.network.NextBlock()).To(BeNil()) - balRes, err = s.grpcHandler.GetBalance(tc.withdrawer.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(tc.withdrawer.Bytes(), s.bondDenom) Expect(err).To(BeNil()) } withdrawerInitialBalance := balRes.Balance // validator acc balance before the tx - balRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil()) valInitialBalance := balRes.Balance @@ -1972,7 +1972,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere } else { expWithdrawerFinalBalance := withdrawerInitialBalance.Amount.Add(expCommission).Add(contractTransferredAmt) // withdrawer balance should have the rewards - balRes, err = s.grpcHandler.GetBalance(tc.withdrawer.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(tc.withdrawer.Bytes(), s.bondDenom) Expect(err).To(BeNil()) withdrawerFinalBalance := balRes.Balance Expect(withdrawerFinalBalance.Amount).To(Equal(expWithdrawerFinalBalance), "expected final balance to be greater than initial balance after withdrawing rewards") @@ -1980,13 +1980,13 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere } // contract balance be updated according to the transferred amount - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBalance := balRes.Balance Expect(contractFinalBalance.Amount).To(Equal(expContractFinalBalance)) // validator balance should have the transferred amt - fees + rewards (when is the withdrawer) - balRes, err = s.grpcHandler.GetBalance(s.validatorsKeys[0].AccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.validatorsKeys[0].AccAddr, s.bondDenom) Expect(err).To(BeNil()) valFinalBalance := balRes.Balance Expect(valFinalBalance.Amount).To(Equal(expValFinalBalance), "expected final balance to be greater than initial balance after withdrawing rewards") @@ -2075,11 +2075,11 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere accruedRewardsAmt = res.Total.AmountOf(s.bondDenom).TruncateInt() Expect(accruedRewardsAmt.IsPositive()).To(BeTrue()) - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) initialBalance = balRes.Balance - balRes, err = s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) diffAddrInitialBalance = balRes.Balance @@ -2101,14 +2101,14 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil()) // balance should be equal as initial balance or less (because of fees) - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) finalBalance := balRes.Balance fees := gasPrice.Mul(math.NewInt(res.GasUsed)) Expect(finalBalance.Amount).To(Equal(initialBalance.Amount.Sub(fees))) // differentAddr balance should remain unchanged - balRes, err = s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) differentAddrFinalBalance := balRes.Balance Expect(differentAddrFinalBalance.Amount).To(Equal(diffAddrInitialBalance.Amount)) @@ -2130,7 +2130,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(s.network.NextBlock()).To(BeNil()) // balance should remain unchanged - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) finalBalance := balRes.Balance Expect(finalBalance.Amount.GT(initialBalance.Amount)).To(BeTrue(), "expected final balance to be greater than initial balance after claiming rewards") @@ -2260,7 +2260,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere // contract's accrued rewards amt accruedRewardsAmt = rwRes.AmountOf(s.bondDenom).TruncateInt() - balRes, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) initialBalance = balRes.Balance @@ -2269,7 +2269,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere }) It("should withdraw rewards successfully without origin check", func() { - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) signerInitialBalance := balRes.Balance @@ -2289,28 +2289,28 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere // tx signer should have paid the fees fees := gasPrice.Mul(math.NewInt(res.GasUsed)) - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) signerFinalBalance := balRes.Balance Expect(signerFinalBalance.Amount).To(Equal(signerInitialBalance.Amount.Sub(fees))) // contract's balance should increase - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) finalBalance := balRes.Balance Expect(finalBalance.Amount).To(Equal(initialBalance.Amount.Add(accruedRewardsAmt)), "expected final balance to be greater than initial balance after withdrawing rewards") }) It("should withdraw rewards successfully to a different address without origin check", func() { - balanceRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balanceRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) signerInitialBalance := balanceRes.Balance - balRes, err := s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) withdrawerInitialBalance := balRes.Balance - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractInitialBalance := balRes.Balance @@ -2352,19 +2352,19 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere // signer balance should decrease - paid for fees fees := gasPrice.Mul(math.NewInt(res1.GasUsed)).Add(gasPrice.Mul(math.NewInt(res2.GasUsed))) - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) signerFinalBalance := balRes.Balance Expect(signerFinalBalance.Amount).To(Equal(signerInitialBalance.Amount.Sub(fees)), "expected signer's final balance to be less than initial balance after withdrawing rewards") // withdrawer balance should increase - balRes, err = s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) withdrawerFinalBalance := balRes.Balance Expect(withdrawerFinalBalance.Amount).To(Equal(withdrawerInitialBalance.Amount.Add(accruedRewardsAmt))) // contract balance should remain unchanged - balRes, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBalance := balRes.Balance Expect(contractFinalBalance.Amount).To(Equal(contractInitialBalance.Amount)) @@ -2374,7 +2374,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Context("Forbidden operations", func() { It("should revert state: modify withdraw address & then try to withdraw rewards corresponding to another user", func() { // check signer address balance should've decreased (fees paid) - balanceRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balanceRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) initBalanceAmt := balanceRes.Balance.Amount @@ -2401,12 +2401,12 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere Expect(res.WithdrawAddress).To(Equal(s.keyring.GetAccAddr(0).String())) // check signer address balance should've decreased (fees paid) - balanceRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balanceRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) Expect(balanceRes.Balance.Amount.LTE(initBalanceAmt)).To(BeTrue()) // check other address' balance remained unchanged - balanceRes, err = s.grpcHandler.GetBalance(differentAddr.Bytes(), s.bondDenom) + balanceRes, err = s.grpcHandler.GetBalanceFromBank(differentAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) Expect(balanceRes.Balance.Amount).To(Equal(math.ZeroInt())) }) @@ -2848,7 +2848,7 @@ var _ = Describe("Calling distribution precompile from another contract", Ordere ) Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) - balRes, err := s.grpcHandler.GetBalance(reverterAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(reverterAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBalance := balRes.Balance diff --git a/precompiles/distribution/setup_test.go b/precompiles/distribution/setup_test.go index f4da1f04..0a8870ab 100644 --- a/precompiles/distribution/setup_test.go +++ b/precompiles/distribution/setup_test.go @@ -13,7 +13,7 @@ import ( "github.com/evmos/os/testutil/integration/os/grpc" testkeyring "github.com/evmos/os/testutil/integration/os/keyring" "github.com/evmos/os/testutil/integration/os/network" - + evmtypes "github.com/evmos/os/x/evm/types" "github.com/stretchr/testify/suite" ) @@ -27,6 +27,7 @@ type PrecompileTestSuite struct { precompile *distribution.Precompile bondDenom string + baseDenom string validatorsKeys []testkeyring.Key withValidatorSlashes bool } @@ -86,6 +87,9 @@ func (s *PrecompileTestSuite) SetupTest() { } s.bondDenom = bondDenom + // TODO: check if this is correct? + s.baseDenom = evmtypes.GetEVMCoinDenom() + s.factory = txFactory s.grpcHandler = grpcHandler s.keyring = keyring diff --git a/precompiles/distribution/tx.go b/precompiles/distribution/tx.go index c2d6a6ca..3151d6ca 100644 --- a/precompiles/distribution/tx.go +++ b/precompiles/distribution/tx.go @@ -12,6 +12,7 @@ import ( "github.com/ethereum/go-ethereum/common" cmn "github.com/evmos/os/precompiles/common" "github.com/evmos/os/x/evm/core/vm" + evmtypes "github.com/evmos/os/x/evm/types" ) const ( @@ -90,8 +91,11 @@ func (p *Precompile) ClaimRewards( return nil, err } - evmDenom := p.evmKeeper.GetParams(ctx).EvmDenom - p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(withdrawerHexAddr, totalCoins.AmountOf(evmDenom).BigInt(), cmn.Add)) + convertedAmount := evmtypes.ConvertAmountTo18DecimalsBigInt(totalCoins.AmountOf(evmtypes.GetEVMCoinDenom()).BigInt()) + // check if converted amount is greater than zero + if convertedAmount.Cmp(common.Big0) == 1 { + p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(withdrawerHexAddr, convertedAmount, cmn.Add)) + } } if err := p.EmitClaimRewardsEvent(ctx, stateDB, delegatorAddr, totalCoins); err != nil { @@ -171,7 +175,11 @@ func (p *Precompile) WithdrawDelegatorRewards( return nil, err } - p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(withdrawerHexAddr, res.Amount[0].Amount.BigInt(), cmn.Add)) + convertedAmount := evmtypes.ConvertAmountTo18DecimalsBigInt(res.Amount.AmountOf(evmtypes.GetEVMCoinDenom()).BigInt()) + // check if converted amount is greater than zero + if convertedAmount.Cmp(common.Big0) == 1 { + p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(withdrawerHexAddr, convertedAmount, cmn.Add)) + } } if err = p.EmitWithdrawDelegatorRewardsEvent(ctx, stateDB, delegatorHexAddr, msg.ValidatorAddress, res.Amount); err != nil { @@ -218,7 +226,12 @@ func (p *Precompile) WithdrawValidatorCommission( return nil, err } - p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(withdrawerHexAddr, res.Amount[0].Amount.BigInt(), cmn.Add)) + // TODO: check in all methods here if evm denom is the correct denom to use! + convertedAmount := evmtypes.ConvertAmountTo18DecimalsBigInt(res.Amount.AmountOf(evmtypes.GetEVMCoinDenom()).BigInt()) + // check if converted amount is greater than zero + if convertedAmount.Cmp(common.Big0) == 1 { + p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(withdrawerHexAddr, convertedAmount, cmn.Add)) + } } if err = p.EmitWithdrawValidatorCommissionEvent(ctx, stateDB, msg.ValidatorAddress, res.Amount); err != nil { @@ -237,8 +250,13 @@ func (p *Precompile) FundCommunityPool( method *abi.Method, args []interface{}, ) ([]byte, error) { - evmDenom := p.evmKeeper.GetParams(ctx).EvmDenom - msg, depositorHexAddr, err := NewMsgFundCommunityPool(evmDenom, args) + // TODO: check if this is correct? Community pool should be funded with sdk base denom instead of evm denom right? + baseDenom, err := sdk.GetBaseDenom() + if err != nil { + return nil, err + } + + msg, depositorHexAddr, err := NewMsgFundCommunityPool(baseDenom, args) if err != nil { return nil, err } @@ -260,7 +278,12 @@ func (p *Precompile) FundCommunityPool( // when calling the precompile from a smart contract // This prevents the stateDB from overwriting the changed balance in the bank keeper when committing the EVM state. if contract.CallerAddress != origin { - p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(depositorHexAddr, msg.Amount.AmountOf(evmDenom).BigInt(), cmn.Sub)) + // TODO: check if correct - should the balance change in the state DB be for the evm denom?? do we need scaling here? + convertedAmount := evmtypes.ConvertAmountTo18DecimalsBigInt(msg.Amount.AmountOf(baseDenom).BigInt()) + // check if converted amount is greater than zero + if convertedAmount.Cmp(common.Big0) == 1 { + p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(depositorHexAddr, convertedAmount, cmn.Sub)) + } } if err = p.EmitFundCommunityPoolEvent(ctx, stateDB, depositorHexAddr, msg.Amount); err != nil { diff --git a/precompiles/erc20/approve_test.go b/precompiles/erc20/approve_test.go index 011caa70..b5d55745 100644 --- a/precompiles/erc20/approve_test.go +++ b/precompiles/erc20/approve_test.go @@ -420,7 +420,6 @@ func (s *PrecompileTestSuite) TestIncreaseAllowance() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { s.SetupTest() @@ -719,7 +718,6 @@ func (s *PrecompileTestSuite) TestDecreaseAllowance() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { s.SetupTest() diff --git a/precompiles/erc20/erc20.go b/precompiles/erc20/erc20.go index 4473c1eb..a504c45f 100644 --- a/precompiles/erc20/erc20.go +++ b/precompiles/erc20/erc20.go @@ -16,7 +16,6 @@ import ( cmn "github.com/evmos/os/precompiles/common" erc20types "github.com/evmos/os/x/erc20/types" "github.com/evmos/os/x/evm/core/vm" - evmkeeper "github.com/evmos/os/x/evm/keeper" transferkeeper "github.com/evmos/os/x/ibc/transfer/keeper" ) @@ -47,9 +46,9 @@ var _ vm.PrecompiledContract = &Precompile{} type Precompile struct { cmn.Precompile tokenPair erc20types.TokenPair - bankKeeper bankkeeper.Keeper transferKeeper transferkeeper.Keeper - evmKeeper *evmkeeper.Keeper + // BankKeeper is a public field so that the werc20 precompile can use it. + BankKeeper bankkeeper.Keeper } // NewPrecompile creates a new ERC-20 Precompile instance as a @@ -59,7 +58,6 @@ func NewPrecompile( bankKeeper bankkeeper.Keeper, authzKeeper authzkeeper.Keeper, transferKeeper transferkeeper.Keeper, - evmKeeper *evmkeeper.Keeper, ) (*Precompile, error) { newABI, err := cmn.LoadABI(f, abiPath) if err != nil { @@ -75,9 +73,8 @@ func NewPrecompile( TransientKVGasConfig: storetypes.GasConfig{}, }, tokenPair: tokenPair, - bankKeeper: bankKeeper, + BankKeeper: bankKeeper, transferKeeper: transferKeeper, - evmKeeper: evmKeeper, } // Address defines the address of the ERC-20 precompile contract. p.SetAddress(p.tokenPair.GetERC20Contract()) @@ -132,6 +129,14 @@ func (p Precompile) RequiredGas(input []byte) uint64 { // Run executes the precompiled contract ERC-20 methods defined in the ABI. func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz []byte, err error) { + // ERC20 precompiles cannot receive funds because they are not managed by an + // EOA and will not be possible to recover funds sent to an instance of + // them.This check is a safety measure because currently funds cannot be + // received due to the lack of a fallback handler. + if value := contract.Value(); value.Sign() == 1 { + return nil, fmt.Errorf(ErrCannotReceiveFunds, contract.Value().String()) + } + ctx, stateDB, snapshot, method, initialGas, args, err := p.RunSetup(evm, contract, readOnly, p.IsTransaction) if err != nil { return nil, err @@ -158,8 +163,8 @@ func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz [ } // IsTransaction checks if the given method name corresponds to a transaction or query. -func (Precompile) IsTransaction(methodName string) bool { - switch methodName { +func (Precompile) IsTransaction(method *abi.Method) bool { + switch method.Name { case TransferMethod, TransferFromMethod, auth.ApproveMethod, diff --git a/precompiles/erc20/erc20_test.go b/precompiles/erc20/erc20_test.go index fc7ba1b4..79236528 100644 --- a/precompiles/erc20/erc20_test.go +++ b/precompiles/erc20/erc20_test.go @@ -14,18 +14,28 @@ func (s *PrecompileTestSuite) TestIsTransaction() { s.SetupTest() // Queries - s.Require().False(s.precompile.IsTransaction(erc20.BalanceOfMethod)) - s.Require().False(s.precompile.IsTransaction(erc20.DecimalsMethod)) - s.Require().False(s.precompile.IsTransaction(erc20.NameMethod)) - s.Require().False(s.precompile.IsTransaction(erc20.SymbolMethod)) - s.Require().False(s.precompile.IsTransaction(erc20.TotalSupplyMethod)) + method := s.precompile.Methods[erc20.BalanceOfMethod] + s.Require().False(s.precompile.IsTransaction(&method)) + method = s.precompile.Methods[erc20.DecimalsMethod] + s.Require().False(s.precompile.IsTransaction(&method)) + method = s.precompile.Methods[erc20.NameMethod] + s.Require().False(s.precompile.IsTransaction(&method)) + method = s.precompile.Methods[erc20.SymbolMethod] + s.Require().False(s.precompile.IsTransaction(&method)) + method = s.precompile.Methods[erc20.TotalSupplyMethod] + s.Require().False(s.precompile.IsTransaction(&method)) // Transactions - s.Require().True(s.precompile.IsTransaction(auth.ApproveMethod)) - s.Require().True(s.precompile.IsTransaction(auth.IncreaseAllowanceMethod)) - s.Require().True(s.precompile.IsTransaction(auth.DecreaseAllowanceMethod)) - s.Require().True(s.precompile.IsTransaction(erc20.TransferMethod)) - s.Require().True(s.precompile.IsTransaction(erc20.TransferFromMethod)) + method = s.precompile.Methods[auth.ApproveMethod] + s.Require().True(s.precompile.IsTransaction(&method)) + method = s.precompile.Methods[auth.IncreaseAllowanceMethod] + s.Require().True(s.precompile.IsTransaction(&method)) + method = s.precompile.Methods[auth.DecreaseAllowanceMethod] + s.Require().True(s.precompile.IsTransaction(&method)) + method = s.precompile.Methods[erc20.TransferMethod] + s.Require().True(s.precompile.IsTransaction(&method)) + method = s.precompile.Methods[erc20.TransferFromMethod] + s.Require().True(s.precompile.IsTransaction(&method)) } func (s *PrecompileTestSuite) TestRequiredGas() { @@ -153,8 +163,6 @@ func (s *PrecompileTestSuite) TestRequiredGas() { for _, tc := range testcases { s.Run(tc.name, func() { - tc := tc - input := tc.malleate() s.Require().Equal(tc.expGas, s.precompile.RequiredGas(input)) diff --git a/precompiles/erc20/errors.go b/precompiles/erc20/errors.go index 1c08b1a8..1282505b 100644 --- a/precompiles/erc20/errors.go +++ b/precompiles/erc20/errors.go @@ -23,6 +23,7 @@ const ( ErrInvalidReceiver = "invalid to address: %s" ErrNoAllowanceForToken = "allowance for token %s does not exist" ErrSubtractMoreThanAllowance = "subtracted value cannot be greater than existing allowance for denom %s: %s > %s" + ErrCannotReceiveFunds = "cannot receive funds, received: %s" ) var ( diff --git a/precompiles/erc20/events_test.go b/precompiles/erc20/events_test.go index 894ed630..515023a7 100644 --- a/precompiles/erc20/events_test.go +++ b/precompiles/erc20/events_test.go @@ -28,7 +28,6 @@ func (s *PrecompileTestSuite) TestEmitTransferEvent() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { s.SetupTest() stateDB := s.network.GetStateDB() @@ -75,7 +74,6 @@ func (s *PrecompileTestSuite) TestEmitApprovalEvent() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { s.SetupTest() diff --git a/precompiles/erc20/integration_test.go b/precompiles/erc20/integration_test.go index 3ea3a192..925cd751 100644 --- a/precompiles/erc20/integration_test.go +++ b/precompiles/erc20/integration_test.go @@ -72,7 +72,7 @@ func (is *IntegrationTestSuite) SetupTest() { is.handler = gh is.keyring = keys - is.bondDenom = nw.GetDenom() + is.bondDenom = nw.GetBaseDenom() erc20Gen := genesis[erc20types.ModuleName].(*erc20types.GenesisState) is.precompile = is.setupERC20Precompile(is.tokenDenom, erc20Gen.TokenPairs) @@ -277,6 +277,10 @@ var _ = Describe("ERC20 Extension -", func() { txArgs.To = &precompileAddress _, err := is.factory.ExecuteEthTx(sender.Priv, txArgs) + // Currently, this check pass because the erc20 precompile does + // not expose a fallback handler. Adding a fallback handler, the + // test should pass again because of the check on the message + // value in the precompile before the setup. Expect(err.Error()).To(ContainSubstring(vm.ErrExecutionReverted.Error()), "precompile should not accept transfers") }, ) @@ -434,10 +438,10 @@ var _ = Describe("ERC20 Extension -", func() { receiver := is.keyring.GetKey(1) amountToSend := big.NewInt(100) - balRes, err := is.handler.GetBalance(receiver.AccAddr, is.bondDenom) + balRes, err := is.handler.GetBalanceFromBank(receiver.AccAddr, is.bondDenom) Expect(err).To(BeNil()) denomInitialBalance := balRes.Balance - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderInitialBalance := balRes.Balance @@ -460,17 +464,17 @@ var _ = Describe("ERC20 Extension -", func() { Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "failed to advance block") - balRes, err = is.handler.GetBalance(receiver.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(receiver.AccAddr, is.bondDenom) Expect(err).To(BeNil()) denomFinalBalance := balRes.Balance Expect(denomFinalBalance.Amount).To(Equal(denomInitialBalance.Amount.Add(math.NewInt(amountToSend.Int64())))) - balRes, err = is.handler.GetBalance(revertContractAddr.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(revertContractAddr.Bytes(), is.bondDenom) Expect(err).To(BeNil()) contractBalance := balRes.Balance Expect(contractBalance.Amount).To(Equal(math.ZeroInt())) - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderFinalBalance := balRes.Balance denomSpent := fees.Add(math.NewIntFromBigInt(amountToSend)) @@ -481,10 +485,10 @@ var _ = Describe("ERC20 Extension -", func() { sender := is.keyring.GetKey(0) receiver := is.keyring.GetAddr(1) amountToSend := big.NewInt(100) - balRes, err := is.handler.GetBalance(receiver.Bytes(), is.bondDenom) + balRes, err := is.handler.GetBalanceFromBank(receiver.Bytes(), is.bondDenom) Expect(err).To(BeNil()) denomInitialBalance := balRes.Balance - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderInitialBalance := balRes.Balance @@ -504,17 +508,17 @@ var _ = Describe("ERC20 Extension -", func() { fees := math.NewIntFromBigInt(gasPrice).MulRaw(res.GasUsed) // contract balance should remain unchanged - balRes, err = is.handler.GetBalance(receiver.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(receiver.Bytes(), is.bondDenom) Expect(err).To(BeNil()) denomFinalBalance := balRes.Balance Expect(denomFinalBalance.Amount).To(Equal(denomInitialBalance.Amount)) - balRes, err = is.handler.GetBalance(revertContractAddr.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(revertContractAddr.Bytes(), is.bondDenom) Expect(err).To(BeNil()) contractBalance := balRes.Balance Expect(contractBalance.Amount).To(Equal(math.ZeroInt())) - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderFinalBalance := balRes.Balance Expect(senderFinalBalance.Amount).To(Equal(senderInitialBalance.Amount.Sub(fees))) @@ -526,10 +530,10 @@ var _ = Describe("ERC20 Extension -", func() { sender := is.keyring.GetKey(0) receiver := is.keyring.GetAddr(1) totalToSend := int64(350) - balRes, err := is.handler.GetBalance(receiver.Bytes(), is.bondDenom) + balRes, err := is.handler.GetBalanceFromBank(receiver.Bytes(), is.bondDenom) Expect(err).To(BeNil()) denomInitialBalance := balRes.Balance - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderInitialBalance := balRes.Balance @@ -553,17 +557,17 @@ var _ = Describe("ERC20 Extension -", func() { fees := math.NewIntFromBigInt(gasPrice).MulRaw(res.GasUsed) // contract balance should remain unchanged - balRes, err = is.handler.GetBalance(receiver.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(receiver.Bytes(), is.bondDenom) Expect(err).To(BeNil()) denomFinalBalance := balRes.Balance Expect(denomFinalBalance.Amount).To(Equal(denomInitialBalance.Amount.Add(math.NewInt(totalToSend)))) - balRes, err = is.handler.GetBalance(revertContractAddr.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(revertContractAddr.Bytes(), is.bondDenom) Expect(err).To(BeNil()) contractBalance := balRes.Balance Expect(contractBalance.Amount).To(Equal(math.ZeroInt())) - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderFinalBalance := balRes.Balance denomSpent := fees.AddRaw(totalToSend) @@ -573,10 +577,10 @@ var _ = Describe("ERC20 Extension -", func() { DescribeTable("it should revert token transfer and send from WEVMOS contract", func(before bool, after bool) { sender := is.keyring.GetKey(0) receiver := is.keyring.GetAddr(1) - balRes, err := is.handler.GetBalance(receiver.Bytes(), is.bondDenom) + balRes, err := is.handler.GetBalanceFromBank(receiver.Bytes(), is.bondDenom) Expect(err).To(BeNil()) denomInitialBalance := balRes.Balance - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderInitialBalance := balRes.Balance @@ -597,17 +601,17 @@ var _ = Describe("ERC20 Extension -", func() { fees := math.NewIntFromBigInt(gasPrice).MulRaw(res.GasUsed) // contract balance should remain unchanged - balRes, err = is.handler.GetBalance(receiver.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(receiver.Bytes(), is.bondDenom) Expect(err).To(BeNil()) denomFinalBalance := balRes.Balance Expect(denomFinalBalance.Amount).To(Equal(denomInitialBalance.Amount)) - balRes, err = is.handler.GetBalance(revertContractAddr.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(revertContractAddr.Bytes(), is.bondDenom) Expect(err).To(BeNil()) contractBalance := balRes.Balance Expect(contractBalance.Amount).To(Equal(math.ZeroInt())) - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderFinalBalance := balRes.Balance Expect(senderFinalBalance.Amount).To(Equal(senderInitialBalance.Amount.Sub(fees))) @@ -619,10 +623,10 @@ var _ = Describe("ERC20 Extension -", func() { sender := is.keyring.GetKey(0) receiver := is.keyring.GetAddr(1) amountToSend := big.NewInt(100) - balRes, err := is.handler.GetBalance(receiver.Bytes(), is.bondDenom) + balRes, err := is.handler.GetBalanceFromBank(receiver.Bytes(), is.bondDenom) Expect(err).To(BeNil()) denomInitialBalance := balRes.Balance - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderInitialBalance := balRes.Balance @@ -642,17 +646,17 @@ var _ = Describe("ERC20 Extension -", func() { Expect(is.network.NextBlock()).To(BeNil()) fees := math.NewIntFromBigInt(gasPrice).MulRaw(res.GasUsed) - balRes, err = is.handler.GetBalance(receiver.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(receiver.Bytes(), is.bondDenom) Expect(err).To(BeNil()) denomFinalBalance := balRes.Balance Expect(denomFinalBalance.Amount).To(Equal(denomInitialBalance.Amount.Add(math.NewInt(amountToSend.Int64())))) - balRes, err = is.handler.GetBalance(revertContractAddr.Bytes(), is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(revertContractAddr.Bytes(), is.bondDenom) Expect(err).To(BeNil()) contractBalance := balRes.Balance Expect(contractBalance.Amount.Int64()).To(Equal(amountToSend.Int64())) - balRes, err = is.handler.GetBalance(sender.AccAddr, is.bondDenom) + balRes, err = is.handler.GetBalanceFromBank(sender.AccAddr, is.bondDenom) Expect(err).To(BeNil()) senderFinalBalance := balRes.Balance denomSpent := fees.AddRaw(amountToSend.Int64() + amountToSend.Int64()) @@ -1146,7 +1150,7 @@ var _ = Describe("ERC20 Extension -", func() { DescribeTable("it should return zero if balance only exists for other tokens", func(callType CallType) { sender := is.keyring.GetKey(0) address := utiltx.GenerateAddress() - fundCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetDenom(), 100)} + fundCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetBaseDenom(), 100)} // Fund account with some tokens err := is.factory.FundAccount(is.keyring.GetKey(0), sender.AccAddr, fundCoins) @@ -1286,7 +1290,7 @@ var _ = Describe("ERC20 Extension -", func() { DescribeTable("it should return zero if an allowance exists for other tokens", func(callType CallType) { grantee := is.keyring.GetKey(1) granter := is.keyring.GetKey(0) - authzCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetDenom(), 100)} + authzCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetBaseDenom(), 100)} is.setupSendAuthz(grantee.AccAddr, granter.Priv, authzCoins) @@ -1417,7 +1421,7 @@ var _ = Describe("ERC20 Extension -", func() { DescribeTable("it should add a new spend limit to an existing allowance with a different token", func(callType CallType) { grantee := is.keyring.GetKey(1) granter := is.keyring.GetKey(0) - bondCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetDenom(), 200)} + bondCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetBaseDenom(), 200)} tokenCoins := sdk.Coins{sdk.NewInt64Coin(is.tokenDenom, 100)} // set up a previous authorization @@ -1448,7 +1452,7 @@ var _ = Describe("ERC20 Extension -", func() { DescribeTable("it should set the new spend limit for an existing allowance with the same token", func(callType CallType) { grantee := is.keyring.GetKey(1) granter := is.keyring.GetKey(0) - bondCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetDenom(), 200)} + bondCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetBaseDenom(), 200)} tokenCoins := sdk.Coins{sdk.NewInt64Coin(is.tokenDenom, 100)} doubleTokenCoin := sdk.NewInt64Coin(is.tokenDenom, 200) @@ -1479,7 +1483,7 @@ var _ = Describe("ERC20 Extension -", func() { DescribeTable("it should remove the token from the spend limit of an existing authorization when approving zero", func(callType CallType) { grantee := is.keyring.GetKey(1) granter := is.keyring.GetKey(0) - bondCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetDenom(), 200)} + bondCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetBaseDenom(), 200)} tokenCoin := sdk.NewInt64Coin(is.tokenDenom, 100) // set up a previous authorization @@ -1631,7 +1635,7 @@ var _ = Describe("ERC20 Extension -", func() { DescribeTable("it should return an error if approving 0 and allowance only exists for other tokens", func(callType CallType) { grantee := is.keyring.GetKey(1) granter := is.keyring.GetKey(0) - bondCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetDenom(), 200)} + bondCoins := sdk.Coins{sdk.NewInt64Coin(is.network.GetBaseDenom(), 200)} // set up a previous authorization is.setupSendAuthz(grantee.AccAddr, granter.Priv, bondCoins) @@ -2288,7 +2292,7 @@ var _ = Describe("ERC20 Extension -", func() { var bondCoins sdk.Coins BeforeEach(func() { - bondCoins = sdk.Coins{sdk.NewInt64Coin(is.network.GetDenom(), 200)} + bondCoins = sdk.Coins{sdk.NewInt64Coin(is.network.GetBaseDenom(), 200)} is.setupSendAuthz(grantee.AccAddr, granter.Priv, bondCoins) }) @@ -2345,7 +2349,7 @@ var _ = Describe("ERC20 Extension -", func() { BeforeEach(func() { authzCoins = sdk.NewCoins( - sdk.NewInt64Coin(is.network.GetDenom(), 100), + sdk.NewInt64Coin(is.network.GetBaseDenom(), 100), sdk.NewInt64Coin(is.tokenDenom, 200), ) @@ -2428,7 +2432,7 @@ var _ = Describe("ERC20 Extension -", func() { Expect(err).ToNot(HaveOccurred(), "error on NextBlock call") // Check that only the spend limit in the network denomination remains - bondDenom := is.network.GetDenom() + bondDenom := is.network.GetBaseDenom() expCoins := sdk.Coins{sdk.NewCoin(bondDenom, authzCoins.AmountOf(bondDenom))} is.ExpectSendAuthzForContract(callType, contractsData, grantee.Addr, granter.Addr, expCoins) }, diff --git a/precompiles/erc20/query.go b/precompiles/erc20/query.go index ebdabcd4..f9c269c7 100644 --- a/precompiles/erc20/query.go +++ b/precompiles/erc20/query.go @@ -51,7 +51,7 @@ func (p Precompile) Name( method *abi.Method, _ []interface{}, ) ([]byte, error) { - metadata, found := p.bankKeeper.GetDenomMetaData(ctx, p.tokenPair.Denom) + metadata, found := p.BankKeeper.GetDenomMetaData(ctx, p.tokenPair.Denom) if found { return method.Outputs.Pack(metadata.Name) } @@ -75,7 +75,7 @@ func (p Precompile) Symbol( method *abi.Method, _ []interface{}, ) ([]byte, error) { - metadata, found := p.bankKeeper.GetDenomMetaData(ctx, p.tokenPair.Denom) + metadata, found := p.BankKeeper.GetDenomMetaData(ctx, p.tokenPair.Denom) if found { return method.Outputs.Pack(metadata.Symbol) } @@ -99,7 +99,7 @@ func (p Precompile) Decimals( method *abi.Method, _ []interface{}, ) ([]byte, error) { - metadata, found := p.bankKeeper.GetDenomMetaData(ctx, p.tokenPair.Denom) + metadata, found := p.BankKeeper.GetDenomMetaData(ctx, p.tokenPair.Denom) if !found { denomTrace, err := ibc.GetDenomTrace(p.transferKeeper, ctx, p.tokenPair.Denom) if err != nil { @@ -152,7 +152,7 @@ func (p Precompile) TotalSupply( method *abi.Method, _ []interface{}, ) ([]byte, error) { - supply := p.bankKeeper.GetSupply(ctx, p.tokenPair.Denom) + supply := p.BankKeeper.GetSupply(ctx, p.tokenPair.Denom) return method.Outputs.Pack(supply.Amount.BigInt()) } @@ -171,7 +171,7 @@ func (p Precompile) BalanceOf( return nil, err } - balance := p.bankKeeper.GetBalance(ctx, account.Bytes(), p.tokenPair.Denom) + balance := p.BankKeeper.GetBalance(ctx, account.Bytes(), p.tokenPair.Denom) return method.Outputs.Pack(balance.Amount.BigInt()) } diff --git a/precompiles/erc20/query_test.go b/precompiles/erc20/query_test.go index a8addbc1..b2bd46ae 100644 --- a/precompiles/erc20/query_test.go +++ b/precompiles/erc20/query_test.go @@ -185,8 +185,6 @@ func (s *PrecompileTestSuite) TestNameSymbol() { } for _, tc := range testcases { - tc := tc - s.Run(tc.name, func() { s.SetupTest() @@ -334,8 +332,6 @@ func (s *PrecompileTestSuite) TestDecimals() { } for _, tc := range testcases { - tc := tc - s.Run(tc.name, func() { s.SetupTest() @@ -387,8 +383,6 @@ func (s *PrecompileTestSuite) TestTotalSupply() { } for _, tc := range testcases { - tc := tc - s.Run(tc.name, func() { s.SetupTest() @@ -467,8 +461,6 @@ func (s *PrecompileTestSuite) TestBalanceOf() { } for _, tc := range testcases { - tc := tc - s.Run(tc.name, func() { s.SetupTest() @@ -569,8 +561,6 @@ func (s *PrecompileTestSuite) TestAllowance() { } for _, tc := range testcases { - tc := tc - s.Run(tc.name, func() { s.SetupTest() diff --git a/precompiles/erc20/tx.go b/precompiles/erc20/tx.go index 893e2857..c94f25d3 100644 --- a/precompiles/erc20/tx.go +++ b/precompiles/erc20/tx.go @@ -14,9 +14,9 @@ import ( banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" - chainconfig "github.com/evmos/os/example_chain/osd/config" cmn "github.com/evmos/os/precompiles/common" "github.com/evmos/os/x/evm/core/vm" + evmtypes "github.com/evmos/os/x/evm/types" ) const ( @@ -93,7 +93,7 @@ func (p *Precompile) transfer( var prevAllowance *big.Int if ownerIsSpender { - msgSrv := bankkeeper.NewMsgServerImpl(p.bankKeeper) + msgSrv := bankkeeper.NewMsgServerImpl(p.BankKeeper) _, err = msgSrv.Send(ctx, msg) } else { _, _, prevAllowance, err = GetAuthzExpirationAndAllowance(p.AuthzKeeper, ctx, spenderAddr, from, p.tokenPair.Denom) @@ -110,13 +110,11 @@ func (p *Precompile) transfer( return nil, err } - // TODO: is this the correct denom? It was hardcoded to testconstants.ExampleAttoDenom before.. - // evmDenom := p.evmKeeper.GetParams(ctx).EvmDenom - // TODO: when using the Evm denomiation here there is an import cycle - how to handle this, we should get the EVM denom here - evmDenom := chainconfig.BaseDenom + evmDenom := evmtypes.GetEVMCoinDenom() if p.tokenPair.Denom == evmDenom { - p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(from, msg.Amount.AmountOf(evmDenom).BigInt(), cmn.Sub), - cmn.NewBalanceChangeEntry(to, msg.Amount.AmountOf(evmDenom).BigInt(), cmn.Add)) + convertedAmount := evmtypes.ConvertAmountTo18DecimalsBigInt(amount) + p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(from, convertedAmount, cmn.Sub), + cmn.NewBalanceChangeEntry(to, convertedAmount, cmn.Add)) } if err = p.EmitTransferEvent(ctx, stateDB, from, to, amount); err != nil { diff --git a/precompiles/erc20/tx_test.go b/precompiles/erc20/tx_test.go index afeea19f..67192601 100644 --- a/precompiles/erc20/tx_test.go +++ b/precompiles/erc20/tx_test.go @@ -85,7 +85,6 @@ func (s *PrecompileTestSuite) TestTransfer() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { s.SetupTest() stateDB := s.network.GetStateDB() @@ -237,7 +236,6 @@ func (s *PrecompileTestSuite) TestTransferFrom() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { s.SetupTest() ctx = s.network.GetContext() diff --git a/precompiles/erc20/types_test.go b/precompiles/erc20/types_test.go index b406219a..edf7461c 100644 --- a/precompiles/erc20/types_test.go +++ b/precompiles/erc20/types_test.go @@ -52,7 +52,6 @@ func (s *PrecompileTestSuite) TestParseTransferArgs() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { to, amount, err := erc20.ParseTransferArgs(tc.args) if tc.expPass { @@ -124,7 +123,6 @@ func (s *PrecompileTestSuite) TestParseTransferFromArgs() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { from, to, amount, err := erc20.ParseTransferFromArgs(tc.args) if tc.expPass { @@ -185,7 +183,6 @@ func (s *PrecompileTestSuite) TestParseApproveArgs() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { spender, amount, err := erc20.ParseApproveArgs(tc.args) if tc.expPass { @@ -244,7 +241,6 @@ func (s *PrecompileTestSuite) TestParseAllowanceArgs() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { owner, spender, err := erc20.ParseAllowanceArgs(tc.args) if tc.expPass { @@ -292,7 +288,6 @@ func (s *PrecompileTestSuite) TestParseBalanceOfArgs() { } for _, tc := range testcases { - tc := tc s.Run(tc.name, func() { account, err := erc20.ParseBalanceOfArgs(tc.args) if tc.expPass { diff --git a/precompiles/erc20/utils_test.go b/precompiles/erc20/utils_test.go index 0d673072..cbe2a9f1 100644 --- a/precompiles/erc20/utils_test.go +++ b/precompiles/erc20/utils_test.go @@ -245,7 +245,6 @@ func (is *IntegrationTestSuite) setupERC20Precompile(denom string, tokenPairs [] is.network.App.BankKeeper, is.network.App.AuthzKeeper, is.network.App.TransferKeeper, - is.network.App.EVMKeeper, ) Expect(err).ToNot(HaveOccurred(), "failed to set up %q erc20 precompile", tokenPair.Denom) @@ -263,7 +262,6 @@ func setupERC20PrecompileForTokenPair( unitNetwork.App.BankKeeper, unitNetwork.App.AuthzKeeper, unitNetwork.App.TransferKeeper, - is.network.App.EVMKeeper, ) if err != nil { return nil, errorsmod.Wrapf(err, "failed to create %q erc20 precompile", tokenPair.Denom) @@ -293,7 +291,6 @@ func setupNewERC20PrecompileForTokenPair( unitNetwork.App.BankKeeper, unitNetwork.App.AuthzKeeper, unitNetwork.App.TransferKeeper, - is.network.App.EVMKeeper, ) if err != nil { return nil, errorsmod.Wrapf(err, "failed to create %q erc20 precompile", tokenPair.Denom) @@ -376,7 +373,7 @@ type ExpectedBalance struct { func (is *IntegrationTestSuite) ExpectBalances(expBalances []ExpectedBalance) { for _, expBalance := range expBalances { for _, expCoin := range expBalance.expCoins { - coinBalance, err := is.handler.GetBalance(expBalance.address, expCoin.Denom) + coinBalance, err := is.handler.GetBalanceFromBank(expBalance.address, expCoin.Denom) Expect(err).ToNot(HaveOccurred(), "expected no error getting balance") Expect(coinBalance.Balance.Amount).To(Equal(expCoin.Amount), "expected different balance") } @@ -566,7 +563,7 @@ func (is *IntegrationTestSuite) fundWithTokens( Expect(is.network.NextBlock()).To(BeNil()) if balanceInBankMod { - balRes, err := is.handler.GetBalance(receiver.Bytes(), fundCoins.Denoms()[0]) + balRes, err := is.handler.GetBalanceFromBank(receiver.Bytes(), fundCoins.Denoms()[0]) Expect(err).To(BeNil()) receiverBalance = balRes.Balance.Amount } diff --git a/precompiles/gov/IGov.sol b/precompiles/gov/IGov.sol new file mode 100644 index 00000000..d3451520 --- /dev/null +++ b/precompiles/gov/IGov.sol @@ -0,0 +1,192 @@ +// SPDX-License-Identifier: LGPL-3.0-only +pragma solidity >=0.8.17; + +import "../common/Types.sol"; + +/// @dev The IGov contract's address. +address constant GOV_PRECOMPILE_ADDRESS = 0x0000000000000000000000000000000000000805; + +/// @dev The IGov contract's instance. +IGov constant GOV_CONTRACT = IGov(GOV_PRECOMPILE_ADDRESS); + +/** + * @dev VoteOption enumerates the valid vote options for a given governance proposal. + */ +enum VoteOption { + // Unspecified defines a no-op vote option. + Unspecified, + // Yes defines a yes vote option. + Yes, + // Abstain defines an abstain vote option. + Abstain, + // No defines a no vote option. + No, + // NoWithWeto defines a no with veto vote option. + NoWithWeto +} +/// @dev WeightedVote represents a vote on a governance proposal +struct WeightedVote { + uint64 proposalId; + address voter; + WeightedVoteOption[] options; + string metadata; +} + +/// @dev WeightedVoteOption represents a weighted vote option +struct WeightedVoteOption { + VoteOption option; + string weight; +} + +/// @dev DepositData represents information about a deposit on a proposal +struct DepositData { + uint64 proposalId; + address depositor; + Coin[] amount; +} + +/// @dev TallyResultData represents the tally result of a proposal +struct TallyResultData { + string yes; + string abstain; + string no; + string noWithVeto; +} + +/// @dev ProposalData represents a governance proposal +struct ProposalData { + uint64 id; + string[] messages; + uint32 status; + TallyResultData finalTallyResult; + uint64 submitTime; + uint64 depositEndTime; + Coin[] totalDeposit; + uint64 votingStartTime; + uint64 votingEndTime; + string metadata; + string title; + string summary; + address proposer; +} + +/// @author The Evmos Core Team +/// @title Gov Precompile Contract +/// @dev The interface through which solidity contracts will interact with Gov +interface IGov { + + /// @dev Vote defines an Event emitted when a proposal voted. + /// @param voter the address of the voter + /// @param proposalId the proposal of id + /// @param option the option for voter + event Vote(address indexed voter, uint64 proposalId, uint8 option); + + /// @dev VoteWeighted defines an Event emitted when a proposal voted. + /// @param voter the address of the voter + /// @param proposalId the proposal of id + /// @param options the options for voter + event VoteWeighted(address indexed voter, uint64 proposalId, WeightedVoteOption[] options); + + /// TRANSACTIONS + + /// @dev vote defines a method to add a vote on a specific proposal. + /// @param voter The address of the voter + /// @param proposalId the proposal of id + /// @param option the option for voter + /// @param metadata the metadata for voter send + /// @return success Whether the transaction was successful or not + function vote( + address voter, + uint64 proposalId, + VoteOption option, + string memory metadata + ) external returns (bool success); + + /// @dev voteWeighted defines a method to add a vote on a specific proposal. + /// @param voter The address of the voter + /// @param proposalId The proposal id + /// @param options The options for voter + /// @param metadata The metadata for voter send + /// @return success Whether the transaction was successful or not + function voteWeighted( + address voter, + uint64 proposalId, + WeightedVoteOption[] calldata options, + string memory metadata + ) external returns (bool success); + + /// QUERIES + + /// @dev getVote returns the vote of a single voter for a + /// given proposalId. + /// @param proposalId The proposal id + /// @param voter The voter on the proposal + /// @return vote Voter's vote for the proposal + function getVote( + uint64 proposalId, + address voter + ) external view returns (WeightedVote memory vote); + + /// @dev getVotes Returns the votes for a specific proposal. + /// @param proposalId The proposal id + /// @param pagination The pagination options + /// @return votes The votes for the proposal + /// @return pageResponse The pagination information + function getVotes( + uint64 proposalId, + PageRequest calldata pagination + ) + external + view + returns (WeightedVote[] memory votes, PageResponse memory pageResponse); + + /// @dev getDeposit returns the deposit of a single depositor for a given proposalId. + /// @param proposalId The proposal id + /// @param depositor The address of the depositor + /// @return deposit The deposit information + function getDeposit( + uint64 proposalId, + address depositor + ) external view returns (DepositData memory deposit); + + /// @dev getDeposits returns all deposits for a specific proposal. + /// @param proposalId The proposal id + /// @param pagination The pagination options + /// @return deposits The deposits for the proposal + /// @return pageResponse The pagination information + function getDeposits( + uint64 proposalId, + PageRequest calldata pagination + ) + external + view + returns (DepositData[] memory deposits, PageResponse memory pageResponse); + + /// @dev getTallyResult returns the tally result of a proposal. + /// @param proposalId The proposal id + /// @return tallyResult The tally result of the proposal + function getTallyResult( + uint64 proposalId + ) external view returns (TallyResultData memory tallyResult); + + /// @dev getProposal returns the proposal details based on proposal id. + /// @param proposalId The proposal id + /// @return proposal The proposal data + function getProposal( + uint64 proposalId + ) external view returns (ProposalData memory proposal); + + /// @dev getProposals returns proposals with matching status. + /// @param proposalStatus The proposal status to filter by + /// @param voter The voter address to filter by, if any + /// @param depositor The depositor address to filter by, if any + /// @param pagination The pagination config + /// @return proposals The proposals matching the filter criteria + /// @return pageResponse The pagination information + function getProposals( + uint32 proposalStatus, + address voter, + address depositor, + PageRequest calldata pagination + ) external view returns (ProposalData[] memory proposals, PageResponse memory pageResponse); +} diff --git a/precompiles/gov/abi.json b/precompiles/gov/abi.json new file mode 100644 index 00000000..8a24e8cb --- /dev/null +++ b/precompiles/gov/abi.json @@ -0,0 +1,803 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "IGov", + "sourceName": "solidity/precompiles/gov/IGov.sol", + "abi": [ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "voter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "indexed": false, + "internalType": "uint8", + "name": "option", + "type": "uint8" + } + ], + "name": "Vote", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "voter", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "components": [ + { + "internalType": "enum VoteOption", + "name": "option", + "type": "uint8" + }, + { + "internalType": "string", + "name": "weight", + "type": "string" + } + ], + "indexed": false, + "internalType": "struct WeightedVoteOption[]", + "name": "options", + "type": "tuple[]" + } + ], + "name": "VoteWeighted", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "internalType": "address", + "name": "depositor", + "type": "address" + } + ], + "name": "getDeposit", + "outputs": [ + { + "components": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "internalType": "address", + "name": "depositor", + "type": "address" + }, + { + "components": [ + { + "internalType": "string", + "name": "denom", + "type": "string" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct Coin[]", + "name": "amount", + "type": "tuple[]" + } + ], + "internalType": "struct DepositData", + "name": "deposit", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "components": [ + { + "internalType": "bytes", + "name": "key", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "offset", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "limit", + "type": "uint64" + }, + { + "internalType": "bool", + "name": "countTotal", + "type": "bool" + }, + { + "internalType": "bool", + "name": "reverse", + "type": "bool" + } + ], + "internalType": "struct PageRequest", + "name": "pagination", + "type": "tuple" + } + ], + "name": "getDeposits", + "outputs": [ + { + "components": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "internalType": "address", + "name": "depositor", + "type": "address" + }, + { + "components": [ + { + "internalType": "string", + "name": "denom", + "type": "string" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct Coin[]", + "name": "amount", + "type": "tuple[]" + } + ], + "internalType": "struct DepositData[]", + "name": "deposits", + "type": "tuple[]" + }, + { + "components": [ + { + "internalType": "bytes", + "name": "nextKey", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "total", + "type": "uint64" + } + ], + "internalType": "struct PageResponse", + "name": "pageResponse", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + } + ], + "name": "getProposal", + "outputs": [ + { + "components": [ + { + "internalType": "uint64", + "name": "id", + "type": "uint64" + }, + { + "internalType": "string[]", + "name": "messages", + "type": "string[]" + }, + { + "internalType": "uint32", + "name": "status", + "type": "uint32" + }, + { + "components": [ + { + "internalType": "string", + "name": "yes", + "type": "string" + }, + { + "internalType": "string", + "name": "abstain", + "type": "string" + }, + { + "internalType": "string", + "name": "no", + "type": "string" + }, + { + "internalType": "string", + "name": "noWithVeto", + "type": "string" + } + ], + "internalType": "struct TallyResultData", + "name": "finalTallyResult", + "type": "tuple" + }, + { + "internalType": "uint64", + "name": "submitTime", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "depositEndTime", + "type": "uint64" + }, + { + "components": [ + { + "internalType": "string", + "name": "denom", + "type": "string" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct Coin[]", + "name": "totalDeposit", + "type": "tuple[]" + }, + { + "internalType": "uint64", + "name": "votingStartTime", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "votingEndTime", + "type": "uint64" + }, + { + "internalType": "string", + "name": "metadata", + "type": "string" + }, + { + "internalType": "string", + "name": "title", + "type": "string" + }, + { + "internalType": "string", + "name": "summary", + "type": "string" + }, + { + "internalType": "address", + "name": "proposer", + "type": "address" + } + ], + "internalType": "struct ProposalData", + "name": "proposal", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint32", + "name": "proposalStatus", + "type": "uint32" + }, + { + "internalType": "address", + "name": "voter", + "type": "address" + }, + { + "internalType": "address", + "name": "depositor", + "type": "address" + }, + { + "components": [ + { + "internalType": "bytes", + "name": "key", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "offset", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "limit", + "type": "uint64" + }, + { + "internalType": "bool", + "name": "countTotal", + "type": "bool" + }, + { + "internalType": "bool", + "name": "reverse", + "type": "bool" + } + ], + "internalType": "struct PageRequest", + "name": "pagination", + "type": "tuple" + } + ], + "name": "getProposals", + "outputs": [ + { + "components": [ + { + "internalType": "uint64", + "name": "id", + "type": "uint64" + }, + { + "internalType": "string[]", + "name": "messages", + "type": "string[]" + }, + { + "internalType": "uint32", + "name": "status", + "type": "uint32" + }, + { + "components": [ + { + "internalType": "string", + "name": "yes", + "type": "string" + }, + { + "internalType": "string", + "name": "abstain", + "type": "string" + }, + { + "internalType": "string", + "name": "no", + "type": "string" + }, + { + "internalType": "string", + "name": "noWithVeto", + "type": "string" + } + ], + "internalType": "struct TallyResultData", + "name": "finalTallyResult", + "type": "tuple" + }, + { + "internalType": "uint64", + "name": "submitTime", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "depositEndTime", + "type": "uint64" + }, + { + "components": [ + { + "internalType": "string", + "name": "denom", + "type": "string" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct Coin[]", + "name": "totalDeposit", + "type": "tuple[]" + }, + { + "internalType": "uint64", + "name": "votingStartTime", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "votingEndTime", + "type": "uint64" + }, + { + "internalType": "string", + "name": "metadata", + "type": "string" + }, + { + "internalType": "string", + "name": "title", + "type": "string" + }, + { + "internalType": "string", + "name": "summary", + "type": "string" + }, + { + "internalType": "address", + "name": "proposer", + "type": "address" + } + ], + "internalType": "struct ProposalData[]", + "name": "proposals", + "type": "tuple[]" + }, + { + "components": [ + { + "internalType": "bytes", + "name": "nextKey", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "total", + "type": "uint64" + } + ], + "internalType": "struct PageResponse", + "name": "pageResponse", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + } + ], + "name": "getTallyResult", + "outputs": [ + { + "components": [ + { + "internalType": "string", + "name": "yes", + "type": "string" + }, + { + "internalType": "string", + "name": "abstain", + "type": "string" + }, + { + "internalType": "string", + "name": "no", + "type": "string" + }, + { + "internalType": "string", + "name": "noWithVeto", + "type": "string" + } + ], + "internalType": "struct TallyResultData", + "name": "tallyResult", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "internalType": "address", + "name": "voter", + "type": "address" + } + ], + "name": "getVote", + "outputs": [ + { + "components": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "internalType": "address", + "name": "voter", + "type": "address" + }, + { + "components": [ + { + "internalType": "enum VoteOption", + "name": "option", + "type": "uint8" + }, + { + "internalType": "string", + "name": "weight", + "type": "string" + } + ], + "internalType": "struct WeightedVoteOption[]", + "name": "options", + "type": "tuple[]" + }, + { + "internalType": "string", + "name": "metadata", + "type": "string" + } + ], + "internalType": "struct WeightedVote", + "name": "vote", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "components": [ + { + "internalType": "bytes", + "name": "key", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "offset", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "limit", + "type": "uint64" + }, + { + "internalType": "bool", + "name": "countTotal", + "type": "bool" + }, + { + "internalType": "bool", + "name": "reverse", + "type": "bool" + } + ], + "internalType": "struct PageRequest", + "name": "pagination", + "type": "tuple" + } + ], + "name": "getVotes", + "outputs": [ + { + "components": [ + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "internalType": "address", + "name": "voter", + "type": "address" + }, + { + "components": [ + { + "internalType": "enum VoteOption", + "name": "option", + "type": "uint8" + }, + { + "internalType": "string", + "name": "weight", + "type": "string" + } + ], + "internalType": "struct WeightedVoteOption[]", + "name": "options", + "type": "tuple[]" + }, + { + "internalType": "string", + "name": "metadata", + "type": "string" + } + ], + "internalType": "struct WeightedVote[]", + "name": "votes", + "type": "tuple[]" + }, + { + "components": [ + { + "internalType": "bytes", + "name": "nextKey", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "total", + "type": "uint64" + } + ], + "internalType": "struct PageResponse", + "name": "pageResponse", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "voter", + "type": "address" + }, + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "internalType": "enum VoteOption", + "name": "option", + "type": "uint8" + }, + { + "internalType": "string", + "name": "metadata", + "type": "string" + } + ], + "name": "vote", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "voter", + "type": "address" + }, + { + "internalType": "uint64", + "name": "proposalId", + "type": "uint64" + }, + { + "components": [ + { + "internalType": "enum VoteOption", + "name": "option", + "type": "uint8" + }, + { + "internalType": "string", + "name": "weight", + "type": "string" + } + ], + "internalType": "struct WeightedVoteOption[]", + "name": "options", + "type": "tuple[]" + }, + { + "internalType": "string", + "name": "metadata", + "type": "string" + } + ], + "name": "voteWeighted", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": "0x", + "deployedBytecode": "0x", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/precompiles/gov/errors.go b/precompiles/gov/errors.go new file mode 100644 index 00000000..a3eef158 --- /dev/null +++ b/precompiles/gov/errors.go @@ -0,0 +1,28 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +package gov + +const ( + // ErrDifferentOrigin is raised when the origin address is not the same as the voter address. + ErrDifferentOrigin = "tx origin address %s does not match the voter address %s" + // ErrInvalidVoter is raised when the voter address is not valid. + ErrInvalidVoter = "invalid voter address: %s" + // ErrInvalidProposalID invalid proposal id. + ErrInvalidProposalID = "invalid proposal id %d " + // ErrInvalidPageRequest invalid page request. + ErrInvalidPageRequest = "invalid page request" + // ErrInvalidOption invalid option. + ErrInvalidOption = "invalid option %s " + // ErrInvalidMetadata invalid metadata. + ErrInvalidMetadata = "invalid metadata %s " + // ErrInvalidWeightedVoteOptions invalid weighted vote options. + ErrInvalidWeightedVoteOptions = "invalid weighted vote options %s " + // ErrInvalidWeightedVoteOption invalid weighted vote option. + ErrInvalidWeightedVoteOption = "invalid weighted vote option %s " + // ErrInvalidWeightedVoteOptionType invalid weighted vote option type. + ErrInvalidWeightedVoteOptionType = "invalid weighted vote option type %s " + // ErrInvalidWeightedVoteOptionWeight invalid weighted vote option weight. + ErrInvalidWeightedVoteOptionWeight = "invalid weighted vote option weight %s " + // ErrInvalidDepositor invalid depositor. + ErrInvalidDepositor = "invalid depositor %s " +) diff --git a/precompiles/gov/events.go b/precompiles/gov/events.go new file mode 100644 index 00000000..08b7a41f --- /dev/null +++ b/precompiles/gov/events.go @@ -0,0 +1,85 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package gov + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + ethtypes "github.com/ethereum/go-ethereum/core/types" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/x/evm/core/vm" +) + +const ( + // EventTypeVote defines the event type for the gov VoteMethod transaction. + EventTypeVote = "Vote" + // EventTypeVoteWeighted defines the event type for the gov VoteWeightedMethod transaction. + EventTypeVoteWeighted = "VoteWeighted" +) + +// EmitVoteEvent creates a new event emitted on a Vote transaction. +func (p Precompile) EmitVoteEvent(ctx sdk.Context, stateDB vm.StateDB, voterAddress common.Address, proposalID uint64, option int32) error { + // Prepare the event topics + event := p.ABI.Events[EventTypeVote] + topics := make([]common.Hash, 2) + + // The first topic is always the signature of the event. + topics[0] = event.ID + + var err error + topics[1], err = cmn.MakeTopic(voterAddress) + if err != nil { + return err + } + + // Prepare the event data + arguments := abi.Arguments{event.Inputs[1], event.Inputs[2]} + packed, err := arguments.Pack(proposalID, uint8(option)) //nolint:gosec // G115 + if err != nil { + return err + } + + stateDB.AddLog(ðtypes.Log{ + Address: p.Address(), + Topics: topics, + Data: packed, + BlockNumber: uint64(ctx.BlockHeight()), //nolint:gosec // G115 + }) + + return nil +} + +// EmitVoteWeightedEvent creates a new event emitted on a VoteWeighted transaction. +func (p Precompile) EmitVoteWeightedEvent(ctx sdk.Context, stateDB vm.StateDB, voterAddress common.Address, proposalID uint64, options WeightedVoteOptions) error { + // Prepare the event topics + event := p.ABI.Events[EventTypeVoteWeighted] + topics := make([]common.Hash, 2) + + // The first topic is always the signature of the event. + topics[0] = event.ID + + var err error + topics[1], err = cmn.MakeTopic(voterAddress) + if err != nil { + return err + } + + // Prepare the event data + arguments := abi.Arguments{event.Inputs[1], event.Inputs[2]} + packed, err := arguments.Pack(proposalID, options) + if err != nil { + return err + } + + stateDB.AddLog(ðtypes.Log{ + Address: p.Address(), + Topics: topics, + Data: packed, + BlockNumber: uint64(ctx.BlockHeight()), //nolint:gosec // G115 + }) + + return nil +} diff --git a/precompiles/gov/events_test.go b/precompiles/gov/events_test.go new file mode 100644 index 00000000..f434436c --- /dev/null +++ b/precompiles/gov/events_test.go @@ -0,0 +1,167 @@ +package gov_test + +import ( + "math/big" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/crypto" + + storetypes "cosmossdk.io/store/types" + sdk "github.com/cosmos/cosmos-sdk/types" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/precompiles/gov" + "github.com/evmos/os/x/evm/core/vm" + "github.com/evmos/os/x/evm/statedb" +) + +func (s *PrecompileTestSuite) TestVoteEvent() { + var ( + stDB *statedb.StateDB + ctx sdk.Context + method = s.precompile.Methods[gov.VoteMethod] + ) + + testCases := []struct { + name string + malleate func(voter common.Address, proposalId uint64, option uint8, metadata string) []interface{} + postCheck func() + gas uint64 + expError bool + errContains string + }{ + { + "success - the correct event is emitted", + func(voter common.Address, proposalId uint64, option uint8, metadata string) []interface{} { + return []interface{}{ + voter, + proposalId, + option, + metadata, + } + }, + func() { + log := stDB.Logs()[0] + s.Require().Equal(log.Address, s.precompile.Address()) + + // Check event signature matches the one emitted + event := s.precompile.ABI.Events[gov.EventTypeVote] + s.Require().Equal(crypto.Keccak256Hash([]byte(event.Sig)), common.HexToHash(log.Topics[0].Hex())) + s.Require().Equal(log.BlockNumber, uint64(ctx.BlockHeight())) //nolint:gosec // G115 + + // Check the fully unpacked event matches the one emitted + var voteEvent gov.EventVote + err := cmn.UnpackLog(s.precompile.ABI, &voteEvent, gov.EventTypeVote, *log) + s.Require().NoError(err) + s.Require().Equal(s.keyring.GetAddr(0), voteEvent.Voter) + s.Require().Equal(uint64(1), voteEvent.ProposalId) + s.Require().Equal(uint8(1), voteEvent.Option) + }, + 20000, + false, + "", + }, + } + + for _, tc := range testCases { + s.SetupTest() + stDB = s.network.GetStateDB() + ctx = s.network.GetContext() + + contract := vm.NewContract(vm.AccountRef(s.keyring.GetAddr(0)), s.precompile, big.NewInt(0), tc.gas) + ctx = ctx.WithGasMeter(storetypes.NewInfiniteGasMeter()) + initialGas := ctx.GasMeter().GasConsumed() + s.Require().Zero(initialGas) + + _, err := s.precompile.Vote(ctx, s.keyring.GetAddr(0), contract, stDB, &method, tc.malleate(s.keyring.GetAddr(0), 1, 1, "metadata")) + + if tc.expError { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } else { + s.Require().NoError(err) + tc.postCheck() + } + } +} + +func (s *PrecompileTestSuite) TestVoteWeightedEvent() { + var ( + stDB *statedb.StateDB + ctx sdk.Context + method = s.precompile.Methods[gov.VoteWeightedMethod] + ) + + testCases := []struct { + name string + malleate func(voter common.Address, proposalId uint64, options gov.WeightedVoteOptions) []interface{} + postCheck func() + gas uint64 + expError bool + errContains string + }{ + { + "success - the correct VoteWeighted event is emitted", + func(voter common.Address, proposalId uint64, options gov.WeightedVoteOptions) []interface{} { + return []interface{}{ + voter, + proposalId, + options, + "", + } + }, + func() { + log := stDB.Logs()[0] + s.Require().Equal(log.Address, s.precompile.Address()) + + // Check event signature matches the one emitted + event := s.precompile.ABI.Events[gov.EventTypeVoteWeighted] + s.Require().Equal(crypto.Keccak256Hash([]byte(event.Sig)), common.HexToHash(log.Topics[0].Hex())) + s.Require().Equal(log.BlockNumber, uint64(ctx.BlockHeight())) //nolint:gosec // G115 + + // Check the fully unpacked event matches the one emitted + var voteWeightedEvent gov.EventVoteWeighted + err := cmn.UnpackLog(s.precompile.ABI, &voteWeightedEvent, gov.EventTypeVoteWeighted, *log) + s.Require().NoError(err) + s.Require().Equal(s.keyring.GetAddr(0), voteWeightedEvent.Voter) + s.Require().Equal(uint64(1), voteWeightedEvent.ProposalId) + s.Require().Equal(2, len(voteWeightedEvent.Options)) + s.Require().Equal(uint8(1), voteWeightedEvent.Options[0].Option) + s.Require().Equal("0.70", voteWeightedEvent.Options[0].Weight) + s.Require().Equal(uint8(2), voteWeightedEvent.Options[1].Option) + s.Require().Equal("0.30", voteWeightedEvent.Options[1].Weight) + }, + 20000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + stDB = s.network.GetStateDB() + ctx = s.network.GetContext() + + contract := vm.NewContract(vm.AccountRef(s.keyring.GetAddr(0)), s.precompile, big.NewInt(0), tc.gas) + ctx = ctx.WithGasMeter(storetypes.NewInfiniteGasMeter()) + initialGas := ctx.GasMeter().GasConsumed() + s.Require().Zero(initialGas) + + options := gov.WeightedVoteOptions{ + {Option: 1, Weight: "0.70"}, + {Option: 2, Weight: "0.30"}, + } + + _, err := s.precompile.VoteWeighted(ctx, s.keyring.GetAddr(0), contract, stDB, &method, tc.malleate(s.keyring.GetAddr(0), 1, options)) + + if tc.expError { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } else { + s.Require().NoError(err) + tc.postCheck() + } + }) + } +} diff --git a/precompiles/gov/gov.go b/precompiles/gov/gov.go new file mode 100644 index 00000000..ab9a20c9 --- /dev/null +++ b/precompiles/gov/gov.go @@ -0,0 +1,158 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package gov + +import ( + "embed" + "fmt" + + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" + sdk "github.com/cosmos/cosmos-sdk/types" + authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" + govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/x/evm/core/vm" + evmtypes "github.com/evmos/os/x/evm/types" +) + +var _ vm.PrecompiledContract = &Precompile{} + +// Embed abi json file to the executable binary. Needed when importing as dependency. +// +//go:embed abi.json +var f embed.FS + +// Precompile defines the precompiled contract for gov. +type Precompile struct { + cmn.Precompile + govKeeper govkeeper.Keeper +} + +// LoadABI loads the gov ABI from the embedded abi.json file +// for the gov precompile. +func LoadABI() (abi.ABI, error) { + return cmn.LoadABI(f, "abi.json") +} + +// NewPrecompile creates a new gov Precompile instance as a +// PrecompiledContract interface. +func NewPrecompile( + govKeeper govkeeper.Keeper, + authzKeeper authzkeeper.Keeper, +) (*Precompile, error) { + abi, err := LoadABI() + if err != nil { + return nil, err + } + + p := &Precompile{ + Precompile: cmn.Precompile{ + ABI: abi, + AuthzKeeper: authzKeeper, + KvGasConfig: storetypes.KVGasConfig(), + TransientKVGasConfig: storetypes.TransientGasConfig(), + ApprovalExpiration: cmn.DefaultExpirationDuration, // should be configurable in the future. + }, + govKeeper: govKeeper, + } + + // SetAddress defines the address of the gov precompiled contract. + p.SetAddress(common.HexToAddress(evmtypes.GovPrecompileAddress)) + + return p, nil +} + +// RequiredGas calculates the precompiled contract's base gas rate. +func (p Precompile) RequiredGas(input []byte) uint64 { + // NOTE: This check avoid panicking when trying to decode the method ID + if len(input) < 4 { + return 0 + } + methodID := input[:4] + + method, err := p.MethodById(methodID) + if err != nil { + // This should never happen since this method is going to fail during Run + return 0 + } + + return p.Precompile.RequiredGas(input, p.IsTransaction(method)) +} + +// Run executes the precompiled contract gov methods defined in the ABI. +func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz []byte, err error) { + ctx, stateDB, snapshot, method, initialGas, args, err := p.RunSetup(evm, contract, readOnly, p.IsTransaction) + if err != nil { + return nil, err + } + + // This handles any out of gas errors that may occur during the execution of a precompile tx or query. + // It avoids panics and returns the out of gas error so the EVM can continue gracefully. + defer cmn.HandleGasError(ctx, contract, initialGas, &err)() + + switch method.Name { + // gov transactions + case VoteMethod: + bz, err = p.Vote(ctx, evm.Origin, contract, stateDB, method, args) + case VoteWeightedMethod: + bz, err = p.VoteWeighted(ctx, evm.Origin, contract, stateDB, method, args) + // gov queries + case GetVoteMethod: + bz, err = p.GetVote(ctx, method, contract, args) + case GetVotesMethod: + bz, err = p.GetVotes(ctx, method, contract, args) + case GetDepositMethod: + bz, err = p.GetDeposit(ctx, method, contract, args) + case GetDepositsMethod: + bz, err = p.GetDeposits(ctx, method, contract, args) + case GetTallyResultMethod: + bz, err = p.GetTallyResult(ctx, method, contract, args) + case GetProposalMethod: + bz, err = p.GetProposal(ctx, method, contract, args) + case GetProposalsMethod: + bz, err = p.GetProposals(ctx, method, contract, args) + default: + return nil, fmt.Errorf(cmn.ErrUnknownMethod, method.Name) + } + + if err != nil { + return nil, err + } + + cost := ctx.GasMeter().GasConsumed() - initialGas + + if !contract.UseGas(cost) { + return nil, vm.ErrOutOfGas + } + + if err := p.AddJournalEntries(stateDB, snapshot); err != nil { + return nil, err + } + + return bz, nil +} + +// IsTransaction checks if the given method name corresponds to a transaction or query. +// +// Available gov transactions are: +// - Vote +// - VoteWeighted +func (Precompile) IsTransaction(method *abi.Method) bool { + switch method.Name { + case VoteMethod, VoteWeightedMethod: + return true + default: + return false + } +} + +// Logger returns a precompile-specific logger. +func (p Precompile) Logger(ctx sdk.Context) log.Logger { + return ctx.Logger().With("evm extension", "gov") +} diff --git a/precompiles/gov/gov_test.go b/precompiles/gov/gov_test.go new file mode 100644 index 00000000..5bc3cb30 --- /dev/null +++ b/precompiles/gov/gov_test.go @@ -0,0 +1,138 @@ +package gov_test + +import ( + "math/big" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + ethtypes "github.com/ethereum/go-ethereum/core/types" + + chainutil "github.com/evmos/os/example_chain/testutil" + "github.com/evmos/os/precompiles/gov" + "github.com/evmos/os/x/evm/core/vm" + "github.com/evmos/os/x/evm/statedb" + evmtypes "github.com/evmos/os/x/evm/types" +) + +func (s *PrecompileTestSuite) TestIsTransaction() { + testCases := []struct { + name string + method abi.Method + isTx bool + }{ + { + gov.VoteMethod, + s.precompile.Methods[gov.VoteMethod], + true, + }, + { + "invalid", + abi.Method{}, + false, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.Require().Equal(s.precompile.IsTransaction(&tc.method), tc.isTx) + }) + } +} + +// TestRun tests the precompile's Run method. +func (s *PrecompileTestSuite) TestRun() { + testcases := []struct { + name string + malleate func() (common.Address, []byte) + readOnly bool + expPass bool + errContains string + }{ + { + name: "pass - vote transaction", + malleate: func() (common.Address, []byte) { + const proposalID uint64 = 1 + const option uint8 = 1 + const metadata = "metadata" + + input, err := s.precompile.Pack( + gov.VoteMethod, + s.keyring.GetAddr(0), + proposalID, + option, + metadata, + ) + s.Require().NoError(err, "failed to pack input") + return s.keyring.GetAddr(0), input + }, + readOnly: false, + expPass: true, + }, + } + + for _, tc := range testcases { + s.Run(tc.name, func() { + // setup basic test suite + s.SetupTest() + ctx := s.network.GetContext() + + baseFee := s.network.App.EVMKeeper.GetBaseFee(ctx) + + // malleate testcase + caller, input := tc.malleate() + + contract := vm.NewPrecompile(vm.AccountRef(caller), s.precompile, big.NewInt(0), uint64(1e6)) + contract.Input = input + + contractAddr := contract.Address() + // Build and sign Ethereum transaction + txArgs := evmtypes.EvmTxArgs{ + ChainID: evmtypes.GetEthChainConfig().ChainID, + Nonce: 0, + To: &contractAddr, + Amount: nil, + GasLimit: 100000, + GasPrice: chainutil.ExampleMinGasPrices.BigInt(), + GasFeeCap: baseFee, + GasTipCap: big.NewInt(1), + Accesses: ðtypes.AccessList{}, + } + msg, err := s.factory.GenerateGethCoreMsg(s.keyring.GetPrivKey(0), txArgs) + s.Require().NoError(err) + + // Instantiate config + proposerAddress := ctx.BlockHeader().ProposerAddress + cfg, err := s.network.App.EVMKeeper.EVMConfig(ctx, proposerAddress) + s.Require().NoError(err, "failed to instantiate EVM config") + + // Instantiate EVM + headerHash := ctx.HeaderHash() + stDB := statedb.New( + ctx, + s.network.App.EVMKeeper, + statedb.NewEmptyTxConfig(common.BytesToHash(headerHash)), + ) + evm := s.network.App.EVMKeeper.NewEVM( + ctx, msg, cfg, nil, stDB, + ) + + precompiles, found, err := s.network.App.EVMKeeper.GetPrecompileInstance(ctx, contractAddr) + s.Require().NoError(err, "failed to instantiate precompile") + s.Require().True(found, "not found precompile") + evm.WithPrecompiles(precompiles.Map, precompiles.Addresses) + + // Run precompiled contract + bz, err := s.precompile.Run(evm, contract, tc.readOnly) + + // Check results + if tc.expPass { + s.Require().NoError(err, "expected no error when running the precompile") + s.Require().NotNil(bz, "expected returned bytes not to be nil") + } else { + s.Require().Error(err, "expected error to be returned when running the precompile") + s.Require().Nil(bz, "expected returned bytes to be nil") + s.Require().ErrorContains(err, tc.errContains) + } + }) + } +} diff --git a/precompiles/gov/integration_test.go b/precompiles/gov/integration_test.go new file mode 100644 index 00000000..79bdbb29 --- /dev/null +++ b/precompiles/gov/integration_test.go @@ -0,0 +1,662 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +package gov_test + +import ( + "math/big" + "testing" + + "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/types/query" + v1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" + "github.com/ethereum/go-ethereum/common" + "github.com/evmos/os/precompiles/gov" + "github.com/evmos/os/precompiles/testutil" + "github.com/evmos/os/testutil/integration/os/factory" + testutiltx "github.com/evmos/os/testutil/tx" + "github.com/evmos/os/x/evm/core/vm" + evmtypes "github.com/evmos/os/x/evm/types" + + //nolint:revive // dot imports are fine for Ginkgo + . "github.com/onsi/ginkgo/v2" + //nolint:revive // dot imports are fine for Ginkgo + . "github.com/onsi/gomega" +) + +// General variables used for integration tests +var ( + // differentAddr is an address generated for testing purposes that e.g. raises the different origin error + differentAddr = testutiltx.GenerateAddress() + // defaultCallArgs are the default arguments for calling the smart contract + // + // NOTE: this has to be populated in a BeforeEach block because the contractAddr would otherwise be a nil address. + callArgs factory.CallArgs + // txArgs are the EVM transaction arguments to use in the transactions + txArgs evmtypes.EvmTxArgs + // defaultLogCheck instantiates a log check arguments struct with the precompile ABI events populated. + defaultLogCheck testutil.LogCheckArgs + // passCheck defines the arguments to check if the precompile returns no error + passCheck testutil.LogCheckArgs + // outOfGasCheck defines the arguments to check if the precompile returns out of gas error + outOfGasCheck testutil.LogCheckArgs +) + +func TestKeeperIntegrationTestSuite(t *testing.T) { + // Run Ginkgo integration tests + RegisterFailHandler(Fail) + RunSpecs(t, "Keeper Suite") +} + +var _ = Describe("Calling governance precompile from EOA", func() { + var s *PrecompileTestSuite + const ( + proposalID uint64 = 1 + option uint8 = 1 + metadata = "metadata" + ) + BeforeEach(func() { + s = new(PrecompileTestSuite) + s.SetupTest() + + // set the default call arguments + callArgs = factory.CallArgs{ + ContractABI: s.precompile.ABI, + } + defaultLogCheck = testutil.LogCheckArgs{ + ABIEvents: s.precompile.ABI.Events, + } + passCheck = defaultLogCheck.WithExpPass(true) + outOfGasCheck = defaultLogCheck.WithErrContains(vm.ErrOutOfGas.Error()) + + // reset tx args each test to avoid keeping custom + // values of previous tests (e.g. gasLimit) + precompileAddr := s.precompile.Address() + txArgs = evmtypes.EvmTxArgs{ + To: &precompileAddr, + } + txArgs.GasLimit = 200_000 + }) + + // ===================================== + // TRANSACTIONS + // ===================================== + Describe("Execute Vote transaction", func() { + const method = gov.VoteMethod + + BeforeEach(func() { + // set the default call arguments + callArgs.MethodName = method + }) + + It("should return error if the provided gasLimit is too low", func() { + txArgs.GasLimit = 30000 + callArgs.Args = []interface{}{ + s.keyring.GetAddr(0), proposalID, option, metadata, + } + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, callArgs, outOfGasCheck) + Expect(err).To(BeNil()) + + // tally result yes count should remain unchanged + proposal, _ := s.network.App.GovKeeper.Proposals.Get(s.network.GetContext(), proposalID) + _, _, tallyResult, err := s.network.App.GovKeeper.Tally(s.network.GetContext(), proposal) + Expect(err).To(BeNil()) + Expect(tallyResult.YesCount).To(Equal("0"), "expected tally result yes count to remain unchanged") + }) + + It("should return error if the origin is different than the voter", func() { + callArgs.Args = []interface{}{ + differentAddr, proposalID, option, metadata, + } + + voterSetCheck := defaultLogCheck.WithErrContains(gov.ErrDifferentOrigin, s.keyring.GetAddr(0).String(), differentAddr.String()) + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, callArgs, voterSetCheck) + Expect(err).To(BeNil()) + }) + + It("should vote success", func() { + callArgs.Args = []interface{}{ + s.keyring.GetAddr(0), proposalID, option, metadata, + } + + voterSetCheck := passCheck.WithExpEvents(gov.EventTypeVote) + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, callArgs, voterSetCheck) + Expect(err).To(BeNil(), "error while calling the precompile") + + // tally result yes count should updated + proposal, _ := s.network.App.GovKeeper.Proposals.Get(s.network.GetContext(), proposalID) + _, _, tallyResult, err := s.network.App.GovKeeper.Tally(s.network.GetContext(), proposal) + Expect(err).To(BeNil()) + + Expect(tallyResult.YesCount).To(Equal(math.NewInt(3e18).String()), "expected tally result yes count updated") + }) + }) + + Describe("Execute VoteWeighted transaction", func() { + const method = gov.VoteWeightedMethod + + BeforeEach(func() { + callArgs.MethodName = method + }) + + It("should return error if the provided gasLimit is too low", func() { + txArgs.GasLimit = 30000 + callArgs.Args = []interface{}{ + s.keyring.GetAddr(0), + proposalID, + []gov.WeightedVoteOption{ + {Option: 1, Weight: "0.5"}, + {Option: 2, Weight: "0.5"}, + }, + metadata, + } + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, callArgs, outOfGasCheck) + Expect(err).To(BeNil()) + + // tally result should remain unchanged + proposal, _ := s.network.App.GovKeeper.Proposals.Get(s.network.GetContext(), proposalID) + _, _, tallyResult, err := s.network.App.GovKeeper.Tally(s.network.GetContext(), proposal) + Expect(err).To(BeNil()) + Expect(tallyResult.YesCount).To(Equal("0"), "expected tally result to remain unchanged") + }) + + It("should return error if the origin is different than the voter", func() { + callArgs.Args = []interface{}{ + differentAddr, + proposalID, + []gov.WeightedVoteOption{ + {Option: 1, Weight: "0.5"}, + {Option: 2, Weight: "0.5"}, + }, + metadata, + } + + voterSetCheck := defaultLogCheck.WithErrContains(gov.ErrDifferentOrigin, s.keyring.GetAddr(0).String(), differentAddr.String()) + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, callArgs, voterSetCheck) + Expect(err).To(BeNil()) + }) + + It("should vote weighted success", func() { + callArgs.Args = []interface{}{ + s.keyring.GetAddr(0), + proposalID, + []gov.WeightedVoteOption{ + {Option: 1, Weight: "0.7"}, + {Option: 2, Weight: "0.3"}, + }, + metadata, + } + + voterSetCheck := passCheck.WithExpEvents(gov.EventTypeVoteWeighted) + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, callArgs, voterSetCheck) + Expect(err).To(BeNil(), "error while calling the precompile") + + // tally result should be updated + proposal, _ := s.network.App.GovKeeper.Proposals.Get(s.network.GetContext(), proposalID) + _, _, tallyResult, err := s.network.App.GovKeeper.Tally(s.network.GetContext(), proposal) + Expect(err).To(BeNil()) + + expectedYesCount := math.NewInt(21e17) // 70% of 3e18 + Expect(tallyResult.YesCount).To(Equal(expectedYesCount.String()), "expected tally result yes count updated") + + expectedAbstainCount := math.NewInt(9e17) // 30% of 3e18 + Expect(tallyResult.AbstainCount).To(Equal(expectedAbstainCount.String()), "expected tally result no count updated") + }) + }) + + // ===================================== + // QUERIES + // ===================================== + Describe("Execute queries", func() { + Context("vote query", func() { + method := gov.GetVoteMethod + BeforeEach(func() { + // submit a vote + voteArgs := factory.CallArgs{ + ContractABI: s.precompile.ABI, + MethodName: gov.VoteMethod, + Args: []interface{}{ + s.keyring.GetAddr(0), proposalID, option, metadata, + }, + } + + voterSetCheck := passCheck.WithExpEvents(gov.EventTypeVote) + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, voteArgs, voterSetCheck) + Expect(err).To(BeNil(), "error while calling the precompile") + Expect(s.network.NextBlock()).To(BeNil()) + }) + It("should return a vote", func() { + callArgs.MethodName = method + callArgs.Args = []interface{}{proposalID, s.keyring.GetAddr(0)} + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) + + var out gov.VoteOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.Vote.Voter).To(Equal(s.keyring.GetAddr(0))) + Expect(out.Vote.ProposalId).To(Equal(proposalID)) + Expect(out.Vote.Metadata).To(Equal(metadata)) + Expect(out.Vote.Options).To(HaveLen(1)) + Expect(out.Vote.Options[0].Option).To(Equal(option)) + Expect(out.Vote.Options[0].Weight).To(Equal(math.LegacyOneDec().String())) + }) + }) + + Context("weighted vote query", func() { + method := gov.GetVoteMethod + BeforeEach(func() { + // submit a weighted vote + voteArgs := factory.CallArgs{ + ContractABI: s.precompile.ABI, + MethodName: gov.VoteWeightedMethod, + Args: []interface{}{ + s.keyring.GetAddr(0), + proposalID, + []gov.WeightedVoteOption{ + {Option: 1, Weight: "0.7"}, + {Option: 2, Weight: "0.3"}, + }, + metadata, + }, + } + + voterSetCheck := passCheck.WithExpEvents(gov.EventTypeVoteWeighted) + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, voteArgs, voterSetCheck) + Expect(err).To(BeNil(), "error while calling the precompile") + Expect(s.network.NextBlock()).To(BeNil()) + }) + + It("should return a weighted vote", func() { + callArgs.MethodName = method + callArgs.Args = []interface{}{proposalID, s.keyring.GetAddr(0)} + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) + + var out gov.VoteOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.Vote.Voter).To(Equal(s.keyring.GetAddr(0))) + Expect(out.Vote.ProposalId).To(Equal(proposalID)) + Expect(out.Vote.Metadata).To(Equal(metadata)) + Expect(out.Vote.Options).To(HaveLen(2)) + Expect(out.Vote.Options[0].Option).To(Equal(uint8(1))) + Expect(out.Vote.Options[0].Weight).To(Equal("0.7")) + Expect(out.Vote.Options[1].Option).To(Equal(uint8(2))) + Expect(out.Vote.Options[1].Weight).To(Equal("0.3")) + }) + }) + + Context("votes query", func() { + method := gov.GetVotesMethod + BeforeEach(func() { + // submit votes + for _, key := range s.keyring.GetKeys() { + voteArgs := factory.CallArgs{ + ContractABI: s.precompile.ABI, + MethodName: gov.VoteMethod, + Args: []interface{}{ + key.Addr, proposalID, option, metadata, + }, + } + + voterSetCheck := passCheck.WithExpEvents(gov.EventTypeVote) + + _, _, err := s.factory.CallContractAndCheckLogs(key.Priv, txArgs, voteArgs, voterSetCheck) + Expect(err).To(BeNil(), "error while calling the precompile") + Expect(s.network.NextBlock()).To(BeNil()) + } + }) + It("should return all votes", func() { + callArgs.MethodName = method + callArgs.Args = []interface{}{ + proposalID, + query.PageRequest{ + CountTotal: true, + }, + } + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) + + var out gov.VotesOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + votersCount := len(s.keyring.GetKeys()) + Expect(out.PageResponse.Total).To(Equal(uint64(votersCount))) + Expect(out.PageResponse.NextKey).To(Equal([]byte{})) + Expect(out.Votes).To(HaveLen(votersCount)) + for _, v := range out.Votes { + Expect(v.ProposalId).To(Equal(proposalID)) + Expect(v.Metadata).To(Equal(metadata)) + Expect(v.Options).To(HaveLen(1)) + Expect(v.Options[0].Option).To(Equal(option)) + Expect(v.Options[0].Weight).To(Equal(math.LegacyOneDec().String())) + } + }) + }) + + Context("deposit query", func() { + method := gov.GetDepositMethod + BeforeEach(func() { + callArgs.MethodName = method + }) + + It("should return a deposit", func() { + callArgs.Args = []interface{}{proposalID, s.keyring.GetAddr(0)} + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) + + var out gov.DepositOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.Deposit.ProposalId).To(Equal(proposalID)) + Expect(out.Deposit.Depositor).To(Equal(s.keyring.GetAddr(0))) + Expect(out.Deposit.Amount).To(HaveLen(1)) + Expect(out.Deposit.Amount[0].Denom).To(Equal(s.network.GetBaseDenom())) + Expect(out.Deposit.Amount[0].Amount.Cmp(big.NewInt(100))).To(Equal(0)) + }) + }) + + Context("deposits query", func() { + method := gov.GetDepositsMethod + BeforeEach(func() { + callArgs.MethodName = method + }) + + It("should return all deposits", func() { + callArgs.Args = []interface{}{ + proposalID, + query.PageRequest{ + CountTotal: true, + }, + } + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) + + var out gov.DepositsOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.PageResponse.Total).To(Equal(uint64(1))) + Expect(out.PageResponse.NextKey).To(Equal([]byte{})) + Expect(out.Deposits).To(HaveLen(1)) + for _, d := range out.Deposits { + Expect(d.ProposalId).To(Equal(proposalID)) + Expect(d.Amount).To(HaveLen(1)) + Expect(d.Amount[0].Denom).To(Equal(s.network.GetBaseDenom())) + Expect(d.Amount[0].Amount.Cmp(big.NewInt(100))).To(Equal(0)) + } + }) + }) + + Context("tally result query", func() { + method := gov.GetTallyResultMethod + BeforeEach(func() { + callArgs.MethodName = method + voteArgs := factory.CallArgs{ + ContractABI: s.precompile.ABI, + MethodName: gov.VoteMethod, + Args: []interface{}{ + s.keyring.GetAddr(0), proposalID, option, metadata, + }, + } + + voterSetCheck := passCheck.WithExpEvents(gov.EventTypeVote) + + _, _, err := s.factory.CallContractAndCheckLogs(s.keyring.GetPrivKey(0), txArgs, voteArgs, voterSetCheck) + Expect(err).To(BeNil(), "error while calling the precompile") + Expect(s.network.NextBlock()).To(BeNil()) + }) + + It("should return the tally result", func() { + callArgs.Args = []interface{}{proposalID} + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) + + var out gov.TallyResultOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.TallyResult.Yes).To(Equal("3000000000000000000")) + Expect(out.TallyResult.Abstain).To(Equal("0")) + Expect(out.TallyResult.No).To(Equal("0")) + Expect(out.TallyResult.NoWithVeto).To(Equal("0")) + }) + }) + + Context("proposal query", func() { + method := gov.GetProposalMethod + BeforeEach(func() { + callArgs.MethodName = method + }) + + It("should return a proposal", func() { + callArgs.Args = []interface{}{uint64(1)} + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) + + var out gov.ProposalOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + // Check proposal details + Expect(out.Proposal.Id).To(Equal(uint64(1))) + Expect(out.Proposal.Status).To(Equal(uint32(v1.StatusVotingPeriod))) + Expect(out.Proposal.Proposer).To(Equal(s.keyring.GetAddr(0))) + Expect(out.Proposal.Metadata).To(Equal("ipfs://CID")) + Expect(out.Proposal.Title).To(Equal("test prop")) + Expect(out.Proposal.Summary).To(Equal("test prop")) + Expect(out.Proposal.Messages).To(HaveLen(1)) + Expect(out.Proposal.Messages[0]).To(Equal("/cosmos.bank.v1beta1.MsgSend")) + + // Check tally result + Expect(out.Proposal.FinalTallyResult.Yes).To(Equal("0")) + Expect(out.Proposal.FinalTallyResult.Abstain).To(Equal("0")) + Expect(out.Proposal.FinalTallyResult.No).To(Equal("0")) + Expect(out.Proposal.FinalTallyResult.NoWithVeto).To(Equal("0")) + }) + + It("should fail when proposal doesn't exist", func() { + callArgs.Args = []interface{}{uint64(999)} + + _, _, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + defaultLogCheck.WithErrContains("proposal 999 doesn't exist"), + ) + Expect(err).To(BeNil()) + }) + }) + + Context("proposals query", func() { + method := gov.GetProposalsMethod + BeforeEach(func() { + callArgs.MethodName = method + }) + + It("should return all proposals", func() { + callArgs.Args = []interface{}{ + uint32(0), // StatusNil to get all proposals + common.Address{}, + common.Address{}, + query.PageRequest{ + CountTotal: true, + }, + } + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) + + var out gov.ProposalsOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.Proposals).To(HaveLen(2)) + Expect(out.PageResponse.Total).To(Equal(uint64(2))) + + proposal := out.Proposals[0] + Expect(proposal.Id).To(Equal(uint64(1))) + Expect(proposal.Status).To(Equal(uint32(v1.StatusVotingPeriod))) + Expect(proposal.Proposer).To(Equal(s.keyring.GetAddr(0))) + Expect(proposal.Messages).To(HaveLen(1)) + Expect(proposal.Messages[0]).To(Equal("/cosmos.bank.v1beta1.MsgSend")) + }) + + It("should filter proposals by status", func() { + callArgs.Args = []interface{}{ + uint32(v1.StatusVotingPeriod), + common.Address{}, + common.Address{}, + query.PageRequest{ + CountTotal: true, + }, + } + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil()) + + var out gov.ProposalsOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.Proposals).To(HaveLen(2)) + Expect(out.Proposals[0].Status).To(Equal(uint32(v1.StatusVotingPeriod))) + Expect(out.Proposals[1].Status).To(Equal(uint32(v1.StatusVotingPeriod))) + }) + + It("should filter proposals by voter", func() { + // First add a vote + voteArgs := factory.CallArgs{ + ContractABI: s.precompile.ABI, + MethodName: gov.VoteMethod, + Args: []interface{}{ + s.keyring.GetAddr(0), uint64(1), uint8(v1.OptionYes), "", + }, + } + _, _, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + voteArgs, + passCheck.WithExpEvents(gov.EventTypeVote), + ) + Expect(err).To(BeNil()) + + // Wait for the vote to be included in the block + Expect(s.network.NextBlock()).To(BeNil()) + + // Query proposals filtered by voter + callArgs.Args = []interface{}{ + uint32(0), // StatusNil + s.keyring.GetAddr(0), + common.Address{}, + query.PageRequest{ + CountTotal: true, + }, + } + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil()) + + var out gov.ProposalsOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.Proposals).To(HaveLen(1)) + }) + + It("should filter proposals by depositor", func() { + callArgs.Args = []interface{}{ + uint32(0), // StatusNil + common.Address{}, + s.keyring.GetAddr(0), + query.PageRequest{ + CountTotal: true, + }, + } + + _, ethRes, err := s.factory.CallContractAndCheckLogs( + s.keyring.GetPrivKey(0), + txArgs, + callArgs, + passCheck, + ) + Expect(err).To(BeNil()) + + var out gov.ProposalsOutput + err = s.precompile.UnpackIntoInterface(&out, method, ethRes.Ret) + Expect(err).To(BeNil()) + + Expect(out.Proposals).To(HaveLen(1)) + }) + }) + }) +}) diff --git a/precompiles/gov/query.go b/precompiles/gov/query.go new file mode 100644 index 00000000..815fcbfb --- /dev/null +++ b/precompiles/gov/query.go @@ -0,0 +1,184 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package gov + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/evmos/os/x/evm/core/vm" +) + +const ( + // GetVotesMethod defines the method name for the votes precompile request. + GetVotesMethod = "getVotes" + // GetVoteMethod defines the method name for the vote precompile request. + GetVoteMethod = "getVote" + // GetDepositMethod defines the method name for the deposit precompile request. + GetDepositMethod = "getDeposit" + // GetDepositsMethod defines the method name for the deposits precompile request. + GetDepositsMethod = "getDeposits" + // GetTallyResultMethod defines the method name for the tally result precompile request. + GetTallyResultMethod = "getTallyResult" + // GetProposalMethod defines the method name for the proposal precompile request. + GetProposalMethod = "getProposal" + // GetProposalsMethod defines the method name for the proposals precompile request. + GetProposalsMethod = "getProposals" +) + +// GetVotes implements the query logic for getting votes for a proposal. +func (p *Precompile) GetVotes( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + queryVotesReq, err := ParseVotesArgs(method, args) + if err != nil { + return nil, err + } + + queryServer := govkeeper.NewQueryServer(&p.govKeeper) + res, err := queryServer.Votes(ctx, queryVotesReq) + if err != nil { + return nil, err + } + + output := new(VotesOutput).FromResponse(res) + return method.Outputs.Pack(output.Votes, output.PageResponse) +} + +// GetVote implements the query logic for getting votes for a proposal. +func (p *Precompile) GetVote( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + queryVotesReq, err := ParseVoteArgs(args) + if err != nil { + return nil, err + } + + queryServer := govkeeper.NewQueryServer(&p.govKeeper) + res, err := queryServer.Vote(ctx, queryVotesReq) + if err != nil { + return nil, err + } + + output := new(VoteOutput).FromResponse(res) + + return method.Outputs.Pack(output.Vote) +} + +// GetDeposit implements the query logic for getting a deposit for a proposal. +func (p *Precompile) GetDeposit( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + queryDepositReq, err := ParseDepositArgs(args) + if err != nil { + return nil, err + } + + queryServer := govkeeper.NewQueryServer(&p.govKeeper) + res, err := queryServer.Deposit(ctx, queryDepositReq) + if err != nil { + return nil, err + } + + output := new(DepositOutput).FromResponse(res) + return method.Outputs.Pack(output.Deposit) +} + +// GetDeposits implements the query logic for getting all deposits for a proposal. +func (p *Precompile) GetDeposits( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + queryDepositsReq, err := ParseDepositsArgs(method, args) + if err != nil { + return nil, err + } + + queryServer := govkeeper.NewQueryServer(&p.govKeeper) + res, err := queryServer.Deposits(ctx, queryDepositsReq) + if err != nil { + return nil, err + } + + output := new(DepositsOutput).FromResponse(res) + return method.Outputs.Pack(output.Deposits, output.PageResponse) +} + +// GetTallyResult implements the query logic for getting the tally result of a proposal. +func (p *Precompile) GetTallyResult( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + queryTallyResultReq, err := ParseTallyResultArgs(args) + if err != nil { + return nil, err + } + + queryServer := govkeeper.NewQueryServer(&p.govKeeper) + res, err := queryServer.TallyResult(ctx, queryTallyResultReq) + if err != nil { + return nil, err + } + + output := new(TallyResultOutput).FromResponse(res) + return method.Outputs.Pack(output.TallyResult) +} + +// GetProposal implements the query logic for getting a proposal +func (p *Precompile) GetProposal( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + queryProposalReq, err := ParseProposalArgs(args) + if err != nil { + return nil, err + } + + queryServer := govkeeper.NewQueryServer(&p.govKeeper) + res, err := queryServer.Proposal(ctx, queryProposalReq) + if err != nil { + return nil, err + } + + output := new(ProposalOutput).FromResponse(res) + return method.Outputs.Pack(output.Proposal) +} + +// GetProposals implements the query logic for getting proposals +func (p *Precompile) GetProposals( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + queryProposalsReq, err := ParseProposalsArgs(method, args) + if err != nil { + return nil, err + } + + queryServer := govkeeper.NewQueryServer(&p.govKeeper) + res, err := queryServer.Proposals(ctx, queryProposalsReq) + if err != nil { + return nil, err + } + + output := new(ProposalsOutput).FromResponse(res) + + return method.Outputs.Pack(output.Proposals, output.PageResponse) +} diff --git a/precompiles/gov/query_test.go b/precompiles/gov/query_test.go new file mode 100644 index 00000000..2b10da51 --- /dev/null +++ b/precompiles/gov/query_test.go @@ -0,0 +1,585 @@ +package gov_test + +import ( + "fmt" + "math/big" + + "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/testutil/testdata" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/query" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" + "github.com/ethereum/go-ethereum/common" + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/precompiles/gov" + "github.com/evmos/os/precompiles/testutil" + testconstants "github.com/evmos/os/testutil/constants" + "github.com/evmos/os/x/evm/core/vm" +) + +var ( + _, _, addr = testdata.KeyTestPubAddr() + // gov account authority address + govAcct = authtypes.NewModuleAddress(govtypes.ModuleName) + // TestProposalMsgs are msgs used on a proposal. + TestProposalMsgs = []sdk.Msg{ + banktypes.NewMsgSend(govAcct, addr, sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(1000)))), + } +) + +func (s *PrecompileTestSuite) TestGetVotes() { + var ctx sdk.Context + method := s.precompile.Methods[gov.GetVotesMethod] + testCases := []struct { + name string + malleate func() []gov.WeightedVote + args []interface{} + expPass bool + expTotal uint64 + gas uint64 + }{ + { + name: "valid query", + malleate: func() []gov.WeightedVote { + err := s.network.App.GovKeeper.AddVote(s.network.GetContext(), 1, s.keyring.GetAccAddr(0), []*govv1.WeightedVoteOption{{Option: govv1.OptionYes, Weight: "1.0"}}, "") + s.Require().NoError(err) + return []gov.WeightedVote{ + {ProposalId: 1, Voter: s.keyring.GetAddr(0), Options: []gov.WeightedVoteOption{{Option: uint8(govv1.OptionYes), Weight: "1.0"}}}, + } + }, + args: []interface{}{uint64(1), query.PageRequest{Limit: 10, CountTotal: true}}, + expPass: true, + expTotal: 1, + gas: 200_000, + }, + { + name: "invalid proposal ID", + args: []interface{}{uint64(0), query.PageRequest{Limit: 10, CountTotal: true}}, + expPass: false, + gas: 200_000, + malleate: func() []gov.WeightedVote { + return []gov.WeightedVote{} + }, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + ctx = s.network.GetContext() + + votes := tc.malleate() + var contract *vm.Contract + contract, ctx = testutil.NewPrecompileContract(s.T(), ctx, s.keyring.GetAddr(0), s.precompile, tc.gas) + + bz, err := s.precompile.GetVotes(ctx, &method, contract, tc.args) + + if tc.expPass { + var out gov.VotesOutput + err = s.precompile.UnpackIntoInterface(&out, gov.GetVotesMethod, bz) + s.Require().NoError(err) + s.Require().Equal(votes, out.Votes) + s.Require().Equal(tc.expTotal, out.PageResponse.Total) + } else { + s.Require().Error(err) + } + }) + } +} + +func (s *PrecompileTestSuite) TestGetVote() { + var voter sdk.AccAddress + method := s.precompile.Methods[gov.GetVoteMethod] + testCases := []struct { + name string + malleate func() + propNumber uint64 + expPass bool + expPropNumber uint64 + expVoter common.Address + gas uint64 + errContains string + }{ + { + name: "valid query", + malleate: func() { + err := s.network.App.GovKeeper.AddVote(s.network.GetContext(), 1, voter, []*govv1.WeightedVoteOption{{Option: govv1.OptionYes, Weight: "1.0"}}, "") + s.Require().NoError(err) + }, + propNumber: uint64(1), + expPropNumber: uint64(1), + expVoter: common.BytesToAddress(voter.Bytes()), + expPass: true, + gas: 200_000, + }, + { + name: "invalid proposal ID", + propNumber: uint64(10), + expPass: false, + gas: 200_000, + malleate: func() { + err := s.network.App.GovKeeper.AddVote(s.network.GetContext(), 1, voter, []*govv1.WeightedVoteOption{{Option: govv1.OptionYes, Weight: "1.0"}}, "") + s.Require().NoError(err) + }, + errContains: "not found for proposal", + }, + { + name: "non-existent vote", + propNumber: uint64(1), + expPass: false, + gas: 200_000, + malleate: func() {}, + errContains: "not found for proposal", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + voter = s.keyring.GetAccAddr(0) + + tc.malleate() + + contract, ctx := testutil.NewPrecompileContract(s.T(), s.network.GetContext(), s.keyring.GetAddr(0), s.precompile, tc.gas) + + args := []interface{}{tc.propNumber, common.BytesToAddress(voter.Bytes())} + bz, err := s.precompile.GetVote(ctx, &method, contract, args) + + expVote := gov.WeightedVote{ + ProposalId: tc.expPropNumber, + Voter: common.BytesToAddress(voter.Bytes()), + Options: []gov.WeightedVoteOption{{Option: uint8(govv1.OptionYes), Weight: "1.0"}}, + Metadata: "", + } + + if tc.expPass { + s.Require().NoError(err) + var out gov.VoteOutput + err = s.precompile.UnpackIntoInterface(&out, gov.GetVoteMethod, bz) + + s.Require().NoError(err) + s.Require().Equal(expVote.ProposalId, out.Vote.ProposalId) + s.Require().Equal(expVote.Voter, out.Vote.Voter) + s.Require().Equal(expVote.Options, out.Vote.Options) + s.Require().Equal(expVote.Metadata, out.Vote.Metadata) + } else { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } + }) + } +} + +func (s *PrecompileTestSuite) TestGetDeposit() { + var depositor sdk.AccAddress + method := s.precompile.Methods[gov.GetDepositMethod] + testCases := []struct { + name string + malleate func() + propNumber uint64 + expPass bool + expPropNumber uint64 + gas uint64 + errContains string + }{ + { + name: "valid query", + malleate: func() {}, + propNumber: uint64(1), + expPropNumber: uint64(1), + expPass: true, + gas: 200_000, + }, + { + name: "invalid proposal ID", + propNumber: uint64(10), + expPass: false, + gas: 200_000, + malleate: func() {}, + errContains: "not found", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + + depositor = s.keyring.GetAccAddr(0) + + tc.malleate() + + contract, ctx := testutil.NewPrecompileContract(s.T(), s.network.GetContext(), s.keyring.GetAddr(0), s.precompile, tc.gas) + + args := []interface{}{tc.propNumber, common.BytesToAddress(depositor.Bytes())} + bz, err := s.precompile.GetDeposit(ctx, &method, contract, args) + + if tc.expPass { + s.Require().NoError(err) + var out gov.DepositOutput + err = s.precompile.UnpackIntoInterface(&out, gov.GetDepositMethod, bz) + + s.Require().NoError(err) + s.Require().Equal(tc.expPropNumber, out.Deposit.ProposalId) + s.Require().Equal(common.BytesToAddress(depositor.Bytes()), out.Deposit.Depositor) + s.Require().Equal([]cmn.Coin{{Denom: "aevmos", Amount: big.NewInt(100)}}, out.Deposit.Amount) + } else { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } + }) + } +} + +func (s *PrecompileTestSuite) TestGetDeposits() { + method := s.precompile.Methods[gov.GetDepositsMethod] + testCases := []struct { + name string + malleate func() []gov.DepositData + args []interface{} + expPass bool + expTotal uint64 + gas uint64 + }{ + { + name: "valid query", + malleate: func() []gov.DepositData { + return []gov.DepositData{ + {ProposalId: 1, Depositor: s.keyring.GetAddr(0), Amount: []cmn.Coin{{Denom: s.network.GetBaseDenom(), Amount: big.NewInt(100)}}}, + } + }, + args: []interface{}{uint64(1), query.PageRequest{Limit: 10, CountTotal: true}}, + expPass: true, + expTotal: 1, + gas: 200_000, + }, + { + name: "invalid proposal ID", + args: []interface{}{uint64(0), query.PageRequest{Limit: 10, CountTotal: true}}, + expPass: false, + gas: 200_000, + malleate: func() []gov.DepositData { + return []gov.DepositData{} + }, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + ctx := s.network.GetContext() + + deposits := tc.malleate() + contract, ctx := testutil.NewPrecompileContract(s.T(), ctx, s.keyring.GetAddr(0), s.precompile, tc.gas) + + bz, err := s.precompile.GetDeposits(ctx, &method, contract, tc.args) + if tc.expPass { + var out gov.DepositsOutput + err = s.precompile.UnpackIntoInterface(&out, gov.GetDepositsMethod, bz) + s.Require().NoError(err) + s.Require().Equal(deposits, out.Deposits) + s.Require().Equal(tc.expTotal, out.PageResponse.Total) + } else { + s.Require().Error(err) + } + }) + } +} + +func (s *PrecompileTestSuite) TestGetTallyResult() { + method := s.precompile.Methods[gov.GetTallyResultMethod] + testCases := []struct { + name string + malleate func() gov.TallyResultData + propNumber uint64 + expPass bool + gas uint64 + errContains string + }{ + { + name: "valid query", + malleate: func() gov.TallyResultData { + proposal, err := s.network.App.GovKeeper.SubmitProposal(s.network.GetContext(), TestProposalMsgs, "", "Proposal", "testing proposal", s.keyring.GetAccAddr(0), false) + s.Require().NoError(err) + votingStarted, err := s.network.App.GovKeeper.AddDeposit(s.network.GetContext(), proposal.Id, s.keyring.GetAccAddr(0), sdk.NewCoins(sdk.NewCoin(s.network.GetBaseDenom(), math.NewInt(100)))) + s.Require().NoError(err) + s.Require().True(votingStarted) + err = s.network.App.GovKeeper.AddVote(s.network.GetContext(), proposal.Id, s.keyring.GetAccAddr(0), govv1.NewNonSplitVoteOption(govv1.OptionYes), "") + s.Require().NoError(err) + return gov.TallyResultData{ + Yes: "3000000000000000000", + Abstain: "0", + No: "0", + NoWithVeto: "0", + } + }, + propNumber: uint64(1), + expPass: true, + gas: 200_000, + }, + { + name: "invalid proposal ID", + propNumber: uint64(10), + expPass: false, + gas: 200_000, + malleate: func() gov.TallyResultData { return gov.TallyResultData{} }, + errContains: "proposal 10 doesn't exist", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + + expTally := tc.malleate() + + contract, ctx := testutil.NewPrecompileContract(s.T(), s.network.GetContext(), s.keyring.GetAddr(0), s.precompile, tc.gas) + + args := []interface{}{tc.propNumber} + bz, err := s.precompile.GetTallyResult(ctx, &method, contract, args) + + if tc.expPass { + s.Require().NoError(err) + var out gov.TallyResultOutput + err = s.precompile.UnpackIntoInterface(&out, gov.GetTallyResultMethod, bz) + + s.Require().NoError(err) + s.Require().Equal(expTally, out.TallyResult) + } else { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } + }) + } +} + +func (s *PrecompileTestSuite) TestGetProposal() { + method := s.precompile.Methods[gov.GetProposalMethod] + + testCases := []struct { + name string + malleate func() []interface{} + postCheck func(data *gov.ProposalData) + gas uint64 + expError bool + errContains string + }{ + { + "fail - empty input args", + func() []interface{} { + return []interface{}{} + }, + func(_ *gov.ProposalData) {}, + 200000, + true, + fmt.Sprintf(cmn.ErrInvalidNumberOfArgs, 1, 0), + }, + { + "fail - invalid proposal ID", + func() []interface{} { + return []interface{}{uint64(0)} + }, + func(_ *gov.ProposalData) {}, + 200000, + true, + "proposal id can not be 0", + }, + { + "fail - proposal doesn't exist", + func() []interface{} { + return []interface{}{uint64(10)} + }, + func(_ *gov.ProposalData) {}, + 200000, + true, + "proposal 10 doesn't exist", + }, + { + "success - get proposal", + func() []interface{} { + return []interface{}{uint64(1)} + }, + func(data *gov.ProposalData) { + s.Require().Equal(uint64(1), data.Id) + s.Require().Equal(uint32(govv1.StatusVotingPeriod), data.Status) + s.Require().Equal(s.keyring.GetAddr(0), data.Proposer) + s.Require().Equal("test prop", data.Title) + s.Require().Equal("test prop", data.Summary) + s.Require().Equal("ipfs://CID", data.Metadata) + s.Require().Len(data.Messages, 1) + s.Require().Equal("/cosmos.bank.v1beta1.MsgSend", data.Messages[0]) + }, + 200000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + + contract, ctx := testutil.NewPrecompileContract(s.T(), s.network.GetContext(), s.keyring.GetAddr(0), s.precompile, tc.gas) + + bz, err := s.precompile.GetProposal(ctx, &method, contract, tc.malleate()) + + if tc.expError { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } else { + s.Require().NoError(err) + var out gov.ProposalOutput + err = s.precompile.UnpackIntoInterface(&out, gov.GetProposalMethod, bz) + s.Require().NoError(err) + tc.postCheck(&out.Proposal) + } + }) + } +} + +func (s *PrecompileTestSuite) TestGetProposals() { + method := s.precompile.Methods[gov.GetProposalsMethod] + + testCases := []struct { + name string + malleate func() []interface{} + postCheck func(data []gov.ProposalData, pageRes *query.PageResponse) + gas uint64 + expError bool + errContains string + }{ + { + "fail - empty input args", + func() []interface{} { + return []interface{}{} + }, + func(_ []gov.ProposalData, _ *query.PageResponse) {}, + 200000, + true, + fmt.Sprintf(cmn.ErrInvalidNumberOfArgs, 4, 0), + }, + { + "success - get all proposals", + func() []interface{} { + return []interface{}{ + uint32(govv1.StatusNil), + common.Address{}, + common.Address{}, + query.PageRequest{ + Limit: 10, + CountTotal: true, + }, + } + }, + func(data []gov.ProposalData, pageRes *query.PageResponse) { + s.Require().Len(data, 2) + s.Require().Equal(uint64(2), pageRes.Total) + + proposal := data[0] + s.Require().Equal(uint64(1), proposal.Id) + s.Require().Equal(uint32(govv1.StatusVotingPeriod), proposal.Status) + s.Require().Equal(s.keyring.GetAddr(0), proposal.Proposer) + s.Require().Equal("test prop", proposal.Title) + s.Require().Equal("test prop", proposal.Summary) + s.Require().Equal("ipfs://CID", proposal.Metadata) + s.Require().Len(proposal.Messages, 1) + s.Require().Equal("/cosmos.bank.v1beta1.MsgSend", proposal.Messages[0]) + }, + 200000, + false, + "", + }, + { + "success - filter by status", + func() []interface{} { + return []interface{}{ + uint32(govv1.StatusVotingPeriod), + common.Address{}, + common.Address{}, + query.PageRequest{ + Limit: 10, + CountTotal: true, + }, + } + }, + func(data []gov.ProposalData, pageRes *query.PageResponse) { + s.Require().Len(data, 2) + s.Require().Equal(uint64(2), pageRes.Total) + s.Require().Equal(uint32(govv1.StatusVotingPeriod), data[0].Status) + s.Require().Equal(uint32(govv1.StatusVotingPeriod), data[1].Status) + }, + 200000, + false, + "", + }, + { + "success - filter by voter", + func() []interface{} { + // First add a vote + err := s.network.App.GovKeeper.AddVote(s.network.GetContext(), 1, s.keyring.GetAccAddr(0), govv1.NewNonSplitVoteOption(govv1.OptionYes), "") + s.Require().NoError(err) + + return []interface{}{ + uint32(govv1.StatusVotingPeriod), + s.keyring.GetAddr(0), + common.Address{}, + query.PageRequest{ + Limit: 10, + CountTotal: true, + }, + } + }, + func(data []gov.ProposalData, pageRes *query.PageResponse) { + s.Require().Len(data, 1) + s.Require().Equal(uint64(1), pageRes.Total) + }, + 200000, + false, + "", + }, + { + "success - filter by depositor", + func() []interface{} { + return []interface{}{ + uint32(govv1.StatusVotingPeriod), + common.Address{}, + s.keyring.GetAddr(0), + query.PageRequest{ + Limit: 10, + CountTotal: true, + }, + } + }, + func(data []gov.ProposalData, pageRes *query.PageResponse) { + s.Require().Len(data, 1) + s.Require().Equal(uint64(1), pageRes.Total) + }, + 200000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + + contract, ctx := testutil.NewPrecompileContract(s.T(), s.network.GetContext(), s.keyring.GetAddr(0), s.precompile, tc.gas) + + bz, err := s.precompile.GetProposals(ctx, &method, contract, tc.malleate()) + + if tc.expError { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } else { + s.Require().NoError(err) + var out gov.ProposalsOutput + err = s.precompile.UnpackIntoInterface(&out, gov.GetProposalsMethod, bz) + s.Require().NoError(err) + tc.postCheck(out.Proposals, &out.PageResponse) + } + }) + } +} diff --git a/precompiles/gov/setup_test.go b/precompiles/gov/setup_test.go new file mode 100644 index 00000000..79af85f5 --- /dev/null +++ b/precompiles/gov/setup_test.go @@ -0,0 +1,137 @@ +package gov_test + +import ( + "testing" + "time" + + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + + "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/codec/types" + sdk "github.com/cosmos/cosmos-sdk/types" + + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" + + "github.com/evmos/os/precompiles/gov" + testconstants "github.com/evmos/os/testutil/constants" + "github.com/evmos/os/testutil/integration/os/factory" + "github.com/evmos/os/testutil/integration/os/grpc" + testkeyring "github.com/evmos/os/testutil/integration/os/keyring" + "github.com/evmos/os/testutil/integration/os/network" + + "github.com/stretchr/testify/suite" +) + +type PrecompileTestSuite struct { + suite.Suite + + network *network.UnitTestNetwork + factory factory.TxFactory + grpcHandler grpc.Handler + keyring testkeyring.Keyring + + precompile *gov.Precompile +} + +func TestPrecompileUnitTestSuite(t *testing.T) { + suite.Run(t, new(PrecompileTestSuite)) +} + +func (s *PrecompileTestSuite) SetupTest() { + keyring := testkeyring.New(2) + + // seed the db with one proposal + customGen := network.CustomGenesisState{} + now := time.Now().UTC() + inOneHour := now.Add(time.Hour) + + var err error + anyMessage, err := types.NewAnyWithValue(TestProposalMsgs[0]) + if err != nil { + panic(err) + } + prop := &govv1.Proposal{ + Id: 1, + Status: govv1.ProposalStatus_PROPOSAL_STATUS_VOTING_PERIOD, + SubmitTime: &now, + DepositEndTime: &inOneHour, + VotingStartTime: &now, + FinalTallyResult: &govv1.TallyResult{ + YesCount: "0", + AbstainCount: "0", + NoCount: "0", + NoWithVetoCount: "0", + }, + VotingEndTime: &inOneHour, + Metadata: "ipfs://CID", + Title: "test prop", + Summary: "test prop", + Proposer: keyring.GetAccAddr(0).String(), + Messages: []*types.Any{anyMessage}, + } + + prop2 := &govv1.Proposal{ + Id: 2, + Status: govv1.ProposalStatus_PROPOSAL_STATUS_VOTING_PERIOD, + SubmitTime: &now, + DepositEndTime: &inOneHour, + VotingStartTime: &now, + FinalTallyResult: &govv1.TallyResult{ + YesCount: "0", + AbstainCount: "0", + NoCount: "0", + NoWithVetoCount: "0", + }, + VotingEndTime: &inOneHour, + Metadata: "ipfs://CID", + Title: "test prop", + Summary: "test prop", + Proposer: keyring.GetAccAddr(1).String(), + Messages: []*types.Any{anyMessage}, + } + + bankGen := banktypes.DefaultGenesisState() + bankGen.Balances = []banktypes.Balance{{ + Address: authtypes.NewModuleAddress(govtypes.ModuleName).String(), + Coins: sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(200))), + }} + govGen := govv1.DefaultGenesisState() + govGen.Deposits = []*govv1.Deposit{ + { + ProposalId: 1, + Depositor: keyring.GetAccAddr(0).String(), + Amount: sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(100))), + }, + { + ProposalId: 2, + Depositor: keyring.GetAccAddr(1).String(), + Amount: sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(100))), + }, + } + govGen.Params.MinDeposit = sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(100))) + govGen.Proposals = append(govGen.Proposals, prop) + govGen.Proposals = append(govGen.Proposals, prop2) + customGen[govtypes.ModuleName] = govGen + customGen[banktypes.ModuleName] = bankGen + + nw := network.NewUnitTestNetwork( + network.WithPreFundedAccounts(keyring.GetAllAccAddrs()...), + network.WithCustomGenesis(customGen), + ) + grpcHandler := grpc.NewIntegrationHandler(nw) + txFactory := factory.New(nw, grpcHandler) + + s.factory = txFactory + s.grpcHandler = grpcHandler + s.keyring = keyring + s.network = nw + + if s.precompile, err = gov.NewPrecompile( + s.network.App.GovKeeper, + s.network.App.AuthzKeeper, + ); err != nil { + panic(err) + } +} diff --git a/precompiles/gov/tx.go b/precompiles/gov/tx.go new file mode 100644 index 00000000..0524e294 --- /dev/null +++ b/precompiles/gov/tx.go @@ -0,0 +1,89 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package gov + +import ( + "fmt" + + govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/evmos/os/x/evm/core/vm" +) + +const ( + // VoteMethod defines the ABI method name for the gov Vote transaction. + VoteMethod = "vote" + // VoteWeightedMethod defines the ABI method name for the gov VoteWeighted transaction. + VoteWeightedMethod = "voteWeighted" +) + +// Vote defines a method to add a vote on a specific proposal. +func (p Precompile) Vote( + ctx sdk.Context, + origin common.Address, + contract *vm.Contract, + stateDB vm.StateDB, + method *abi.Method, + args []interface{}, +) ([]byte, error) { + msg, voterHexAddr, err := NewMsgVote(args) + if err != nil { + return nil, err + } + + // If the contract is the voter, we don't need an origin check + // Otherwise check if the origin matches the voter address + isContractVoter := contract.CallerAddress == voterHexAddr && contract.CallerAddress != origin + if !isContractVoter && origin != voterHexAddr { + return nil, fmt.Errorf(ErrDifferentOrigin, origin.String(), voterHexAddr.String()) + } + + msgSrv := govkeeper.NewMsgServerImpl(&p.govKeeper) + if _, err = msgSrv.Vote(ctx, msg); err != nil { + return nil, err + } + + if err = p.EmitVoteEvent(ctx, stateDB, voterHexAddr, msg.ProposalId, int32(msg.Option)); err != nil { + return nil, err + } + + return method.Outputs.Pack(true) +} + +// VoteWeighted defines a method to add a vote on a specific proposal. +func (p Precompile) VoteWeighted( + ctx sdk.Context, + origin common.Address, + contract *vm.Contract, + stateDB vm.StateDB, + method *abi.Method, + args []interface{}, +) ([]byte, error) { + msg, voterHexAddr, options, err := NewMsgVoteWeighted(method, args) + if err != nil { + return nil, err + } + + // If the contract is the voter, we don't need an origin check + // Otherwise check if the origin matches the voter address + isContractVoter := contract.CallerAddress == voterHexAddr && contract.CallerAddress != origin + if !isContractVoter && origin != voterHexAddr { + return nil, fmt.Errorf(ErrDifferentOrigin, origin.String(), voterHexAddr.String()) + } + + msgSrv := govkeeper.NewMsgServerImpl(&p.govKeeper) + if _, err = msgSrv.VoteWeighted(ctx, msg); err != nil { + return nil, err + } + + if err = p.EmitVoteWeightedEvent(ctx, stateDB, voterHexAddr, msg.ProposalId, options); err != nil { + return nil, err + } + + return method.Outputs.Pack(true) +} diff --git a/precompiles/gov/tx_test.go b/precompiles/gov/tx_test.go new file mode 100644 index 00000000..260da366 --- /dev/null +++ b/precompiles/gov/tx_test.go @@ -0,0 +1,278 @@ +package gov_test + +import ( + "fmt" + + "cosmossdk.io/math" + + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/ethereum/go-ethereum/common" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/precompiles/gov" + "github.com/evmos/os/precompiles/testutil" + utiltx "github.com/evmos/os/testutil/tx" + "github.com/evmos/os/x/evm/core/vm" +) + +func (s *PrecompileTestSuite) TestVote() { + var ctx sdk.Context + method := s.precompile.Methods[gov.VoteMethod] + newVoterAddr := utiltx.GenerateAddress() + const proposalID uint64 = 1 + const option uint8 = 1 + const metadata = "metadata" + + testCases := []struct { + name string + malleate func() []interface{} + postCheck func() + gas uint64 + expError bool + errContains string + }{ + { + "fail - empty input args", + func() []interface{} { + return []interface{}{} + }, + func() {}, + 200000, + true, + fmt.Sprintf(cmn.ErrInvalidNumberOfArgs, 4, 0), + }, + { + "fail - invalid voter address", + func() []interface{} { + return []interface{}{ + "", + proposalID, + option, + metadata, + } + }, + func() {}, + 200000, + true, + "invalid voter address", + }, + { + "fail - invalid voter address", + func() []interface{} { + return []interface{}{ + common.Address{}, + proposalID, + option, + metadata, + } + }, + func() {}, + 200000, + true, + "invalid voter address", + }, + { + "fail - using a different voter address", + func() []interface{} { + return []interface{}{ + newVoterAddr, + proposalID, + option, + metadata, + } + }, + func() {}, + 200000, + true, + "does not match the voter address", + }, + { + "fail - invalid vote option", + func() []interface{} { + return []interface{}{ + s.keyring.GetAddr(0), + proposalID, + option + 10, + metadata, + } + }, + func() {}, + 200000, + true, + "invalid vote option", + }, + { + "success - vote proposal success", + func() []interface{} { + return []interface{}{ + s.keyring.GetAddr(0), + proposalID, + option, + metadata, + } + }, + func() { + proposal, _ := s.network.App.GovKeeper.Proposals.Get(ctx, proposalID) + _, _, tallyResult, err := s.network.App.GovKeeper.Tally(ctx, proposal) + s.Require().NoError(err) + s.Require().Equal(math.NewInt(3e18).String(), tallyResult.YesCount) + }, + 200000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + ctx = s.network.GetContext() + + var contract *vm.Contract + contract, ctx = testutil.NewPrecompileContract(s.T(), ctx, s.keyring.GetAddr(0), s.precompile, tc.gas) + + _, err := s.precompile.Vote(ctx, s.keyring.GetAddr(0), contract, s.network.GetStateDB(), &method, tc.malleate()) + + if tc.expError { + s.Require().ErrorContains(err, tc.errContains) + } else { + s.Require().NoError(err) + tc.postCheck() + } + }) + } +} + +func (s *PrecompileTestSuite) TestVoteWeighted() { + var ctx sdk.Context + method := s.precompile.Methods[gov.VoteWeightedMethod] + newVoterAddr := utiltx.GenerateAddress() + const proposalID uint64 = 1 + const metadata = "metadata" + + testCases := []struct { + name string + malleate func() []interface{} + postCheck func() + gas uint64 + expError bool + errContains string + }{ + { + "fail - empty input args", + func() []interface{} { + return []interface{}{} + }, + func() {}, + 200000, + true, + fmt.Sprintf(cmn.ErrInvalidNumberOfArgs, 4, 0), + }, + { + "fail - invalid voter address", + func() []interface{} { + return []interface{}{ + "", + proposalID, + []gov.WeightedVoteOption{}, + metadata, + } + }, + func() {}, + 200000, + true, + "invalid voter address", + }, + { + "fail - using a different voter address", + func() []interface{} { + return []interface{}{ + newVoterAddr, + proposalID, + []gov.WeightedVoteOption{}, + metadata, + } + }, + func() {}, + 200000, + true, + "does not match the voter address", + }, + { + "fail - invalid vote option", + func() []interface{} { + return []interface{}{ + s.keyring.GetAddr(0), + proposalID, + []gov.WeightedVoteOption{{Option: 10, Weight: "1.0"}}, + metadata, + } + }, + func() {}, + 200000, + true, + "invalid vote option", + }, + { + "fail - invalid weight sum", + func() []interface{} { + return []interface{}{ + s.keyring.GetAddr(0), + proposalID, + []gov.WeightedVoteOption{ + {Option: 1, Weight: "0.5"}, + {Option: 2, Weight: "0.6"}, + }, + metadata, + } + }, + func() {}, + 200000, + true, + "total weight overflow 1.00", + }, + { + "success - vote weighted proposal", + func() []interface{} { + return []interface{}{ + s.keyring.GetAddr(0), + proposalID, + []gov.WeightedVoteOption{ + {Option: 1, Weight: "0.7"}, + {Option: 2, Weight: "0.3"}, + }, + metadata, + } + }, + func() { + proposal, _ := s.network.App.GovKeeper.Proposals.Get(ctx, proposalID) + _, _, tallyResult, err := s.network.App.GovKeeper.Tally(ctx, proposal) + s.Require().NoError(err) + s.Require().Equal("2100000000000000000", tallyResult.YesCount) + s.Require().Equal("900000000000000000", tallyResult.AbstainCount) + }, + 200000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + ctx = s.network.GetContext() + + var contract *vm.Contract + contract, ctx = testutil.NewPrecompileContract(s.T(), ctx, s.keyring.GetAddr(0), s.precompile, tc.gas) + + _, err := s.precompile.VoteWeighted(ctx, s.keyring.GetAddr(0), contract, s.network.GetStateDB(), &method, tc.malleate()) + + if tc.expError { + s.Require().ErrorContains(err, tc.errContains) + } else { + s.Require().NoError(err) + tc.postCheck() + } + }) + } +} diff --git a/precompiles/gov/types.go b/precompiles/gov/types.go new file mode 100644 index 00000000..71ce6c75 --- /dev/null +++ b/precompiles/gov/types.go @@ -0,0 +1,571 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package gov + +import ( + "fmt" + + "github.com/cosmos/cosmos-sdk/types/query" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + "github.com/evmos/os/utils" + + sdk "github.com/cosmos/cosmos-sdk/types" + govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" + + cmn "github.com/evmos/os/precompiles/common" +) + +// EventVote defines the event data for the Vote transaction. +type EventVote struct { + Voter common.Address + ProposalId uint64 //nolint:revive,stylecheck + Option uint8 +} + +// EventVoteWeighted defines the event data for the VoteWeighted transaction. +type EventVoteWeighted struct { + Voter common.Address + ProposalId uint64 //nolint:revive,stylecheck + Options WeightedVoteOptions +} + +// VotesInput defines the input for the Votes query. +type VotesInput struct { + ProposalId uint64 //nolint:revive,stylecheck + Pagination query.PageRequest +} + +// VotesOutput defines the output for the Votes query. +type VotesOutput struct { + Votes []WeightedVote + PageResponse query.PageResponse +} + +// VoteOutput is the output response returned by the vote query method. +type VoteOutput struct { + Vote WeightedVote +} + +// WeightedVote defines a struct of vote for vote split. +type WeightedVote struct { + ProposalId uint64 //nolint:revive,stylecheck + Voter common.Address + Options []WeightedVoteOption + Metadata string +} + +// WeightedVoteOption defines a unit of vote for vote split. +type WeightedVoteOption struct { + Option uint8 + Weight string +} + +// WeightedVoteOptions defines a slice of WeightedVoteOption. +type WeightedVoteOptions []WeightedVoteOption + +// DepositInput defines the input for the Deposit query. +type DepositInput struct { + ProposalId uint64 //nolint:revive,stylecheck + Depositor common.Address +} + +// DepositOutput defines the output for the Deposit query. +type DepositOutput struct { + Deposit DepositData +} + +// DepositsInput defines the input for the Deposits query. +type DepositsInput struct { + ProposalId uint64 //nolint:revive,stylecheck + Pagination query.PageRequest +} + +// DepositsOutput defines the output for the Deposits query. +type DepositsOutput struct { + Deposits []DepositData `abi:"deposits"` + PageResponse query.PageResponse `abi:"pageResponse"` +} + +// TallyResultOutput defines the output for the TallyResult query. +type TallyResultOutput struct { + TallyResult TallyResultData +} + +// DepositData represents information about a deposit on a proposal +type DepositData struct { + ProposalId uint64 `abi:"proposalId"` //nolint:revive,stylecheck + Depositor common.Address `abi:"depositor"` + Amount []cmn.Coin `abi:"amount"` +} + +// TallyResultData represents the tally result of a proposal +type TallyResultData struct { + Yes string + Abstain string + No string + NoWithVeto string +} + +// NewMsgVote creates a new MsgVote instance. +func NewMsgVote(args []interface{}) (*govv1.MsgVote, common.Address, error) { + if len(args) != 4 { + return nil, common.Address{}, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 4, len(args)) + } + + voterAddress, ok := args[0].(common.Address) + if !ok || voterAddress == (common.Address{}) { + return nil, common.Address{}, fmt.Errorf(ErrInvalidVoter, args[0]) + } + + proposalID, ok := args[1].(uint64) + if !ok { + return nil, common.Address{}, fmt.Errorf(ErrInvalidProposalID, args[1]) + } + + option, ok := args[2].(uint8) + if !ok { + return nil, common.Address{}, fmt.Errorf(ErrInvalidOption, args[2]) + } + + metadata, ok := args[3].(string) + if !ok { + return nil, common.Address{}, fmt.Errorf(ErrInvalidMetadata, args[3]) + } + + msg := &govv1.MsgVote{ + ProposalId: proposalID, + Voter: sdk.AccAddress(voterAddress.Bytes()).String(), + Option: govv1.VoteOption(option), + Metadata: metadata, + } + + return msg, voterAddress, nil +} + +// NewMsgVoteWeighted creates a new MsgVoteWeighted instance. +func NewMsgVoteWeighted(method *abi.Method, args []interface{}) (*govv1.MsgVoteWeighted, common.Address, WeightedVoteOptions, error) { + if len(args) != 4 { + return nil, common.Address{}, WeightedVoteOptions{}, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 4, len(args)) + } + + voterAddress, ok := args[0].(common.Address) + if !ok || voterAddress == (common.Address{}) { + return nil, common.Address{}, WeightedVoteOptions{}, fmt.Errorf(ErrInvalidVoter, args[0]) + } + + proposalID, ok := args[1].(uint64) + if !ok { + return nil, common.Address{}, WeightedVoteOptions{}, fmt.Errorf(ErrInvalidProposalID, args[1]) + } + + // Unpack the input struct + var options WeightedVoteOptions + arguments := abi.Arguments{method.Inputs[2]} + if err := arguments.Copy(&options, []interface{}{args[2]}); err != nil { + return nil, common.Address{}, WeightedVoteOptions{}, fmt.Errorf("error while unpacking args to Options struct: %s", err) + } + + weightedOptions := make([]*govv1.WeightedVoteOption, len(options)) + for i, option := range options { + weightedOptions[i] = &govv1.WeightedVoteOption{ + Option: govv1.VoteOption(option.Option), + Weight: option.Weight, + } + } + + metadata, ok := args[3].(string) + if !ok { + return nil, common.Address{}, WeightedVoteOptions{}, fmt.Errorf(ErrInvalidMetadata, args[3]) + } + + msg := &govv1.MsgVoteWeighted{ + ProposalId: proposalID, + Voter: sdk.AccAddress(voterAddress.Bytes()).String(), + Options: weightedOptions, + Metadata: metadata, + } + + return msg, voterAddress, options, nil +} + +// ParseVotesArgs parses the arguments for the Votes query. +func ParseVotesArgs(method *abi.Method, args []interface{}) (*govv1.QueryVotesRequest, error) { + if len(args) != 2 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 2, len(args)) + } + + var input VotesInput + if err := method.Inputs.Copy(&input, args); err != nil { + return nil, fmt.Errorf("error while unpacking args to VotesInput: %s", err) + } + + return &govv1.QueryVotesRequest{ + ProposalId: input.ProposalId, + Pagination: &input.Pagination, + }, nil +} + +func (vo *VotesOutput) FromResponse(res *govv1.QueryVotesResponse) *VotesOutput { + vo.Votes = make([]WeightedVote, len(res.Votes)) + for i, v := range res.Votes { + hexAddr, err := utils.Bech32ToHexAddr(v.Voter) + if err != nil { + return nil + } + options := make([]WeightedVoteOption, len(v.Options)) + for j, opt := range v.Options { + options[j] = WeightedVoteOption{ + Option: uint8(opt.Option), //nolint:gosec // G115 + Weight: opt.Weight, + } + } + vo.Votes[i] = WeightedVote{ + ProposalId: v.ProposalId, + Voter: hexAddr, + Options: options, + Metadata: v.Metadata, + } + } + if res.Pagination != nil { + vo.PageResponse = query.PageResponse{ + NextKey: res.Pagination.NextKey, + Total: res.Pagination.Total, + } + } + return vo +} + +// ParseVoteArgs parses the arguments for the Votes query. +func ParseVoteArgs(args []interface{}) (*govv1.QueryVoteRequest, error) { + if len(args) != 2 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 2, len(args)) + } + + proposalID, ok := args[0].(uint64) + if !ok { + return nil, fmt.Errorf(ErrInvalidProposalID, args[0]) + } + + voter, ok := args[1].(common.Address) + if !ok { + return nil, fmt.Errorf(ErrInvalidVoter, args[1]) + } + + voterAccAddr := sdk.AccAddress(voter.Bytes()) + return &govv1.QueryVoteRequest{ + ProposalId: proposalID, + Voter: voterAccAddr.String(), + }, nil +} + +func (vo *VoteOutput) FromResponse(res *govv1.QueryVoteResponse) *VoteOutput { + hexVoter, err := utils.Bech32ToHexAddr(res.Vote.Voter) + if err != nil { + return nil + } + vo.Vote.Voter = hexVoter + vo.Vote.Metadata = res.Vote.Metadata + vo.Vote.ProposalId = res.Vote.ProposalId + + options := make([]WeightedVoteOption, len(res.Vote.Options)) + for j, opt := range res.Vote.Options { + options[j] = WeightedVoteOption{ + Option: uint8(opt.Option), //nolint:gosec // G115 + Weight: opt.Weight, + } + } + vo.Vote.Options = options + return vo +} + +// ParseDepositArgs parses the arguments for the Deposit query. +func ParseDepositArgs(args []interface{}) (*govv1.QueryDepositRequest, error) { + if len(args) != 2 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 2, len(args)) + } + + proposalID, ok := args[0].(uint64) + if !ok { + return nil, fmt.Errorf(ErrInvalidProposalID, args[0]) + } + + depositor, ok := args[1].(common.Address) + if !ok { + return nil, fmt.Errorf(ErrInvalidDepositor, args[1]) + } + + depositorAccAddr := sdk.AccAddress(depositor.Bytes()) + return &govv1.QueryDepositRequest{ + ProposalId: proposalID, + Depositor: depositorAccAddr.String(), + }, nil +} + +// ParseDepositsArgs parses the arguments for the Deposits query. +func ParseDepositsArgs(method *abi.Method, args []interface{}) (*govv1.QueryDepositsRequest, error) { + if len(args) != 2 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 2, len(args)) + } + + var input DepositsInput + if err := method.Inputs.Copy(&input, args); err != nil { + return nil, fmt.Errorf("error while unpacking args to DepositsInput: %s", err) + } + + return &govv1.QueryDepositsRequest{ + ProposalId: input.ProposalId, + Pagination: &input.Pagination, + }, nil +} + +// ParseTallyResultArgs parses the arguments for the TallyResult query. +func ParseTallyResultArgs(args []interface{}) (*govv1.QueryTallyResultRequest, error) { + if len(args) != 1 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 1, len(args)) + } + + proposalID, ok := args[0].(uint64) + if !ok { + return nil, fmt.Errorf(ErrInvalidProposalID, args[0]) + } + + return &govv1.QueryTallyResultRequest{ + ProposalId: proposalID, + }, nil +} + +func (do *DepositOutput) FromResponse(res *govv1.QueryDepositResponse) *DepositOutput { + hexDepositor, err := utils.Bech32ToHexAddr(res.Deposit.Depositor) + if err != nil { + return nil + } + coins := make([]cmn.Coin, len(res.Deposit.Amount)) + for i, c := range res.Deposit.Amount { + coins[i] = cmn.Coin{ + Denom: c.Denom, + Amount: c.Amount.BigInt(), + } + } + do.Deposit = DepositData{ + ProposalId: res.Deposit.ProposalId, + Depositor: hexDepositor, + Amount: coins, + } + return do +} + +func (do *DepositsOutput) FromResponse(res *govv1.QueryDepositsResponse) *DepositsOutput { + do.Deposits = make([]DepositData, len(res.Deposits)) + for i, d := range res.Deposits { + hexDepositor, err := utils.Bech32ToHexAddr(d.Depositor) + if err != nil { + return nil + } + coins := make([]cmn.Coin, len(d.Amount)) + for j, c := range d.Amount { + coins[j] = cmn.Coin{ + Denom: c.Denom, + Amount: c.Amount.BigInt(), + } + } + do.Deposits[i] = DepositData{ + ProposalId: d.ProposalId, + Depositor: hexDepositor, + Amount: coins, + } + } + if res.Pagination != nil { + do.PageResponse = query.PageResponse{ + NextKey: res.Pagination.NextKey, + Total: res.Pagination.Total, + } + } + return do +} + +func (tro *TallyResultOutput) FromResponse(res *govv1.QueryTallyResultResponse) *TallyResultOutput { + tro.TallyResult = TallyResultData{ + Yes: res.Tally.YesCount, + Abstain: res.Tally.AbstainCount, + No: res.Tally.NoCount, + NoWithVeto: res.Tally.NoWithVetoCount, + } + return tro +} + +// ProposalOutput defines the output for the Proposal query +type ProposalOutput struct { + Proposal ProposalData +} + +// ProposalsInput defines the input for the Proposals query +type ProposalsInput struct { + ProposalStatus uint32 + Voter common.Address + Depositor common.Address + Pagination query.PageRequest +} + +// ProposalsOutput defines the output for the Proposals query +type ProposalsOutput struct { + Proposals []ProposalData + PageResponse query.PageResponse +} + +// ProposalData represents a governance proposal +type ProposalData struct { + Id uint64 `abi:"id"` //nolint + Messages []string `abi:"messages"` + Status uint32 `abi:"status"` + FinalTallyResult TallyResultData `abi:"finalTallyResult"` + SubmitTime uint64 `abi:"submitTime"` + DepositEndTime uint64 `abi:"depositEndTime"` + TotalDeposit []cmn.Coin `abi:"totalDeposit"` + VotingStartTime uint64 `abi:"votingStartTime"` + VotingEndTime uint64 `abi:"votingEndTime"` + Metadata string `abi:"metadata"` + Title string `abi:"title"` + Summary string `abi:"summary"` + Proposer common.Address `abi:"proposer"` +} + +// ParseProposalArgs parses the arguments for the Proposal query +func ParseProposalArgs(args []interface{}) (*govv1.QueryProposalRequest, error) { + if len(args) != 1 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 1, len(args)) + } + + proposalID, ok := args[0].(uint64) + if !ok { + return nil, fmt.Errorf(ErrInvalidProposalID, args[0]) + } + + return &govv1.QueryProposalRequest{ + ProposalId: proposalID, + }, nil +} + +// ParseProposalsArgs parses the arguments for the Proposals query +func ParseProposalsArgs(method *abi.Method, args []interface{}) (*govv1.QueryProposalsRequest, error) { + if len(args) != 4 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 4, len(args)) + } + + var input ProposalsInput + if err := method.Inputs.Copy(&input, args); err != nil { + return nil, fmt.Errorf("error while unpacking args to ProposalsInput: %s", err) + } + + voter := "" + if input.Voter != (common.Address{}) { + voter = sdk.AccAddress(input.Voter.Bytes()).String() + } + + depositor := "" + if input.Depositor != (common.Address{}) { + depositor = sdk.AccAddress(input.Depositor.Bytes()).String() + } + + return &govv1.QueryProposalsRequest{ + ProposalStatus: govv1.ProposalStatus(input.ProposalStatus), //nolint:gosec // G115 + Voter: voter, + Depositor: depositor, + Pagination: &input.Pagination, + }, nil +} + +func (po *ProposalOutput) FromResponse(res *govv1.QueryProposalResponse) *ProposalOutput { + msgs := make([]string, len(res.Proposal.Messages)) + for i, msg := range res.Proposal.Messages { + msgs[i] = msg.TypeUrl + } + + coins := make([]cmn.Coin, len(res.Proposal.TotalDeposit)) + for i, c := range res.Proposal.TotalDeposit { + coins[i] = cmn.Coin{ + Denom: c.Denom, + Amount: c.Amount.BigInt(), + } + } + + proposer, err := utils.Bech32ToHexAddr(res.Proposal.Proposer) + if err != nil { + return nil + } + + po.Proposal = ProposalData{ + Id: res.Proposal.Id, + Messages: msgs, + Status: uint32(res.Proposal.Status), //nolint:gosec // G115 + FinalTallyResult: TallyResultData{ + Yes: res.Proposal.FinalTallyResult.YesCount, + Abstain: res.Proposal.FinalTallyResult.AbstainCount, + No: res.Proposal.FinalTallyResult.NoCount, + NoWithVeto: res.Proposal.FinalTallyResult.NoWithVetoCount, + }, + SubmitTime: uint64(res.Proposal.SubmitTime.Unix()), //nolint:gosec // G115 + DepositEndTime: uint64(res.Proposal.DepositEndTime.Unix()), //nolint:gosec // G115 + TotalDeposit: coins, + VotingStartTime: uint64(res.Proposal.VotingStartTime.Unix()), //nolint:gosec // G115 + VotingEndTime: uint64(res.Proposal.VotingEndTime.Unix()), //nolint:gosec // G115 + Metadata: res.Proposal.Metadata, + Title: res.Proposal.Title, + Summary: res.Proposal.Summary, + Proposer: proposer, + } + return po +} + +func (po *ProposalsOutput) FromResponse(res *govv1.QueryProposalsResponse) *ProposalsOutput { + po.Proposals = make([]ProposalData, len(res.Proposals)) + for i, p := range res.Proposals { + msgs := make([]string, len(p.Messages)) + for j, msg := range p.Messages { + msgs[j] = msg.TypeUrl + } + + coins := make([]cmn.Coin, len(p.TotalDeposit)) + for j, c := range p.TotalDeposit { + coins[j] = cmn.Coin{ + Denom: c.Denom, + Amount: c.Amount.BigInt(), + } + } + + proposer, err := utils.Bech32ToHexAddr(p.Proposer) + if err != nil { + return nil + } + + po.Proposals[i] = ProposalData{ + Id: p.Id, + Messages: msgs, + Status: uint32(p.Status), //nolint:gosec // G115 + FinalTallyResult: TallyResultData{ + Yes: p.FinalTallyResult.YesCount, + Abstain: p.FinalTallyResult.AbstainCount, + No: p.FinalTallyResult.NoCount, + NoWithVeto: p.FinalTallyResult.NoWithVetoCount, + }, + SubmitTime: uint64(p.SubmitTime.Unix()), //nolint:gosec // G115 + DepositEndTime: uint64(p.DepositEndTime.Unix()), //nolint:gosec // G115 + TotalDeposit: coins, + VotingStartTime: uint64(p.VotingStartTime.Unix()), //nolint:gosec // G115 + VotingEndTime: uint64(p.VotingEndTime.Unix()), //nolint:gosec // G115 + Metadata: p.Metadata, + Title: p.Title, + Summary: p.Summary, + Proposer: proposer, + } + } + + if res.Pagination != nil { + po.PageResponse = query.PageResponse{ + NextKey: res.Pagination.NextKey, + Total: res.Pagination.Total, + } + } + return po +} diff --git a/precompiles/ics20/ics20.go b/precompiles/ics20/ics20.go index 18afc082..1a2864e3 100644 --- a/precompiles/ics20/ics20.go +++ b/precompiles/ics20/ics20.go @@ -11,6 +11,7 @@ import ( authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" channelkeeper "github.com/cosmos/ibc-go/v8/modules/core/04-channel/keeper" + "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/evmos/os/precompiles/authorization" cmn "github.com/evmos/os/precompiles/common" @@ -87,7 +88,7 @@ func (p Precompile) RequiredGas(input []byte) uint64 { return 0 } - return p.Precompile.RequiredGas(input, p.IsTransaction(method.Name)) + return p.Precompile.RequiredGas(input, p.IsTransaction(method)) } // Run executes the precompiled contract IBC transfer methods defined in the ABI. @@ -155,8 +156,8 @@ func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz [ // - Revoke // - IncreaseAllowance // - DecreaseAllowance -func (Precompile) IsTransaction(method string) bool { - switch method { +func (Precompile) IsTransaction(method *abi.Method) bool { + switch method.Name { case TransferMethod, authorization.ApproveMethod, authorization.RevokeMethod, diff --git a/precompiles/ics20/tx.go b/precompiles/ics20/tx.go index 9d25eb4a..1b2033c1 100644 --- a/precompiles/ics20/tx.go +++ b/precompiles/ics20/tx.go @@ -15,6 +15,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/evmos/os/x/evm/core/vm" + evmtypes "github.com/evmos/os/x/evm/types" cmn "github.com/evmos/os/precompiles/common" ) @@ -68,7 +69,7 @@ func (p *Precompile) Transfer( return nil, err } - evmDenom := p.evmKeeper.GetParams(ctx).EvmDenom + evmDenom := evmtypes.GetEVMCoinDenom() if contract.CallerAddress != origin && msg.Token.Denom == evmDenom { // escrow address is also changed on this tx, and it is not a module account // so we need to account for this on the UpdateDirties diff --git a/precompiles/slashing/ISlashing.sol b/precompiles/slashing/ISlashing.sol new file mode 100644 index 00000000..f06bb275 --- /dev/null +++ b/precompiles/slashing/ISlashing.sol @@ -0,0 +1,77 @@ +// SPDX-License-Identifier: LGPL-3.0-only +pragma solidity >=0.8.17; + +import "../common/Types.sol"; + +/// @dev The ISlashing contract's address. +address constant SLASHING_PRECOMPILE_ADDRESS = 0x0000000000000000000000000000000000000806; + +/// @dev The ISlashing contract's instance. +ISlashing constant SLASHING_CONTRACT = ISlashing(SLASHING_PRECOMPILE_ADDRESS); + +/// @dev SigningInfo defines a validator's signing info for monitoring their +/// liveness activity. +struct SigningInfo { + /// @dev Address of the validator + address validatorAddress; + /// @dev Height at which validator was first a candidate OR was unjailed + uint64 startHeight; + /// @dev Index offset into signed block bit array + uint64 indexOffset; + /// @dev Timestamp until which validator is jailed due to liveness downtime + uint64 jailedUntil; + /// @dev Whether or not a validator has been tombstoned (killed out of validator set) + bool tombstoned; + /// @dev Missed blocks counter (to avoid scanning the array every time) + uint64 missedBlocksCounter; +} + +/// @dev Params defines the parameters for the slashing module. +struct Params { + /// @dev SignedBlocksWindow defines how many blocks the validator should have signed + uint64 signedBlocksWindow; + /// @dev MinSignedPerWindow defines the minimum blocks signed per window to avoid slashing + string minSignedPerWindow; + /// @dev DowntimeJailDuration defines how long the validator will be jailed for downtime + uint64 downtimeJailDuration; + /// @dev SlashFractionDoubleSign defines the percentage of slash for double sign + string slashFractionDoubleSign; + /// @dev SlashFractionDowntime defines the percentage of slash for downtime + string slashFractionDowntime; +} + +/// @author Evmos Team +/// @title Slashing Precompiled Contract +/// @dev The interface through which solidity contracts will interact with slashing. +/// We follow this same interface including four-byte function selectors, in the precompile that +/// wraps the pallet. +/// @custom:address 0x0000000000000000000000000000000000000806 +interface ISlashing { + /// @dev Emitted when a validator is unjailed + /// @param validator The address of the validator + event ValidatorUnjailed(address indexed validator); + + /// @dev GetSigningInfo returns the signing info for a specific validator. + /// @param consAddress The validator consensus address + /// @return signingInfo The validator signing info + function getSigningInfo( + address consAddress + ) external view returns (SigningInfo memory signingInfo); + + /// @dev GetSigningInfos returns the signing info for all validators. + /// @param pagination Pagination configuration for the query + /// @return signingInfos The list of validator signing info + /// @return pageResponse Pagination information for the response + function getSigningInfos( + PageRequest calldata pagination + ) external view returns (SigningInfo[] memory signingInfos, PageResponse memory pageResponse); + + /// @dev Unjail allows validators to unjail themselves after being jailed for downtime + /// @param validatorAddress The validator operator address to unjail + /// @return success true if the unjail operation was successful + function unjail(address validatorAddress) external returns (bool success); + + /// @dev GetParams returns the slashing module parameters + /// @return params The slashing module parameters + function getParams() external view returns (Params memory params); +} diff --git a/precompiles/slashing/abi.json b/precompiles/slashing/abi.json new file mode 100644 index 00000000..7651de5d --- /dev/null +++ b/precompiles/slashing/abi.json @@ -0,0 +1,229 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "ISlashing", + "sourceName": "solidity/precompiles/slashing/ISlashing.sol", + "abi": [ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "validator", + "type": "address" + } + ], + "name": "ValidatorUnjailed", + "type": "event" + }, + { + "inputs": [], + "name": "getParams", + "outputs": [ + { + "components": [ + { + "internalType": "uint64", + "name": "signedBlocksWindow", + "type": "uint64" + }, + { + "internalType": "string", + "name": "minSignedPerWindow", + "type": "string" + }, + { + "internalType": "uint64", + "name": "downtimeJailDuration", + "type": "uint64" + }, + { + "internalType": "string", + "name": "slashFractionDoubleSign", + "type": "string" + }, + { + "internalType": "string", + "name": "slashFractionDowntime", + "type": "string" + } + ], + "internalType": "struct Params", + "name": "params", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "consAddress", + "type": "address" + } + ], + "name": "getSigningInfo", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "validatorAddress", + "type": "address" + }, + { + "internalType": "uint64", + "name": "startHeight", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "indexOffset", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "jailedUntil", + "type": "uint64" + }, + { + "internalType": "bool", + "name": "tombstoned", + "type": "bool" + }, + { + "internalType": "uint64", + "name": "missedBlocksCounter", + "type": "uint64" + } + ], + "internalType": "struct SigningInfo", + "name": "signingInfo", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "bytes", + "name": "key", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "offset", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "limit", + "type": "uint64" + }, + { + "internalType": "bool", + "name": "countTotal", + "type": "bool" + }, + { + "internalType": "bool", + "name": "reverse", + "type": "bool" + } + ], + "internalType": "struct PageRequest", + "name": "pagination", + "type": "tuple" + } + ], + "name": "getSigningInfos", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "validatorAddress", + "type": "address" + }, + { + "internalType": "uint64", + "name": "startHeight", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "indexOffset", + "type": "uint64" + }, + { + "internalType": "uint64", + "name": "jailedUntil", + "type": "uint64" + }, + { + "internalType": "bool", + "name": "tombstoned", + "type": "bool" + }, + { + "internalType": "uint64", + "name": "missedBlocksCounter", + "type": "uint64" + } + ], + "internalType": "struct SigningInfo[]", + "name": "signingInfos", + "type": "tuple[]" + }, + { + "components": [ + { + "internalType": "bytes", + "name": "nextKey", + "type": "bytes" + }, + { + "internalType": "uint64", + "name": "total", + "type": "uint64" + } + ], + "internalType": "struct PageResponse", + "name": "pageResponse", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "validatorAddress", + "type": "address" + } + ], + "name": "unjail", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": "0x", + "deployedBytecode": "0x", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/precompiles/slashing/events.go b/precompiles/slashing/events.go new file mode 100644 index 00000000..798d5d3d --- /dev/null +++ b/precompiles/slashing/events.go @@ -0,0 +1,46 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/ethereum/go-ethereum/common" + ethtypes "github.com/ethereum/go-ethereum/core/types" + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/x/evm/core/vm" +) + +const ( + // EventTypeValidatorUnjailed defines the event type for validator unjailing + EventTypeValidatorUnjailed = "ValidatorUnjailed" +) + +// Add this struct after the existing constants +type EventValidatorUnjailed struct { + Validator common.Address +} + +// EmitValidatorUnjailedEvent emits the ValidatorUnjailed event +func (p Precompile) EmitValidatorUnjailedEvent(ctx sdk.Context, stateDB vm.StateDB, validator common.Address) error { + // Prepare the event topics + event := p.ABI.Events[EventTypeValidatorUnjailed] + topics := make([]common.Hash, 2) + + // The first topic is always the signature of the event + topics[0] = event.ID + + var err error + topics[1], err = cmn.MakeTopic(validator) + if err != nil { + return err + } + + stateDB.AddLog(ðtypes.Log{ + Address: p.Address(), + Topics: topics, + BlockNumber: uint64(ctx.BlockHeight()), //nolint:gosec // G115 + }) + + return nil +} diff --git a/precompiles/slashing/events_test.go b/precompiles/slashing/events_test.go new file mode 100644 index 00000000..47ca318c --- /dev/null +++ b/precompiles/slashing/events_test.go @@ -0,0 +1,104 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing_test + +import ( + "math/big" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/crypto" + + storetypes "cosmossdk.io/store/types" + sdk "github.com/cosmos/cosmos-sdk/types" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/precompiles/slashing" + "github.com/evmos/os/x/evm/core/vm" + "github.com/evmos/os/x/evm/statedb" +) + +func (s *PrecompileTestSuite) TestUnjailEvent() { + var ( + stateDB *statedb.StateDB + ctx sdk.Context + method = s.precompile.Methods[slashing.UnjailMethod] + ) + + testCases := []struct { + name string + malleate func() []interface{} + postCheck func() + gas uint64 + expError bool + errContains string + }{ + { + "success - the correct event is emitted", + func() []interface{} { + validator, err := s.network.App.StakingKeeper.GetValidator(ctx, sdk.ValAddress(s.keyring.GetAccAddr(0))) + s.Require().NoError(err) + + consAddr, err := validator.GetConsAddr() + s.Require().NoError(err) + + err = s.network.App.SlashingKeeper.Jail( + s.network.GetContext(), + consAddr, + ) + s.Require().NoError(err) + + return []interface{}{ + s.keyring.GetAddr(0), + } + }, + func() { + log := stateDB.Logs()[0] + s.Require().Equal(log.Address, s.precompile.Address()) + + // Check event signature matches the one emitted + event := s.precompile.ABI.Events[slashing.EventTypeValidatorUnjailed] + s.Require().Equal(crypto.Keccak256Hash([]byte(event.Sig)), common.HexToHash(log.Topics[0].Hex())) + s.Require().Equal(log.BlockNumber, uint64(ctx.BlockHeight())) //nolint:gosec // G115 + + // Check the validator address in the event matches + hash, err := cmn.MakeTopic(s.keyring.GetAddr(0)) + s.Require().NoError(err) + + s.Require().Equal(hash, log.Topics[1]) + + // Check the fully unpacked event matches the one emitted + var unjailEvent slashing.EventValidatorUnjailed + err = cmn.UnpackLog(s.precompile.ABI, &unjailEvent, slashing.EventTypeValidatorUnjailed, *log) + s.Require().NoError(err) + s.Require().Equal(s.keyring.GetAddr(0), unjailEvent.Validator) + }, + 20000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + stateDB = s.network.GetStateDB() + ctx = s.network.GetContext() + + contract := vm.NewContract(vm.AccountRef(s.keyring.GetAddr(0)), s.precompile, big.NewInt(0), tc.gas) + ctx = ctx.WithGasMeter(storetypes.NewInfiniteGasMeter()) + initialGas := ctx.GasMeter().GasConsumed() + s.Require().Zero(initialGas) + + _, err := s.precompile.Unjail(ctx, &method, stateDB, contract, tc.malleate()) + + if tc.expError { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } else { + s.Require().NoError(err) + tc.postCheck() + } + }) + } +} diff --git a/precompiles/slashing/query.go b/precompiles/slashing/query.go new file mode 100644 index 00000000..a3580ee6 --- /dev/null +++ b/precompiles/slashing/query.go @@ -0,0 +1,78 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/slashing/types" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/evmos/os/x/evm/core/vm" +) + +const ( + // GetSigningInfoMethod defines the ABI method name for the slashing SigningInfo query + GetSigningInfoMethod = "getSigningInfo" + // GetSigningInfosMethod defines the ABI method name for the slashing SigningInfos query + GetSigningInfosMethod = "getSigningInfos" + // GetParamsMethod defines the ABI method name for the slashing Params query + GetParamsMethod = "getParams" +) + +// GetSigningInfo implements the query to get a validator's signing info. +func (p *Precompile) GetSigningInfo( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + req, err := ParseSigningInfoArgs(args) + if err != nil { + return nil, err + } + + res, err := p.slashingKeeper.SigningInfo(ctx, req) + if err != nil { + return nil, err + } + + out := new(SigningInfoOutput).FromResponse(res) + return method.Outputs.Pack(out.SigningInfo) +} + +// GetSigningInfos implements the query to get signing info for all validators. +func (p *Precompile) GetSigningInfos( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + req, err := ParseSigningInfosArgs(method, args) + if err != nil { + return nil, err + } + + res, err := p.slashingKeeper.SigningInfos(ctx, req) + if err != nil { + return nil, err + } + + out := new(SigningInfosOutput).FromResponse(res) + return method.Outputs.Pack(out.SigningInfos, out.PageResponse) +} + +// GetParams implements the query to get the slashing parameters. +func (p *Precompile) GetParams( + ctx sdk.Context, + method *abi.Method, + _ *vm.Contract, + _ []interface{}, +) ([]byte, error) { + res, err := p.slashingKeeper.Params(ctx, &types.QueryParamsRequest{}) + if err != nil { + return nil, err + } + + out := new(ParamsOutput).FromResponse(res) + return method.Outputs.Pack(out.Params) +} diff --git a/precompiles/slashing/query_test.go b/precompiles/slashing/query_test.go new file mode 100644 index 00000000..59e277df --- /dev/null +++ b/precompiles/slashing/query_test.go @@ -0,0 +1,261 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing_test + +import ( + "fmt" + + "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/query" + slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" + "github.com/ethereum/go-ethereum/common" + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/precompiles/slashing" + "github.com/evmos/os/precompiles/testutil" +) + +func (s *PrecompileTestSuite) TestGetSigningInfo() { + method := s.precompile.Methods[slashing.GetSigningInfoMethod] + + testCases := []struct { + name string + malleate func() []interface{} + postCheck func(signingInfo *slashing.SigningInfo) + gas uint64 + expError bool + errContains string + }{ + { + "fail - empty input args", + func() []interface{} { + return []interface{}{} + }, + func(_ *slashing.SigningInfo) {}, + 200000, + true, + fmt.Sprintf(cmn.ErrInvalidNumberOfArgs, 1, 0), + }, + { + "fail - invalid consensus address", + func() []interface{} { + return []interface{}{ + common.Address{}, + } + }, + func(_ *slashing.SigningInfo) {}, + 200000, + true, + "invalid consensus address", + }, + { + "success - get signing info for validator", + func() []interface{} { + err := s.network.App.SlashingKeeper.SetValidatorSigningInfo( + s.network.GetContext(), + types.ConsAddress(s.keyring.GetAddr(0).Bytes()), + slashingtypes.ValidatorSigningInfo{ + StartHeight: 1, + IndexOffset: 2, + MissedBlocksCounter: 1, + Tombstoned: false, + }, + ) + s.Require().NoError(err) + return []interface{}{ + s.keyring.GetAddr(0), + } + }, + func(signingInfo *slashing.SigningInfo) { + s.Require().Equal(uint64(1), signingInfo.StartHeight) + s.Require().Equal(uint64(2), signingInfo.IndexOffset) + s.Require().Equal(uint64(1), signingInfo.MissedBlocksCounter) + s.Require().False(signingInfo.Tombstoned) + }, + 200000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + + contract, ctx := testutil.NewPrecompileContract(s.T(), s.network.GetContext(), s.keyring.GetAddr(0), s.precompile, tc.gas) + + bz, err := s.precompile.GetSigningInfo(ctx, &method, contract, tc.malleate()) + + if tc.expError { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } else { + s.Require().NoError(err) + var out slashing.SigningInfoOutput + err = s.precompile.UnpackIntoInterface(&out, slashing.GetSigningInfoMethod, bz) + s.Require().NoError(err) + tc.postCheck(&out.SigningInfo) + } + }) + } +} + +func (s *PrecompileTestSuite) TestGetSigningInfos() { + method := s.precompile.Methods[slashing.GetSigningInfosMethod] + + testCases := []struct { + name string + malleate func() []interface{} + postCheck func(signingInfos []slashing.SigningInfo, pageResponse *query.PageResponse) + gas uint64 + expError bool + errContains string + }{ + { + "fail - empty input args", + func() []interface{} { + return []interface{}{} + }, + func(_ []slashing.SigningInfo, _ *query.PageResponse) {}, + 200000, + true, + fmt.Sprintf(cmn.ErrInvalidNumberOfArgs, 1, 0), + }, + { + "success - get all signing infos", + func() []interface{} { + return []interface{}{ + query.PageRequest{ + Limit: 10, + CountTotal: true, + }, + } + }, + func(signingInfos []slashing.SigningInfo, pageResponse *query.PageResponse) { + s.Require().Len(signingInfos, 3) + s.Require().Equal(uint64(3), pageResponse.Total) + + // Check first validator's signing info + s.Require().Equal(uint64(0), signingInfos[0].StartHeight) + s.Require().Equal(uint64(1), signingInfos[0].IndexOffset) + s.Require().Equal(uint64(18446744011573954816), signingInfos[0].JailedUntil) + s.Require().False(signingInfos[0].Tombstoned) + + // Check second validator's signing info + s.Require().Equal(uint64(0), signingInfos[1].StartHeight) + s.Require().Equal(uint64(1), signingInfos[1].IndexOffset) + s.Require().Equal(uint64(18446744011573954816), signingInfos[1].JailedUntil) + s.Require().False(signingInfos[1].Tombstoned) + + // Check third validator's signing info + s.Require().Equal(uint64(0), signingInfos[2].StartHeight) + s.Require().Equal(uint64(1), signingInfos[2].IndexOffset) + s.Require().Equal(uint64(18446744011573954816), signingInfos[2].JailedUntil) + s.Require().False(signingInfos[2].Tombstoned) + }, + 200000, + false, + "", + }, + { + "success - get signing infos with pagination", + func() []interface{} { + return []interface{}{ + query.PageRequest{ + Limit: 1, + CountTotal: true, + }, + } + }, + func(signingInfos []slashing.SigningInfo, pageResponse *query.PageResponse) { + s.Require().Len(signingInfos, 1) + s.Require().Equal(uint64(3), pageResponse.Total) + s.Require().NotNil(pageResponse.NextKey) + + // Check first validator's signing info + s.Require().Equal(uint64(0), signingInfos[0].StartHeight) + s.Require().Equal(uint64(1), signingInfos[0].IndexOffset) + s.Require().Equal(uint64(18446744011573954816), signingInfos[0].JailedUntil) + s.Require().False(signingInfos[0].Tombstoned) + }, + 200000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + + contract, ctx := testutil.NewPrecompileContract(s.T(), s.network.GetContext(), s.keyring.GetAddr(0), s.precompile, tc.gas) + + bz, err := s.precompile.GetSigningInfos(ctx, &method, contract, tc.malleate()) + + if tc.expError { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } else { + s.Require().NoError(err) + var out slashing.SigningInfosOutput + err = s.precompile.UnpackIntoInterface(&out, slashing.GetSigningInfosMethod, bz) + s.Require().NoError(err) + tc.postCheck(out.SigningInfos, &out.PageResponse) + } + }) + } +} + +func (s *PrecompileTestSuite) TestGetParams() { + method := s.precompile.Methods[slashing.GetParamsMethod] + + testCases := []struct { + name string + malleate func() []interface{} + postCheck func(params *slashing.Params) + gas uint64 + expError bool + errContains string + }{ + { + "success - get params", + func() []interface{} { + return []interface{}{} + }, + func(params *slashing.Params) { + // Get the default params from the network + defaultParams, err := s.network.App.SlashingKeeper.GetParams(s.network.GetContext()) + s.Require().NoError(err) + s.Require().Equal(uint64(defaultParams.SignedBlocksWindow), params.SignedBlocksWindow) //nolint:gosec // G115 + s.Require().Equal(defaultParams.MinSignedPerWindow.String(), params.MinSignedPerWindow) + s.Require().Equal(uint64(defaultParams.DowntimeJailDuration.Seconds()), params.DowntimeJailDuration) + s.Require().Equal(defaultParams.SlashFractionDoubleSign.String(), params.SlashFractionDoubleSign) + s.Require().Equal(defaultParams.SlashFractionDowntime.String(), params.SlashFractionDowntime) + }, + 200000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + + contract, ctx := testutil.NewPrecompileContract(s.T(), s.network.GetContext(), s.keyring.GetAddr(0), s.precompile, tc.gas) + + bz, err := s.precompile.GetParams(ctx, &method, contract, tc.malleate()) + + if tc.expError { + s.Require().Error(err) + s.Require().Contains(err.Error(), tc.errContains) + } else { + s.Require().NoError(err) + var out slashing.ParamsOutput + err = s.precompile.UnpackIntoInterface(&out, slashing.GetParamsMethod, bz) + s.Require().NoError(err) + tc.postCheck(&out.Params) + } + }) + } +} diff --git a/precompiles/slashing/setup_test.go b/precompiles/slashing/setup_test.go new file mode 100644 index 00000000..4dab6629 --- /dev/null +++ b/precompiles/slashing/setup_test.go @@ -0,0 +1,61 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing_test + +import ( + "testing" + + sdk "github.com/cosmos/cosmos-sdk/types" + + "github.com/evmos/os/precompiles/slashing" + "github.com/evmos/os/testutil/integration/os/factory" + "github.com/evmos/os/testutil/integration/os/grpc" + testkeyring "github.com/evmos/os/testutil/integration/os/keyring" + "github.com/evmos/os/testutil/integration/os/network" + + "github.com/stretchr/testify/suite" +) + +type PrecompileTestSuite struct { + suite.Suite + + network *network.UnitTestNetwork + factory factory.TxFactory + grpcHandler grpc.Handler + keyring testkeyring.Keyring + + precompile *slashing.Precompile +} + +func TestPrecompileTestSuite(t *testing.T) { + suite.Run(t, new(PrecompileTestSuite)) +} + +func (s *PrecompileTestSuite) SetupTest() { + keyring := testkeyring.New(3) + var err error + nw := network.NewUnitTestNetwork( + network.WithPreFundedAccounts(keyring.GetAllAccAddrs()...), + network.WithValidatorOperators([]sdk.AccAddress{ + keyring.GetAccAddr(0), + keyring.GetAccAddr(1), + keyring.GetAccAddr(2), + }), + ) + + grpcHandler := grpc.NewIntegrationHandler(nw) + txFactory := factory.New(nw, grpcHandler) + + s.network = nw + s.factory = txFactory + s.grpcHandler = grpcHandler + s.keyring = keyring + + if s.precompile, err = slashing.NewPrecompile( + s.network.App.SlashingKeeper, + s.network.App.AuthzKeeper, + ); err != nil { + panic(err) + } +} diff --git a/precompiles/slashing/slashing.go b/precompiles/slashing/slashing.go new file mode 100644 index 00000000..0ff4d8d6 --- /dev/null +++ b/precompiles/slashing/slashing.go @@ -0,0 +1,145 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing + +import ( + "embed" + "fmt" + + slashingkeeper "github.com/cosmos/cosmos-sdk/x/slashing/keeper" + + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" + sdk "github.com/cosmos/cosmos-sdk/types" + authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/x/evm/core/vm" + evmtypes "github.com/evmos/os/x/evm/types" +) + +var _ vm.PrecompiledContract = &Precompile{} + +// Embed abi json file to the executable binary. Needed when importing as dependency. +// +//go:embed abi.json +var f embed.FS + +// Precompile defines the precompiled contract for slashing. +type Precompile struct { + cmn.Precompile + slashingKeeper slashingkeeper.Keeper +} + +// LoadABI loads the slashing ABI from the embedded abi.json file +// for the slashing precompile. +func LoadABI() (abi.ABI, error) { + return cmn.LoadABI(f, "abi.json") +} + +// NewPrecompile creates a new slashing Precompile instance as a +// PrecompiledContract interface. +func NewPrecompile( + slashingKeeper slashingkeeper.Keeper, + authzKeeper authzkeeper.Keeper, +) (*Precompile, error) { + abi, err := LoadABI() + if err != nil { + return nil, err + } + + p := &Precompile{ + Precompile: cmn.Precompile{ + ABI: abi, + AuthzKeeper: authzKeeper, + KvGasConfig: storetypes.KVGasConfig(), + TransientKVGasConfig: storetypes.TransientGasConfig(), + ApprovalExpiration: cmn.DefaultExpirationDuration, // should be configurable in the future. + }, + slashingKeeper: slashingKeeper, + } + + // SetAddress defines the address of the slashing precompiled contract. + p.SetAddress(common.HexToAddress(evmtypes.SlashingPrecompileAddress)) + + return p, nil +} + +// RequiredGas calculates the precompiled contract's base gas rate. +func (p Precompile) RequiredGas(input []byte) uint64 { + // NOTE: This check avoid panicking when trying to decode the method ID + if len(input) < 4 { + return 0 + } + methodID := input[:4] + + method, err := p.MethodById(methodID) + if err != nil { + // This should never happen since this method is going to fail during Run + return 0 + } + + return p.Precompile.RequiredGas(input, p.IsTransaction(method)) +} + +// Run executes the precompiled contract slashing methods defined in the ABI. +func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz []byte, err error) { + ctx, stateDB, snapshot, method, initialGas, args, err := p.RunSetup(evm, contract, readOnly, p.IsTransaction) + if err != nil { + return nil, err + } + + // This handles any out of gas errors that may occur during the execution of a precompile tx or query. + // It avoids panics and returns the out of gas error so the EVM can continue gracefully. + defer cmn.HandleGasError(ctx, contract, initialGas, &err)() + + switch method.Name { + // slashing transactions + case UnjailMethod: + bz, err = p.Unjail(ctx, method, stateDB, contract, args) + // slashing queries + case GetSigningInfoMethod: + bz, err = p.GetSigningInfo(ctx, method, contract, args) + case GetSigningInfosMethod: + bz, err = p.GetSigningInfos(ctx, method, contract, args) + default: + return nil, fmt.Errorf(cmn.ErrUnknownMethod, method.Name) + } + + if err != nil { + return nil, err + } + + cost := ctx.GasMeter().GasConsumed() - initialGas + + if !contract.UseGas(cost) { + return nil, vm.ErrOutOfGas + } + + if err := p.AddJournalEntries(stateDB, snapshot); err != nil { + return nil, err + } + + return bz, nil +} + +// IsTransaction checks if the given method name corresponds to a transaction or query. +// +// Available slashing transactions are: +// - Unjail +func (Precompile) IsTransaction(method *abi.Method) bool { + switch method.Name { + case UnjailMethod: + return true + default: + return false + } +} + +// Logger returns a precompile-specific logger. +func (p Precompile) Logger(ctx sdk.Context) log.Logger { + return ctx.Logger().With("evm extension", "slashing") +} diff --git a/precompiles/slashing/tx.go b/precompiles/slashing/tx.go new file mode 100644 index 00000000..5aa11623 --- /dev/null +++ b/precompiles/slashing/tx.go @@ -0,0 +1,57 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing + +import ( + "fmt" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/x/evm/core/vm" + + sdk "github.com/cosmos/cosmos-sdk/types" + slashingkeeper "github.com/cosmos/cosmos-sdk/x/slashing/keeper" + "github.com/cosmos/cosmos-sdk/x/slashing/types" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" +) + +const ( + // UnjailMethod defines the ABI method name for the slashing Unjail + // transaction. + UnjailMethod = "unjail" +) + +// Unjail implements the unjail precompile transaction, which allows validators +// to unjail themselves after being jailed for downtime. +func (p Precompile) Unjail( + ctx sdk.Context, + method *abi.Method, + stateDB vm.StateDB, + _ *vm.Contract, + args []interface{}, +) ([]byte, error) { + if len(args) != 1 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 1, len(args)) + } + + validatorAddress, ok := args[0].(common.Address) + if !ok { + return nil, fmt.Errorf("invalid validator hex address") + } + + msg := &types.MsgUnjail{ + ValidatorAddr: sdk.ValAddress(validatorAddress.Bytes()).String(), + } + + msgSrv := slashingkeeper.NewMsgServerImpl(p.slashingKeeper) + if _, err := msgSrv.Unjail(ctx, msg); err != nil { + return nil, err + } + + if err := p.EmitValidatorUnjailedEvent(ctx, stateDB, validatorAddress); err != nil { + return nil, err + } + + return method.Outputs.Pack(true) +} diff --git a/precompiles/slashing/tx_test.go b/precompiles/slashing/tx_test.go new file mode 100644 index 00000000..ecff0c6a --- /dev/null +++ b/precompiles/slashing/tx_test.go @@ -0,0 +1,141 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing_test + +import ( + "fmt" + + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/ethereum/go-ethereum/common" + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/precompiles/slashing" + "github.com/evmos/os/precompiles/testutil" + utiltx "github.com/evmos/os/testutil/tx" +) + +func (s *PrecompileTestSuite) TestUnjail() { + method := s.precompile.Methods[slashing.UnjailMethod] + testCases := []struct { + name string + malleate func() []interface{} + postCheck func() + gas uint64 + expError bool + errContains string + }{ + { + "fail - empty input args", + func() []interface{} { + return []interface{}{} + }, + func() {}, + 200000, + true, + fmt.Sprintf(cmn.ErrInvalidNumberOfArgs, 1, 0), + }, + { + "fail - invalid validator address", + func() []interface{} { + return []interface{}{ + "", + } + }, + func() {}, + 200000, + true, + "invalid validator hex address", + }, + { + "fail - invalid validator address (empty address)", + func() []interface{} { + return []interface{}{ + common.Address{}, + } + }, + func() {}, + 200000, + true, + "validator does not exist", + }, + { + "fail - validator not found", + func() []interface{} { + return []interface{}{ + utiltx.GenerateAddress(), + } + }, + func() {}, + 200000, + true, + "validator does not exist", + }, + { + "fail - validator not jailed", + func() []interface{} { + return []interface{}{ + s.keyring.GetAddr(0), + } + }, + func() {}, + 200000, + true, + "validator not jailed", + }, + { + "success - validator unjailed", + func() []interface{} { + validator, err := s.network.App.StakingKeeper.GetValidator(s.network.GetContext(), sdk.ValAddress(s.keyring.GetAccAddr(0))) + s.Require().NoError(err) + + valConsAddr, err := validator.GetConsAddr() + s.Require().NoError(err) + err = s.network.App.SlashingKeeper.Jail( + s.network.GetContext(), + valConsAddr, + ) + s.Require().NoError(err) + + validatorAfterJail, err := s.network.App.StakingKeeper.GetValidator(s.network.GetContext(), sdk.ValAddress(s.keyring.GetAddr(0).Bytes())) + s.Require().NoError(err) + s.Require().True(validatorAfterJail.IsJailed()) + + return []interface{}{ + s.keyring.GetAddr(0), + } + }, + func() { + validatorAfterUnjail, err := s.network.App.StakingKeeper.GetValidator(s.network.GetContext(), sdk.ValAddress(s.keyring.GetAddr(0).Bytes())) + s.Require().NoError(err) + s.Require().False(validatorAfterUnjail.IsJailed()) + }, + 200000, + false, + "", + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest() + + contract, ctx := testutil.NewPrecompileContract( + s.T(), + s.network.GetContext(), + s.keyring.GetAddr(0), + s.precompile, + tc.gas, + ) + + res, err := s.precompile.Unjail(ctx, &method, s.network.GetStateDB(), contract, tc.malleate()) + + if tc.expError { + s.Require().ErrorContains(err, tc.errContains) + } else { + s.Require().NoError(err) + s.Require().Equal(cmn.TrueValue, res) + tc.postCheck() + } + }) + } +} diff --git a/precompiles/slashing/types.go b/precompiles/slashing/types.go new file mode 100644 index 00000000..dfa811a1 --- /dev/null +++ b/precompiles/slashing/types.go @@ -0,0 +1,137 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package slashing + +import ( + "fmt" + + "github.com/cosmos/cosmos-sdk/types" + + "github.com/cosmos/cosmos-sdk/types/query" + slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + cmn "github.com/evmos/os/precompiles/common" +) + +// SigningInfo represents the signing info for a validator +type SigningInfo struct { + ValidatorAddress common.Address `abi:"validatorAddress"` + StartHeight uint64 `abi:"startHeight"` + IndexOffset uint64 `abi:"indexOffset"` + JailedUntil uint64 `abi:"jailedUntil"` + Tombstoned bool `abi:"tombstoned"` + MissedBlocksCounter uint64 `abi:"missedBlocksCounter"` +} + +// SigningInfoOutput represents the output of the signing info query +type SigningInfoOutput struct { + SigningInfo SigningInfo +} + +// SigningInfosOutput represents the output of the signing infos query +type SigningInfosOutput struct { + SigningInfos []SigningInfo `abi:"signingInfos"` + PageResponse query.PageResponse `abi:"pageResponse"` +} + +// SigningInfosInput represents the input for the signing infos query +type SigningInfosInput struct { + Pagination query.PageRequest `abi:"pagination"` +} + +// ParseSigningInfoArgs parses the arguments for the signing info query +func ParseSigningInfoArgs(args []interface{}) (*slashingtypes.QuerySigningInfoRequest, error) { + if len(args) != 1 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 1, len(args)) + } + + hexAddr, ok := args[0].(common.Address) + if !ok || hexAddr == (common.Address{}) { + return nil, fmt.Errorf("invalid consensus address") + } + + return &slashingtypes.QuerySigningInfoRequest{ + ConsAddress: types.ConsAddress(hexAddr.Bytes()).String(), + }, nil +} + +// ParseSigningInfosArgs parses the arguments for the signing infos query +func ParseSigningInfosArgs(method *abi.Method, args []interface{}) (*slashingtypes.QuerySigningInfosRequest, error) { + if len(args) != 1 { + return nil, fmt.Errorf(cmn.ErrInvalidNumberOfArgs, 1, len(args)) + } + + var input SigningInfosInput + if err := method.Inputs.Copy(&input, args); err != nil { + return nil, fmt.Errorf("error while unpacking args to SigningInfosInput: %s", err) + } + + return &slashingtypes.QuerySigningInfosRequest{ + Pagination: &input.Pagination, + }, nil +} + +func (sio *SigningInfoOutput) FromResponse(res *slashingtypes.QuerySigningInfoResponse) *SigningInfoOutput { + sio.SigningInfo = SigningInfo{ + ValidatorAddress: common.BytesToAddress([]byte(res.ValSigningInfo.Address)), + StartHeight: uint64(res.ValSigningInfo.StartHeight), //nolint:gosec // G115 + IndexOffset: uint64(res.ValSigningInfo.IndexOffset), //nolint:gosec // G115 + JailedUntil: uint64(res.ValSigningInfo.JailedUntil.Unix()), //nolint:gosec // G115 + Tombstoned: res.ValSigningInfo.Tombstoned, + MissedBlocksCounter: uint64(res.ValSigningInfo.MissedBlocksCounter), //nolint:gosec // G115 + } + return sio +} + +func (sio *SigningInfosOutput) FromResponse(res *slashingtypes.QuerySigningInfosResponse) *SigningInfosOutput { + sio.SigningInfos = make([]SigningInfo, len(res.Info)) + for i, info := range res.Info { + sio.SigningInfos[i] = SigningInfo{ + ValidatorAddress: common.BytesToAddress([]byte(info.Address)), + StartHeight: uint64(info.StartHeight), //nolint:gosec // G115 + IndexOffset: uint64(info.IndexOffset), //nolint:gosec // G115 + JailedUntil: uint64(info.JailedUntil.Unix()), //nolint:gosec // G115 + Tombstoned: info.Tombstoned, + MissedBlocksCounter: uint64(info.MissedBlocksCounter), //nolint:gosec // G115 + } + } + if res.Pagination != nil { + sio.PageResponse = query.PageResponse{ + NextKey: res.Pagination.NextKey, + Total: res.Pagination.Total, + } + } + return sio +} + +// ValidatorUnjailed defines the data structure for the ValidatorUnjailed event. +type ValidatorUnjailed struct { + Validator common.Address +} + +// Params defines the parameters for the slashing module +type Params struct { + SignedBlocksWindow uint64 `abi:"signedBlocksWindow"` + MinSignedPerWindow string `abi:"minSignedPerWindow"` + DowntimeJailDuration uint64 `abi:"downtimeJailDuration"` + SlashFractionDoubleSign string `abi:"slashFractionDoubleSign"` + SlashFractionDowntime string `abi:"slashFractionDowntime"` +} + +// ParamsOutput represents the output of the params query +type ParamsOutput struct { + Params Params +} + +func (po *ParamsOutput) FromResponse(res *slashingtypes.QueryParamsResponse) *ParamsOutput { + po.Params = Params{ + SignedBlocksWindow: uint64(res.Params.SignedBlocksWindow), //nolint:gosec // G115 + MinSignedPerWindow: res.Params.MinSignedPerWindow.String(), + DowntimeJailDuration: uint64(res.Params.DowntimeJailDuration.Seconds()), + SlashFractionDoubleSign: res.Params.SlashFractionDoubleSign.String(), + SlashFractionDowntime: res.Params.SlashFractionDowntime.String(), + } + return po +} diff --git a/precompiles/staking/StakingI.sol b/precompiles/staking/StakingI.sol index 5ebe752c..5abeff88 100644 --- a/precompiles/staking/StakingI.sol +++ b/precompiles/staking/StakingI.sol @@ -166,7 +166,8 @@ interface StakingI is authorization.AuthorizationI { /// @dev Defines a method for performing a delegation of coins from a delegator to a validator. /// @param delegatorAddress The address of the delegator /// @param validatorAddress The address of the validator - /// @param amount The amount of the Coin to be delegated to the validator + /// @param amount The amount of the bond denomination to be delegated to the validator. + /// This amount should use the bond denomination precision stored in the bank metadata. /// @return success Whether or not the delegate was successful function delegate( address delegatorAddress, @@ -177,7 +178,8 @@ interface StakingI is authorization.AuthorizationI { /// @dev Defines a method for performing an undelegation from a delegate and a validator. /// @param delegatorAddress The address of the delegator /// @param validatorAddress The address of the validator - /// @param amount The amount to be undelegated from the validator + /// @param amount The amount of the bond denomination to be undelegated from the validator. + /// This amount should use the bond denomination precision stored in the bank metadata. /// @return completionTime The time when the undelegation is completed function undelegate( address delegatorAddress, @@ -190,7 +192,8 @@ interface StakingI is authorization.AuthorizationI { /// @param delegatorAddress The address of the delegator /// @param validatorSrcAddress The validator from which the redelegation is initiated /// @param validatorDstAddress The validator to which the redelegation is destined - /// @param amount The amount to be redelegated to the validator + /// @param amount The amount of the bond denomination to be redelegated to the validator + /// This amount should use the bond denomination precision stored in the bank metadata. /// @return completionTime The time when the redelegation is completed function redelegate( address delegatorAddress, @@ -203,7 +206,8 @@ interface StakingI is authorization.AuthorizationI { /// and to delegate back to a previous validator. /// @param delegatorAddress The address of the delegator /// @param validatorAddress The address of the validator - /// @param amount The amount of the Coin + /// @param amount The amount of the bond denomination + /// This amount should use the bond denomination precision stored in the bank metadata. /// @param creationHeight The height at which the unbonding took place /// @return success Whether or not the unbonding delegation was cancelled function cancelUnbondingDelegation( @@ -218,6 +222,7 @@ interface StakingI is authorization.AuthorizationI { /// @param validatorAddress The address of the validator. /// @return shares The amount of shares, that the delegator has received. /// @return balance The amount in Coin, that the delegator has delegated to the given validator. + /// This returned balance uses the bond denomination precision stored in the bank metadata. function delegation( address delegatorAddress, string memory validatorAddress @@ -310,7 +315,8 @@ interface StakingI is authorization.AuthorizationI { /// delegator address to the validator address. /// @param delegatorAddress The address of the delegator /// @param validatorAddress The address of the validator - /// @param amount The amount of Coin being delegated + /// @param amount The amount of bond denomination being delegated + /// This amount has the bond denomination precision stored in the bank metadata. /// @param newShares The new delegation shares being held event Delegate( address indexed delegatorAddress, @@ -323,7 +329,8 @@ interface StakingI is authorization.AuthorizationI { /// validator address to the delegator address. /// @param delegatorAddress The address of the delegator /// @param validatorAddress The address of the validator - /// @param amount The amount of Coin being unbonded + /// @param amount The amount of bond denomination being unbonded + /// This amount has the bond denomination precision stored in the bank metadata. /// @param completionTime The time at which the unbonding is completed event Unbond( address indexed delegatorAddress, @@ -337,7 +344,8 @@ interface StakingI is authorization.AuthorizationI { /// @param delegatorAddress The address of the delegator /// @param validatorSrcAddress The address of the validator from which the delegation is retracted /// @param validatorDstAddress The address of the validator to which the delegation is directed - /// @param amount The amount of Coin being redelegated + /// @param amount The amount of bond denomination being redelegated + /// This amount has the bond denomination precision stored in the bank metadata. /// @param completionTime The time at which the redelegation is completed event Redelegate( address indexed delegatorAddress, @@ -351,7 +359,8 @@ interface StakingI is authorization.AuthorizationI { /// that are in the process of unbonding from the validator address are bonded again. /// @param delegatorAddress The address of the delegator /// @param validatorAddress The address of the validator - /// @param amount The amount of Coin that was in the unbonding process which is to be canceled + /// @param amount The amount of bond denomination that was in the unbonding process which is to be canceled + /// This amount has the bond denomination precision stored in the bank metadata. /// @param creationHeight The block height at which the unbonding of a delegation was initiated event CancelUnbondingDelegation( address indexed delegatorAddress, diff --git a/precompiles/staking/approve_test.go b/precompiles/staking/approve_test.go index ace3ca6a..8da9a74f 100644 --- a/precompiles/staking/approve_test.go +++ b/precompiles/staking/approve_test.go @@ -712,7 +712,6 @@ func (s *PrecompileTestSuite) TestRevoke() { } for _, tc := range testCases { - tc := tc s.Run(tc.name, func() { s.SetupTest() // reset ctx = s.network.GetContext() diff --git a/precompiles/staking/integration_test.go b/precompiles/staking/integration_test.go index b0745dc5..ded3a6d9 100644 --- a/precompiles/staking/integration_test.go +++ b/precompiles/staking/integration_test.go @@ -102,6 +102,9 @@ var _ = Describe("Calling staking precompile directly", func() { defaultLogCheck = testutil.LogCheckArgs{ABIEvents: s.precompile.ABI.Events} passCheck = defaultLogCheck.WithExpPass(true) outOfGasCheck = defaultLogCheck.WithErrContains(vm.ErrOutOfGas.Error()) + + oneE18Coin = sdk.NewCoin(s.bondDenom, math.NewInt(1e18)) + twoE18Coin = sdk.NewCoin(s.bondDenom, math.NewInt(2e18)) }) Describe("when the precompile is not enabled in the EVM params", func() { @@ -1740,7 +1743,7 @@ var _ = Describe("Calling staking precompile directly", func() { It("Should refund leftover gas", func() { delegator := s.keyring.GetKey(0) - resBal, err := s.grpcHandler.GetBalance(delegator.AccAddr, s.bondDenom) + resBal, err := s.grpcHandler.GetBalanceFromBank(delegator.AccAddr, s.bondDenom) Expect(err).To(BeNil(), "error while getting balance") balancePre := resBal.Balance gasPrice := big.NewInt(1e9) @@ -1761,7 +1764,7 @@ var _ = Describe("Calling staking precompile directly", func() { Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) Expect(s.network.NextBlock()).To(BeNil()) - resBal, err = s.grpcHandler.GetBalance(delegator.AccAddr, s.bondDenom) + resBal, err = s.grpcHandler.GetBalanceFromBank(delegator.AccAddr, s.bondDenom) Expect(err).To(BeNil(), "error while getting balance") balancePost := resBal.Balance difference := balancePre.Sub(*balancePost) @@ -2492,10 +2495,10 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { // set approval for the StakingReverter contract s.SetupApproval(s.keyring.GetPrivKey(0), stkReverterAddr, delAmt.BigInt(), []string{staking.DelegateMsg}) - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) txSenderInitialBal = balRes.Balance - balRes, err = s.grpcHandler.GetBalance(stkReverterAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(stkReverterAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractInitialBalance = balRes.Balance }) @@ -2525,7 +2528,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { fees := gasPrice.MulRaw(res.GasUsed) // contract balance should remain unchanged - balRes, err := s.grpcHandler.GetBalance(stkReverterAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(stkReverterAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBalance := balRes.Balance Expect(contractFinalBalance.Amount).To(Equal(contractInitialBalance.Amount)) @@ -2536,7 +2539,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { Expect(err.Error()).To(ContainSubstring("not found"), "expected NO delegation created") // Only fees deducted on tx sender - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) txSenderFinalBal := balRes.Balance Expect(txSenderFinalBal.Amount).To(Equal(txSenderInitialBal.Amount.Sub(fees))) @@ -2564,7 +2567,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) // contract balance should remain unchanged - balRes, err := s.grpcHandler.GetBalance(stkReverterAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(stkReverterAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBalance := balRes.Balance Expect(contractFinalBalance.Amount).To(Equal(contractInitialBalance.Amount)) @@ -2610,13 +2613,13 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { To: &contractTwoAddr, }, args) - balRes, err := s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) delegatorInitialBal = balRes.Balance - balRes, err = s.grpcHandler.GetBalance(contractTwoAddr.Bytes(), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(contractTwoAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractInitialBalance = balRes.Balance - balRes, err = s.grpcHandler.GetBalance(bondedTokensPoolAccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(bondedTokensPoolAccAddr, s.bondDenom) Expect(err).To(BeNil()) bondedTokensPoolInitialBalance = balRes.Balance @@ -2655,7 +2658,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { fees := gasPrice.MulRaw(res.GasUsed) // check the contract's balance was deducted to fund the vesting account - balRes, err := s.grpcHandler.GetBalance(contractTwoAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(contractTwoAddr.Bytes(), s.bondDenom) contractFinalBal := balRes.Balance Expect(err).To(BeNil()) Expect(contractFinalBal.Amount).To(Equal(contractInitialBalance.Amount.Sub(transferToDelAmt))) @@ -2667,13 +2670,13 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { expShares := prevDelegation.GetShares().Add(math.LegacyNewDec(1)) Expect(delegation.GetShares()).To(Equal(expShares), "expected delegation shares to be 2") - balRes, err = s.grpcHandler.GetBalance(s.keyring.GetAccAddr(0), s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(s.keyring.GetAccAddr(0), s.bondDenom) Expect(err).To(BeNil()) delegatorFinalBal := balRes.Balance Expect(delegatorFinalBal.Amount).To(Equal(delegatorInitialBal.Amount.Sub(fees).Sub(delAmt).Add(transferToDelAmt))) // check the bondedTokenPool is updated with the delegated tokens - balRes, err = s.grpcHandler.GetBalance(bondedTokensPoolAccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(bondedTokensPoolAccAddr, s.bondDenom) bondedTokensPoolFinalBalance := balRes.Balance Expect(err).To(BeNil()) Expect(bondedTokensPoolFinalBalance.Amount).To(Equal(bondedTokensPoolInitialBalance.Amount.Add(delAmt))) @@ -2709,13 +2712,13 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { Expect(s.network.NextBlock()).To(BeNil()) // contract balance should remain unchanged - balRes, err := s.grpcHandler.GetBalance(contractTwoAddr.Bytes(), s.bondDenom) + balRes, err := s.grpcHandler.GetBalanceFromBank(contractTwoAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil()) contractFinalBal := balRes.Balance Expect(contractFinalBal.Amount).To(Equal(contractInitialBalance.Amount)) // check the bondedTokenPool should remain unchanged - balRes, err = s.grpcHandler.GetBalance(bondedTokensPoolAccAddr, s.bondDenom) + balRes, err = s.grpcHandler.GetBalanceFromBank(bondedTokensPoolAccAddr, s.bondDenom) Expect(err).To(BeNil()) bondedTokensPoolFinalBalance := balRes.Balance Expect(bondedTokensPoolFinalBalance.Amount).To(Equal(bondedTokensPoolInitialBalance.Amount)) @@ -3960,7 +3963,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { // Set up funding for the contract address. // NOTE: we are first asserting that no balance exists and then check successful // funding afterwards. - resBal, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + resBal, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil(), "error while getting balance") balanceBefore := resBal.Balance @@ -3970,7 +3973,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { Expect(err).To(BeNil(), "error while funding account") Expect(s.network.NextBlock()).To(BeNil()) - resBal, err = s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + resBal, err = s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil(), "error while getting balance") balanceAfterFunding := resBal.Balance @@ -4007,7 +4010,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { Expect(res.DelegationResponse).NotTo(BeNil()) Expect(res.DelegationResponse.Delegation.GetShares().BigInt()).To(Equal(delegationAmount), "expected different delegation shares") - resBal, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + resBal, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil(), "error while getting balance") postBalance := resBal.Balance @@ -4036,7 +4039,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) Expect(s.network.NextBlock()).To(BeNil()) - resBal, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + resBal, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil(), "error while getting balance") balance := resBal.Balance @@ -4065,7 +4068,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) Expect(s.network.NextBlock()).To(BeNil()) - resBal, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + resBal, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil(), "error while getting balance") balance := resBal.Balance @@ -4096,7 +4099,7 @@ var _ = Describe("Calling staking precompile via Solidity", Ordered, func() { Expect(err).To(BeNil(), "error while calling the smart contract: %v", err) Expect(s.network.NextBlock()).To(BeNil()) - resBal, err := s.grpcHandler.GetBalance(contractAddr.Bytes(), s.bondDenom) + resBal, err := s.grpcHandler.GetBalanceFromBank(contractAddr.Bytes(), s.bondDenom) Expect(err).To(BeNil(), "error while getting balance") balance := resBal.Balance diff --git a/precompiles/staking/staking.go b/precompiles/staking/staking.go index c84dfe85..bcb2640e 100644 --- a/precompiles/staking/staking.go +++ b/precompiles/staking/staking.go @@ -80,7 +80,7 @@ func (p Precompile) RequiredGas(input []byte) uint64 { return 0 } - return p.Precompile.RequiredGas(input, p.IsTransaction(method.Name)) + return p.Precompile.RequiredGas(input, p.IsTransaction(method)) } // Run executes the precompiled contract staking methods defined in the ABI. @@ -167,8 +167,8 @@ func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz [ // - Revoke // - IncreaseAllowance // - DecreaseAllowance -func (Precompile) IsTransaction(method string) bool { - switch method { +func (Precompile) IsTransaction(method *abi.Method) bool { + switch method.Name { case CreateValidatorMethod, EditValidatorMethod, DelegateMethod, diff --git a/precompiles/staking/staking_test.go b/precompiles/staking/staking_test.go index 3a71737e..8f1436af 100644 --- a/precompiles/staking/staking_test.go +++ b/precompiles/staking/staking_test.go @@ -4,13 +4,13 @@ import ( "math/big" "time" - chainutil "github.com/evmos/os/example_chain/testutil" - "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" + chainutil "github.com/evmos/os/example_chain/testutil" "github.com/evmos/os/precompiles/authorization" "github.com/evmos/os/precompiles/staking" testconstants "github.com/evmos/os/testutil/constants" @@ -23,64 +23,64 @@ import ( func (s *PrecompileTestSuite) TestIsTransaction() { testCases := []struct { name string - method string + method abi.Method isTx bool }{ { authorization.ApproveMethod, - s.precompile.Methods[authorization.ApproveMethod].Name, + s.precompile.Methods[authorization.ApproveMethod], true, }, { authorization.IncreaseAllowanceMethod, - s.precompile.Methods[authorization.IncreaseAllowanceMethod].Name, + s.precompile.Methods[authorization.IncreaseAllowanceMethod], true, }, { authorization.DecreaseAllowanceMethod, - s.precompile.Methods[authorization.DecreaseAllowanceMethod].Name, + s.precompile.Methods[authorization.DecreaseAllowanceMethod], true, }, { staking.CreateValidatorMethod, - s.precompile.Methods[staking.CreateValidatorMethod].Name, + s.precompile.Methods[staking.CreateValidatorMethod], true, }, { staking.DelegateMethod, - s.precompile.Methods[staking.DelegateMethod].Name, + s.precompile.Methods[staking.DelegateMethod], true, }, { staking.UndelegateMethod, - s.precompile.Methods[staking.UndelegateMethod].Name, + s.precompile.Methods[staking.UndelegateMethod], true, }, { staking.RedelegateMethod, - s.precompile.Methods[staking.RedelegateMethod].Name, + s.precompile.Methods[staking.RedelegateMethod], true, }, { staking.CancelUnbondingDelegationMethod, - s.precompile.Methods[staking.CancelUnbondingDelegationMethod].Name, + s.precompile.Methods[staking.CancelUnbondingDelegationMethod], true, }, { staking.DelegationMethod, - s.precompile.Methods[staking.DelegationMethod].Name, + s.precompile.Methods[staking.DelegationMethod], false, }, { "invalid", - "invalid", + abi.Method{}, false, }, } for _, tc := range testCases { s.Run(tc.name, func() { - s.Require().Equal(s.precompile.IsTransaction(tc.method), tc.isTx) + s.Require().Equal(s.precompile.IsTransaction(&tc.method), tc.isTx) }) } } @@ -431,7 +431,7 @@ func (s *PrecompileTestSuite) TestRun() { s.SetupTest() ctx = s.network.GetContext().WithBlockTime(time.Now()) - baseFee := s.network.App.FeeMarketKeeper.GetBaseFee(ctx) + baseFee := s.network.App.EVMKeeper.GetBaseFee(ctx) delegator := s.keyring.GetKey(0) grantee := s.keyring.GetKey(1) @@ -444,7 +444,7 @@ func (s *PrecompileTestSuite) TestRun() { // Build and sign Ethereum transaction txArgs := evmtypes.EvmTxArgs{ - ChainID: s.network.App.EVMKeeper.ChainID(), + ChainID: evmtypes.GetEthChainConfig().ChainID, Nonce: 0, To: &contractAddr, Amount: nil, @@ -460,7 +460,7 @@ func (s *PrecompileTestSuite) TestRun() { // Instantiate config proposerAddress := ctx.BlockHeader().ProposerAddress - cfg, err := s.network.App.EVMKeeper.EVMConfig(ctx, proposerAddress, s.network.App.EVMKeeper.ChainID()) + cfg, err := s.network.App.EVMKeeper.EVMConfig(ctx, proposerAddress) s.Require().NoError(err, "failed to instantiate EVM config") // Instantiate EVM diff --git a/precompiles/staking/tx.go b/precompiles/staking/tx.go index 36dd3e94..bf43645a 100644 --- a/precompiles/staking/tx.go +++ b/precompiles/staking/tx.go @@ -9,14 +9,14 @@ import ( "time" sdk "github.com/cosmos/cosmos-sdk/types" + stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/evmos/os/precompiles/authorization" cmn "github.com/evmos/os/precompiles/common" "github.com/evmos/os/x/evm/core/vm" - - stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" + evmtypes "github.com/evmos/os/x/evm/types" ) const ( @@ -233,14 +233,17 @@ func (p *Precompile) Delegate( return nil, err } - if !isCallerOrigin { + if !isCallerOrigin && msg.Amount.Denom == evmtypes.GetEVMCoinDenom() { // get the delegator address from the message delAccAddr := sdk.MustAccAddressFromBech32(msg.DelegatorAddress) delHexAddr := common.BytesToAddress(delAccAddr) // NOTE: This ensures that the changes in the bank keeper are correctly mirrored to the EVM stateDB // when calling the precompile from a smart contract // This prevents the stateDB from overwriting the changed balance in the bank keeper when committing the EVM state. - p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(delHexAddr, msg.Amount.Amount.BigInt(), cmn.Sub)) + + // Need to scale the amount to 18 decimals for the EVM balance change entry + scaledAmt := evmtypes.ConvertAmountTo18DecimalsBigInt(msg.Amount.Amount.BigInt()) + p.SetBalanceChangeEntries(cmn.NewBalanceChangeEntry(delHexAddr, scaledAmt, cmn.Sub)) } return method.Outputs.Pack(true) diff --git a/precompiles/testutil/contracts/InterchainSender.json b/precompiles/testutil/contracts/InterchainSender.json index 2d6d645a..ba8e5aa8 100644 --- a/precompiles/testutil/contracts/InterchainSender.json +++ b/precompiles/testutil/contracts/InterchainSender.json @@ -558,8 +558,8 @@ "type": "function" } ], - "bytecode": "0x608060405234801561001057600080fd5b50613818806100206000396000f3fe608060405234801561001057600080fd5b50600436106100cf5760003560e01c8063a363df841161008c578063dfa10f3911610066578063dfa10f3914610210578063ee5766d914610241578063f298e7a814610271578063f3675f081461028d576100cf565b8063a363df8414610194578063b9672879146101c4578063c595699a146101e0576100cf565b80631dba685b146100d4578063424af9f6146100f057806361bc221a1461010c5780636fdf23cc1461012a5780637492bdd81461015a5780637a6185e11461018a575b600080fd5b6100ee60048036038101906100e99190611302565b6102a9565b005b61010a6004803603810190610105919061149c565b61070f565b005b6101146107e9565b6040516101219190611581565b60405180910390f35b610144600480360381019061013f9190611636565b6107fa565b6040516101519190611788565b60405180910390f35b610174600480360381019061016f9190611636565b610898565b6040516101819190611788565b60405180910390f35b610192610936565b005b6101ae60048036038101906101a991906117e1565b6109fb565b6040516101bb9190611bc4565b60405180910390f35b6101de60048036038101906101d99190611be6565b610a88565b005b6101fa60048036038101906101f59190611d20565b610d4b565b6040516102079190611db3565b60405180910390f35b61022a60048036038101906102259190611df9565b610dd5565b604051610238929190611fe9565b60405180910390f35b61025b60048036038101906102569190611d20565b610e69565b6040516102689190612064565b60405180910390f35b61028b6004803603810190610286919061149c565b610ef9565b005b6102a760048036038101906102a291906120dc565b610fd3565b005b82156103a65760008081819054906101000a900460070b809291906102cd90612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008973ffffffffffffffffffffffffffffffffffffffff16600f60405161031e906121b9565b60006040518083038185875af1925050503d806000811461035b576040519150601f19603f3d011682016040523d82523d6000602084013e610360565b606091505b50509050806103a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161039b90612240565b60405180910390fd5b505b60006040518060400160405280606467ffffffffffffffff168152602001606467ffffffffffffffff16815250905061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a60028b610403919061228f565b8f8b8860006040518963ffffffff1660e01b815260040161042b9897969594939291906123bb565b6020604051808303816000875af115801561044a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061046e919061247f565b50821561056c5760008081819054906101000a900460070b8092919061049390612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16600f6040516104e4906121b9565b60006040518083038185875af1925050503d8060008114610521576040519150601f19603f3d011682016040523d82523d6000602084013e610526565b606091505b505090508061056a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161056190612240565b60405180910390fd5b505b61080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a60028b61059a919061228f565b8f8b8860006040518963ffffffff1660e01b81526004016105c29897969594939291906123bb565b6020604051808303816000875af11580156105e1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610605919061247f565b5081156107035760008081819054906101000a900460070b8092919061062a90612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16600f60405161067b906121b9565b60006040518083038185875af1925050503d80600081146106b8576040519150601f19603f3d011682016040523d82523d6000602084013e6106bd565b606091505b5050905080610701576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106f890612240565b60405180910390fd5b505b50505050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff166354de647b308a8a8a8a8a8a8a6040518963ffffffff1660e01b815260040161075a9897969594939291906124e8565b6020604051808303816000875af1158015610779573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061079d919061256b565b9050806107df576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d6906125e4565b60405180910390fd5b5050505050505050565b60008054906101000a900460070b81565b600061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a8a308b8b8b8b6040518a63ffffffff1660e01b815260040161084799989796959493929190612604565b6020604051808303816000875af1158015610866573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061088a919061247f565b905098975050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a8a338b8b8b8b6040518a63ffffffff1660e01b81526004016108e599989796959493929190612604565b6020604051808303816000875af1158015610904573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610928919061247f565b905098975050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff166374a8f103306040518263ffffffff1660e01b815260040161097391906126b5565b6020604051808303816000875af1158015610992573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b6919061256b565b9050806109f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109ef9061271c565b60405180910390fd5b50565b606061080273ffffffffffffffffffffffffffffffffffffffff1663dd62ed3e84846040518363ffffffff1660e01b8152600401610a3a92919061273c565b600060405180830381865afa158015610a57573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610a809190612c11565b905092915050565b8115610b855760008081819054906101000a900460070b80929190610aac90612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008973ffffffffffffffffffffffffffffffffffffffff16600f604051610afd906121b9565b60006040518083038185875af1925050503d8060008114610b3a576040519150601f19603f3d011682016040523d82523d6000602084013e610b3f565b606091505b5050905080610b83576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b7a90612240565b60405180910390fd5b505b60006040518060400160405280606467ffffffffffffffff168152602001606467ffffffffffffffff16815250905061080273ffffffffffffffffffffffffffffffffffffffff1663632535b9898989898e8a8860006040518963ffffffff1660e01b8152600401610bfe989796959493929190612c5a565b6020604051808303816000875af1158015610c1d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c41919061247f565b508115610d3f5760008081819054906101000a900460070b80929190610c6690612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16600f604051610cb7906121b9565b60006040518083038185875af1925050503d8060008114610cf4576040519150601f19603f3d011682016040523d82523d6000602084013e610cf9565b606091505b5050905080610d3d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d3490612240565b60405180910390fd5b505b50505050505050505050565b606061080273ffffffffffffffffffffffffffffffffffffffff1663b5cb6e7d836040518263ffffffff1660e01b8152600401610d889190611db3565b600060405180830381865afa158015610da5573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610dce9190612d09565b9050919050565b6060610ddf61109e565b61080273ffffffffffffffffffffffffffffffffffffffff166322b6fad6846040518263ffffffff1660e01b8152600401610e1a9190612ece565b600060405180830381865afa158015610e37573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610e609190613166565b91509150915091565b610e716110c2565b61080273ffffffffffffffffffffffffffffffffffffffff1663a815cdd9836040518263ffffffff1660e01b8152600401610eac9190611db3565b600060405180830381865afa158015610ec9573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610ef291906131de565b9050919050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663b3f536ec308a8a8a8a8a8a8a6040518963ffffffff1660e01b8152600401610f449897969594939291906124e8565b6020604051808303816000875af1158015610f63573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f87919061256b565b905080610fc9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fc090613273565b60405180910390fd5b5050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663473c90c73085856040518463ffffffff1660e01b815260040161101493929190613744565b6020604051808303816000875af1158015611033573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611057919061256b565b905080611099576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611090906137c2565b60405180910390fd5b505050565b604051806040016040528060608152602001600067ffffffffffffffff1681525090565b604051806040016040528060608152602001606081525090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061111b826110f0565b9050919050565b61112b81611110565b811461113657600080fd5b50565b60008135905061114881611122565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6111a182611158565b810181811067ffffffffffffffff821117156111c0576111bf611169565b5b80604052505050565b60006111d36110dc565b90506111df8282611198565b919050565b600067ffffffffffffffff8211156111ff576111fe611169565b5b61120882611158565b9050602081019050919050565b82818337600083830152505050565b6000611237611232846111e4565b6111c9565b90508281526020810184848401111561125357611252611153565b5b61125e848285611215565b509392505050565b600082601f83011261127b5761127a61114e565b5b813561128b848260208601611224565b91505092915050565b6000819050919050565b6112a781611294565b81146112b257600080fd5b50565b6000813590506112c48161129e565b92915050565b60008115159050919050565b6112df816112ca565b81146112ea57600080fd5b50565b6000813590506112fc816112d6565b92915050565b60008060008060008060008060006101208a8c031215611325576113246110e6565b5b60006113338c828d01611139565b99505060208a013567ffffffffffffffff811115611354576113536110eb565b5b6113608c828d01611266565b98505060408a013567ffffffffffffffff811115611381576113806110eb565b5b61138d8c828d01611266565b97505060608a013567ffffffffffffffff8111156113ae576113ad6110eb565b5b6113ba8c828d01611266565b96505060806113cb8c828d016112b5565b95505060a08a013567ffffffffffffffff8111156113ec576113eb6110eb565b5b6113f88c828d01611266565b94505060c06114098c828d016112ed565b93505060e061141a8c828d016112ed565b92505061010061142c8c828d016112ed565b9150509295985092959850929598565b600080fd5b600080fd5b60008083601f84011261145c5761145b61114e565b5b8235905067ffffffffffffffff8111156114795761147861143c565b5b60208301915083600182028301111561149557611494611441565b5b9250929050565b60008060008060008060006080888a0312156114bb576114ba6110e6565b5b600088013567ffffffffffffffff8111156114d9576114d86110eb565b5b6114e58a828b01611446565b9750975050602088013567ffffffffffffffff811115611508576115076110eb565b5b6115148a828b01611446565b9550955050604088013567ffffffffffffffff811115611537576115366110eb565b5b6115438a828b01611446565b935093505060606115568a828b016112b5565b91505092959891949750929550565b60008160070b9050919050565b61157b81611565565b82525050565b60006020820190506115966000830184611572565b92915050565b600080fd5b600080fd5b600067ffffffffffffffff82169050919050565b6115c3816115a6565b81146115ce57600080fd5b50565b6000813590506115e0816115ba565b92915050565b6000604082840312156115fc576115fb61159c565b5b61160660406111c9565b90506000611616848285016115d1565b600083015250602061162a848285016115d1565b60208301525092915050565b600080600080600080600080610120898b031215611657576116566110e6565b5b600089013567ffffffffffffffff811115611675576116746110eb565b5b6116818b828c01611266565b985050602089013567ffffffffffffffff8111156116a2576116a16110eb565b5b6116ae8b828c01611266565b975050604089013567ffffffffffffffff8111156116cf576116ce6110eb565b5b6116db8b828c01611266565b96505060606116ec8b828c016112b5565b955050608089013567ffffffffffffffff81111561170d5761170c6110eb565b5b6117198b828c01611266565b94505060a061172a8b828c016115e6565b93505060e061173b8b828c016115d1565b92505061010089013567ffffffffffffffff81111561175d5761175c6110eb565b5b6117698b828c01611266565b9150509295985092959890939650565b611782816115a6565b82525050565b600060208201905061179d6000830184611779565b92915050565b60006117ae826110f0565b9050919050565b6117be816117a3565b81146117c957600080fd5b50565b6000813590506117db816117b5565b92915050565b600080604083850312156117f8576117f76110e6565b5b6000611806858286016117cc565b9250506020611817858286016117cc565b9150509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561188757808201518184015260208101905061186c565b60008484015250505050565b600061189e8261184d565b6118a88185611858565b93506118b8818560208601611869565b6118c181611158565b840191505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61190181611294565b82525050565b600060408301600083015184820360008601526119248282611893565b915050602083015161193960208601826118f8565b508091505092915050565b60006119508383611907565b905092915050565b6000602082019050919050565b6000611970826118cc565b61197a81856118d7565b93508360208202850161198c856118e8565b8060005b858110156119c857848403895281516119a98582611944565b94506119b483611958565b925060208a01995050600181019050611990565b50829750879550505050505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000611a128383611893565b905092915050565b6000602082019050919050565b6000611a32826119da565b611a3c81856119e5565b935083602082028501611a4e856119f6565b8060005b85811015611a8a5784840389528151611a6b8582611a06565b9450611a7683611a1a565b925060208a01995050600181019050611a52565b50829750879550505050505092915050565b600060a0830160008301518482036000860152611ab98282611893565b91505060208301518482036020860152611ad38282611893565b91505060408301518482036040860152611aed8282611965565b91505060608301518482036060860152611b078282611a27565b91505060808301518482036080860152611b218282611a27565b9150508091505092915050565b6000611b3a8383611a9c565b905092915050565b6000602082019050919050565b6000611b5a82611821565b611b64818561182c565b935083602082028501611b768561183d565b8060005b85811015611bb25784840389528151611b938582611b2e565b9450611b9e83611b42565b925060208a01995050600181019050611b7a565b50829750879550505050505092915050565b60006020820190508181036000830152611bde8184611b4f565b905092915050565b60008060008060008060008060006101208a8c031215611c0957611c086110e6565b5b6000611c178c828d01611139565b9950506020611c288c828d016117cc565b98505060408a013567ffffffffffffffff811115611c4957611c486110eb565b5b611c558c828d01611266565b97505060608a013567ffffffffffffffff811115611c7657611c756110eb565b5b611c828c828d01611266565b96505060808a013567ffffffffffffffff811115611ca357611ca26110eb565b5b611caf8c828d01611266565b95505060a0611cc08c828d016112b5565b94505060c08a013567ffffffffffffffff811115611ce157611ce06110eb565b5b611ced8c828d01611266565b93505060e0611cfe8c828d016112ed565b925050610100611d108c828d016112ed565b9150509295985092959850929598565b600060208284031215611d3657611d356110e6565b5b600082013567ffffffffffffffff811115611d5457611d536110eb565b5b611d6084828501611266565b91505092915050565b600082825260208201905092915050565b6000611d858261184d565b611d8f8185611d69565b9350611d9f818560208601611869565b611da881611158565b840191505092915050565b60006020820190508181036000830152611dcd8184611d7a565b905092915050565b600080fd5b600060a08284031215611df057611def611dd5565b5b81905092915050565b600060208284031215611e0f57611e0e6110e6565b5b600082013567ffffffffffffffff811115611e2d57611e2c6110eb565b5b611e3984828501611dda565b91505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60006040830160008301518482036000860152611e8b8282611893565b91505060208301518482036020860152611ea58282611893565b9150508091505092915050565b6000611ebe8383611e6e565b905092915050565b6000602082019050919050565b6000611ede82611e42565b611ee88185611e4d565b935083602082028501611efa85611e5e565b8060005b85811015611f365784840389528151611f178582611eb2565b9450611f2283611ec6565b925060208a01995050600181019050611efe565b50829750879550505050505092915050565b600081519050919050565b600082825260208201905092915050565b6000611f6f82611f48565b611f798185611f53565b9350611f89818560208601611869565b611f9281611158565b840191505092915050565b611fa6816115a6565b82525050565b60006040830160008301518482036000860152611fc98282611f64565b9150506020830151611fde6020860182611f9d565b508091505092915050565b600060408201905081810360008301526120038185611ed3565b905081810360208301526120178184611fac565b90509392505050565b6000604083016000830151848203600086015261203d8282611893565b915050602083015184820360208601526120578282611893565b9150508091505092915050565b6000602082019050818103600083015261207e8184612020565b905092915050565b60008083601f84011261209c5761209b61114e565b5b8235905067ffffffffffffffff8111156120b9576120b861143c565b5b6020830191508360208202830111156120d5576120d4611441565b5b9250929050565b600080602083850312156120f3576120f26110e6565b5b600083013567ffffffffffffffff811115612111576121106110eb565b5b61211d85828601612086565b92509250509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061216382611565565b9150677fffffffffffffff820361217d5761217c612129565b5b600182019050919050565b600081905092915050565b50565b60006121a3600083612188565b91506121ae82612193565b600082019050919050565b60006121c482612196565b9150819050919050565b7f4661696c656420746f2073656e6420457468657220746f2064656c656761746f60008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b600061222a602183611d69565b9150612235826121ce565b604082019050919050565b600060208201905081810360008301526122598161221d565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061229a82611294565b91506122a583611294565b9250826122b5576122b4612260565b5b828204905092915050565b6122c981611294565b82525050565b6000819050919050565b60006122f46122ef6122ea846110f0565b6122cf565b6110f0565b9050919050565b6000612306826122d9565b9050919050565b6000612318826122fb565b9050919050565b6123288161230d565b82525050565b6040820160008201516123446000850182611f9d565b5060208201516123576020850182611f9d565b50505050565b6000819050919050565b600061238261237d6123788461235d565b6122cf565b6115a6565b9050919050565b61239281612367565b82525050565b60006123a5600083611d69565b91506123b082612193565b600082019050919050565b60006101408201905081810360008301526123d6818b611d7a565b905081810360208301526123ea818a611d7a565b905081810360408301526123fe8189611d7a565b905061240d60608301886122c0565b61241a608083018761231f565b81810360a083015261242c8186611d7a565b905061243b60c083018561232e565b612449610100830184612389565b81810361012083015261245b81612398565b90509998505050505050505050565b600081519050612479816115ba565b92915050565b600060208284031215612495576124946110e6565b5b60006124a38482850161246a565b91505092915050565b6124b5816117a3565b82525050565b60006124c78385611d69565b93506124d4838584611215565b6124dd83611158565b840190509392505050565b600060a0820190506124fd600083018b6124ac565b818103602083015261251081898b6124bb565b905081810360408301526125258187896124bb565b9050818103606083015261253a8185876124bb565b905061254960808301846122c0565b9998505050505050505050565b600081519050612565816112d6565b92915050565b600060208284031215612581576125806110e6565b5b600061258f84828501612556565b91505092915050565b7f4661696c656420746f20696e63726561736520616c6c6f77616e636500000000600082015250565b60006125ce601c83611d69565b91506125d982612598565b602082019050919050565b600060208201905081810360008301526125fd816125c1565b9050919050565b600061014082019050818103600083015261261f818c611d7a565b90508181036020830152612633818b611d7a565b90508181036040830152612647818a611d7a565b905061265660608301896122c0565b61266360808301886124ac565b81810360a08301526126758187611d7a565b905061268460c083018661232e565b612692610100830185611779565b8181036101208301526126a58184611d7a565b90509a9950505050505050505050565b60006020820190506126ca60008301846124ac565b92915050565b7f4661696c656420746f207265766f6b6520617070726f76616c00000000000000600082015250565b6000612706601983611d69565b9150612711826126d0565b602082019050919050565b60006020820190508181036000830152612735816126f9565b9050919050565b600060408201905061275160008301856124ac565b61275e60208301846124ac565b9392505050565b600067ffffffffffffffff8211156127805761277f611169565b5b602082029050602081019050919050565b60006127a461279f846111e4565b6111c9565b9050828152602081018484840111156127c0576127bf611153565b5b6127cb848285611869565b509392505050565b600082601f8301126127e8576127e761114e565b5b81516127f8848260208601612791565b91505092915050565b600067ffffffffffffffff82111561281c5761281b611169565b5b602082029050602081019050919050565b60008151905061283c8161129e565b92915050565b6000604082840312156128585761285761159c565b5b61286260406111c9565b9050600082015167ffffffffffffffff811115612882576128816115a1565b5b61288e848285016127d3565b60008301525060206128a28482850161282d565b60208301525092915050565b60006128c16128bc84612801565b6111c9565b905080838252602082019050602084028301858111156128e4576128e3611441565b5b835b8181101561292b57805167ffffffffffffffff8111156129095761290861114e565b5b8086016129168982612842565b855260208501945050506020810190506128e6565b5050509392505050565b600082601f83011261294a5761294961114e565b5b815161295a8482602086016128ae565b91505092915050565b600067ffffffffffffffff82111561297e5761297d611169565b5b602082029050602081019050919050565b60006129a261299d84612963565b6111c9565b905080838252602082019050602084028301858111156129c5576129c4611441565b5b835b81811015612a0c57805167ffffffffffffffff8111156129ea576129e961114e565b5b8086016129f789826127d3565b855260208501945050506020810190506129c7565b5050509392505050565b600082601f830112612a2b57612a2a61114e565b5b8151612a3b84826020860161298f565b91505092915050565b600060a08284031215612a5a57612a5961159c565b5b612a6460a06111c9565b9050600082015167ffffffffffffffff811115612a8457612a836115a1565b5b612a90848285016127d3565b600083015250602082015167ffffffffffffffff811115612ab457612ab36115a1565b5b612ac0848285016127d3565b602083015250604082015167ffffffffffffffff811115612ae457612ae36115a1565b5b612af084828501612935565b604083015250606082015167ffffffffffffffff811115612b1457612b136115a1565b5b612b2084828501612a16565b606083015250608082015167ffffffffffffffff811115612b4457612b436115a1565b5b612b5084828501612a16565b60808301525092915050565b6000612b6f612b6a84612765565b6111c9565b90508083825260208201905060208402830185811115612b9257612b91611441565b5b835b81811015612bd957805167ffffffffffffffff811115612bb757612bb661114e565b5b808601612bc48982612a44565b85526020850194505050602081019050612b94565b5050509392505050565b600082601f830112612bf857612bf761114e565b5b8151612c08848260208601612b5c565b91505092915050565b600060208284031215612c2757612c266110e6565b5b600082015167ffffffffffffffff811115612c4557612c446110eb565b5b612c5184828501612be3565b91505092915050565b6000610140820190508181036000830152612c75818b611d7a565b90508181036020830152612c89818a611d7a565b90508181036040830152612c9d8189611d7a565b9050612cac60608301886122c0565b612cb960808301876124ac565b81810360a0830152612ccb8186611d7a565b9050612cda60c083018561232e565b612ce8610100830184612389565b818103610120830152612cfa81612398565b90509998505050505050505050565b600060208284031215612d1f57612d1e6110e6565b5b600082015167ffffffffffffffff811115612d3d57612d3c6110eb565b5b612d49848285016127d3565b91505092915050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112612d7e57612d7d612d5c565b5b83810192508235915060208301925067ffffffffffffffff821115612da657612da5612d52565b5b600182023603831315612dbc57612dbb612d57565b5b509250929050565b6000612dd08385611f53565b9350612ddd838584611215565b612de683611158565b840190509392505050565b6000612e0060208401846115d1565b905092915050565b6000612e1760208401846112ed565b905092915050565b612e28816112ca565b82525050565b600060a08301612e416000840184612d61565b8583036000870152612e54838284612dc4565b92505050612e656020840184612df1565b612e726020860182611f9d565b50612e806040840184612df1565b612e8d6040860182611f9d565b50612e9b6060840184612e08565b612ea86060860182612e1f565b50612eb66080840184612e08565b612ec36080860182612e1f565b508091505092915050565b60006020820190508181036000830152612ee88184612e2e565b905092915050565b600067ffffffffffffffff821115612f0b57612f0a611169565b5b602082029050602081019050919050565b600060408284031215612f3257612f3161159c565b5b612f3c60406111c9565b9050600082015167ffffffffffffffff811115612f5c57612f5b6115a1565b5b612f68848285016127d3565b600083015250602082015167ffffffffffffffff811115612f8c57612f8b6115a1565b5b612f98848285016127d3565b60208301525092915050565b6000612fb7612fb284612ef0565b6111c9565b90508083825260208201905060208402830185811115612fda57612fd9611441565b5b835b8181101561302157805167ffffffffffffffff811115612fff57612ffe61114e565b5b80860161300c8982612f1c565b85526020850194505050602081019050612fdc565b5050509392505050565b600082601f8301126130405761303f61114e565b5b8151613050848260208601612fa4565b91505092915050565b600067ffffffffffffffff82111561307457613073611169565b5b61307d82611158565b9050602081019050919050565b600061309d61309884613059565b6111c9565b9050828152602081018484840111156130b9576130b8611153565b5b6130c4848285611869565b509392505050565b600082601f8301126130e1576130e061114e565b5b81516130f184826020860161308a565b91505092915050565b6000604082840312156131105761310f61159c565b5b61311a60406111c9565b9050600082015167ffffffffffffffff81111561313a576131396115a1565b5b613146848285016130cc565b600083015250602061315a8482850161246a565b60208301525092915050565b6000806040838503121561317d5761317c6110e6565b5b600083015167ffffffffffffffff81111561319b5761319a6110eb565b5b6131a78582860161302b565b925050602083015167ffffffffffffffff8111156131c8576131c76110eb565b5b6131d4858286016130fa565b9150509250929050565b6000602082840312156131f4576131f36110e6565b5b600082015167ffffffffffffffff811115613212576132116110eb565b5b61321e84828501612f1c565b91505092915050565b7f4661696c656420746f20646563726561736520616c6c6f77616e636500000000600082015250565b600061325d601c83611d69565b915061326882613227565b602082019050919050565b6000602082019050818103600083015261328c81613250565b9050919050565b6000819050919050565b600080833560016020038436030381126132ba576132b9612d5c565b5b83810192508235915060208301925067ffffffffffffffff8211156132e2576132e1612d52565b5b6001820236038313156132f8576132f7612d57565b5b509250929050565b600061330c8385611858565b9350613319838584611215565b61332283611158565b840190509392505050565b6000808335600160200384360303811261334a57613349612d5c565b5b83810192508235915060208301925067ffffffffffffffff82111561337257613371612d52565b5b60208202360383131561338857613387612d57565b5b509250929050565b6000819050919050565b60006133a960208401846112b5565b905092915050565b6000604083016133c4600084018461329d565b85830360008701526133d7838284613300565b925050506133e8602084018461339a565b6133f560208601826118f8565b508091505092915050565b600061340c83836133b1565b905092915050565b6000823560016040038336030381126134305761342f612d5c565b5b82810191505092915050565b6000602082019050919050565b600061345583856118d7565b93508360208402850161346784613390565b8060005b878110156134ab5784840389526134828284613414565b61348c8582613400565b94506134978361343c565b925060208a0199505060018101905061346b565b50829750879450505050509392505050565b600080833560016020038436030381126134da576134d9612d5c565b5b83810192508235915060208301925067ffffffffffffffff82111561350257613501612d52565b5b60208202360383131561351857613517612d57565b5b509250929050565b6000819050919050565b6000613537848484613300565b90509392505050565b6000602082019050919050565b600061355983856119e5565b93508360208402850161356b84613520565b8060005b878110156135b1578484038952613586828461329d565b61359186828461352a565b955061359c84613540565b935060208b019a50505060018101905061356f565b50829750879450505050509392505050565b600060a083016135d6600084018461329d565b85830360008701526135e9838284613300565b925050506135fa602084018461329d565b858303602087015261360d838284613300565b9250505061361e604084018461332d565b8583036040870152613631838284613449565b9250505061364260608401846134bd565b858303606087015261365583828461354d565b9250505061366660808401846134bd565b858303608087015261367983828461354d565b925050508091505092915050565b600061369383836135c3565b905092915050565b60008235600160a0038336030381126136b7576136b6612d5c565b5b82810191505092915050565b6000602082019050919050565b60006136dc838561182c565b9350836020840285016136ee84613293565b8060005b87811015613732578484038952613709828461369b565b6137138582613687565b945061371e836136c3565b925060208a019950506001810190506136f2565b50829750879450505050509392505050565b600060408201905061375960008301866124ac565b818103602083015261376c8184866136d0565b9050949350505050565b7f4661696c656420746f20706572666f726d20617070726f76616c000000000000600082015250565b60006137ac601a83611d69565b91506137b782613776565b602082019050919050565b600060208201905081810360008301526137db8161379f565b905091905056fea26469706673582212207be0ce4d0a8d92b87200fc1f1502c94bf3336b2ea1b72d9b3a8530020fc7057564736f6c63430008140033", - "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100cf5760003560e01c8063a363df841161008c578063dfa10f3911610066578063dfa10f3914610210578063ee5766d914610241578063f298e7a814610271578063f3675f081461028d576100cf565b8063a363df8414610194578063b9672879146101c4578063c595699a146101e0576100cf565b80631dba685b146100d4578063424af9f6146100f057806361bc221a1461010c5780636fdf23cc1461012a5780637492bdd81461015a5780637a6185e11461018a575b600080fd5b6100ee60048036038101906100e99190611302565b6102a9565b005b61010a6004803603810190610105919061149c565b61070f565b005b6101146107e9565b6040516101219190611581565b60405180910390f35b610144600480360381019061013f9190611636565b6107fa565b6040516101519190611788565b60405180910390f35b610174600480360381019061016f9190611636565b610898565b6040516101819190611788565b60405180910390f35b610192610936565b005b6101ae60048036038101906101a991906117e1565b6109fb565b6040516101bb9190611bc4565b60405180910390f35b6101de60048036038101906101d99190611be6565b610a88565b005b6101fa60048036038101906101f59190611d20565b610d4b565b6040516102079190611db3565b60405180910390f35b61022a60048036038101906102259190611df9565b610dd5565b604051610238929190611fe9565b60405180910390f35b61025b60048036038101906102569190611d20565b610e69565b6040516102689190612064565b60405180910390f35b61028b6004803603810190610286919061149c565b610ef9565b005b6102a760048036038101906102a291906120dc565b610fd3565b005b82156103a65760008081819054906101000a900460070b809291906102cd90612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008973ffffffffffffffffffffffffffffffffffffffff16600f60405161031e906121b9565b60006040518083038185875af1925050503d806000811461035b576040519150601f19603f3d011682016040523d82523d6000602084013e610360565b606091505b50509050806103a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161039b90612240565b60405180910390fd5b505b60006040518060400160405280606467ffffffffffffffff168152602001606467ffffffffffffffff16815250905061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a60028b610403919061228f565b8f8b8860006040518963ffffffff1660e01b815260040161042b9897969594939291906123bb565b6020604051808303816000875af115801561044a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061046e919061247f565b50821561056c5760008081819054906101000a900460070b8092919061049390612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16600f6040516104e4906121b9565b60006040518083038185875af1925050503d8060008114610521576040519150601f19603f3d011682016040523d82523d6000602084013e610526565b606091505b505090508061056a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161056190612240565b60405180910390fd5b505b61080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a60028b61059a919061228f565b8f8b8860006040518963ffffffff1660e01b81526004016105c29897969594939291906123bb565b6020604051808303816000875af11580156105e1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610605919061247f565b5081156107035760008081819054906101000a900460070b8092919061062a90612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16600f60405161067b906121b9565b60006040518083038185875af1925050503d80600081146106b8576040519150601f19603f3d011682016040523d82523d6000602084013e6106bd565b606091505b5050905080610701576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106f890612240565b60405180910390fd5b505b50505050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff166354de647b308a8a8a8a8a8a8a6040518963ffffffff1660e01b815260040161075a9897969594939291906124e8565b6020604051808303816000875af1158015610779573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061079d919061256b565b9050806107df576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d6906125e4565b60405180910390fd5b5050505050505050565b60008054906101000a900460070b81565b600061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a8a308b8b8b8b6040518a63ffffffff1660e01b815260040161084799989796959493929190612604565b6020604051808303816000875af1158015610866573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061088a919061247f565b905098975050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a8a338b8b8b8b6040518a63ffffffff1660e01b81526004016108e599989796959493929190612604565b6020604051808303816000875af1158015610904573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610928919061247f565b905098975050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff166374a8f103306040518263ffffffff1660e01b815260040161097391906126b5565b6020604051808303816000875af1158015610992573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b6919061256b565b9050806109f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109ef9061271c565b60405180910390fd5b50565b606061080273ffffffffffffffffffffffffffffffffffffffff1663dd62ed3e84846040518363ffffffff1660e01b8152600401610a3a92919061273c565b600060405180830381865afa158015610a57573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610a809190612c11565b905092915050565b8115610b855760008081819054906101000a900460070b80929190610aac90612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008973ffffffffffffffffffffffffffffffffffffffff16600f604051610afd906121b9565b60006040518083038185875af1925050503d8060008114610b3a576040519150601f19603f3d011682016040523d82523d6000602084013e610b3f565b606091505b5050905080610b83576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b7a90612240565b60405180910390fd5b505b60006040518060400160405280606467ffffffffffffffff168152602001606467ffffffffffffffff16815250905061080273ffffffffffffffffffffffffffffffffffffffff1663632535b9898989898e8a8860006040518963ffffffff1660e01b8152600401610bfe989796959493929190612c5a565b6020604051808303816000875af1158015610c1d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c41919061247f565b508115610d3f5760008081819054906101000a900460070b80929190610c6690612158565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16600f604051610cb7906121b9565b60006040518083038185875af1925050503d8060008114610cf4576040519150601f19603f3d011682016040523d82523d6000602084013e610cf9565b606091505b5050905080610d3d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d3490612240565b60405180910390fd5b505b50505050505050505050565b606061080273ffffffffffffffffffffffffffffffffffffffff1663b5cb6e7d836040518263ffffffff1660e01b8152600401610d889190611db3565b600060405180830381865afa158015610da5573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610dce9190612d09565b9050919050565b6060610ddf61109e565b61080273ffffffffffffffffffffffffffffffffffffffff166322b6fad6846040518263ffffffff1660e01b8152600401610e1a9190612ece565b600060405180830381865afa158015610e37573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610e609190613166565b91509150915091565b610e716110c2565b61080273ffffffffffffffffffffffffffffffffffffffff1663a815cdd9836040518263ffffffff1660e01b8152600401610eac9190611db3565b600060405180830381865afa158015610ec9573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610ef291906131de565b9050919050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663b3f536ec308a8a8a8a8a8a8a6040518963ffffffff1660e01b8152600401610f449897969594939291906124e8565b6020604051808303816000875af1158015610f63573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f87919061256b565b905080610fc9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fc090613273565b60405180910390fd5b5050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663473c90c73085856040518463ffffffff1660e01b815260040161101493929190613744565b6020604051808303816000875af1158015611033573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611057919061256b565b905080611099576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611090906137c2565b60405180910390fd5b505050565b604051806040016040528060608152602001600067ffffffffffffffff1681525090565b604051806040016040528060608152602001606081525090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061111b826110f0565b9050919050565b61112b81611110565b811461113657600080fd5b50565b60008135905061114881611122565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6111a182611158565b810181811067ffffffffffffffff821117156111c0576111bf611169565b5b80604052505050565b60006111d36110dc565b90506111df8282611198565b919050565b600067ffffffffffffffff8211156111ff576111fe611169565b5b61120882611158565b9050602081019050919050565b82818337600083830152505050565b6000611237611232846111e4565b6111c9565b90508281526020810184848401111561125357611252611153565b5b61125e848285611215565b509392505050565b600082601f83011261127b5761127a61114e565b5b813561128b848260208601611224565b91505092915050565b6000819050919050565b6112a781611294565b81146112b257600080fd5b50565b6000813590506112c48161129e565b92915050565b60008115159050919050565b6112df816112ca565b81146112ea57600080fd5b50565b6000813590506112fc816112d6565b92915050565b60008060008060008060008060006101208a8c031215611325576113246110e6565b5b60006113338c828d01611139565b99505060208a013567ffffffffffffffff811115611354576113536110eb565b5b6113608c828d01611266565b98505060408a013567ffffffffffffffff811115611381576113806110eb565b5b61138d8c828d01611266565b97505060608a013567ffffffffffffffff8111156113ae576113ad6110eb565b5b6113ba8c828d01611266565b96505060806113cb8c828d016112b5565b95505060a08a013567ffffffffffffffff8111156113ec576113eb6110eb565b5b6113f88c828d01611266565b94505060c06114098c828d016112ed565b93505060e061141a8c828d016112ed565b92505061010061142c8c828d016112ed565b9150509295985092959850929598565b600080fd5b600080fd5b60008083601f84011261145c5761145b61114e565b5b8235905067ffffffffffffffff8111156114795761147861143c565b5b60208301915083600182028301111561149557611494611441565b5b9250929050565b60008060008060008060006080888a0312156114bb576114ba6110e6565b5b600088013567ffffffffffffffff8111156114d9576114d86110eb565b5b6114e58a828b01611446565b9750975050602088013567ffffffffffffffff811115611508576115076110eb565b5b6115148a828b01611446565b9550955050604088013567ffffffffffffffff811115611537576115366110eb565b5b6115438a828b01611446565b935093505060606115568a828b016112b5565b91505092959891949750929550565b60008160070b9050919050565b61157b81611565565b82525050565b60006020820190506115966000830184611572565b92915050565b600080fd5b600080fd5b600067ffffffffffffffff82169050919050565b6115c3816115a6565b81146115ce57600080fd5b50565b6000813590506115e0816115ba565b92915050565b6000604082840312156115fc576115fb61159c565b5b61160660406111c9565b90506000611616848285016115d1565b600083015250602061162a848285016115d1565b60208301525092915050565b600080600080600080600080610120898b031215611657576116566110e6565b5b600089013567ffffffffffffffff811115611675576116746110eb565b5b6116818b828c01611266565b985050602089013567ffffffffffffffff8111156116a2576116a16110eb565b5b6116ae8b828c01611266565b975050604089013567ffffffffffffffff8111156116cf576116ce6110eb565b5b6116db8b828c01611266565b96505060606116ec8b828c016112b5565b955050608089013567ffffffffffffffff81111561170d5761170c6110eb565b5b6117198b828c01611266565b94505060a061172a8b828c016115e6565b93505060e061173b8b828c016115d1565b92505061010089013567ffffffffffffffff81111561175d5761175c6110eb565b5b6117698b828c01611266565b9150509295985092959890939650565b611782816115a6565b82525050565b600060208201905061179d6000830184611779565b92915050565b60006117ae826110f0565b9050919050565b6117be816117a3565b81146117c957600080fd5b50565b6000813590506117db816117b5565b92915050565b600080604083850312156117f8576117f76110e6565b5b6000611806858286016117cc565b9250506020611817858286016117cc565b9150509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561188757808201518184015260208101905061186c565b60008484015250505050565b600061189e8261184d565b6118a88185611858565b93506118b8818560208601611869565b6118c181611158565b840191505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61190181611294565b82525050565b600060408301600083015184820360008601526119248282611893565b915050602083015161193960208601826118f8565b508091505092915050565b60006119508383611907565b905092915050565b6000602082019050919050565b6000611970826118cc565b61197a81856118d7565b93508360208202850161198c856118e8565b8060005b858110156119c857848403895281516119a98582611944565b94506119b483611958565b925060208a01995050600181019050611990565b50829750879550505050505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000611a128383611893565b905092915050565b6000602082019050919050565b6000611a32826119da565b611a3c81856119e5565b935083602082028501611a4e856119f6565b8060005b85811015611a8a5784840389528151611a6b8582611a06565b9450611a7683611a1a565b925060208a01995050600181019050611a52565b50829750879550505050505092915050565b600060a0830160008301518482036000860152611ab98282611893565b91505060208301518482036020860152611ad38282611893565b91505060408301518482036040860152611aed8282611965565b91505060608301518482036060860152611b078282611a27565b91505060808301518482036080860152611b218282611a27565b9150508091505092915050565b6000611b3a8383611a9c565b905092915050565b6000602082019050919050565b6000611b5a82611821565b611b64818561182c565b935083602082028501611b768561183d565b8060005b85811015611bb25784840389528151611b938582611b2e565b9450611b9e83611b42565b925060208a01995050600181019050611b7a565b50829750879550505050505092915050565b60006020820190508181036000830152611bde8184611b4f565b905092915050565b60008060008060008060008060006101208a8c031215611c0957611c086110e6565b5b6000611c178c828d01611139565b9950506020611c288c828d016117cc565b98505060408a013567ffffffffffffffff811115611c4957611c486110eb565b5b611c558c828d01611266565b97505060608a013567ffffffffffffffff811115611c7657611c756110eb565b5b611c828c828d01611266565b96505060808a013567ffffffffffffffff811115611ca357611ca26110eb565b5b611caf8c828d01611266565b95505060a0611cc08c828d016112b5565b94505060c08a013567ffffffffffffffff811115611ce157611ce06110eb565b5b611ced8c828d01611266565b93505060e0611cfe8c828d016112ed565b925050610100611d108c828d016112ed565b9150509295985092959850929598565b600060208284031215611d3657611d356110e6565b5b600082013567ffffffffffffffff811115611d5457611d536110eb565b5b611d6084828501611266565b91505092915050565b600082825260208201905092915050565b6000611d858261184d565b611d8f8185611d69565b9350611d9f818560208601611869565b611da881611158565b840191505092915050565b60006020820190508181036000830152611dcd8184611d7a565b905092915050565b600080fd5b600060a08284031215611df057611def611dd5565b5b81905092915050565b600060208284031215611e0f57611e0e6110e6565b5b600082013567ffffffffffffffff811115611e2d57611e2c6110eb565b5b611e3984828501611dda565b91505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60006040830160008301518482036000860152611e8b8282611893565b91505060208301518482036020860152611ea58282611893565b9150508091505092915050565b6000611ebe8383611e6e565b905092915050565b6000602082019050919050565b6000611ede82611e42565b611ee88185611e4d565b935083602082028501611efa85611e5e565b8060005b85811015611f365784840389528151611f178582611eb2565b9450611f2283611ec6565b925060208a01995050600181019050611efe565b50829750879550505050505092915050565b600081519050919050565b600082825260208201905092915050565b6000611f6f82611f48565b611f798185611f53565b9350611f89818560208601611869565b611f9281611158565b840191505092915050565b611fa6816115a6565b82525050565b60006040830160008301518482036000860152611fc98282611f64565b9150506020830151611fde6020860182611f9d565b508091505092915050565b600060408201905081810360008301526120038185611ed3565b905081810360208301526120178184611fac565b90509392505050565b6000604083016000830151848203600086015261203d8282611893565b915050602083015184820360208601526120578282611893565b9150508091505092915050565b6000602082019050818103600083015261207e8184612020565b905092915050565b60008083601f84011261209c5761209b61114e565b5b8235905067ffffffffffffffff8111156120b9576120b861143c565b5b6020830191508360208202830111156120d5576120d4611441565b5b9250929050565b600080602083850312156120f3576120f26110e6565b5b600083013567ffffffffffffffff811115612111576121106110eb565b5b61211d85828601612086565b92509250509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061216382611565565b9150677fffffffffffffff820361217d5761217c612129565b5b600182019050919050565b600081905092915050565b50565b60006121a3600083612188565b91506121ae82612193565b600082019050919050565b60006121c482612196565b9150819050919050565b7f4661696c656420746f2073656e6420457468657220746f2064656c656761746f60008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b600061222a602183611d69565b9150612235826121ce565b604082019050919050565b600060208201905081810360008301526122598161221d565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061229a82611294565b91506122a583611294565b9250826122b5576122b4612260565b5b828204905092915050565b6122c981611294565b82525050565b6000819050919050565b60006122f46122ef6122ea846110f0565b6122cf565b6110f0565b9050919050565b6000612306826122d9565b9050919050565b6000612318826122fb565b9050919050565b6123288161230d565b82525050565b6040820160008201516123446000850182611f9d565b5060208201516123576020850182611f9d565b50505050565b6000819050919050565b600061238261237d6123788461235d565b6122cf565b6115a6565b9050919050565b61239281612367565b82525050565b60006123a5600083611d69565b91506123b082612193565b600082019050919050565b60006101408201905081810360008301526123d6818b611d7a565b905081810360208301526123ea818a611d7a565b905081810360408301526123fe8189611d7a565b905061240d60608301886122c0565b61241a608083018761231f565b81810360a083015261242c8186611d7a565b905061243b60c083018561232e565b612449610100830184612389565b81810361012083015261245b81612398565b90509998505050505050505050565b600081519050612479816115ba565b92915050565b600060208284031215612495576124946110e6565b5b60006124a38482850161246a565b91505092915050565b6124b5816117a3565b82525050565b60006124c78385611d69565b93506124d4838584611215565b6124dd83611158565b840190509392505050565b600060a0820190506124fd600083018b6124ac565b818103602083015261251081898b6124bb565b905081810360408301526125258187896124bb565b9050818103606083015261253a8185876124bb565b905061254960808301846122c0565b9998505050505050505050565b600081519050612565816112d6565b92915050565b600060208284031215612581576125806110e6565b5b600061258f84828501612556565b91505092915050565b7f4661696c656420746f20696e63726561736520616c6c6f77616e636500000000600082015250565b60006125ce601c83611d69565b91506125d982612598565b602082019050919050565b600060208201905081810360008301526125fd816125c1565b9050919050565b600061014082019050818103600083015261261f818c611d7a565b90508181036020830152612633818b611d7a565b90508181036040830152612647818a611d7a565b905061265660608301896122c0565b61266360808301886124ac565b81810360a08301526126758187611d7a565b905061268460c083018661232e565b612692610100830185611779565b8181036101208301526126a58184611d7a565b90509a9950505050505050505050565b60006020820190506126ca60008301846124ac565b92915050565b7f4661696c656420746f207265766f6b6520617070726f76616c00000000000000600082015250565b6000612706601983611d69565b9150612711826126d0565b602082019050919050565b60006020820190508181036000830152612735816126f9565b9050919050565b600060408201905061275160008301856124ac565b61275e60208301846124ac565b9392505050565b600067ffffffffffffffff8211156127805761277f611169565b5b602082029050602081019050919050565b60006127a461279f846111e4565b6111c9565b9050828152602081018484840111156127c0576127bf611153565b5b6127cb848285611869565b509392505050565b600082601f8301126127e8576127e761114e565b5b81516127f8848260208601612791565b91505092915050565b600067ffffffffffffffff82111561281c5761281b611169565b5b602082029050602081019050919050565b60008151905061283c8161129e565b92915050565b6000604082840312156128585761285761159c565b5b61286260406111c9565b9050600082015167ffffffffffffffff811115612882576128816115a1565b5b61288e848285016127d3565b60008301525060206128a28482850161282d565b60208301525092915050565b60006128c16128bc84612801565b6111c9565b905080838252602082019050602084028301858111156128e4576128e3611441565b5b835b8181101561292b57805167ffffffffffffffff8111156129095761290861114e565b5b8086016129168982612842565b855260208501945050506020810190506128e6565b5050509392505050565b600082601f83011261294a5761294961114e565b5b815161295a8482602086016128ae565b91505092915050565b600067ffffffffffffffff82111561297e5761297d611169565b5b602082029050602081019050919050565b60006129a261299d84612963565b6111c9565b905080838252602082019050602084028301858111156129c5576129c4611441565b5b835b81811015612a0c57805167ffffffffffffffff8111156129ea576129e961114e565b5b8086016129f789826127d3565b855260208501945050506020810190506129c7565b5050509392505050565b600082601f830112612a2b57612a2a61114e565b5b8151612a3b84826020860161298f565b91505092915050565b600060a08284031215612a5a57612a5961159c565b5b612a6460a06111c9565b9050600082015167ffffffffffffffff811115612a8457612a836115a1565b5b612a90848285016127d3565b600083015250602082015167ffffffffffffffff811115612ab457612ab36115a1565b5b612ac0848285016127d3565b602083015250604082015167ffffffffffffffff811115612ae457612ae36115a1565b5b612af084828501612935565b604083015250606082015167ffffffffffffffff811115612b1457612b136115a1565b5b612b2084828501612a16565b606083015250608082015167ffffffffffffffff811115612b4457612b436115a1565b5b612b5084828501612a16565b60808301525092915050565b6000612b6f612b6a84612765565b6111c9565b90508083825260208201905060208402830185811115612b9257612b91611441565b5b835b81811015612bd957805167ffffffffffffffff811115612bb757612bb661114e565b5b808601612bc48982612a44565b85526020850194505050602081019050612b94565b5050509392505050565b600082601f830112612bf857612bf761114e565b5b8151612c08848260208601612b5c565b91505092915050565b600060208284031215612c2757612c266110e6565b5b600082015167ffffffffffffffff811115612c4557612c446110eb565b5b612c5184828501612be3565b91505092915050565b6000610140820190508181036000830152612c75818b611d7a565b90508181036020830152612c89818a611d7a565b90508181036040830152612c9d8189611d7a565b9050612cac60608301886122c0565b612cb960808301876124ac565b81810360a0830152612ccb8186611d7a565b9050612cda60c083018561232e565b612ce8610100830184612389565b818103610120830152612cfa81612398565b90509998505050505050505050565b600060208284031215612d1f57612d1e6110e6565b5b600082015167ffffffffffffffff811115612d3d57612d3c6110eb565b5b612d49848285016127d3565b91505092915050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112612d7e57612d7d612d5c565b5b83810192508235915060208301925067ffffffffffffffff821115612da657612da5612d52565b5b600182023603831315612dbc57612dbb612d57565b5b509250929050565b6000612dd08385611f53565b9350612ddd838584611215565b612de683611158565b840190509392505050565b6000612e0060208401846115d1565b905092915050565b6000612e1760208401846112ed565b905092915050565b612e28816112ca565b82525050565b600060a08301612e416000840184612d61565b8583036000870152612e54838284612dc4565b92505050612e656020840184612df1565b612e726020860182611f9d565b50612e806040840184612df1565b612e8d6040860182611f9d565b50612e9b6060840184612e08565b612ea86060860182612e1f565b50612eb66080840184612e08565b612ec36080860182612e1f565b508091505092915050565b60006020820190508181036000830152612ee88184612e2e565b905092915050565b600067ffffffffffffffff821115612f0b57612f0a611169565b5b602082029050602081019050919050565b600060408284031215612f3257612f3161159c565b5b612f3c60406111c9565b9050600082015167ffffffffffffffff811115612f5c57612f5b6115a1565b5b612f68848285016127d3565b600083015250602082015167ffffffffffffffff811115612f8c57612f8b6115a1565b5b612f98848285016127d3565b60208301525092915050565b6000612fb7612fb284612ef0565b6111c9565b90508083825260208201905060208402830185811115612fda57612fd9611441565b5b835b8181101561302157805167ffffffffffffffff811115612fff57612ffe61114e565b5b80860161300c8982612f1c565b85526020850194505050602081019050612fdc565b5050509392505050565b600082601f8301126130405761303f61114e565b5b8151613050848260208601612fa4565b91505092915050565b600067ffffffffffffffff82111561307457613073611169565b5b61307d82611158565b9050602081019050919050565b600061309d61309884613059565b6111c9565b9050828152602081018484840111156130b9576130b8611153565b5b6130c4848285611869565b509392505050565b600082601f8301126130e1576130e061114e565b5b81516130f184826020860161308a565b91505092915050565b6000604082840312156131105761310f61159c565b5b61311a60406111c9565b9050600082015167ffffffffffffffff81111561313a576131396115a1565b5b613146848285016130cc565b600083015250602061315a8482850161246a565b60208301525092915050565b6000806040838503121561317d5761317c6110e6565b5b600083015167ffffffffffffffff81111561319b5761319a6110eb565b5b6131a78582860161302b565b925050602083015167ffffffffffffffff8111156131c8576131c76110eb565b5b6131d4858286016130fa565b9150509250929050565b6000602082840312156131f4576131f36110e6565b5b600082015167ffffffffffffffff811115613212576132116110eb565b5b61321e84828501612f1c565b91505092915050565b7f4661696c656420746f20646563726561736520616c6c6f77616e636500000000600082015250565b600061325d601c83611d69565b915061326882613227565b602082019050919050565b6000602082019050818103600083015261328c81613250565b9050919050565b6000819050919050565b600080833560016020038436030381126132ba576132b9612d5c565b5b83810192508235915060208301925067ffffffffffffffff8211156132e2576132e1612d52565b5b6001820236038313156132f8576132f7612d57565b5b509250929050565b600061330c8385611858565b9350613319838584611215565b61332283611158565b840190509392505050565b6000808335600160200384360303811261334a57613349612d5c565b5b83810192508235915060208301925067ffffffffffffffff82111561337257613371612d52565b5b60208202360383131561338857613387612d57565b5b509250929050565b6000819050919050565b60006133a960208401846112b5565b905092915050565b6000604083016133c4600084018461329d565b85830360008701526133d7838284613300565b925050506133e8602084018461339a565b6133f560208601826118f8565b508091505092915050565b600061340c83836133b1565b905092915050565b6000823560016040038336030381126134305761342f612d5c565b5b82810191505092915050565b6000602082019050919050565b600061345583856118d7565b93508360208402850161346784613390565b8060005b878110156134ab5784840389526134828284613414565b61348c8582613400565b94506134978361343c565b925060208a0199505060018101905061346b565b50829750879450505050509392505050565b600080833560016020038436030381126134da576134d9612d5c565b5b83810192508235915060208301925067ffffffffffffffff82111561350257613501612d52565b5b60208202360383131561351857613517612d57565b5b509250929050565b6000819050919050565b6000613537848484613300565b90509392505050565b6000602082019050919050565b600061355983856119e5565b93508360208402850161356b84613520565b8060005b878110156135b1578484038952613586828461329d565b61359186828461352a565b955061359c84613540565b935060208b019a50505060018101905061356f565b50829750879450505050509392505050565b600060a083016135d6600084018461329d565b85830360008701526135e9838284613300565b925050506135fa602084018461329d565b858303602087015261360d838284613300565b9250505061361e604084018461332d565b8583036040870152613631838284613449565b9250505061364260608401846134bd565b858303606087015261365583828461354d565b9250505061366660808401846134bd565b858303608087015261367983828461354d565b925050508091505092915050565b600061369383836135c3565b905092915050565b60008235600160a0038336030381126136b7576136b6612d5c565b5b82810191505092915050565b6000602082019050919050565b60006136dc838561182c565b9350836020840285016136ee84613293565b8060005b87811015613732578484038952613709828461369b565b6137138582613687565b945061371e836136c3565b925060208a019950506001810190506136f2565b50829750879450505050509392505050565b600060408201905061375960008301866124ac565b818103602083015261376c8184866136d0565b9050949350505050565b7f4661696c656420746f20706572666f726d20617070726f76616c000000000000600082015250565b60006137ac601a83611d69565b91506137b782613776565b602082019050919050565b600060208201905081810360008301526137db8161379f565b905091905056fea26469706673582212207be0ce4d0a8d92b87200fc1f1502c94bf3336b2ea1b72d9b3a8530020fc7057564736f6c63430008140033", + "bytecode": "0x608060405234801561001057600080fd5b50613831806100206000396000f3fe608060405234801561001057600080fd5b50600436106100cf5760003560e01c8063a363df841161008c578063dfa10f3911610066578063dfa10f3914610210578063ee5766d914610241578063f298e7a814610271578063f3675f081461028d576100cf565b8063a363df8414610194578063b9672879146101c4578063c595699a146101e0576100cf565b80631dba685b146100d4578063424af9f6146100f057806361bc221a1461010c5780636fdf23cc1461012a5780637492bdd81461015a5780637a6185e11461018a575b600080fd5b6100ee60048036038101906100e9919061131b565b6102a9565b005b61010a600480360381019061010591906114b5565b61071e565b005b6101146107f8565b604051610121919061159a565b60405180910390f35b610144600480360381019061013f919061164f565b610809565b60405161015191906117a1565b60405180910390f35b610174600480360381019061016f919061164f565b6108a7565b60405161018191906117a1565b60405180910390f35b610192610945565b005b6101ae60048036038101906101a991906117fa565b610a0a565b6040516101bb9190611bdd565b60405180910390f35b6101de60048036038101906101d99190611bff565b610a97565b005b6101fa60048036038101906101f59190611d39565b610d64565b6040516102079190611dcc565b60405180910390f35b61022a60048036038101906102259190611e12565b610dee565b604051610238929190612002565b60405180910390f35b61025b60048036038101906102569190611d39565b610e82565b604051610268919061207d565b60405180910390f35b61028b600480360381019061028691906114b5565b610f12565b005b6102a760048036038101906102a291906120f5565b610fec565b005b82156103ab5760008081819054906101000a900460070b809291906102cd90612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008973ffffffffffffffffffffffffffffffffffffffff16650da475abf000604051610323906121d2565b60006040518083038185875af1925050503d8060008114610360576040519150601f19603f3d011682016040523d82523d6000602084013e610365565b606091505b50509050806103a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103a090612259565b60405180910390fd5b505b60006040518060400160405280606467ffffffffffffffff168152602001606467ffffffffffffffff16815250905061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a60028b61040891906122a8565b8f8b8860006040518963ffffffff1660e01b81526004016104309897969594939291906123d4565b6020604051808303816000875af115801561044f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104739190612498565b5082156105765760008081819054906101000a900460070b8092919061049890612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16650da475abf0006040516104ee906121d2565b60006040518083038185875af1925050503d806000811461052b576040519150601f19603f3d011682016040523d82523d6000602084013e610530565b606091505b5050905080610574576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161056b90612259565b60405180910390fd5b505b61080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a60028b6105a491906122a8565b8f8b8860006040518963ffffffff1660e01b81526004016105cc9897969594939291906123d4565b6020604051808303816000875af11580156105eb573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061060f9190612498565b5081156107125760008081819054906101000a900460070b8092919061063490612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16650da475abf00060405161068a906121d2565b60006040518083038185875af1925050503d80600081146106c7576040519150601f19603f3d011682016040523d82523d6000602084013e6106cc565b606091505b5050905080610710576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161070790612259565b60405180910390fd5b505b50505050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff166354de647b308a8a8a8a8a8a8a6040518963ffffffff1660e01b8152600401610769989796959493929190612501565b6020604051808303816000875af1158015610788573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107ac9190612584565b9050806107ee576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107e5906125fd565b60405180910390fd5b5050505050505050565b60008054906101000a900460070b81565b600061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a8a308b8b8b8b6040518a63ffffffff1660e01b81526004016108569998979695949392919061261d565b6020604051808303816000875af1158015610875573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108999190612498565b905098975050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a8a338b8b8b8b6040518a63ffffffff1660e01b81526004016108f49998979695949392919061261d565b6020604051808303816000875af1158015610913573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109379190612498565b905098975050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff166374a8f103306040518263ffffffff1660e01b815260040161098291906126ce565b6020604051808303816000875af11580156109a1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109c59190612584565b905080610a07576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109fe90612735565b60405180910390fd5b50565b606061080273ffffffffffffffffffffffffffffffffffffffff1663dd62ed3e84846040518363ffffffff1660e01b8152600401610a49929190612755565b600060405180830381865afa158015610a66573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610a8f9190612c2a565b905092915050565b8115610b995760008081819054906101000a900460070b80929190610abb90612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008973ffffffffffffffffffffffffffffffffffffffff16650da475abf000604051610b11906121d2565b60006040518083038185875af1925050503d8060008114610b4e576040519150601f19603f3d011682016040523d82523d6000602084013e610b53565b606091505b5050905080610b97576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b8e90612259565b60405180910390fd5b505b60006040518060400160405280606467ffffffffffffffff168152602001606467ffffffffffffffff16815250905061080273ffffffffffffffffffffffffffffffffffffffff1663632535b9898989898e8a8860006040518963ffffffff1660e01b8152600401610c12989796959493929190612c73565b6020604051808303816000875af1158015610c31573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c559190612498565b508115610d585760008081819054906101000a900460070b80929190610c7a90612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16650da475abf000604051610cd0906121d2565b60006040518083038185875af1925050503d8060008114610d0d576040519150601f19603f3d011682016040523d82523d6000602084013e610d12565b606091505b5050905080610d56576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d4d90612259565b60405180910390fd5b505b50505050505050505050565b606061080273ffffffffffffffffffffffffffffffffffffffff1663b5cb6e7d836040518263ffffffff1660e01b8152600401610da19190611dcc565b600060405180830381865afa158015610dbe573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610de79190612d22565b9050919050565b6060610df86110b7565b61080273ffffffffffffffffffffffffffffffffffffffff166322b6fad6846040518263ffffffff1660e01b8152600401610e339190612ee7565b600060405180830381865afa158015610e50573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610e79919061317f565b91509150915091565b610e8a6110db565b61080273ffffffffffffffffffffffffffffffffffffffff1663a815cdd9836040518263ffffffff1660e01b8152600401610ec59190611dcc565b600060405180830381865afa158015610ee2573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610f0b91906131f7565b9050919050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663b3f536ec308a8a8a8a8a8a8a6040518963ffffffff1660e01b8152600401610f5d989796959493929190612501565b6020604051808303816000875af1158015610f7c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fa09190612584565b905080610fe2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fd99061328c565b60405180910390fd5b5050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663473c90c73085856040518463ffffffff1660e01b815260040161102d9392919061375d565b6020604051808303816000875af115801561104c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110709190612584565b9050806110b2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016110a9906137db565b60405180910390fd5b505050565b604051806040016040528060608152602001600067ffffffffffffffff1681525090565b604051806040016040528060608152602001606081525090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061113482611109565b9050919050565b61114481611129565b811461114f57600080fd5b50565b6000813590506111618161113b565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6111ba82611171565b810181811067ffffffffffffffff821117156111d9576111d8611182565b5b80604052505050565b60006111ec6110f5565b90506111f882826111b1565b919050565b600067ffffffffffffffff82111561121857611217611182565b5b61122182611171565b9050602081019050919050565b82818337600083830152505050565b600061125061124b846111fd565b6111e2565b90508281526020810184848401111561126c5761126b61116c565b5b61127784828561122e565b509392505050565b600082601f83011261129457611293611167565b5b81356112a484826020860161123d565b91505092915050565b6000819050919050565b6112c0816112ad565b81146112cb57600080fd5b50565b6000813590506112dd816112b7565b92915050565b60008115159050919050565b6112f8816112e3565b811461130357600080fd5b50565b600081359050611315816112ef565b92915050565b60008060008060008060008060006101208a8c03121561133e5761133d6110ff565b5b600061134c8c828d01611152565b99505060208a013567ffffffffffffffff81111561136d5761136c611104565b5b6113798c828d0161127f565b98505060408a013567ffffffffffffffff81111561139a57611399611104565b5b6113a68c828d0161127f565b97505060608a013567ffffffffffffffff8111156113c7576113c6611104565b5b6113d38c828d0161127f565b96505060806113e48c828d016112ce565b95505060a08a013567ffffffffffffffff81111561140557611404611104565b5b6114118c828d0161127f565b94505060c06114228c828d01611306565b93505060e06114338c828d01611306565b9250506101006114458c828d01611306565b9150509295985092959850929598565b600080fd5b600080fd5b60008083601f84011261147557611474611167565b5b8235905067ffffffffffffffff81111561149257611491611455565b5b6020830191508360018202830111156114ae576114ad61145a565b5b9250929050565b60008060008060008060006080888a0312156114d4576114d36110ff565b5b600088013567ffffffffffffffff8111156114f2576114f1611104565b5b6114fe8a828b0161145f565b9750975050602088013567ffffffffffffffff81111561152157611520611104565b5b61152d8a828b0161145f565b9550955050604088013567ffffffffffffffff8111156115505761154f611104565b5b61155c8a828b0161145f565b9350935050606061156f8a828b016112ce565b91505092959891949750929550565b60008160070b9050919050565b6115948161157e565b82525050565b60006020820190506115af600083018461158b565b92915050565b600080fd5b600080fd5b600067ffffffffffffffff82169050919050565b6115dc816115bf565b81146115e757600080fd5b50565b6000813590506115f9816115d3565b92915050565b600060408284031215611615576116146115b5565b5b61161f60406111e2565b9050600061162f848285016115ea565b6000830152506020611643848285016115ea565b60208301525092915050565b600080600080600080600080610120898b0312156116705761166f6110ff565b5b600089013567ffffffffffffffff81111561168e5761168d611104565b5b61169a8b828c0161127f565b985050602089013567ffffffffffffffff8111156116bb576116ba611104565b5b6116c78b828c0161127f565b975050604089013567ffffffffffffffff8111156116e8576116e7611104565b5b6116f48b828c0161127f565b96505060606117058b828c016112ce565b955050608089013567ffffffffffffffff81111561172657611725611104565b5b6117328b828c0161127f565b94505060a06117438b828c016115ff565b93505060e06117548b828c016115ea565b92505061010089013567ffffffffffffffff81111561177657611775611104565b5b6117828b828c0161127f565b9150509295985092959890939650565b61179b816115bf565b82525050565b60006020820190506117b66000830184611792565b92915050565b60006117c782611109565b9050919050565b6117d7816117bc565b81146117e257600080fd5b50565b6000813590506117f4816117ce565b92915050565b60008060408385031215611811576118106110ff565b5b600061181f858286016117e5565b9250506020611830858286016117e5565b9150509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b60005b838110156118a0578082015181840152602081019050611885565b60008484015250505050565b60006118b782611866565b6118c18185611871565b93506118d1818560208601611882565b6118da81611171565b840191505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61191a816112ad565b82525050565b6000604083016000830151848203600086015261193d82826118ac565b91505060208301516119526020860182611911565b508091505092915050565b60006119698383611920565b905092915050565b6000602082019050919050565b6000611989826118e5565b61199381856118f0565b9350836020820285016119a585611901565b8060005b858110156119e157848403895281516119c2858261195d565b94506119cd83611971565b925060208a019950506001810190506119a9565b50829750879550505050505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000611a2b83836118ac565b905092915050565b6000602082019050919050565b6000611a4b826119f3565b611a5581856119fe565b935083602082028501611a6785611a0f565b8060005b85811015611aa35784840389528151611a848582611a1f565b9450611a8f83611a33565b925060208a01995050600181019050611a6b565b50829750879550505050505092915050565b600060a0830160008301518482036000860152611ad282826118ac565b91505060208301518482036020860152611aec82826118ac565b91505060408301518482036040860152611b06828261197e565b91505060608301518482036060860152611b208282611a40565b91505060808301518482036080860152611b3a8282611a40565b9150508091505092915050565b6000611b538383611ab5565b905092915050565b6000602082019050919050565b6000611b738261183a565b611b7d8185611845565b935083602082028501611b8f85611856565b8060005b85811015611bcb5784840389528151611bac8582611b47565b9450611bb783611b5b565b925060208a01995050600181019050611b93565b50829750879550505050505092915050565b60006020820190508181036000830152611bf78184611b68565b905092915050565b60008060008060008060008060006101208a8c031215611c2257611c216110ff565b5b6000611c308c828d01611152565b9950506020611c418c828d016117e5565b98505060408a013567ffffffffffffffff811115611c6257611c61611104565b5b611c6e8c828d0161127f565b97505060608a013567ffffffffffffffff811115611c8f57611c8e611104565b5b611c9b8c828d0161127f565b96505060808a013567ffffffffffffffff811115611cbc57611cbb611104565b5b611cc88c828d0161127f565b95505060a0611cd98c828d016112ce565b94505060c08a013567ffffffffffffffff811115611cfa57611cf9611104565b5b611d068c828d0161127f565b93505060e0611d178c828d01611306565b925050610100611d298c828d01611306565b9150509295985092959850929598565b600060208284031215611d4f57611d4e6110ff565b5b600082013567ffffffffffffffff811115611d6d57611d6c611104565b5b611d798482850161127f565b91505092915050565b600082825260208201905092915050565b6000611d9e82611866565b611da88185611d82565b9350611db8818560208601611882565b611dc181611171565b840191505092915050565b60006020820190508181036000830152611de68184611d93565b905092915050565b600080fd5b600060a08284031215611e0957611e08611dee565b5b81905092915050565b600060208284031215611e2857611e276110ff565b5b600082013567ffffffffffffffff811115611e4657611e45611104565b5b611e5284828501611df3565b91505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60006040830160008301518482036000860152611ea482826118ac565b91505060208301518482036020860152611ebe82826118ac565b9150508091505092915050565b6000611ed78383611e87565b905092915050565b6000602082019050919050565b6000611ef782611e5b565b611f018185611e66565b935083602082028501611f1385611e77565b8060005b85811015611f4f5784840389528151611f308582611ecb565b9450611f3b83611edf565b925060208a01995050600181019050611f17565b50829750879550505050505092915050565b600081519050919050565b600082825260208201905092915050565b6000611f8882611f61565b611f928185611f6c565b9350611fa2818560208601611882565b611fab81611171565b840191505092915050565b611fbf816115bf565b82525050565b60006040830160008301518482036000860152611fe28282611f7d565b9150506020830151611ff76020860182611fb6565b508091505092915050565b6000604082019050818103600083015261201c8185611eec565b905081810360208301526120308184611fc5565b90509392505050565b6000604083016000830151848203600086015261205682826118ac565b9150506020830151848203602086015261207082826118ac565b9150508091505092915050565b600060208201905081810360008301526120978184612039565b905092915050565b60008083601f8401126120b5576120b4611167565b5b8235905067ffffffffffffffff8111156120d2576120d1611455565b5b6020830191508360208202830111156120ee576120ed61145a565b5b9250929050565b6000806020838503121561210c5761210b6110ff565b5b600083013567ffffffffffffffff81111561212a57612129611104565b5b6121368582860161209f565b92509250509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061217c8261157e565b9150677fffffffffffffff820361219657612195612142565b5b600182019050919050565b600081905092915050565b50565b60006121bc6000836121a1565b91506121c7826121ac565b600082019050919050565b60006121dd826121af565b9150819050919050565b7f4661696c656420746f2073656e6420457468657220746f2064656c656761746f60008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b6000612243602183611d82565b915061224e826121e7565b604082019050919050565b6000602082019050818103600083015261227281612236565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006122b3826112ad565b91506122be836112ad565b9250826122ce576122cd612279565b5b828204905092915050565b6122e2816112ad565b82525050565b6000819050919050565b600061230d61230861230384611109565b6122e8565b611109565b9050919050565b600061231f826122f2565b9050919050565b600061233182612314565b9050919050565b61234181612326565b82525050565b60408201600082015161235d6000850182611fb6565b5060208201516123706020850182611fb6565b50505050565b6000819050919050565b600061239b61239661239184612376565b6122e8565b6115bf565b9050919050565b6123ab81612380565b82525050565b60006123be600083611d82565b91506123c9826121ac565b600082019050919050565b60006101408201905081810360008301526123ef818b611d93565b90508181036020830152612403818a611d93565b905081810360408301526124178189611d93565b905061242660608301886122d9565b6124336080830187612338565b81810360a08301526124458186611d93565b905061245460c0830185612347565b6124626101008301846123a2565b818103610120830152612474816123b1565b90509998505050505050505050565b600081519050612492816115d3565b92915050565b6000602082840312156124ae576124ad6110ff565b5b60006124bc84828501612483565b91505092915050565b6124ce816117bc565b82525050565b60006124e08385611d82565b93506124ed83858461122e565b6124f683611171565b840190509392505050565b600060a082019050612516600083018b6124c5565b818103602083015261252981898b6124d4565b9050818103604083015261253e8187896124d4565b905081810360608301526125538185876124d4565b905061256260808301846122d9565b9998505050505050505050565b60008151905061257e816112ef565b92915050565b60006020828403121561259a576125996110ff565b5b60006125a88482850161256f565b91505092915050565b7f4661696c656420746f20696e63726561736520616c6c6f77616e636500000000600082015250565b60006125e7601c83611d82565b91506125f2826125b1565b602082019050919050565b60006020820190508181036000830152612616816125da565b9050919050565b6000610140820190508181036000830152612638818c611d93565b9050818103602083015261264c818b611d93565b90508181036040830152612660818a611d93565b905061266f60608301896122d9565b61267c60808301886124c5565b81810360a083015261268e8187611d93565b905061269d60c0830186612347565b6126ab610100830185611792565b8181036101208301526126be8184611d93565b90509a9950505050505050505050565b60006020820190506126e360008301846124c5565b92915050565b7f4661696c656420746f207265766f6b6520617070726f76616c00000000000000600082015250565b600061271f601983611d82565b915061272a826126e9565b602082019050919050565b6000602082019050818103600083015261274e81612712565b9050919050565b600060408201905061276a60008301856124c5565b61277760208301846124c5565b9392505050565b600067ffffffffffffffff82111561279957612798611182565b5b602082029050602081019050919050565b60006127bd6127b8846111fd565b6111e2565b9050828152602081018484840111156127d9576127d861116c565b5b6127e4848285611882565b509392505050565b600082601f83011261280157612800611167565b5b81516128118482602086016127aa565b91505092915050565b600067ffffffffffffffff82111561283557612834611182565b5b602082029050602081019050919050565b600081519050612855816112b7565b92915050565b600060408284031215612871576128706115b5565b5b61287b60406111e2565b9050600082015167ffffffffffffffff81111561289b5761289a6115ba565b5b6128a7848285016127ec565b60008301525060206128bb84828501612846565b60208301525092915050565b60006128da6128d58461281a565b6111e2565b905080838252602082019050602084028301858111156128fd576128fc61145a565b5b835b8181101561294457805167ffffffffffffffff81111561292257612921611167565b5b80860161292f898261285b565b855260208501945050506020810190506128ff565b5050509392505050565b600082601f83011261296357612962611167565b5b81516129738482602086016128c7565b91505092915050565b600067ffffffffffffffff82111561299757612996611182565b5b602082029050602081019050919050565b60006129bb6129b68461297c565b6111e2565b905080838252602082019050602084028301858111156129de576129dd61145a565b5b835b81811015612a2557805167ffffffffffffffff811115612a0357612a02611167565b5b808601612a1089826127ec565b855260208501945050506020810190506129e0565b5050509392505050565b600082601f830112612a4457612a43611167565b5b8151612a548482602086016129a8565b91505092915050565b600060a08284031215612a7357612a726115b5565b5b612a7d60a06111e2565b9050600082015167ffffffffffffffff811115612a9d57612a9c6115ba565b5b612aa9848285016127ec565b600083015250602082015167ffffffffffffffff811115612acd57612acc6115ba565b5b612ad9848285016127ec565b602083015250604082015167ffffffffffffffff811115612afd57612afc6115ba565b5b612b098482850161294e565b604083015250606082015167ffffffffffffffff811115612b2d57612b2c6115ba565b5b612b3984828501612a2f565b606083015250608082015167ffffffffffffffff811115612b5d57612b5c6115ba565b5b612b6984828501612a2f565b60808301525092915050565b6000612b88612b838461277e565b6111e2565b90508083825260208201905060208402830185811115612bab57612baa61145a565b5b835b81811015612bf257805167ffffffffffffffff811115612bd057612bcf611167565b5b808601612bdd8982612a5d565b85526020850194505050602081019050612bad565b5050509392505050565b600082601f830112612c1157612c10611167565b5b8151612c21848260208601612b75565b91505092915050565b600060208284031215612c4057612c3f6110ff565b5b600082015167ffffffffffffffff811115612c5e57612c5d611104565b5b612c6a84828501612bfc565b91505092915050565b6000610140820190508181036000830152612c8e818b611d93565b90508181036020830152612ca2818a611d93565b90508181036040830152612cb68189611d93565b9050612cc560608301886122d9565b612cd260808301876124c5565b81810360a0830152612ce48186611d93565b9050612cf360c0830185612347565b612d016101008301846123a2565b818103610120830152612d13816123b1565b90509998505050505050505050565b600060208284031215612d3857612d376110ff565b5b600082015167ffffffffffffffff811115612d5657612d55611104565b5b612d62848285016127ec565b91505092915050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112612d9757612d96612d75565b5b83810192508235915060208301925067ffffffffffffffff821115612dbf57612dbe612d6b565b5b600182023603831315612dd557612dd4612d70565b5b509250929050565b6000612de98385611f6c565b9350612df683858461122e565b612dff83611171565b840190509392505050565b6000612e1960208401846115ea565b905092915050565b6000612e306020840184611306565b905092915050565b612e41816112e3565b82525050565b600060a08301612e5a6000840184612d7a565b8583036000870152612e6d838284612ddd565b92505050612e7e6020840184612e0a565b612e8b6020860182611fb6565b50612e996040840184612e0a565b612ea66040860182611fb6565b50612eb46060840184612e21565b612ec16060860182612e38565b50612ecf6080840184612e21565b612edc6080860182612e38565b508091505092915050565b60006020820190508181036000830152612f018184612e47565b905092915050565b600067ffffffffffffffff821115612f2457612f23611182565b5b602082029050602081019050919050565b600060408284031215612f4b57612f4a6115b5565b5b612f5560406111e2565b9050600082015167ffffffffffffffff811115612f7557612f746115ba565b5b612f81848285016127ec565b600083015250602082015167ffffffffffffffff811115612fa557612fa46115ba565b5b612fb1848285016127ec565b60208301525092915050565b6000612fd0612fcb84612f09565b6111e2565b90508083825260208201905060208402830185811115612ff357612ff261145a565b5b835b8181101561303a57805167ffffffffffffffff81111561301857613017611167565b5b8086016130258982612f35565b85526020850194505050602081019050612ff5565b5050509392505050565b600082601f83011261305957613058611167565b5b8151613069848260208601612fbd565b91505092915050565b600067ffffffffffffffff82111561308d5761308c611182565b5b61309682611171565b9050602081019050919050565b60006130b66130b184613072565b6111e2565b9050828152602081018484840111156130d2576130d161116c565b5b6130dd848285611882565b509392505050565b600082601f8301126130fa576130f9611167565b5b815161310a8482602086016130a3565b91505092915050565b600060408284031215613129576131286115b5565b5b61313360406111e2565b9050600082015167ffffffffffffffff811115613153576131526115ba565b5b61315f848285016130e5565b600083015250602061317384828501612483565b60208301525092915050565b60008060408385031215613196576131956110ff565b5b600083015167ffffffffffffffff8111156131b4576131b3611104565b5b6131c085828601613044565b925050602083015167ffffffffffffffff8111156131e1576131e0611104565b5b6131ed85828601613113565b9150509250929050565b60006020828403121561320d5761320c6110ff565b5b600082015167ffffffffffffffff81111561322b5761322a611104565b5b61323784828501612f35565b91505092915050565b7f4661696c656420746f20646563726561736520616c6c6f77616e636500000000600082015250565b6000613276601c83611d82565b915061328182613240565b602082019050919050565b600060208201905081810360008301526132a581613269565b9050919050565b6000819050919050565b600080833560016020038436030381126132d3576132d2612d75565b5b83810192508235915060208301925067ffffffffffffffff8211156132fb576132fa612d6b565b5b60018202360383131561331157613310612d70565b5b509250929050565b60006133258385611871565b935061333283858461122e565b61333b83611171565b840190509392505050565b6000808335600160200384360303811261336357613362612d75565b5b83810192508235915060208301925067ffffffffffffffff82111561338b5761338a612d6b565b5b6020820236038313156133a1576133a0612d70565b5b509250929050565b6000819050919050565b60006133c260208401846112ce565b905092915050565b6000604083016133dd60008401846132b6565b85830360008701526133f0838284613319565b9250505061340160208401846133b3565b61340e6020860182611911565b508091505092915050565b600061342583836133ca565b905092915050565b60008235600160400383360303811261344957613448612d75565b5b82810191505092915050565b6000602082019050919050565b600061346e83856118f0565b935083602084028501613480846133a9565b8060005b878110156134c457848403895261349b828461342d565b6134a58582613419565b94506134b083613455565b925060208a01995050600181019050613484565b50829750879450505050509392505050565b600080833560016020038436030381126134f3576134f2612d75565b5b83810192508235915060208301925067ffffffffffffffff82111561351b5761351a612d6b565b5b60208202360383131561353157613530612d70565b5b509250929050565b6000819050919050565b6000613550848484613319565b90509392505050565b6000602082019050919050565b600061357283856119fe565b93508360208402850161358484613539565b8060005b878110156135ca57848403895261359f82846132b6565b6135aa868284613543565b95506135b584613559565b935060208b019a505050600181019050613588565b50829750879450505050509392505050565b600060a083016135ef60008401846132b6565b8583036000870152613602838284613319565b9250505061361360208401846132b6565b8583036020870152613626838284613319565b925050506136376040840184613346565b858303604087015261364a838284613462565b9250505061365b60608401846134d6565b858303606087015261366e838284613566565b9250505061367f60808401846134d6565b8583036080870152613692838284613566565b925050508091505092915050565b60006136ac83836135dc565b905092915050565b60008235600160a0038336030381126136d0576136cf612d75565b5b82810191505092915050565b6000602082019050919050565b60006136f58385611845565b935083602084028501613707846132ac565b8060005b8781101561374b57848403895261372282846136b4565b61372c85826136a0565b9450613737836136dc565b925060208a0199505060018101905061370b565b50829750879450505050509392505050565b600060408201905061377260008301866124c5565b81810360208301526137858184866136e9565b9050949350505050565b7f4661696c656420746f20706572666f726d20617070726f76616c000000000000600082015250565b60006137c5601a83611d82565b91506137d08261378f565b602082019050919050565b600060208201905081810360008301526137f4816137b8565b905091905056fea2646970667358221220ad77753d207f5fa16ed802e3577e3ce385d25445983916e5d53914f0d256891964736f6c63430008140033", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100cf5760003560e01c8063a363df841161008c578063dfa10f3911610066578063dfa10f3914610210578063ee5766d914610241578063f298e7a814610271578063f3675f081461028d576100cf565b8063a363df8414610194578063b9672879146101c4578063c595699a146101e0576100cf565b80631dba685b146100d4578063424af9f6146100f057806361bc221a1461010c5780636fdf23cc1461012a5780637492bdd81461015a5780637a6185e11461018a575b600080fd5b6100ee60048036038101906100e9919061131b565b6102a9565b005b61010a600480360381019061010591906114b5565b61071e565b005b6101146107f8565b604051610121919061159a565b60405180910390f35b610144600480360381019061013f919061164f565b610809565b60405161015191906117a1565b60405180910390f35b610174600480360381019061016f919061164f565b6108a7565b60405161018191906117a1565b60405180910390f35b610192610945565b005b6101ae60048036038101906101a991906117fa565b610a0a565b6040516101bb9190611bdd565b60405180910390f35b6101de60048036038101906101d99190611bff565b610a97565b005b6101fa60048036038101906101f59190611d39565b610d64565b6040516102079190611dcc565b60405180910390f35b61022a60048036038101906102259190611e12565b610dee565b604051610238929190612002565b60405180910390f35b61025b60048036038101906102569190611d39565b610e82565b604051610268919061207d565b60405180910390f35b61028b600480360381019061028691906114b5565b610f12565b005b6102a760048036038101906102a291906120f5565b610fec565b005b82156103ab5760008081819054906101000a900460070b809291906102cd90612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008973ffffffffffffffffffffffffffffffffffffffff16650da475abf000604051610323906121d2565b60006040518083038185875af1925050503d8060008114610360576040519150601f19603f3d011682016040523d82523d6000602084013e610365565b606091505b50509050806103a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103a090612259565b60405180910390fd5b505b60006040518060400160405280606467ffffffffffffffff168152602001606467ffffffffffffffff16815250905061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a60028b61040891906122a8565b8f8b8860006040518963ffffffff1660e01b81526004016104309897969594939291906123d4565b6020604051808303816000875af115801561044f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104739190612498565b5082156105765760008081819054906101000a900460070b8092919061049890612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16650da475abf0006040516104ee906121d2565b60006040518083038185875af1925050503d806000811461052b576040519150601f19603f3d011682016040523d82523d6000602084013e610530565b606091505b5050905080610574576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161056b90612259565b60405180910390fd5b505b61080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a60028b6105a491906122a8565b8f8b8860006040518963ffffffff1660e01b81526004016105cc9897969594939291906123d4565b6020604051808303816000875af11580156105eb573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061060f9190612498565b5081156107125760008081819054906101000a900460070b8092919061063490612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16650da475abf00060405161068a906121d2565b60006040518083038185875af1925050503d80600081146106c7576040519150601f19603f3d011682016040523d82523d6000602084013e6106cc565b606091505b5050905080610710576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161070790612259565b60405180910390fd5b505b50505050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff166354de647b308a8a8a8a8a8a8a6040518963ffffffff1660e01b8152600401610769989796959493929190612501565b6020604051808303816000875af1158015610788573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107ac9190612584565b9050806107ee576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107e5906125fd565b60405180910390fd5b5050505050505050565b60008054906101000a900460070b81565b600061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a8a308b8b8b8b6040518a63ffffffff1660e01b81526004016108569998979695949392919061261d565b6020604051808303816000875af1158015610875573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108999190612498565b905098975050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663632535b98a8a8a8a338b8b8b8b6040518a63ffffffff1660e01b81526004016108f49998979695949392919061261d565b6020604051808303816000875af1158015610913573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109379190612498565b905098975050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff166374a8f103306040518263ffffffff1660e01b815260040161098291906126ce565b6020604051808303816000875af11580156109a1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109c59190612584565b905080610a07576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109fe90612735565b60405180910390fd5b50565b606061080273ffffffffffffffffffffffffffffffffffffffff1663dd62ed3e84846040518363ffffffff1660e01b8152600401610a49929190612755565b600060405180830381865afa158015610a66573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610a8f9190612c2a565b905092915050565b8115610b995760008081819054906101000a900460070b80929190610abb90612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008973ffffffffffffffffffffffffffffffffffffffff16650da475abf000604051610b11906121d2565b60006040518083038185875af1925050503d8060008114610b4e576040519150601f19603f3d011682016040523d82523d6000602084013e610b53565b606091505b5050905080610b97576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b8e90612259565b60405180910390fd5b505b60006040518060400160405280606467ffffffffffffffff168152602001606467ffffffffffffffff16815250905061080273ffffffffffffffffffffffffffffffffffffffff1663632535b9898989898e8a8860006040518963ffffffff1660e01b8152600401610c12989796959493929190612c73565b6020604051808303816000875af1158015610c31573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c559190612498565b508115610d585760008081819054906101000a900460070b80929190610c7a90612171565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff1602179055505060008a73ffffffffffffffffffffffffffffffffffffffff16650da475abf000604051610cd0906121d2565b60006040518083038185875af1925050503d8060008114610d0d576040519150601f19603f3d011682016040523d82523d6000602084013e610d12565b606091505b5050905080610d56576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d4d90612259565b60405180910390fd5b505b50505050505050505050565b606061080273ffffffffffffffffffffffffffffffffffffffff1663b5cb6e7d836040518263ffffffff1660e01b8152600401610da19190611dcc565b600060405180830381865afa158015610dbe573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610de79190612d22565b9050919050565b6060610df86110b7565b61080273ffffffffffffffffffffffffffffffffffffffff166322b6fad6846040518263ffffffff1660e01b8152600401610e339190612ee7565b600060405180830381865afa158015610e50573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610e79919061317f565b91509150915091565b610e8a6110db565b61080273ffffffffffffffffffffffffffffffffffffffff1663a815cdd9836040518263ffffffff1660e01b8152600401610ec59190611dcc565b600060405180830381865afa158015610ee2573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250810190610f0b91906131f7565b9050919050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663b3f536ec308a8a8a8a8a8a8a6040518963ffffffff1660e01b8152600401610f5d989796959493929190612501565b6020604051808303816000875af1158015610f7c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fa09190612584565b905080610fe2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fd99061328c565b60405180910390fd5b5050505050505050565b600061080273ffffffffffffffffffffffffffffffffffffffff1663473c90c73085856040518463ffffffff1660e01b815260040161102d9392919061375d565b6020604051808303816000875af115801561104c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110709190612584565b9050806110b2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016110a9906137db565b60405180910390fd5b505050565b604051806040016040528060608152602001600067ffffffffffffffff1681525090565b604051806040016040528060608152602001606081525090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061113482611109565b9050919050565b61114481611129565b811461114f57600080fd5b50565b6000813590506111618161113b565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6111ba82611171565b810181811067ffffffffffffffff821117156111d9576111d8611182565b5b80604052505050565b60006111ec6110f5565b90506111f882826111b1565b919050565b600067ffffffffffffffff82111561121857611217611182565b5b61122182611171565b9050602081019050919050565b82818337600083830152505050565b600061125061124b846111fd565b6111e2565b90508281526020810184848401111561126c5761126b61116c565b5b61127784828561122e565b509392505050565b600082601f83011261129457611293611167565b5b81356112a484826020860161123d565b91505092915050565b6000819050919050565b6112c0816112ad565b81146112cb57600080fd5b50565b6000813590506112dd816112b7565b92915050565b60008115159050919050565b6112f8816112e3565b811461130357600080fd5b50565b600081359050611315816112ef565b92915050565b60008060008060008060008060006101208a8c03121561133e5761133d6110ff565b5b600061134c8c828d01611152565b99505060208a013567ffffffffffffffff81111561136d5761136c611104565b5b6113798c828d0161127f565b98505060408a013567ffffffffffffffff81111561139a57611399611104565b5b6113a68c828d0161127f565b97505060608a013567ffffffffffffffff8111156113c7576113c6611104565b5b6113d38c828d0161127f565b96505060806113e48c828d016112ce565b95505060a08a013567ffffffffffffffff81111561140557611404611104565b5b6114118c828d0161127f565b94505060c06114228c828d01611306565b93505060e06114338c828d01611306565b9250506101006114458c828d01611306565b9150509295985092959850929598565b600080fd5b600080fd5b60008083601f84011261147557611474611167565b5b8235905067ffffffffffffffff81111561149257611491611455565b5b6020830191508360018202830111156114ae576114ad61145a565b5b9250929050565b60008060008060008060006080888a0312156114d4576114d36110ff565b5b600088013567ffffffffffffffff8111156114f2576114f1611104565b5b6114fe8a828b0161145f565b9750975050602088013567ffffffffffffffff81111561152157611520611104565b5b61152d8a828b0161145f565b9550955050604088013567ffffffffffffffff8111156115505761154f611104565b5b61155c8a828b0161145f565b9350935050606061156f8a828b016112ce565b91505092959891949750929550565b60008160070b9050919050565b6115948161157e565b82525050565b60006020820190506115af600083018461158b565b92915050565b600080fd5b600080fd5b600067ffffffffffffffff82169050919050565b6115dc816115bf565b81146115e757600080fd5b50565b6000813590506115f9816115d3565b92915050565b600060408284031215611615576116146115b5565b5b61161f60406111e2565b9050600061162f848285016115ea565b6000830152506020611643848285016115ea565b60208301525092915050565b600080600080600080600080610120898b0312156116705761166f6110ff565b5b600089013567ffffffffffffffff81111561168e5761168d611104565b5b61169a8b828c0161127f565b985050602089013567ffffffffffffffff8111156116bb576116ba611104565b5b6116c78b828c0161127f565b975050604089013567ffffffffffffffff8111156116e8576116e7611104565b5b6116f48b828c0161127f565b96505060606117058b828c016112ce565b955050608089013567ffffffffffffffff81111561172657611725611104565b5b6117328b828c0161127f565b94505060a06117438b828c016115ff565b93505060e06117548b828c016115ea565b92505061010089013567ffffffffffffffff81111561177657611775611104565b5b6117828b828c0161127f565b9150509295985092959890939650565b61179b816115bf565b82525050565b60006020820190506117b66000830184611792565b92915050565b60006117c782611109565b9050919050565b6117d7816117bc565b81146117e257600080fd5b50565b6000813590506117f4816117ce565b92915050565b60008060408385031215611811576118106110ff565b5b600061181f858286016117e5565b9250506020611830858286016117e5565b9150509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b600081519050919050565b600082825260208201905092915050565b60005b838110156118a0578082015181840152602081019050611885565b60008484015250505050565b60006118b782611866565b6118c18185611871565b93506118d1818560208601611882565b6118da81611171565b840191505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61191a816112ad565b82525050565b6000604083016000830151848203600086015261193d82826118ac565b91505060208301516119526020860182611911565b508091505092915050565b60006119698383611920565b905092915050565b6000602082019050919050565b6000611989826118e5565b61199381856118f0565b9350836020820285016119a585611901565b8060005b858110156119e157848403895281516119c2858261195d565b94506119cd83611971565b925060208a019950506001810190506119a9565b50829750879550505050505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000611a2b83836118ac565b905092915050565b6000602082019050919050565b6000611a4b826119f3565b611a5581856119fe565b935083602082028501611a6785611a0f565b8060005b85811015611aa35784840389528151611a848582611a1f565b9450611a8f83611a33565b925060208a01995050600181019050611a6b565b50829750879550505050505092915050565b600060a0830160008301518482036000860152611ad282826118ac565b91505060208301518482036020860152611aec82826118ac565b91505060408301518482036040860152611b06828261197e565b91505060608301518482036060860152611b208282611a40565b91505060808301518482036080860152611b3a8282611a40565b9150508091505092915050565b6000611b538383611ab5565b905092915050565b6000602082019050919050565b6000611b738261183a565b611b7d8185611845565b935083602082028501611b8f85611856565b8060005b85811015611bcb5784840389528151611bac8582611b47565b9450611bb783611b5b565b925060208a01995050600181019050611b93565b50829750879550505050505092915050565b60006020820190508181036000830152611bf78184611b68565b905092915050565b60008060008060008060008060006101208a8c031215611c2257611c216110ff565b5b6000611c308c828d01611152565b9950506020611c418c828d016117e5565b98505060408a013567ffffffffffffffff811115611c6257611c61611104565b5b611c6e8c828d0161127f565b97505060608a013567ffffffffffffffff811115611c8f57611c8e611104565b5b611c9b8c828d0161127f565b96505060808a013567ffffffffffffffff811115611cbc57611cbb611104565b5b611cc88c828d0161127f565b95505060a0611cd98c828d016112ce565b94505060c08a013567ffffffffffffffff811115611cfa57611cf9611104565b5b611d068c828d0161127f565b93505060e0611d178c828d01611306565b925050610100611d298c828d01611306565b9150509295985092959850929598565b600060208284031215611d4f57611d4e6110ff565b5b600082013567ffffffffffffffff811115611d6d57611d6c611104565b5b611d798482850161127f565b91505092915050565b600082825260208201905092915050565b6000611d9e82611866565b611da88185611d82565b9350611db8818560208601611882565b611dc181611171565b840191505092915050565b60006020820190508181036000830152611de68184611d93565b905092915050565b600080fd5b600060a08284031215611e0957611e08611dee565b5b81905092915050565b600060208284031215611e2857611e276110ff565b5b600082013567ffffffffffffffff811115611e4657611e45611104565b5b611e5284828501611df3565b91505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60006040830160008301518482036000860152611ea482826118ac565b91505060208301518482036020860152611ebe82826118ac565b9150508091505092915050565b6000611ed78383611e87565b905092915050565b6000602082019050919050565b6000611ef782611e5b565b611f018185611e66565b935083602082028501611f1385611e77565b8060005b85811015611f4f5784840389528151611f308582611ecb565b9450611f3b83611edf565b925060208a01995050600181019050611f17565b50829750879550505050505092915050565b600081519050919050565b600082825260208201905092915050565b6000611f8882611f61565b611f928185611f6c565b9350611fa2818560208601611882565b611fab81611171565b840191505092915050565b611fbf816115bf565b82525050565b60006040830160008301518482036000860152611fe28282611f7d565b9150506020830151611ff76020860182611fb6565b508091505092915050565b6000604082019050818103600083015261201c8185611eec565b905081810360208301526120308184611fc5565b90509392505050565b6000604083016000830151848203600086015261205682826118ac565b9150506020830151848203602086015261207082826118ac565b9150508091505092915050565b600060208201905081810360008301526120978184612039565b905092915050565b60008083601f8401126120b5576120b4611167565b5b8235905067ffffffffffffffff8111156120d2576120d1611455565b5b6020830191508360208202830111156120ee576120ed61145a565b5b9250929050565b6000806020838503121561210c5761210b6110ff565b5b600083013567ffffffffffffffff81111561212a57612129611104565b5b6121368582860161209f565b92509250509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061217c8261157e565b9150677fffffffffffffff820361219657612195612142565b5b600182019050919050565b600081905092915050565b50565b60006121bc6000836121a1565b91506121c7826121ac565b600082019050919050565b60006121dd826121af565b9150819050919050565b7f4661696c656420746f2073656e6420457468657220746f2064656c656761746f60008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b6000612243602183611d82565b915061224e826121e7565b604082019050919050565b6000602082019050818103600083015261227281612236565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006122b3826112ad565b91506122be836112ad565b9250826122ce576122cd612279565b5b828204905092915050565b6122e2816112ad565b82525050565b6000819050919050565b600061230d61230861230384611109565b6122e8565b611109565b9050919050565b600061231f826122f2565b9050919050565b600061233182612314565b9050919050565b61234181612326565b82525050565b60408201600082015161235d6000850182611fb6565b5060208201516123706020850182611fb6565b50505050565b6000819050919050565b600061239b61239661239184612376565b6122e8565b6115bf565b9050919050565b6123ab81612380565b82525050565b60006123be600083611d82565b91506123c9826121ac565b600082019050919050565b60006101408201905081810360008301526123ef818b611d93565b90508181036020830152612403818a611d93565b905081810360408301526124178189611d93565b905061242660608301886122d9565b6124336080830187612338565b81810360a08301526124458186611d93565b905061245460c0830185612347565b6124626101008301846123a2565b818103610120830152612474816123b1565b90509998505050505050505050565b600081519050612492816115d3565b92915050565b6000602082840312156124ae576124ad6110ff565b5b60006124bc84828501612483565b91505092915050565b6124ce816117bc565b82525050565b60006124e08385611d82565b93506124ed83858461122e565b6124f683611171565b840190509392505050565b600060a082019050612516600083018b6124c5565b818103602083015261252981898b6124d4565b9050818103604083015261253e8187896124d4565b905081810360608301526125538185876124d4565b905061256260808301846122d9565b9998505050505050505050565b60008151905061257e816112ef565b92915050565b60006020828403121561259a576125996110ff565b5b60006125a88482850161256f565b91505092915050565b7f4661696c656420746f20696e63726561736520616c6c6f77616e636500000000600082015250565b60006125e7601c83611d82565b91506125f2826125b1565b602082019050919050565b60006020820190508181036000830152612616816125da565b9050919050565b6000610140820190508181036000830152612638818c611d93565b9050818103602083015261264c818b611d93565b90508181036040830152612660818a611d93565b905061266f60608301896122d9565b61267c60808301886124c5565b81810360a083015261268e8187611d93565b905061269d60c0830186612347565b6126ab610100830185611792565b8181036101208301526126be8184611d93565b90509a9950505050505050505050565b60006020820190506126e360008301846124c5565b92915050565b7f4661696c656420746f207265766f6b6520617070726f76616c00000000000000600082015250565b600061271f601983611d82565b915061272a826126e9565b602082019050919050565b6000602082019050818103600083015261274e81612712565b9050919050565b600060408201905061276a60008301856124c5565b61277760208301846124c5565b9392505050565b600067ffffffffffffffff82111561279957612798611182565b5b602082029050602081019050919050565b60006127bd6127b8846111fd565b6111e2565b9050828152602081018484840111156127d9576127d861116c565b5b6127e4848285611882565b509392505050565b600082601f83011261280157612800611167565b5b81516128118482602086016127aa565b91505092915050565b600067ffffffffffffffff82111561283557612834611182565b5b602082029050602081019050919050565b600081519050612855816112b7565b92915050565b600060408284031215612871576128706115b5565b5b61287b60406111e2565b9050600082015167ffffffffffffffff81111561289b5761289a6115ba565b5b6128a7848285016127ec565b60008301525060206128bb84828501612846565b60208301525092915050565b60006128da6128d58461281a565b6111e2565b905080838252602082019050602084028301858111156128fd576128fc61145a565b5b835b8181101561294457805167ffffffffffffffff81111561292257612921611167565b5b80860161292f898261285b565b855260208501945050506020810190506128ff565b5050509392505050565b600082601f83011261296357612962611167565b5b81516129738482602086016128c7565b91505092915050565b600067ffffffffffffffff82111561299757612996611182565b5b602082029050602081019050919050565b60006129bb6129b68461297c565b6111e2565b905080838252602082019050602084028301858111156129de576129dd61145a565b5b835b81811015612a2557805167ffffffffffffffff811115612a0357612a02611167565b5b808601612a1089826127ec565b855260208501945050506020810190506129e0565b5050509392505050565b600082601f830112612a4457612a43611167565b5b8151612a548482602086016129a8565b91505092915050565b600060a08284031215612a7357612a726115b5565b5b612a7d60a06111e2565b9050600082015167ffffffffffffffff811115612a9d57612a9c6115ba565b5b612aa9848285016127ec565b600083015250602082015167ffffffffffffffff811115612acd57612acc6115ba565b5b612ad9848285016127ec565b602083015250604082015167ffffffffffffffff811115612afd57612afc6115ba565b5b612b098482850161294e565b604083015250606082015167ffffffffffffffff811115612b2d57612b2c6115ba565b5b612b3984828501612a2f565b606083015250608082015167ffffffffffffffff811115612b5d57612b5c6115ba565b5b612b6984828501612a2f565b60808301525092915050565b6000612b88612b838461277e565b6111e2565b90508083825260208201905060208402830185811115612bab57612baa61145a565b5b835b81811015612bf257805167ffffffffffffffff811115612bd057612bcf611167565b5b808601612bdd8982612a5d565b85526020850194505050602081019050612bad565b5050509392505050565b600082601f830112612c1157612c10611167565b5b8151612c21848260208601612b75565b91505092915050565b600060208284031215612c4057612c3f6110ff565b5b600082015167ffffffffffffffff811115612c5e57612c5d611104565b5b612c6a84828501612bfc565b91505092915050565b6000610140820190508181036000830152612c8e818b611d93565b90508181036020830152612ca2818a611d93565b90508181036040830152612cb68189611d93565b9050612cc560608301886122d9565b612cd260808301876124c5565b81810360a0830152612ce48186611d93565b9050612cf360c0830185612347565b612d016101008301846123a2565b818103610120830152612d13816123b1565b90509998505050505050505050565b600060208284031215612d3857612d376110ff565b5b600082015167ffffffffffffffff811115612d5657612d55611104565b5b612d62848285016127ec565b91505092915050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112612d9757612d96612d75565b5b83810192508235915060208301925067ffffffffffffffff821115612dbf57612dbe612d6b565b5b600182023603831315612dd557612dd4612d70565b5b509250929050565b6000612de98385611f6c565b9350612df683858461122e565b612dff83611171565b840190509392505050565b6000612e1960208401846115ea565b905092915050565b6000612e306020840184611306565b905092915050565b612e41816112e3565b82525050565b600060a08301612e5a6000840184612d7a565b8583036000870152612e6d838284612ddd565b92505050612e7e6020840184612e0a565b612e8b6020860182611fb6565b50612e996040840184612e0a565b612ea66040860182611fb6565b50612eb46060840184612e21565b612ec16060860182612e38565b50612ecf6080840184612e21565b612edc6080860182612e38565b508091505092915050565b60006020820190508181036000830152612f018184612e47565b905092915050565b600067ffffffffffffffff821115612f2457612f23611182565b5b602082029050602081019050919050565b600060408284031215612f4b57612f4a6115b5565b5b612f5560406111e2565b9050600082015167ffffffffffffffff811115612f7557612f746115ba565b5b612f81848285016127ec565b600083015250602082015167ffffffffffffffff811115612fa557612fa46115ba565b5b612fb1848285016127ec565b60208301525092915050565b6000612fd0612fcb84612f09565b6111e2565b90508083825260208201905060208402830185811115612ff357612ff261145a565b5b835b8181101561303a57805167ffffffffffffffff81111561301857613017611167565b5b8086016130258982612f35565b85526020850194505050602081019050612ff5565b5050509392505050565b600082601f83011261305957613058611167565b5b8151613069848260208601612fbd565b91505092915050565b600067ffffffffffffffff82111561308d5761308c611182565b5b61309682611171565b9050602081019050919050565b60006130b66130b184613072565b6111e2565b9050828152602081018484840111156130d2576130d161116c565b5b6130dd848285611882565b509392505050565b600082601f8301126130fa576130f9611167565b5b815161310a8482602086016130a3565b91505092915050565b600060408284031215613129576131286115b5565b5b61313360406111e2565b9050600082015167ffffffffffffffff811115613153576131526115ba565b5b61315f848285016130e5565b600083015250602061317384828501612483565b60208301525092915050565b60008060408385031215613196576131956110ff565b5b600083015167ffffffffffffffff8111156131b4576131b3611104565b5b6131c085828601613044565b925050602083015167ffffffffffffffff8111156131e1576131e0611104565b5b6131ed85828601613113565b9150509250929050565b60006020828403121561320d5761320c6110ff565b5b600082015167ffffffffffffffff81111561322b5761322a611104565b5b61323784828501612f35565b91505092915050565b7f4661696c656420746f20646563726561736520616c6c6f77616e636500000000600082015250565b6000613276601c83611d82565b915061328182613240565b602082019050919050565b600060208201905081810360008301526132a581613269565b9050919050565b6000819050919050565b600080833560016020038436030381126132d3576132d2612d75565b5b83810192508235915060208301925067ffffffffffffffff8211156132fb576132fa612d6b565b5b60018202360383131561331157613310612d70565b5b509250929050565b60006133258385611871565b935061333283858461122e565b61333b83611171565b840190509392505050565b6000808335600160200384360303811261336357613362612d75565b5b83810192508235915060208301925067ffffffffffffffff82111561338b5761338a612d6b565b5b6020820236038313156133a1576133a0612d70565b5b509250929050565b6000819050919050565b60006133c260208401846112ce565b905092915050565b6000604083016133dd60008401846132b6565b85830360008701526133f0838284613319565b9250505061340160208401846133b3565b61340e6020860182611911565b508091505092915050565b600061342583836133ca565b905092915050565b60008235600160400383360303811261344957613448612d75565b5b82810191505092915050565b6000602082019050919050565b600061346e83856118f0565b935083602084028501613480846133a9565b8060005b878110156134c457848403895261349b828461342d565b6134a58582613419565b94506134b083613455565b925060208a01995050600181019050613484565b50829750879450505050509392505050565b600080833560016020038436030381126134f3576134f2612d75565b5b83810192508235915060208301925067ffffffffffffffff82111561351b5761351a612d6b565b5b60208202360383131561353157613530612d70565b5b509250929050565b6000819050919050565b6000613550848484613319565b90509392505050565b6000602082019050919050565b600061357283856119fe565b93508360208402850161358484613539565b8060005b878110156135ca57848403895261359f82846132b6565b6135aa868284613543565b95506135b584613559565b935060208b019a505050600181019050613588565b50829750879450505050509392505050565b600060a083016135ef60008401846132b6565b8583036000870152613602838284613319565b9250505061361360208401846132b6565b8583036020870152613626838284613319565b925050506136376040840184613346565b858303604087015261364a838284613462565b9250505061365b60608401846134d6565b858303606087015261366e838284613566565b9250505061367f60808401846134d6565b8583036080870152613692838284613566565b925050508091505092915050565b60006136ac83836135dc565b905092915050565b60008235600160a0038336030381126136d0576136cf612d75565b5b82810191505092915050565b6000602082019050919050565b60006136f58385611845565b935083602084028501613707846132ac565b8060005b8781101561374b57848403895261372282846136b4565b61372c85826136a0565b9450613737836136dc565b925060208a0199505060018101905061370b565b50829750879450505050509392505050565b600060408201905061377260008301866124c5565b81810360208301526137858184866136e9565b9050949350505050565b7f4661696c656420746f20706572666f726d20617070726f76616c000000000000600082015250565b60006137c5601a83611d82565b91506137d08261378f565b602082019050919050565b600060208201905081810360008301526137f4816137b8565b905091905056fea2646970667358221220ad77753d207f5fa16ed802e3577e3ce385d25445983916e5d53914f0d256891964736f6c63430008140033", "linkReferences": {}, "deployedLinkReferences": {} } diff --git a/precompiles/testutil/contracts/InterchainSender.sol b/precompiles/testutil/contracts/InterchainSender.sol index f71f4f33..581d032f 100644 --- a/precompiles/testutil/contracts/InterchainSender.sol +++ b/precompiles/testutil/contracts/InterchainSender.sol @@ -124,7 +124,7 @@ contract InterchainSender { ) public { if (_before) { counter++; - (bool sent, ) = _source.call{value: 15}(""); + (bool sent, ) = _source.call{value: 15000000000000}(""); require(sent, "Failed to send Ether to delegator"); } Height memory timeoutHeight = Height(100, 100); @@ -141,7 +141,7 @@ contract InterchainSender { ); if (_between) { counter++; - (bool sent, ) = _source.call{value: 15}(""); + (bool sent, ) = _source.call{value: 15000000000000}(""); require(sent, "Failed to send Ether to delegator"); } ICS20_CONTRACT.transfer( @@ -157,7 +157,7 @@ contract InterchainSender { ); if (_after) { counter++; - (bool sent, ) = _source.call{value: 15}(""); + (bool sent, ) = _source.call{value: 15000000000000}(""); require(sent, "Failed to send Ether to delegator"); } } @@ -176,7 +176,7 @@ contract InterchainSender { ) public { if (_before) { counter++; - (bool sent, ) = _otherAcc.call{value: 15}(""); + (bool sent, ) = _otherAcc.call{value: 15000000000000}(""); require(sent, "Failed to send Ether to delegator"); } Height memory timeoutHeight = Height(100, 100); @@ -193,7 +193,7 @@ contract InterchainSender { ); if (_after) { counter++; - (bool sent, ) = _otherAcc.call{value: 15}(""); + (bool sent, ) = _otherAcc.call{value: 15000000000000}(""); require(sent, "Failed to send Ether to delegator"); } } diff --git a/precompiles/testutil/contracts/InterchainSenderCaller.json b/precompiles/testutil/contracts/InterchainSenderCaller.json index a5d70ab9..09e32888 100644 --- a/precompiles/testutil/contracts/InterchainSenderCaller.json +++ b/precompiles/testutil/contracts/InterchainSenderCaller.json @@ -180,8 +180,8 @@ "type": "function" } ], - "bytecode": "0x6080604052604051610c04380380610c04833981810160405281019061002591906100cf565b80600060086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506100fc565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061009c82610071565b9050919050565b6100ac81610091565b81146100b757600080fd5b50565b6000815190506100c9816100a3565b92915050565b6000602082840312156100e5576100e461006c565b5b60006100f3848285016100ba565b91505092915050565b610af98061010b6000396000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c8063073989ff1461005c578063427c1cb61461007857806361bc221a1461009457806369a98b2b146100b2578063ec3c5a14146100ce575b600080fd5b61007660048036038101906100719190610752565b6100ea565b005b610092600480360381019061008d9190610752565b6101f1565b005b61009c61030d565b6040516100a9919061086b565b60405180910390f35b6100cc60048036038101906100c79190610752565b61031e565b005b6100e860048036038101906100e39190610752565b6104c4565b005b60008081819054906101000a900460070b80929190610108906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff160217905550503073ffffffffffffffffffffffffffffffffffffffff1663427c1cb68787878787876040518763ffffffff1660e01b815260040161017596959493929190610982565b600060405180830381600087803b15801561018f57600080fd5b505af19250505080156101a0575060015b5060008081819054906101000a900460070b809291906101bf906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050505050505050565b600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b815260040161025e99989796959493929190610a1a565b600060405180830381600087803b15801561027857600080fd5b505af115801561028c573d6000803e3d6000fd5b505050503073ffffffffffffffffffffffffffffffffffffffff1663ec3c5a148787878787876040518763ffffffff1660e01b81526004016102d396959493929190610982565b600060405180830381600087803b1580156102ed57600080fd5b505af1158015610301573d6000803e3d6000fd5b50505050505050505050565b60008054906101000a900460070b81565b60008081819054906101000a900460070b8092919061033c906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b81526004016103d399989796959493929190610a1a565b600060405180830381600087803b1580156103ed57600080fd5b505af1158015610401573d6000803e3d6000fd5b505050503073ffffffffffffffffffffffffffffffffffffffff1663ec3c5a148787878787876040518763ffffffff1660e01b815260040161044896959493929190610982565b600060405180830381600087803b15801561046257600080fd5b505af1925050508015610473575060015b5060008081819054906101000a900460070b80929190610492906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050505050505050565b600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b815260040161053199989796959493929190610a1a565b600060405180830381600087803b15801561054b57600080fd5b505af115801561055f573d6000803e3d6000fd5b600080fd5b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006105a382610578565b9050919050565b6105b381610598565b81146105be57600080fd5b50565b6000813590506105d0816105aa565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610629826105e0565b810181811067ffffffffffffffff82111715610648576106476105f1565b5b80604052505050565b600061065b610564565b90506106678282610620565b919050565b600067ffffffffffffffff821115610687576106866105f1565b5b610690826105e0565b9050602081019050919050565b82818337600083830152505050565b60006106bf6106ba8461066c565b610651565b9050828152602081018484840111156106db576106da6105db565b5b6106e684828561069d565b509392505050565b600082601f830112610703576107026105d6565b5b81356107138482602086016106ac565b91505092915050565b6000819050919050565b61072f8161071c565b811461073a57600080fd5b50565b60008135905061074c81610726565b92915050565b60008060008060008060c0878903121561076f5761076e61056e565b5b600061077d89828a016105c1565b965050602087013567ffffffffffffffff81111561079e5761079d610573565b5b6107aa89828a016106ee565b955050604087013567ffffffffffffffff8111156107cb576107ca610573565b5b6107d789828a016106ee565b945050606087013567ffffffffffffffff8111156107f8576107f7610573565b5b61080489828a016106ee565b935050608061081589828a0161073d565b92505060a087013567ffffffffffffffff81111561083657610835610573565b5b61084289828a016106ee565b9150509295509295509295565b60008160070b9050919050565b6108658161084f565b82525050565b6000602082019050610880600083018461085c565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006108c08261084f565b9150677fffffffffffffff82036108da576108d9610886565b5b600182019050919050565b6108ee81610598565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561092e578082015181840152602081019050610913565b60008484015250505050565b6000610945826108f4565b61094f81856108ff565b935061095f818560208601610910565b610968816105e0565b840191505092915050565b61097c8161071c565b82525050565b600060c08201905061099760008301896108e5565b81810360208301526109a9818861093a565b905081810360408301526109bd818761093a565b905081810360608301526109d1818661093a565b90506109e06080830185610973565b81810360a08301526109f2818461093a565b9050979650505050505050565b60008115159050919050565b610a14816109ff565b82525050565b600061012082019050610a30600083018c6108e5565b8181036020830152610a42818b61093a565b90508181036040830152610a56818a61093a565b90508181036060830152610a6a818961093a565b9050610a796080830188610973565b81810360a0830152610a8b818761093a565b9050610a9a60c0830186610a0b565b610aa760e0830185610a0b565b610ab5610100830184610a0b565b9a995050505050505050505056fea264697066735822122006c420c5aa76bec23eee91c787113b6c1dfdae997bcb2dcf4c8df1eba21043d964736f6c63430008140033", - "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100575760003560e01c8063073989ff1461005c578063427c1cb61461007857806361bc221a1461009457806369a98b2b146100b2578063ec3c5a14146100ce575b600080fd5b61007660048036038101906100719190610752565b6100ea565b005b610092600480360381019061008d9190610752565b6101f1565b005b61009c61030d565b6040516100a9919061086b565b60405180910390f35b6100cc60048036038101906100c79190610752565b61031e565b005b6100e860048036038101906100e39190610752565b6104c4565b005b60008081819054906101000a900460070b80929190610108906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff160217905550503073ffffffffffffffffffffffffffffffffffffffff1663427c1cb68787878787876040518763ffffffff1660e01b815260040161017596959493929190610982565b600060405180830381600087803b15801561018f57600080fd5b505af19250505080156101a0575060015b5060008081819054906101000a900460070b809291906101bf906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050505050505050565b600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b815260040161025e99989796959493929190610a1a565b600060405180830381600087803b15801561027857600080fd5b505af115801561028c573d6000803e3d6000fd5b505050503073ffffffffffffffffffffffffffffffffffffffff1663ec3c5a148787878787876040518763ffffffff1660e01b81526004016102d396959493929190610982565b600060405180830381600087803b1580156102ed57600080fd5b505af1158015610301573d6000803e3d6000fd5b50505050505050505050565b60008054906101000a900460070b81565b60008081819054906101000a900460070b8092919061033c906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b81526004016103d399989796959493929190610a1a565b600060405180830381600087803b1580156103ed57600080fd5b505af1158015610401573d6000803e3d6000fd5b505050503073ffffffffffffffffffffffffffffffffffffffff1663ec3c5a148787878787876040518763ffffffff1660e01b815260040161044896959493929190610982565b600060405180830381600087803b15801561046257600080fd5b505af1925050508015610473575060015b5060008081819054906101000a900460070b80929190610492906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050505050505050565b600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b815260040161053199989796959493929190610a1a565b600060405180830381600087803b15801561054b57600080fd5b505af115801561055f573d6000803e3d6000fd5b600080fd5b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006105a382610578565b9050919050565b6105b381610598565b81146105be57600080fd5b50565b6000813590506105d0816105aa565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610629826105e0565b810181811067ffffffffffffffff82111715610648576106476105f1565b5b80604052505050565b600061065b610564565b90506106678282610620565b919050565b600067ffffffffffffffff821115610687576106866105f1565b5b610690826105e0565b9050602081019050919050565b82818337600083830152505050565b60006106bf6106ba8461066c565b610651565b9050828152602081018484840111156106db576106da6105db565b5b6106e684828561069d565b509392505050565b600082601f830112610703576107026105d6565b5b81356107138482602086016106ac565b91505092915050565b6000819050919050565b61072f8161071c565b811461073a57600080fd5b50565b60008135905061074c81610726565b92915050565b60008060008060008060c0878903121561076f5761076e61056e565b5b600061077d89828a016105c1565b965050602087013567ffffffffffffffff81111561079e5761079d610573565b5b6107aa89828a016106ee565b955050604087013567ffffffffffffffff8111156107cb576107ca610573565b5b6107d789828a016106ee565b945050606087013567ffffffffffffffff8111156107f8576107f7610573565b5b61080489828a016106ee565b935050608061081589828a0161073d565b92505060a087013567ffffffffffffffff81111561083657610835610573565b5b61084289828a016106ee565b9150509295509295509295565b60008160070b9050919050565b6108658161084f565b82525050565b6000602082019050610880600083018461085c565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006108c08261084f565b9150677fffffffffffffff82036108da576108d9610886565b5b600182019050919050565b6108ee81610598565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561092e578082015181840152602081019050610913565b60008484015250505050565b6000610945826108f4565b61094f81856108ff565b935061095f818560208601610910565b610968816105e0565b840191505092915050565b61097c8161071c565b82525050565b600060c08201905061099760008301896108e5565b81810360208301526109a9818861093a565b905081810360408301526109bd818761093a565b905081810360608301526109d1818661093a565b90506109e06080830185610973565b81810360a08301526109f2818461093a565b9050979650505050505050565b60008115159050919050565b610a14816109ff565b82525050565b600061012082019050610a30600083018c6108e5565b8181036020830152610a42818b61093a565b90508181036040830152610a56818a61093a565b90508181036060830152610a6a818961093a565b9050610a796080830188610973565b81810360a0830152610a8b818761093a565b9050610a9a60c0830186610a0b565b610aa760e0830185610a0b565b610ab5610100830184610a0b565b9a995050505050505050505056fea264697066735822122006c420c5aa76bec23eee91c787113b6c1dfdae997bcb2dcf4c8df1eba21043d964736f6c63430008140033", + "bytecode": "0x6080604052604051610c04380380610c04833981810160405281019061002591906100cf565b80600060086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506100fc565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061009c82610071565b9050919050565b6100ac81610091565b81146100b757600080fd5b50565b6000815190506100c9816100a3565b92915050565b6000602082840312156100e5576100e461006c565b5b60006100f3848285016100ba565b91505092915050565b610af98061010b6000396000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c8063073989ff1461005c578063427c1cb61461007857806361bc221a1461009457806369a98b2b146100b2578063ec3c5a14146100ce575b600080fd5b61007660048036038101906100719190610752565b6100ea565b005b610092600480360381019061008d9190610752565b6101f1565b005b61009c61030d565b6040516100a9919061086b565b60405180910390f35b6100cc60048036038101906100c79190610752565b61031e565b005b6100e860048036038101906100e39190610752565b6104c4565b005b60008081819054906101000a900460070b80929190610108906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff160217905550503073ffffffffffffffffffffffffffffffffffffffff1663427c1cb68787878787876040518763ffffffff1660e01b815260040161017596959493929190610982565b600060405180830381600087803b15801561018f57600080fd5b505af19250505080156101a0575060015b5060008081819054906101000a900460070b809291906101bf906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050505050505050565b600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b815260040161025e99989796959493929190610a1a565b600060405180830381600087803b15801561027857600080fd5b505af115801561028c573d6000803e3d6000fd5b505050503073ffffffffffffffffffffffffffffffffffffffff1663ec3c5a148787878787876040518763ffffffff1660e01b81526004016102d396959493929190610982565b600060405180830381600087803b1580156102ed57600080fd5b505af1158015610301573d6000803e3d6000fd5b50505050505050505050565b60008054906101000a900460070b81565b60008081819054906101000a900460070b8092919061033c906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b81526004016103d399989796959493929190610a1a565b600060405180830381600087803b1580156103ed57600080fd5b505af1158015610401573d6000803e3d6000fd5b505050503073ffffffffffffffffffffffffffffffffffffffff1663ec3c5a148787878787876040518763ffffffff1660e01b815260040161044896959493929190610982565b600060405180830381600087803b15801561046257600080fd5b505af1925050508015610473575060015b5060008081819054906101000a900460070b80929190610492906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050505050505050565b600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b815260040161053199989796959493929190610a1a565b600060405180830381600087803b15801561054b57600080fd5b505af115801561055f573d6000803e3d6000fd5b600080fd5b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006105a382610578565b9050919050565b6105b381610598565b81146105be57600080fd5b50565b6000813590506105d0816105aa565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610629826105e0565b810181811067ffffffffffffffff82111715610648576106476105f1565b5b80604052505050565b600061065b610564565b90506106678282610620565b919050565b600067ffffffffffffffff821115610687576106866105f1565b5b610690826105e0565b9050602081019050919050565b82818337600083830152505050565b60006106bf6106ba8461066c565b610651565b9050828152602081018484840111156106db576106da6105db565b5b6106e684828561069d565b509392505050565b600082601f830112610703576107026105d6565b5b81356107138482602086016106ac565b91505092915050565b6000819050919050565b61072f8161071c565b811461073a57600080fd5b50565b60008135905061074c81610726565b92915050565b60008060008060008060c0878903121561076f5761076e61056e565b5b600061077d89828a016105c1565b965050602087013567ffffffffffffffff81111561079e5761079d610573565b5b6107aa89828a016106ee565b955050604087013567ffffffffffffffff8111156107cb576107ca610573565b5b6107d789828a016106ee565b945050606087013567ffffffffffffffff8111156107f8576107f7610573565b5b61080489828a016106ee565b935050608061081589828a0161073d565b92505060a087013567ffffffffffffffff81111561083657610835610573565b5b61084289828a016106ee565b9150509295509295509295565b60008160070b9050919050565b6108658161084f565b82525050565b6000602082019050610880600083018461085c565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006108c08261084f565b9150677fffffffffffffff82036108da576108d9610886565b5b600182019050919050565b6108ee81610598565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561092e578082015181840152602081019050610913565b60008484015250505050565b6000610945826108f4565b61094f81856108ff565b935061095f818560208601610910565b610968816105e0565b840191505092915050565b61097c8161071c565b82525050565b600060c08201905061099760008301896108e5565b81810360208301526109a9818861093a565b905081810360408301526109bd818761093a565b905081810360608301526109d1818661093a565b90506109e06080830185610973565b81810360a08301526109f2818461093a565b9050979650505050505050565b60008115159050919050565b610a14816109ff565b82525050565b600061012082019050610a30600083018c6108e5565b8181036020830152610a42818b61093a565b90508181036040830152610a56818a61093a565b90508181036060830152610a6a818961093a565b9050610a796080830188610973565b81810360a0830152610a8b818761093a565b9050610a9a60c0830186610a0b565b610aa760e0830185610a0b565b610ab5610100830184610a0b565b9a995050505050505050505056fea26469706673582212208d9ac6bb34cf465f323f24873e5ecdfed0aee3ab51a2385e500175826995e5c364736f6c63430008140033", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100575760003560e01c8063073989ff1461005c578063427c1cb61461007857806361bc221a1461009457806369a98b2b146100b2578063ec3c5a14146100ce575b600080fd5b61007660048036038101906100719190610752565b6100ea565b005b610092600480360381019061008d9190610752565b6101f1565b005b61009c61030d565b6040516100a9919061086b565b60405180910390f35b6100cc60048036038101906100c79190610752565b61031e565b005b6100e860048036038101906100e39190610752565b6104c4565b005b60008081819054906101000a900460070b80929190610108906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff160217905550503073ffffffffffffffffffffffffffffffffffffffff1663427c1cb68787878787876040518763ffffffff1660e01b815260040161017596959493929190610982565b600060405180830381600087803b15801561018f57600080fd5b505af19250505080156101a0575060015b5060008081819054906101000a900460070b809291906101bf906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050505050505050565b600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b815260040161025e99989796959493929190610a1a565b600060405180830381600087803b15801561027857600080fd5b505af115801561028c573d6000803e3d6000fd5b505050503073ffffffffffffffffffffffffffffffffffffffff1663ec3c5a148787878787876040518763ffffffff1660e01b81526004016102d396959493929190610982565b600060405180830381600087803b1580156102ed57600080fd5b505af1158015610301573d6000803e3d6000fd5b50505050505050505050565b60008054906101000a900460070b81565b60008081819054906101000a900460070b8092919061033c906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b81526004016103d399989796959493929190610a1a565b600060405180830381600087803b1580156103ed57600080fd5b505af1158015610401573d6000803e3d6000fd5b505050503073ffffffffffffffffffffffffffffffffffffffff1663ec3c5a148787878787876040518763ffffffff1660e01b815260040161044896959493929190610982565b600060405180830381600087803b15801561046257600080fd5b505af1925050508015610473575060015b5060008081819054906101000a900460070b80929190610492906108b5565b91906101000a81548167ffffffffffffffff021916908360070b67ffffffffffffffff16021790555050505050505050565b600060089054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dba685b87878787878760018060016040518a63ffffffff1660e01b815260040161053199989796959493929190610a1a565b600060405180830381600087803b15801561054b57600080fd5b505af115801561055f573d6000803e3d6000fd5b600080fd5b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006105a382610578565b9050919050565b6105b381610598565b81146105be57600080fd5b50565b6000813590506105d0816105aa565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610629826105e0565b810181811067ffffffffffffffff82111715610648576106476105f1565b5b80604052505050565b600061065b610564565b90506106678282610620565b919050565b600067ffffffffffffffff821115610687576106866105f1565b5b610690826105e0565b9050602081019050919050565b82818337600083830152505050565b60006106bf6106ba8461066c565b610651565b9050828152602081018484840111156106db576106da6105db565b5b6106e684828561069d565b509392505050565b600082601f830112610703576107026105d6565b5b81356107138482602086016106ac565b91505092915050565b6000819050919050565b61072f8161071c565b811461073a57600080fd5b50565b60008135905061074c81610726565b92915050565b60008060008060008060c0878903121561076f5761076e61056e565b5b600061077d89828a016105c1565b965050602087013567ffffffffffffffff81111561079e5761079d610573565b5b6107aa89828a016106ee565b955050604087013567ffffffffffffffff8111156107cb576107ca610573565b5b6107d789828a016106ee565b945050606087013567ffffffffffffffff8111156107f8576107f7610573565b5b61080489828a016106ee565b935050608061081589828a0161073d565b92505060a087013567ffffffffffffffff81111561083657610835610573565b5b61084289828a016106ee565b9150509295509295509295565b60008160070b9050919050565b6108658161084f565b82525050565b6000602082019050610880600083018461085c565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006108c08261084f565b9150677fffffffffffffff82036108da576108d9610886565b5b600182019050919050565b6108ee81610598565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561092e578082015181840152602081019050610913565b60008484015250505050565b6000610945826108f4565b61094f81856108ff565b935061095f818560208601610910565b610968816105e0565b840191505092915050565b61097c8161071c565b82525050565b600060c08201905061099760008301896108e5565b81810360208301526109a9818861093a565b905081810360408301526109bd818761093a565b905081810360608301526109d1818661093a565b90506109e06080830185610973565b81810360a08301526109f2818461093a565b9050979650505050505050565b60008115159050919050565b610a14816109ff565b82525050565b600061012082019050610a30600083018c6108e5565b8181036020830152610a42818b61093a565b90508181036040830152610a56818a61093a565b90508181036060830152610a6a818961093a565b9050610a796080830188610973565b81810360a0830152610a8b818761093a565b9050610a9a60c0830186610a0b565b610aa760e0830185610a0b565b610ab5610100830184610a0b565b9a995050505050505050505056fea26469706673582212208d9ac6bb34cf465f323f24873e5ecdfed0aee3ab51a2385e500175826995e5c364736f6c63430008140033", "linkReferences": {}, "deployedLinkReferences": {} } diff --git a/precompiles/testutil/contracts/contracts.go b/precompiles/testutil/contracts/contracts.go index 1ac9ca31..cd725635 100644 --- a/precompiles/testutil/contracts/contracts.go +++ b/precompiles/testutil/contracts/contracts.go @@ -56,11 +56,14 @@ func Call(ctx sdk.Context, app *exampleapp.ExampleChain, args CallArgs) (res abc // if gas price not provided var gasPrice *big.Int if args.GasPrice == nil { - gasPrice = app.FeeMarketKeeper.GetBaseFee(ctx) // default gas price == block base fee + baseFeeRes, err := app.EVMKeeper.BaseFee(ctx, &evmtypes.QueryBaseFeeRequest{}) + if err != nil { + return abci.ExecTxResult{}, nil, err + } + gasPrice = baseFeeRes.BaseFee.BigInt() // default gas price == block base fee } else { gasPrice = args.GasPrice } - // Create MsgEthereumTx that calls the contract input, err := args.ContractABI.Pack(args.MethodName, args.Args...) if err != nil { @@ -69,7 +72,7 @@ func Call(ctx sdk.Context, app *exampleapp.ExampleChain, args CallArgs) (res abc // Create MsgEthereumTx that calls the contract msg := evmtypes.NewTx(&evmtypes.EvmTxArgs{ - ChainID: app.EVMKeeper.ChainID(), + ChainID: evmtypes.GetEthChainConfig().ChainID, Nonce: nonce, To: &args.ContractAddr, Amount: args.Amount, diff --git a/precompiles/werc20/IWERC20.sol b/precompiles/werc20/IWERC20.sol new file mode 100644 index 00000000..6a2e019e --- /dev/null +++ b/precompiles/werc20/IWERC20.sol @@ -0,0 +1,36 @@ +// SPDX-License-Identifier: LGPL-3.0-only +pragma solidity >=0.8.18; + +import "./../erc20/IERC20MetadataAllowance.sol"; + +/** + * @author Evmos Team + * @title Wrapped ERC20 Interface + * @dev Interface for representing the native EVM token as a wrapped ERC20 standard. + */ +interface IWERC20 is IERC20MetadataAllowance { + /// @dev Emitted when the native tokens are deposited in exchange for the wrapped ERC20. + /// @param dst The account for which the deposit is made. + /// @param wad The amount of native tokens deposited. + event Deposit(address indexed dst, uint256 wad); + + /// @dev Emitted when the native token is withdrawn. + /// @param src The account for which the withdrawal is made. + /// @param wad The amount of native tokens withdrawn. + event Withdrawal(address indexed src, uint256 wad); + + /// @dev Default fallback payable function. Must call the deposit method in implementing contracts. + fallback() external payable; + + /// @dev Default receive payable function. Must call the deposit method in implementing contracts. + receive() external payable; + + /// @dev Deposits native tokens in exchange for wrapped ERC20 token. + /// @dev Emits a Deposit Event. + function deposit() external payable; + + /// @dev Withdraws native tokens from wrapped ERC20 token. + /// @dev Emits a Withdrawal Event. + /// @param wad The amount of native tokens to be withdrawn. + function withdraw(uint256 wad) external; +} diff --git a/precompiles/werc20/abi.json b/precompiles/werc20/abi.json new file mode 100644 index 00000000..eac5c128 --- /dev/null +++ b/precompiles/werc20/abi.json @@ -0,0 +1,347 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "IWERC20", + "sourceName": "solidity/precompiles/werc20/IWERC20.sol", + "abi": [ + { + "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": "dst", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "wad", + "type": "uint256" + } + ], + "name": "Deposit", + "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" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "wad", + "type": "uint256" + } + ], + "name": "Withdrawal", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "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": "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": "approved", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "deposit", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "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": [ + { + "internalType": "uint256", + "name": "wad", + "type": "uint256" + } + ], + "name": "withdraw", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + } + ], + "bytecode": "0x", + "deployedBytecode": "0x", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/precompiles/werc20/events.go b/precompiles/werc20/events.go new file mode 100644 index 00000000..f5ff75a1 --- /dev/null +++ b/precompiles/werc20/events.go @@ -0,0 +1,81 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package werc20 + +import ( + "math/big" + + sdk "github.com/cosmos/cosmos-sdk/types" + + "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/core/vm" + cmn "github.com/evmos/os/precompiles/common" +) + +const ( + // EventTypeDeposit is the key of the event type for the Deposit transaction. + EventTypeDeposit = "Deposit" + // EventTypeWithdrawal is the key of the event type for the Withdraw transaction. + EventTypeWithdrawal = "Withdrawal" +) + +// EmitDepositEvent creates a new Deposit event emitted after a Deposit transaction. +func (p Precompile) EmitDepositEvent( + ctx sdk.Context, + stateDB vm.StateDB, + caller common.Address, + amount *big.Int, +) error { + event := p.ABI.Events[EventTypeDeposit] + return p.createWERC20Event(ctx, stateDB, event, caller, amount) +} + +// EmitWithdrawalEvent creates a new Withdrawal event emitted after a Withdraw transaction. +func (p Precompile) EmitWithdrawalEvent( + ctx sdk.Context, + stateDB vm.StateDB, + src common.Address, + amount *big.Int, +) error { + event := p.ABI.Events[EventTypeWithdrawal] + return p.createWERC20Event(ctx, stateDB, event, src, amount) +} + +// createWERC20Event adds to the StateDB a log representing an event for the +// WERC20 precompile. +func (p Precompile) createWERC20Event( + ctx sdk.Context, + stateDB vm.StateDB, + event abi.Event, + address common.Address, + amount *big.Int, +) error { + // Prepare the event topics + topics := make([]common.Hash, 2) + + topics[0] = event.ID + + var err error + topics[1], err = cmn.MakeTopic(address) + if err != nil { + return err + } + + arguments := abi.Arguments{event.Inputs[1]} + packed, err := arguments.Pack(amount) + if err != nil { + return err + } + + stateDB.AddLog(ðtypes.Log{ + Address: p.Address(), + Topics: topics, + Data: packed, + BlockNumber: uint64(ctx.BlockHeight()), //nolint:gosec // G115 + }) + + return nil +} diff --git a/precompiles/werc20/events_test.go b/precompiles/werc20/events_test.go new file mode 100644 index 00000000..c7286acb --- /dev/null +++ b/precompiles/werc20/events_test.go @@ -0,0 +1,207 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package werc20_test + +import ( + "math/big" + "testing" + + "github.com/stretchr/testify/suite" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/crypto" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/precompiles/werc20" + testconstants "github.com/evmos/os/testutil/constants" + "github.com/evmos/os/testutil/integration/os/factory" + "github.com/evmos/os/testutil/integration/os/grpc" + "github.com/evmos/os/testutil/integration/os/keyring" + "github.com/evmos/os/testutil/integration/os/network" +) + +type PrecompileUnitTestSuite struct { + suite.Suite + + network *network.UnitTestNetwork + factory factory.TxFactory + grpcHandler grpc.Handler + keyring keyring.Keyring + + // WEVMOS related fields + precompile *werc20.Precompile + precompileAddrHex string +} + +func TestPrecompileUnitTestSuite(t *testing.T) { + suite.Run(t, new(PrecompileUnitTestSuite)) +} + +// SetupTest allows to configure the testing suite embedding a network with a +// custom chainID. This is important to check that the correct address is used +// for the precompile. +func (s *PrecompileUnitTestSuite) SetupTest(chainID string) { + keyring := keyring.New(2) + + integrationNetwork := network.NewUnitTestNetwork( + network.WithChainID(chainID), + network.WithPreFundedAccounts(keyring.GetAllAccAddrs()...), + ) + grpcHandler := grpc.NewIntegrationHandler(integrationNetwork) + txFactory := factory.New(integrationNetwork, grpcHandler) + + s.network = integrationNetwork + s.factory = txFactory + s.grpcHandler = grpcHandler + s.keyring = keyring + + s.precompileAddrHex = network.GetWEVMOSContractHex(chainID) + + ctx := integrationNetwork.GetContext() + + tokenDenom, err := s.network.App.Erc20Keeper.GetTokenDenom(ctx, common.HexToAddress(s.precompileAddrHex)) + s.Require().NoError(err, "failed to get token denom") + tokenPairID := s.network.App.Erc20Keeper.GetTokenPairID(ctx, tokenDenom) + tokenPair, found := s.network.App.Erc20Keeper.GetTokenPair(ctx, tokenPairID) + s.Require().True(found, "expected wevmos precompile to be registered in the tokens map") + s.Require().Equal(s.precompileAddrHex, tokenPair.Erc20Address, "expected a different address of the contract") + + precompile, err := werc20.NewPrecompile( + tokenPair, + s.network.App.BankKeeper, + s.network.App.AuthzKeeper, + s.network.App.TransferKeeper, + ) + s.Require().NoError(err, "failed to instantiate the werc20 precompile") + s.Require().NotNil(precompile) + s.precompile = precompile +} + +type DepositEvent struct { + Dst common.Address + Wad *big.Int +} + +type WithdrawalEvent struct { + Src common.Address + Wad *big.Int +} + +//nolint:dupl +func (s *PrecompileUnitTestSuite) TestEmitDepositEvent() { + testCases := []struct { + name string + chainID string + }{ + { + name: "mainnet", + chainID: testconstants.ExampleChainID, + }, { + name: "six decimals", + chainID: testconstants.SixDecimalsChainID, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest(tc.chainID) + caller := s.keyring.GetAddr(0) + amount := new(big.Int).SetInt64(1_000) + + stateDB := s.network.GetStateDB() + + err := s.precompile.EmitDepositEvent( + s.network.GetContext(), + stateDB, + caller, + amount, + ) + s.Require().NoError(err, "expected deposit event to be emitted successfully") + + log := stateDB.Logs()[0] + + // Check on the address + s.Require().Equal(log.Address, s.precompile.Address()) + + // Check on the topics + event := s.precompile.ABI.Events[werc20.EventTypeDeposit] + s.Require().Equal( + crypto.Keccak256Hash([]byte(event.Sig)), + common.HexToHash(log.Topics[0].Hex()), + ) + var adddressTopic common.Hash + copy(adddressTopic[common.HashLength-common.AddressLength:], caller[:]) + s.Require().Equal(adddressTopic, log.Topics[1]) + + s.Require().EqualValues(log.BlockNumber, s.network.GetContext().BlockHeight()) + + // Verify data + var depositEvent DepositEvent + err = cmn.UnpackLog(s.precompile.ABI, &depositEvent, werc20.EventTypeDeposit, *log) + s.Require().NoError(err, "unable to unpack log into deposit event") + + s.Require().Equal(caller, depositEvent.Dst, "expected different destination address") + s.Require().Equal(amount, depositEvent.Wad, "expected different amount") + }) + } +} + +//nolint:dupl +func (s *PrecompileUnitTestSuite) TestEmitWithdrawalEvent() { + testCases := []struct { + name string + chainID string + }{ + { + name: "mainnet", + chainID: testconstants.ExampleChainID, + }, { + name: "six decimals", + chainID: testconstants.SixDecimalsChainID, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + s.SetupTest(tc.chainID) + caller := s.keyring.GetAddr(0) + amount := new(big.Int).SetInt64(1_000) + + stateDB := s.network.GetStateDB() + + err := s.precompile.EmitWithdrawalEvent( + s.network.GetContext(), + stateDB, + caller, + amount, + ) + s.Require().NoError(err, "expected withdrawal event to be emitted successfully") + + log := stateDB.Logs()[0] + + // Check on the address + s.Require().Equal(log.Address, s.precompile.Address()) + + // Check on the topics + event := s.precompile.ABI.Events[werc20.EventTypeWithdrawal] + s.Require().Equal( + crypto.Keccak256Hash([]byte(event.Sig)), + common.HexToHash(log.Topics[0].Hex()), + ) + var adddressTopic common.Hash + copy(adddressTopic[common.HashLength-common.AddressLength:], caller[:]) + s.Require().Equal(adddressTopic, log.Topics[1]) + + s.Require().EqualValues(log.BlockNumber, s.network.GetContext().BlockHeight()) + + // Verify data + var withdrawalEvent WithdrawalEvent + err = cmn.UnpackLog(s.precompile.ABI, &withdrawalEvent, werc20.EventTypeWithdrawal, *log) + s.Require().NoError(err, "unable to unpack log into withdrawal event") + + s.Require().Equal(caller, withdrawalEvent.Src, "expected different source address") + s.Require().Equal(amount, withdrawalEvent.Wad, "expected different amount") + }) + } +} diff --git a/precompiles/werc20/integration_test.go b/precompiles/werc20/integration_test.go new file mode 100644 index 00000000..adb90023 --- /dev/null +++ b/precompiles/werc20/integration_test.go @@ -0,0 +1,607 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package werc20_test + +import ( + "fmt" + "math/big" + "testing" + + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" + + auth "github.com/evmos/os/precompiles/authorization" + "github.com/evmos/os/precompiles/erc20" + "github.com/evmos/os/precompiles/testutil" + "github.com/evmos/os/precompiles/werc20" + "github.com/evmos/os/precompiles/werc20/testdata" + testconstants "github.com/evmos/os/testutil/constants" + "github.com/evmos/os/testutil/integration/os/factory" + "github.com/evmos/os/testutil/integration/os/grpc" + "github.com/evmos/os/testutil/integration/os/keyring" + "github.com/evmos/os/testutil/integration/os/network" + utiltx "github.com/evmos/os/testutil/tx" + erc20types "github.com/evmos/os/x/erc20/types" + evmtypes "github.com/evmos/os/x/evm/types" + feemarkettypes "github.com/evmos/os/x/feemarket/types" + + "github.com/ethereum/go-ethereum/common" + + //nolint:revive // dot imports are fine for Ginkgo + . "github.com/onsi/ginkgo/v2" + //nolint:revive // dot imports are fine for Ginkgo + . "github.com/onsi/gomega" +) + +// ------------------------------------------------------------------------------------------------- +// Integration test suite +// ------------------------------------------------------------------------------------------------- + +type PrecompileIntegrationTestSuite struct { + network *network.UnitTestNetwork + factory factory.TxFactory + grpcHandler grpc.Handler + keyring keyring.Keyring + + wrappedCoinDenom string + + // WEVMOS related fields + precompile *werc20.Precompile + precompileAddrHex string +} + +func TestPrecompileIntegrationTestSuite(t *testing.T) { + // Run Ginkgo integration tests + RegisterFailHandler(Fail) + RunSpecs(t, "WEVMOS precompile test suite") +} + +// checkAndReturnBalance check that the balance of the address is the same in +// the smart contract and in the balance and returns the amount. +func (is *PrecompileIntegrationTestSuite) checkAndReturnBalance( + balanceCheck testutil.LogCheckArgs, + callsData CallsData, + address common.Address, +) *big.Int { + txArgs, balancesArgs := callsData.getTxAndCallArgs(directCall, erc20.BalanceOfMethod, address) + txArgs.GasLimit = 1_000_000_000_000 + + _, ethRes, err := is.factory.CallContractAndCheckLogs(callsData.sender.Priv, txArgs, balancesArgs, balanceCheck) + Expect(err).ToNot(HaveOccurred(), "failed to execute balanceOf") + var erc20Balance *big.Int + err = is.precompile.UnpackIntoInterface(&erc20Balance, erc20.BalanceOfMethod, ethRes.Ret) + Expect(err).ToNot(HaveOccurred(), "failed to unpack result") + + addressAcc := sdk.AccAddress(address.Bytes()) + balanceAfter, err := is.grpcHandler.GetBalanceFromBank(addressAcc, is.wrappedCoinDenom) + Expect(err).ToNot(HaveOccurred(), "expected no error getting balance") + + Expect(erc20Balance.String()).To(Equal(balanceAfter.Balance.Amount.BigInt().String()), "expected return balance from contract equal to bank") + return erc20Balance +} + +// ------------------------------------------------------------------------------------------------- +// Integration tests +// ------------------------------------------------------------------------------------------------- + +var _ = When("a user interact with the WEVMOS precompiled contract", func() { + var ( + is *PrecompileIntegrationTestSuite + passCheck, failCheck testutil.LogCheckArgs + transferCheck, depositCheck, withdrawCheck testutil.LogCheckArgs + + callsData CallsData + + txSender, user keyring.Key + + revertContractAddr common.Address + ) + + depositAmount := big.NewInt(1e18) + withdrawAmount := depositAmount + transferAmount := depositAmount + + BeforeEach(func() { + is = new(PrecompileIntegrationTestSuite) + keyring := keyring.New(2) + + txSender = keyring.GetKey(0) + user = keyring.GetKey(1) + + // Set the base fee to zero to allow for zero cost tx. The final gas cost is + // not part of the logic tested here so this makes testing more easy. + customGenesis := network.CustomGenesisState{} + feemarketGenesis := feemarkettypes.DefaultGenesisState() + feemarketGenesis.Params.NoBaseFee = true + customGenesis[feemarkettypes.ModuleName] = feemarketGenesis + + // Reset evm config here for the standard case + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + Expect(configurator. + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(evmtypes.EighteenDecimals)). + Configure()).To(BeNil(), "expected no error setting the evm configurator") + + integrationNetwork := network.NewUnitTestNetwork( + network.WithPreFundedAccounts(keyring.GetAllAccAddrs()...), + network.WithCustomGenesis(customGenesis), + ) + grpcHandler := grpc.NewIntegrationHandler(integrationNetwork) + txFactory := factory.New(integrationNetwork, grpcHandler) + + is.network = integrationNetwork + is.factory = txFactory + is.grpcHandler = grpcHandler + is.keyring = keyring + + is.wrappedCoinDenom = evmtypes.GetEVMCoinDenom() + is.precompileAddrHex = network.GetWEVMOSContractHex(is.network.GetChainID()) + + fmt.Println("evm coin denom", evmtypes.GetEVMCoinDenom()) + fmt.Println("chain id", is.network.GetChainID()) + + ctx := integrationNetwork.GetContext() + + // Perform some check before adding the precompile to the suite. + + // Check that WEVMOS is part of the native precompiles. + erc20Params := is.network.App.Erc20Keeper.GetParams(ctx) + Expect(erc20Params.NativePrecompiles).To( + ContainElement(is.precompileAddrHex), + "expected wevmos to be in the native precompiles", + ) + _, found := is.network.App.BankKeeper.GetDenomMetaData(ctx, evmtypes.GetEVMCoinDenom()) + Expect(found).To(BeTrue(), "expected native token metadata to be registered") + + // Check that WEVMOS is registered in the token pairs map. + tokenPairID := is.network.App.Erc20Keeper.GetTokenPairID(ctx, is.wrappedCoinDenom) + tokenPair, found := is.network.App.Erc20Keeper.GetTokenPair(ctx, tokenPairID) + Expect(found).To(BeTrue(), "expected wevmos precompile to be registered in the tokens map") + Expect(tokenPair.Erc20Address).To(Equal(is.precompileAddrHex)) + + precompileAddr := common.HexToAddress(is.precompileAddrHex) + tokenPair = erc20types.NewTokenPair( + precompileAddr, + evmtypes.GetEVMCoinDenom(), + erc20types.OWNER_MODULE, + ) + precompile, err := werc20.NewPrecompile( + tokenPair, + is.network.App.BankKeeper, + is.network.App.AuthzKeeper, + is.network.App.TransferKeeper, + ) + Expect(err).ToNot(HaveOccurred(), "failed to instantiate the werc20 precompile") + is.precompile = precompile + + // Setup of the contract calling into the precompile to tests revert + // edge cases and proper handling of snapshots. + revertCallerContract, err := testdata.LoadWEVMOS9TestCaller() + Expect(err).ToNot(HaveOccurred(), "failed to load werc20 reverter caller contract") + + txArgs := evmtypes.EvmTxArgs{} + txArgs.GasTipCap = new(big.Int).SetInt64(0) + txArgs.GasLimit = 1_000_000_000_000 + revertContractAddr, err = is.factory.DeployContract( + txSender.Priv, + txArgs, + factory.ContractDeploymentData{ + Contract: revertCallerContract, + ConstructorArgs: []interface{}{ + common.HexToAddress(is.precompileAddrHex), + }, + }, + ) + Expect(err).ToNot(HaveOccurred(), "failed to deploy werc20 reverter contract") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + // Support struct used to simplify transactions creation. + callsData = CallsData{ + sender: txSender, + + precompileAddr: precompileAddr, + precompileABI: precompile.ABI, + + precompileReverterAddr: revertContractAddr, + precompileReverterABI: revertCallerContract.ABI, + } + + // Utility types used to check the different events emitted. + failCheck = testutil.LogCheckArgs{ABIEvents: is.precompile.Events} + passCheck = failCheck.WithExpPass(true) + withdrawCheck = passCheck.WithExpEvents(werc20.EventTypeWithdrawal) + depositCheck = passCheck.WithExpEvents(werc20.EventTypeDeposit) + transferCheck = passCheck.WithExpEvents(erc20.EventTypeTransfer) + }) + Context("calling a specific wrapped coin method", func() { + Context("and funds are part of the transaction", func() { + When("the method is deposit", func() { + It("it should return funds to sender and emit the event", func() { + // Store initial balance to verify that sender + // balance remains the same after the contract call. + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, werc20.DepositMethod) + txArgs.Amount = depositAmount + + _, _, err := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance.String()).To(Equal(initBalance.String())) + }) + It("it should consume at least the deposit requested gas", func() { + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, werc20.DepositMethod) + txArgs.Amount = depositAmount + + _, ethRes, _ := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + Expect(ethRes.GasUsed).To(BeNumerically(">=", werc20.DepositRequiredGas), "expected different gas used for deposit") + }) + }) + //nolint:dupl + When("no calldata is provided", func() { + It("it should call the receive which behave like deposit", func() { + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + + _, _, err := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance).To(Equal(initBalance)) + }) + It("it should consume at least the deposit requested gas", func() { + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, werc20.DepositMethod) + txArgs.Amount = depositAmount + + _, ethRes, _ := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + Expect(ethRes.GasUsed).To(BeNumerically(">=", werc20.DepositRequiredGas), "expected different gas used for receive") + }) + }) + When("the specified method is too short", func() { + It("it should call the fallback which behave like deposit", func() { + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + // Short method is directly set in the input to skip ABI validation + txArgs.Input = []byte{1, 2, 3} + + _, _, err := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance).To(Equal(initBalance)) + }) + It("it should consume at least the deposit requested gas", func() { + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + // Short method is directly set in the input to skip ABI validation + txArgs.Input = []byte{1, 2, 3} + + _, ethRes, _ := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + Expect(ethRes.GasUsed).To(BeNumerically(">=", werc20.DepositRequiredGas), "expected different gas used for fallback") + }) + }) + When("the specified method does not exist", func() { + It("it should call the fallback which behave like deposit", func() { + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + // Wrong method is directly set in the input to skip ABI validation + txArgs.Input = []byte("nonExistingMethod") + + _, _, err := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance).To(Equal(initBalance)) + }) + It("it should consume at least the deposit requested gas", func() { + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + // Wrong method is directly set in the input to skip ABI validation + txArgs.Input = []byte("nonExistingMethod") + + _, ethRes, _ := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + Expect(ethRes.GasUsed).To(BeNumerically(">=", werc20.DepositRequiredGas), "expected different gas used for fallback") + }) + }) + }) + Context("and funds are NOT part of the transaction", func() { + When("the method is withdraw", func() { + It("it should fail if user doesn't have enough funds", func() { + // Store initial balance to verify withdraw is a no-op and sender + // balance remains the same after the contract call. + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + newUserAcc, newUserPriv := utiltx.NewAccAddressAndKey() + newUserBalance := sdk.Coins{sdk.Coin{ + Denom: evmtypes.GetEVMCoinDenom(), + Amount: math.NewIntFromBigInt(withdrawAmount).SubRaw(1), + }} + err := is.network.App.BankKeeper.SendCoins(is.network.GetContext(), user.AccAddr, newUserAcc, newUserBalance) + Expect(err).ToNot(HaveOccurred(), "expected no error sending tokens") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, werc20.WithdrawMethod, withdrawAmount) + + _, _, err = is.factory.CallContractAndCheckLogs(newUserPriv, txArgs, callArgs, withdrawCheck) + Expect(err).To(HaveOccurred(), "expected an error because not enough funds") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance).To(Equal(initBalance)) + }) + It("it should be a no-op and emit the event", func() { + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, werc20.WithdrawMethod, withdrawAmount) + + _, _, err := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, withdrawCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance).To(Equal(initBalance)) + }) + It("it should consume at least the withdraw requested gas", func() { + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, werc20.WithdrawMethod, withdrawAmount) + + _, ethRes, _ := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, withdrawCheck) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + Expect(ethRes.GasUsed).To(BeNumerically(">=", werc20.WithdrawRequiredGas), "expected different gas used for withdraw") + }) + }) + //nolint:dupl + When("no calldata is provided", func() { + It("it should call the fallback which behave like deposit", func() { + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + + _, _, err := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance).To(Equal(initBalance)) + }) + It("it should consume at least the deposit requested gas", func() { + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, werc20.DepositMethod) + txArgs.Amount = depositAmount + + _, ethRes, _ := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + Expect(ethRes.GasUsed).To(BeNumerically(">=", werc20.DepositRequiredGas), "expected different gas used for receive") + }) + }) + When("the specified method is too short", func() { + It("it should call the fallback which behave like deposit", func() { + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + // Short method is directly set in the input to skip ABI validation + txArgs.Input = []byte{1, 2, 3} + + _, _, err := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance).To(Equal(initBalance)) + }) + It("it should consume at least the deposit requested gas", func() { + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + // Short method is directly set in the input to skip ABI validation + txArgs.Input = []byte{1, 2, 3} + + _, ethRes, _ := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + Expect(ethRes.GasUsed).To(BeNumerically(">=", werc20.DepositRequiredGas), "expected different gas used for fallback") + }) + }) + When("the specified method does not exist", func() { + It("it should call the fallback which behave like deposit", func() { + initBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + // Wrong method is directly set in the input to skip ABI validation + txArgs.Input = []byte("nonExistingMethod") + + _, _, err := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.checkAndReturnBalance(passCheck, callsData, user.Addr) + Expect(finalBalance).To(Equal(initBalance)) + }) + It("it should consume at least the deposit requested gas", func() { + txArgs, callArgs := callsData.getTxAndCallArgs(directCall, "") + txArgs.Amount = depositAmount + // Wrong method is directly set in the input to skip ABI validation + txArgs.Input = []byte("nonExistingMethod") + + _, ethRes, _ := is.factory.CallContractAndCheckLogs(user.Priv, txArgs, callArgs, depositCheck) + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + Expect(ethRes.GasUsed).To(BeNumerically(">=", werc20.DepositRequiredGas), "expected different gas used for fallback") + }) + }) + }) + }) + Context("calling a reverter contract", func() { + When("to call the deposit", func() { + It("it should return funds to the last sender and emit the event", func() { + ctx := is.network.GetContext() + + txArgs, callArgs := callsData.getTxAndCallArgs(contractCall, "depositWithRevert", false, false) + txArgs.Amount = depositAmount + + _, _, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, callArgs, depositCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected error calling the precompile") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.network.App.BankKeeper.GetAllBalances(ctx, revertContractAddr.Bytes()) + Expect(finalBalance.AmountOf(evmtypes.GetEVMCoinDenom()).String()).To(Equal(depositAmount.String()), "expected final balance equal to deposit") + }) + }) + DescribeTable("to call the deposit", func(before, after bool) { + ctx := is.network.GetContext() + + initBalance := is.network.App.BankKeeper.GetAllBalances(ctx, txSender.AccAddr) + + txArgs, callArgs := callsData.getTxAndCallArgs(contractCall, "depositWithRevert", before, after) + txArgs.Amount = depositAmount + + _, _, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, callArgs, depositCheck) + Expect(err).To(HaveOccurred(), "execution should have reverted") + Expect(is.network.NextBlock()).ToNot(HaveOccurred(), "error on NextBlock") + + finalBalance := is.network.App.BankKeeper.GetAllBalances(ctx, txSender.AccAddr) + Expect(finalBalance.String()).To(Equal(initBalance.String()), "expected final balance equal to initial") + }, + Entry("it should not move funds and dont emit the event reverting before changing state", true, false), + Entry("it should not move funds and dont emit the event reverting after changing state", false, true), + ) + }) + Context("calling an erc20 method", func() { + When("transferring tokens", func() { + It("it should transfer tokens to a receiver using `transfer`", func() { + ctx := is.network.GetContext() + + senderBalance := is.network.App.BankKeeper.GetAllBalances(ctx, txSender.AccAddr) + receiverBalance := is.network.App.BankKeeper.GetAllBalances(ctx, user.AccAddr) + + txArgs, transferArgs := callsData.getTxAndCallArgs(directCall, erc20.TransferMethod, user.Addr, transferAmount) + transferCoins := sdk.Coins{sdk.NewInt64Coin(is.wrappedCoinDenom, transferAmount.Int64())} + + _, _, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, transferArgs, transferCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected result calling contract") + + senderBalanceAfter := is.network.App.BankKeeper.GetAllBalances(ctx, txSender.AccAddr) + receiverBalanceAfter := is.network.App.BankKeeper.GetAllBalances(ctx, user.AccAddr) + Expect(senderBalanceAfter).To(Equal(senderBalance.Sub(transferCoins...))) + Expect(receiverBalanceAfter).To(Equal(receiverBalance.Add(transferCoins...))) + }) + It("it should transfer tokens to a receiver using `transferFrom`", func() { + ctx := is.network.GetContext() + + senderBalance := is.network.App.BankKeeper.GetAllBalances(ctx, txSender.AccAddr) + receiverBalance := is.network.App.BankKeeper.GetAllBalances(ctx, user.AccAddr) + + txArgs, transferArgs := callsData.getTxAndCallArgs(directCall, erc20.TransferFromMethod, txSender.Addr, user.Addr, transferAmount) + transferCoins := sdk.Coins{sdk.NewInt64Coin(is.wrappedCoinDenom, transferAmount.Int64())} + + transferCheck := passCheck.WithExpEvents(erc20.EventTypeTransfer, auth.EventTypeApproval) + _, _, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, transferArgs, transferCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected result calling contract") + + senderBalanceAfter := is.network.App.BankKeeper.GetAllBalances(ctx, txSender.AccAddr) + receiverBalanceAfter := is.network.App.BankKeeper.GetAllBalances(ctx, user.AccAddr) + Expect(senderBalanceAfter).To(Equal(senderBalance.Sub(transferCoins...))) + Expect(receiverBalanceAfter).To(Equal(receiverBalance.Add(transferCoins...))) + }) + }) + When("querying information", func() { + Context("to retrieve a balance", func() { + It("should return the correct balance for an existing account", func() { + // Query the balance + txArgs, balancesArgs := callsData.getTxAndCallArgs(directCall, erc20.BalanceOfMethod, txSender.Addr) + + _, ethRes, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, balancesArgs, passCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected result calling contract") + + expBalance := is.network.App.BankKeeper.GetBalance(is.network.GetContext(), txSender.AccAddr, is.wrappedCoinDenom) + + var balance *big.Int + err = is.precompile.UnpackIntoInterface(&balance, erc20.BalanceOfMethod, ethRes.Ret) + Expect(err).ToNot(HaveOccurred(), "failed to unpack result") + Expect(balance).To(Equal(expBalance.Amount.BigInt()), "expected different balance") + }) + It("should return 0 for a new account", func() { + // Query the balance + txArgs, balancesArgs := callsData.getTxAndCallArgs(directCall, erc20.BalanceOfMethod, utiltx.GenerateAddress()) + + _, ethRes, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, balancesArgs, passCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected result calling contract") + + var balance *big.Int + err = is.precompile.UnpackIntoInterface(&balance, erc20.BalanceOfMethod, ethRes.Ret) + Expect(err).ToNot(HaveOccurred(), "failed to unpack result") + Expect(balance.Int64()).To(Equal(int64(0)), "expected different balance") + }) + }) + It("should return the correct name", func() { + txArgs, nameArgs := callsData.getTxAndCallArgs(directCall, erc20.NameMethod) + + _, ethRes, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, nameArgs, passCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected result calling contract") + + var name string + err = is.precompile.UnpackIntoInterface(&name, erc20.NameMethod, ethRes.Ret) + Expect(err).ToNot(HaveOccurred(), "failed to unpack result") + Expect(name).To(ContainSubstring("evmOS"), "expected different name") + }) + + It("should return the correct symbol", func() { + txArgs, symbolArgs := callsData.getTxAndCallArgs(directCall, erc20.SymbolMethod) + + _, ethRes, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, symbolArgs, passCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected result calling contract") + + var symbol string + err = is.precompile.UnpackIntoInterface(&symbol, erc20.SymbolMethod, ethRes.Ret) + Expect(err).ToNot(HaveOccurred(), "failed to unpack result") + Expect(symbol).To(ContainSubstring("EVMOS"), "expected different symbol") + }) + + It("should return the decimals", func() { + txArgs, decimalsArgs := callsData.getTxAndCallArgs(directCall, erc20.DecimalsMethod) + + _, ethRes, err := is.factory.CallContractAndCheckLogs(txSender.Priv, txArgs, decimalsArgs, passCheck) + Expect(err).ToNot(HaveOccurred(), "unexpected result calling contract") + + var decimals uint8 + err = is.precompile.UnpackIntoInterface(&decimals, erc20.DecimalsMethod, ethRes.Ret) + Expect(err).ToNot(HaveOccurred(), "failed to unpack result") + + coinInfo := testconstants.ExampleChainCoinInfo[is.network.GetChainID()] + Expect(decimals).To(Equal(uint8(coinInfo.Decimals)), "expected different decimals") + }, + ) + }) + }) +}) diff --git a/precompiles/werc20/testdata/WEVMOS9.json b/precompiles/werc20/testdata/WEVMOS9.json new file mode 100644 index 00000000..484cf6b5 --- /dev/null +++ b/precompiles/werc20/testdata/WEVMOS9.json @@ -0,0 +1,288 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "WEVMOS9", + "sourceName": "solidity/precompiles/werc20/testdata/WEVMOS9.sol", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "guy", + "type": "address" + }, + { + "name": "wad", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "src", + "type": "address" + }, + { + "name": "dst", + "type": "address" + }, + { + "name": "wad", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "wad", + "type": "uint256" + } + ], + "name": "withdraw", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "dst", + "type": "address" + }, + { + "name": "wad", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "deposit", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "", + "type": "address" + }, + { + "name": "", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "src", + "type": "address" + }, + { + "indexed": true, + "name": "guy", + "type": "address" + }, + { + "indexed": false, + "name": "wad", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "src", + "type": "address" + }, + { + "indexed": true, + "name": "dst", + "type": "address" + }, + { + "indexed": false, + "name": "wad", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "dst", + "type": "address" + }, + { + "indexed": false, + "name": "wad", + "type": "uint256" + } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "src", + "type": "address" + }, + { + "indexed": false, + "name": "wad", + "type": "uint256" + } + ], + "name": "Withdrawal", + "type": "event" + } + ], + "bytecode": "0x60806040526040805190810160405280600d81526020017f577261707065642045766d6f73000000000000000000000000000000000000008152506000908051906020019061004f9291906100ca565b506040805190810160405280600681526020017f5745564d4f5300000000000000000000000000000000000000000000000000008152506001908051906020019061009b9291906100ca565b506012600260006101000a81548160ff021916908360ff1602179055503480156100c457600080fd5b5061016f565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061010b57805160ff1916838001178555610139565b82800160010185558215610139579182015b8281111561013857825182559160200191906001019061011d565b5b509050610146919061014a565b5090565b61016c91905b80821115610168576000816000905550600101610150565b5090565b90565b610c848061017e6000396000f3006080604052600436106100af576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806306fdde03146100b9578063095ea7b31461014957806318160ddd146101ae57806323b872dd146101d95780632e1a7d4d1461025e578063313ce5671461028b57806370a08231146102bc57806395d89b4114610313578063a9059cbb146103a3578063d0e30db014610408578063dd62ed3e14610412575b6100b7610489565b005b3480156100c557600080fd5b506100ce610526565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561010e5780820151818401526020810190506100f3565b50505050905090810190601f16801561013b5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561015557600080fd5b50610194600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105c4565b604051808215151515815260200191505060405180910390f35b3480156101ba57600080fd5b506101c36106b6565b6040518082815260200191505060405180910390f35b3480156101e557600080fd5b50610244600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d5565b604051808215151515815260200191505060405180910390f35b34801561026a57600080fd5b5061028960048036038101908080359060200190929190505050610a22565b005b34801561029757600080fd5b506102a0610b55565b604051808260ff1660ff16815260200191505060405180910390f35b3480156102c857600080fd5b506102fd600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b68565b6040518082815260200191505060405180910390f35b34801561031f57600080fd5b50610328610b80565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036857808201518184015260208101905061034d565b50505050905090810190601f1680156103955780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156103af57600080fd5b506103ee600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610c1e565b604051808215151515815260200191505060405180910390f35b610410610489565b005b34801561041e57600080fd5b50610473600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610c33565b6040518082815260200191505060405180910390f35b34600360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055503373ffffffffffffffffffffffffffffffffffffffff167fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c346040518082815260200191505060405180910390a2565b60008054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105bc5780601f10610591576101008083540402835291602001916105bc565b820191906000526020600020905b81548152906001019060200180831161059f57829003601f168201915b505050505081565b600081600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040518082815260200191505060405180910390a36001905092915050565b60003073ffffffffffffffffffffffffffffffffffffffff1631905090565b600081600360008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541015151561072557600080fd5b3373ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16141580156107fd57507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205414155b156109185781600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541015151561088d57600080fd5b81600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825403925050819055505b81600360008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254039250508190555081600360008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a3600190509392505050565b80600360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205410151515610a7057600080fd5b80600360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825403925050819055503373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015610b03573d6000803e3d6000fd5b503373ffffffffffffffffffffffffffffffffffffffff167f7fcf532c15f0a6db0bd6d0e038bea71d30d808c7d98cb3bf7268a95bf5081b65826040518082815260200191505060405180910390a250565b600260009054906101000a900460ff1681565b60036020528060005260406000206000915090505481565b60018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610c165780601f10610beb57610100808354040283529160200191610c16565b820191906000526020600020905b815481529060010190602001808311610bf957829003601f168201915b505050505081565b6000610c2b3384846106d5565b905092915050565b60046020528160005260406000206020528060005260406000206000915091505054815600a165627a7a72305820db857be5acdb9fff88465fff82532b1f9016393994729caa282163d5e3bd9da10029", + "deployedBytecode": "0x6080604052600436106100af576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806306fdde03146100b9578063095ea7b31461014957806318160ddd146101ae57806323b872dd146101d95780632e1a7d4d1461025e578063313ce5671461028b57806370a08231146102bc57806395d89b4114610313578063a9059cbb146103a3578063d0e30db014610408578063dd62ed3e14610412575b6100b7610489565b005b3480156100c557600080fd5b506100ce610526565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561010e5780820151818401526020810190506100f3565b50505050905090810190601f16801561013b5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561015557600080fd5b50610194600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105c4565b604051808215151515815260200191505060405180910390f35b3480156101ba57600080fd5b506101c36106b6565b6040518082815260200191505060405180910390f35b3480156101e557600080fd5b50610244600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d5565b604051808215151515815260200191505060405180910390f35b34801561026a57600080fd5b5061028960048036038101908080359060200190929190505050610a22565b005b34801561029757600080fd5b506102a0610b55565b604051808260ff1660ff16815260200191505060405180910390f35b3480156102c857600080fd5b506102fd600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b68565b6040518082815260200191505060405180910390f35b34801561031f57600080fd5b50610328610b80565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036857808201518184015260208101905061034d565b50505050905090810190601f1680156103955780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156103af57600080fd5b506103ee600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610c1e565b604051808215151515815260200191505060405180910390f35b610410610489565b005b34801561041e57600080fd5b50610473600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610c33565b6040518082815260200191505060405180910390f35b34600360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055503373ffffffffffffffffffffffffffffffffffffffff167fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c346040518082815260200191505060405180910390a2565b60008054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105bc5780601f10610591576101008083540402835291602001916105bc565b820191906000526020600020905b81548152906001019060200180831161059f57829003601f168201915b505050505081565b600081600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040518082815260200191505060405180910390a36001905092915050565b60003073ffffffffffffffffffffffffffffffffffffffff1631905090565b600081600360008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541015151561072557600080fd5b3373ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16141580156107fd57507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205414155b156109185781600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541015151561088d57600080fd5b81600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825403925050819055505b81600360008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254039250508190555081600360008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a3600190509392505050565b80600360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205410151515610a7057600080fd5b80600360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825403925050819055503373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015610b03573d6000803e3d6000fd5b503373ffffffffffffffffffffffffffffffffffffffff167f7fcf532c15f0a6db0bd6d0e038bea71d30d808c7d98cb3bf7268a95bf5081b65826040518082815260200191505060405180910390a250565b600260009054906101000a900460ff1681565b60036020528060005260406000206000915090505481565b60018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610c165780601f10610beb57610100808354040283529160200191610c16565b820191906000526020600020905b815481529060010190602001808311610bf957829003601f168201915b505050505081565b6000610c2b3384846106d5565b905092915050565b60046020528160005260406000206020528060005260406000206000915091505054815600a165627a7a72305820db857be5acdb9fff88465fff82532b1f9016393994729caa282163d5e3bd9da10029", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/precompiles/werc20/testdata/WEVMOS9TestCaller.json b/precompiles/werc20/testdata/WEVMOS9TestCaller.json new file mode 100644 index 00000000..874d620d --- /dev/null +++ b/precompiles/werc20/testdata/WEVMOS9TestCaller.json @@ -0,0 +1,79 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "WEVMOS9TestCaller", + "sourceName": "solidity/precompiles/werc20/testdata/WEVMOS9TestCaller.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "address payable", + "name": "_wrappedTokenAddress", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "message", + "type": "string" + } + ], + "name": "Log", + "type": "event" + }, + { + "inputs": [], + "name": "WEVMOS", + "outputs": [ + { + "internalType": "address payable", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "counter", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bool", + "name": "before", + "type": "bool" + }, + { + "internalType": "bool", + "name": "aft", + "type": "bool" + } + ], + "name": "depositWithRevert", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } + ], + "bytecode": "0x60a060405234801561001057600080fd5b506040516105a23803806105a2833981810160405281019061003291906100d6565b8073ffffffffffffffffffffffffffffffffffffffff1660808173ffffffffffffffffffffffffffffffffffffffff16815250506000808190555050610103565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006100a382610078565b9050919050565b6100b381610098565b81146100be57600080fd5b50565b6000815190506100d0816100aa565b92915050565b6000602082840312156100ec576100eb610073565b5b60006100fa848285016100c1565b91505092915050565b60805161047e6101246000396000818160c901526101fc015261047e6000f3fe6080604052600436106100345760003560e01c80635dab6f8c1461003957806361bc221a146100555780637cf5b4fc14610080575b600080fd5b610053600480360381019061004e919061025b565b6100ab565b005b34801561006157600080fd5b5061006a6101f4565b60405161007791906102b4565b60405180910390f35b34801561008c57600080fd5b506100956101fa565b6040516100a29190610310565b60405180910390f35b6000808154809291906100bd9061035a565b919050555060003490507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d0e30db0826040518263ffffffff1660e01b81526004016000604051808303818588803b15801561012f57600080fd5b505af1158015610143573d6000803e3d6000fd5b5050505050821561019057600061018f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610186906103ff565b60405180910390fd5b5b6000808154809291906101a29061041f565b919050555081156101ef5760006101ee576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101e5906103ff565b60405180910390fd5b5b505050565b60005481565b7f000000000000000000000000000000000000000000000000000000000000000081565b600080fd5b60008115159050919050565b61023881610223565b811461024357600080fd5b50565b6000813590506102558161022f565b92915050565b600080604083850312156102725761027161021e565b5b600061028085828601610246565b925050602061029185828601610246565b9150509250929050565b6000819050919050565b6102ae8161029b565b82525050565b60006020820190506102c960008301846102a5565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006102fa826102cf565b9050919050565b61030a816102ef565b82525050565b60006020820190506103256000830184610301565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006103658261029b565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036103975761039661032b565b5b600182019050919050565b600082825260208201905092915050565b7f7265766572742068657265000000000000000000000000000000000000000000600082015250565b60006103e9600b836103a2565b91506103f4826103b3565b602082019050919050565b60006020820190508181036000830152610418816103dc565b9050919050565b600061042a8261029b565b91506000820361043d5761043c61032b565b5b60018203905091905056fea26469706673582212203d3e97b0a77f9600830da2e2cbaeb60b338f3a8a14102bdb21638d4010f269fd64736f6c63430008140033", + "deployedBytecode": "0x6080604052600436106100345760003560e01c80635dab6f8c1461003957806361bc221a146100555780637cf5b4fc14610080575b600080fd5b610053600480360381019061004e919061025b565b6100ab565b005b34801561006157600080fd5b5061006a6101f4565b60405161007791906102b4565b60405180910390f35b34801561008c57600080fd5b506100956101fa565b6040516100a29190610310565b60405180910390f35b6000808154809291906100bd9061035a565b919050555060003490507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d0e30db0826040518263ffffffff1660e01b81526004016000604051808303818588803b15801561012f57600080fd5b505af1158015610143573d6000803e3d6000fd5b5050505050821561019057600061018f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610186906103ff565b60405180910390fd5b5b6000808154809291906101a29061041f565b919050555081156101ef5760006101ee576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101e5906103ff565b60405180910390fd5b5b505050565b60005481565b7f000000000000000000000000000000000000000000000000000000000000000081565b600080fd5b60008115159050919050565b61023881610223565b811461024357600080fd5b50565b6000813590506102558161022f565b92915050565b600080604083850312156102725761027161021e565b5b600061028085828601610246565b925050602061029185828601610246565b9150509250929050565b6000819050919050565b6102ae8161029b565b82525050565b60006020820190506102c960008301846102a5565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006102fa826102cf565b9050919050565b61030a816102ef565b82525050565b60006020820190506103256000830184610301565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006103658261029b565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036103975761039661032b565b5b600182019050919050565b600082825260208201905092915050565b7f7265766572742068657265000000000000000000000000000000000000000000600082015250565b60006103e9600b836103a2565b91506103f4826103b3565b602082019050919050565b60006020820190508181036000830152610418816103dc565b9050919050565b600061042a8261029b565b91506000820361043d5761043c61032b565b5b60018203905091905056fea26469706673582212203d3e97b0a77f9600830da2e2cbaeb60b338f3a8a14102bdb21638d4010f269fd64736f6c63430008140033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/precompiles/werc20/testdata/WEVMOS9TestCaller.sol b/precompiles/werc20/testdata/WEVMOS9TestCaller.sol new file mode 100644 index 00000000..327297c2 --- /dev/null +++ b/precompiles/werc20/testdata/WEVMOS9TestCaller.sol @@ -0,0 +1,34 @@ +// SPDX-License-Identifier: LGPL-3.0-only +pragma solidity >=0.8.17; + +import "../IWERC20.sol"; + +contract WEVMOS9TestCaller { + address payable public immutable WEVMOS; + uint256 public counter; + + constructor(address payable _wrappedTokenAddress) { + WEVMOS = _wrappedTokenAddress; + counter = 0; + } + + event Log(string message); + + function depositWithRevert(bool before, bool aft) public payable { + counter++; + + uint amountIn = msg.value; + IWERC20(WEVMOS).deposit{value: amountIn}(); + + if (before) { + require(false, "revert here"); + } + + counter--; + + if (aft) { + require(false, "revert here"); + } + return; + } +} diff --git a/precompiles/werc20/testdata/wevmos9.go b/precompiles/werc20/testdata/wevmos9.go new file mode 100644 index 00000000..885d1dc3 --- /dev/null +++ b/precompiles/werc20/testdata/wevmos9.go @@ -0,0 +1,15 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package testdata + +import ( + contractutils "github.com/evmos/os/contracts/utils" + evmtypes "github.com/evmos/os/x/evm/types" +) + +// LoadWEVMOS9Contract load the WEVMOS9 contract from the json representation of +// the Solidity contract. +func LoadWEVMOS9Contract() (evmtypes.CompiledContract, error) { + return contractutils.LoadContractFromJSONFile("WEVMOS9.json") +} diff --git a/precompiles/werc20/testdata/wevmos9_test_caller.go b/precompiles/werc20/testdata/wevmos9_test_caller.go new file mode 100644 index 00000000..a989b69c --- /dev/null +++ b/precompiles/werc20/testdata/wevmos9_test_caller.go @@ -0,0 +1,13 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package testdata + +import ( + contractutils "github.com/evmos/os/contracts/utils" + evmtypes "github.com/evmos/os/x/evm/types" +) + +func LoadWEVMOS9TestCaller() (evmtypes.CompiledContract, error) { + return contractutils.LoadContractFromJSONFile("WEVMOS9TestCaller.json") +} diff --git a/precompiles/werc20/tx.go b/precompiles/werc20/tx.go new file mode 100644 index 00000000..5cbeca66 --- /dev/null +++ b/precompiles/werc20/tx.go @@ -0,0 +1,88 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package werc20 + +import ( + "fmt" + "math/big" + + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" + + cmn "github.com/evmos/os/precompiles/common" + "github.com/evmos/os/x/evm/core/vm" + evmtypes "github.com/evmos/os/x/evm/types" +) + +const ( + // DepositMethod defines the ABI method name for the IWERC20 deposit + // transaction. + DepositMethod = "deposit" + // WithdrawMethod defines the ABI method name for the IWERC20 withdraw + // transaction. + WithdrawMethod = "withdraw" +) + +// Deposit handles the payable deposit function. It retrieves the deposited amount +// and sends it back to the sender using the bank keeper. +func (p Precompile) Deposit( + ctx sdk.Context, + contract *vm.Contract, + stateDB vm.StateDB, +) ([]byte, error) { + caller := contract.Caller() + depositedAmount := contract.Value() + + callerAccAddress := sdk.AccAddress(caller.Bytes()) + precompileAccAddr := sdk.AccAddress(p.Address().Bytes()) + + // Send the coins back to the sender + if err := p.BankKeeper.SendCoins( + ctx, + precompileAccAddr, + callerAccAddress, + sdk.NewCoins(sdk.Coin{ + Denom: evmtypes.GetEVMCoinDenom(), + Amount: math.NewIntFromBigInt(depositedAmount), + }), + ); err != nil { + return nil, err + } + + // Add the entries to the statedb journal since the function signature of + // the associated Solidity interface payable. + p.SetBalanceChangeEntries( + cmn.NewBalanceChangeEntry(caller, depositedAmount, cmn.Add), + cmn.NewBalanceChangeEntry(p.Address(), depositedAmount, cmn.Sub), + ) + + if err := p.EmitDepositEvent(ctx, stateDB, caller, depositedAmount); err != nil { + return nil, err + } + + return nil, nil +} + +// Withdraw is a no-op and mock function that provides the same interface as the +// WETH contract to support equality between the native coin and its wrapped +// ERC-20 (e.g. EVMOS and WEVMOS). +func (p Precompile) Withdraw(ctx sdk.Context, contract *vm.Contract, stateDB vm.StateDB, args []interface{}) ([]byte, error) { + amount, ok := args[0].(*big.Int) + if !ok { + return nil, fmt.Errorf("invalid argument type: %T", args[0]) + } + amountInt := math.NewIntFromBigInt(amount) + + caller := contract.Caller() + callerAccAddress := sdk.AccAddress(caller.Bytes()) + nativeBalance := p.BankKeeper.GetBalance(ctx, callerAccAddress, evmtypes.GetEVMCoinDenom()) + if nativeBalance.Amount.LT(amountInt) { + return nil, fmt.Errorf("account balance %v is lower than withdraw balance %v", nativeBalance.Amount, amountInt) + } + + if err := p.EmitWithdrawalEvent(ctx, stateDB, caller, amount); err != nil { + return nil, err + } + return nil, nil +} diff --git a/precompiles/werc20/utils_test.go b/precompiles/werc20/utils_test.go new file mode 100644 index 00000000..0b60228f --- /dev/null +++ b/precompiles/werc20/utils_test.go @@ -0,0 +1,70 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package werc20_test + +import ( + "math/big" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + + "github.com/evmos/os/testutil/integration/os/factory" + "github.com/evmos/os/testutil/integration/os/keyring" + evmtypes "github.com/evmos/os/x/evm/types" +) + +// callType constants to differentiate between +// the different types of call to the precompile. +type callType int + +const ( + directCall callType = iota + contractCall +) + +// CallsData is a helper struct to hold the addresses and ABIs for the +// different contract instances that are subject to testing here. +type CallsData struct { + // This field is used to perform transactions that are not relevant for + // testing purposes like query to the contract. + sender keyring.Key + + // precompileReverter is used to call into the werc20 interface and + precompileReverterAddr common.Address + precompileReverterABI abi.ABI + + precompileAddr common.Address + precompileABI abi.ABI +} + +// getTxCallArgs is a helper function to return the correct call arguments and +// transaction data for a given call type. +func (cd CallsData) getTxAndCallArgs( + callType callType, + methodName string, + args ...interface{}, +) (evmtypes.EvmTxArgs, factory.CallArgs) { + txArgs := evmtypes.EvmTxArgs{} + callArgs := factory.CallArgs{} + + switch callType { + case directCall: + txArgs.To = &cd.precompileAddr + callArgs.ContractABI = cd.precompileABI + case contractCall: + txArgs.To = &cd.precompileReverterAddr + callArgs.ContractABI = cd.precompileReverterABI + } + + callArgs.MethodName = methodName + callArgs.Args = args + + // Setting gas tip cap to zero to have zero gas price. + txArgs.GasTipCap = new(big.Int).SetInt64(0) + // Gas limit is added only to skip the estimate gas call + // that makes debugging more complex. + txArgs.GasLimit = 1_000_000_000_000 + + return txArgs, callArgs +} diff --git a/precompiles/werc20/werc20.go b/precompiles/werc20/werc20.go new file mode 100644 index 00000000..c8d61bd6 --- /dev/null +++ b/precompiles/werc20/werc20.go @@ -0,0 +1,162 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package werc20 + +import ( + "embed" + "fmt" + "slices" + + "github.com/evmos/os/x/evm/core/vm" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + + authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" + bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" + cmn "github.com/evmos/os/precompiles/common" + erc20 "github.com/evmos/os/precompiles/erc20" + erc20types "github.com/evmos/os/x/erc20/types" + transferkeeper "github.com/evmos/os/x/ibc/transfer/keeper" +) + +// abiPath defines the path to the WERC-20 precompile ABI JSON file. +const abiPath = "abi.json" + +// Embed abi json file to the executable binary. Needed when importing as dependency. +// +//go:embed abi.json +var f embed.FS + +var _ vm.PrecompiledContract = &Precompile{} + +// Precompile defines the precompiled contract for WERC20. +type Precompile struct { + *erc20.Precompile +} + +const ( + // DepositRequiredGas defines the gas required for the Deposit transaction. + DepositRequiredGas uint64 = 23_878 + // WithdrawRequiredGas defines the gas required for the Withdraw transaction. + WithdrawRequiredGas uint64 = 9207 +) + +// LoadABI loads the IWERC20 ABI from the embedded abi.json file +// for the werc20 precompile. +func LoadABI() (abi.ABI, error) { + return cmn.LoadABI(f, abiPath) +} + +// NewPrecompile creates a new WERC20 Precompile instance implementing the +// PrecompiledContract interface. This type wraps around the ERC20 Precompile +// instance to provide additional methods. +func NewPrecompile( + tokenPair erc20types.TokenPair, + bankKeeper bankkeeper.Keeper, + authzKeeper authzkeeper.Keeper, + transferKeeper transferkeeper.Keeper, +) (*Precompile, error) { + newABI, err := LoadABI() + if err != nil { + return nil, fmt.Errorf("error loading the ABI: %w", err) + } + + erc20Precompile, err := erc20.NewPrecompile(tokenPair, bankKeeper, authzKeeper, transferKeeper) + if err != nil { + return nil, fmt.Errorf("error instantiating the ERC20 precompile: %w", err) + } + + // use the IWERC20 ABI + erc20Precompile.Precompile.ABI = newABI + + return &Precompile{ + Precompile: erc20Precompile, + }, nil +} + +// Address returns the address of the WERC20 precompiled contract. +func (p Precompile) Address() common.Address { + return p.Precompile.Address() +} + +// RequiredGas calculates the contract gas use. +func (p Precompile) RequiredGas(input []byte) uint64 { + // TODO: these values were obtained from Remix using the WEVMOS9.sol. + // We should execute the transactions from Evmos testnet + // to ensure parity in the values. + + // If there is no method ID, then it's the fallback or receive case + if len(input) < 4 { + return DepositRequiredGas + } + + methodID := input[:4] + method, err := p.MethodById(methodID) + if err != nil { + return 0 + } + + switch method.Name { + case DepositMethod: + return DepositRequiredGas + case WithdrawMethod: + return WithdrawRequiredGas + default: + return p.Precompile.RequiredGas(input) + } +} + +// Run executes the precompiled contract WERC20 methods defined in the ABI. +func (p Precompile) Run(evm *vm.EVM, contract *vm.Contract, readOnly bool) (bz []byte, err error) { + ctx, stateDB, snapshot, method, initialGas, args, err := p.RunSetup(evm, contract, readOnly, p.IsTransaction) + if err != nil { + return nil, err + } + + // This handles any out of gas errors that may occur during the execution of + // a precompile tx or query. It avoids panics and returns the out of gas error so + // the EVM can continue gracefully. + defer cmn.HandleGasError(ctx, contract, initialGas, &err)() + + switch { + case method.Type == abi.Fallback, + method.Type == abi.Receive, + method.Name == DepositMethod: + bz, err = p.Deposit(ctx, contract, stateDB) + case method.Name == WithdrawMethod: + bz, err = p.Withdraw(ctx, contract, stateDB, args) + default: + // ERC20 transactions and queries + bz, err = p.Precompile.HandleMethod(ctx, contract, stateDB, method, args) + } + + if err != nil { + return nil, err + } + + cost := ctx.GasMeter().GasConsumed() - initialGas + + if !contract.UseGas(cost) { + return nil, vm.ErrOutOfGas + } + + if err := p.AddJournalEntries(stateDB, snapshot); err != nil { + return nil, err + } + return bz, nil +} + +// IsTransaction returns true if the given method name correspond to a +// transaction. Returns false otherwise. +func (p Precompile) IsTransaction(method *abi.Method) bool { + txMethodName := []string{DepositMethod, WithdrawMethod} + txMethodType := []abi.FunctionType{abi.Fallback, abi.Receive} + + if slices.Contains(txMethodName, method.Name) || slices.Contains(txMethodType, method.Type) { + return true + } + + return p.Precompile.IsTransaction(method) +} diff --git a/proto/os/evm/v1/evm.proto b/proto/os/evm/v1/evm.proto index 2a79dc3f..04007e9e 100644 --- a/proto/os/evm/v1/evm.proto +++ b/proto/os/evm/v1/evm.proto @@ -208,6 +208,12 @@ message ChainConfig { (gogoproto.customtype) = "cosmossdk.io/math.Int", (gogoproto.moretags) = "yaml:\"cancun_block\"" ]; + // chain_id is the id of the chain (EIP-155) + uint64 chain_id = 24; + // denom is the denomination used on the EVM + string denom = 25; + // decimals is the real decimal precision of the denomination used on the EVM + uint64 decimals = 26; } // State represents a single Storage key value pair item. diff --git a/proto/os/evm/v1/query.proto b/proto/os/evm/v1/query.proto index bcec5388..f529e8e8 100644 --- a/proto/os/evm/v1/query.proto +++ b/proto/os/evm/v1/query.proto @@ -82,6 +82,29 @@ service Query { rpc BaseFee(QueryBaseFeeRequest) returns (QueryBaseFeeResponse) { option (google.api.http).get = "/evmos/evm/v1/base_fee"; } + + // Config queries the EVM configuration + rpc Config(QueryConfigRequest) returns (QueryConfigResponse) { + option (google.api.http).get = "/evmos/evm/v1/config"; + } + + // GlobalMinGasPrice queries the MinGasPrice + // it's similar to feemarket module's method, + // but makes the conversion to 18 decimals + // when the evm denom is represented with a different precision. + rpc GlobalMinGasPrice(QueryGlobalMinGasPriceRequest) + returns (QueryGlobalMinGasPriceResponse) { + option (google.api.http).get = "/evmos/evm/v1/min_gas_price"; + } +} + +// QueryConfigRequest defines the request type for querying the config +message QueryConfigRequest {} + +// QueryConfigResponse returns the EVM config. +message QueryConfigResponse { + // config is the evm configuration + ChainConfig config = 1; } // QueryAccountRequest is the request type for the Query/Account RPC method. @@ -242,6 +265,11 @@ message EthCallRequest { message EstimateGasResponse { // gas returns the estimated gas uint64 gas = 1; + // ret is the returned data from evm function (result or data supplied with + // revert opcode) + bytes ret = 2; + // vm_error is the error returned by vm execution + string vm_error = 3; } // QueryTraceTxRequest defines TraceTx request @@ -323,3 +351,16 @@ message QueryBaseFeeResponse { // base_fee is the EIP1559 base fee string base_fee = 1 [ (gogoproto.customtype) = "cosmossdk.io/math.Int" ]; } + +// QueryGlobalMinGasPriceRequest defines the request type for querying the +// GlobalMinGasPrice +message QueryGlobalMinGasPriceRequest {} + +// QueryGlobalMinGasPriceResponse returns the GlobalMinGasPrice +message QueryGlobalMinGasPriceResponse { + // min_gas_price is the feemarket's min_gas_price + string min_gas_price = 1 [ + (gogoproto.customtype) = "cosmossdk.io/math.Int", + (gogoproto.nullable) = false + ]; +} diff --git a/proto/os/feemarket/v1/feemarket.proto b/proto/os/feemarket/v1/feemarket.proto index 67145fa1..c4fc7d3e 100644 --- a/proto/os/feemarket/v1/feemarket.proto +++ b/proto/os/feemarket/v1/feemarket.proto @@ -28,7 +28,7 @@ message Params { int64 enable_height = 5; // base_fee for EIP-1559 blocks. string base_fee = 6 [ - (gogoproto.customtype) = "cosmossdk.io/math.Int", + (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false, (amino.dont_omitempty) = true ]; diff --git a/proto/os/feemarket/v1/query.proto b/proto/os/feemarket/v1/query.proto index 8c2b606c..236231ba 100644 --- a/proto/os/feemarket/v1/query.proto +++ b/proto/os/feemarket/v1/query.proto @@ -45,7 +45,8 @@ message QueryBaseFeeRequest {} // QueryBaseFeeResponse returns the EIP1559 base fee. message QueryBaseFeeResponse { // base_fee is the EIP1559 base fee - string base_fee = 1 [ (gogoproto.customtype) = "cosmossdk.io/math.Int" ]; + string base_fee = 1 + [ (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec" ]; } // QueryBlockGasRequest defines the request type for querying the EIP1559 base diff --git a/proto/os/types/v1/dynamic_fee.proto b/proto/os/types/v1/dynamic_fee.proto index 0a912032..3aa30a25 100644 --- a/proto/os/types/v1/dynamic_fee.proto +++ b/proto/os/types/v1/dynamic_fee.proto @@ -14,7 +14,7 @@ message ExtensionOptionDynamicFeeTx { // max_priority_price is the same as `max_priority_fee_per_gas` in eip-1559 // spec string max_priority_price = 1 [ - (gogoproto.customtype) = "cosmossdk.io/math.Int", + (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false, (amino.dont_omitempty) = true ]; diff --git a/rpc/backend/backend.go b/rpc/backend/backend.go index e0db76be..1f629e62 100644 --- a/rpc/backend/backend.go +++ b/rpc/backend/backend.go @@ -4,11 +4,13 @@ package backend import ( "context" + "fmt" "math/big" "time" + tmrpcclient "github.com/cometbft/cometbft/rpc/client" + "cosmossdk.io/log" - "cosmossdk.io/math" tmrpctypes "github.com/cometbft/cometbft/rpc/core/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/crypto/keyring" @@ -28,19 +30,9 @@ import ( // BackendI implements the Cosmos and EVM backend. type BackendI interface { //nolint: revive - CosmosBackend EVMBackend } -// CosmosBackend implements the functionality shared within cosmos namespaces -// as defined by Wallet Connect V2: https://docs.walletconnect.com/2.0/json-rpc/cosmos. -// Implemented by Backend. -type CosmosBackend interface { // TODO: define - // GetAccounts() - // SignDirect() - // SignAmino() -} - // EVMBackend implements the functionality shared within ethereum namespaces // as defined by EIP-1474: https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1474.md // Implemented by Backend. @@ -57,7 +49,7 @@ type EVMBackend interface { RPCGasCap() uint64 // global gas cap for eth_call over rpc: DoS protection RPCEVMTimeout() time.Duration // global timeout for eth_call over rpc: DoS protection RPCTxFeeCap() float64 // RPCTxFeeCap is the global transaction fee(price * gaslimit) cap for send-transaction variants. The unit is ether. - RPCMinGasPrice() int64 + RPCMinGasPrice() *big.Int // Sign Tx Sign(address common.Address, data hexutil.Bytes) (hexutil.Bytes, error) @@ -71,7 +63,6 @@ type EVMBackend interface { GetBlockTransactionCountByHash(hash common.Hash) *hexutil.Uint GetBlockTransactionCountByNumber(blockNum rpctypes.BlockNumber) *hexutil.Uint TendermintBlockByNumber(blockNum rpctypes.BlockNumber) (*tmrpctypes.ResultBlock, error) - TendermintBlockResultByNumber(height *int64) (*tmrpctypes.ResultBlockResults, error) TendermintBlockByHash(blockHash common.Hash) (*tmrpctypes.ResultBlock, error) BlockNumberFromTendermint(blockNrOrHash rpctypes.BlockNumberOrHash) (rpctypes.BlockNumber, error) BlockNumberFromTendermintByHash(blockHash common.Hash) (*big.Int, error) @@ -93,7 +84,7 @@ type EVMBackend interface { // Chain Info ChainID() (*hexutil.Big, error) ChainConfig() *params.ChainConfig - GlobalMinGasPrice() (math.LegacyDec, error) + GlobalMinGasPrice() (*big.Int, error) BaseFee(blockRes *tmrpctypes.ResultBlockResults) (*big.Int, error) CurrentHeader() (*ethtypes.Header, error) PendingTransactions() ([]*sdk.Tx, error) @@ -107,6 +98,7 @@ type EVMBackend interface { GetTxByTxIndex(height int64, txIndex uint) (*evmostypes.TxResult, error) GetTransactionByBlockAndIndex(block *tmrpctypes.ResultBlock, idx hexutil.Uint) (*rpctypes.RPCTransaction, error) GetTransactionReceipt(hash common.Hash) (map[string]interface{}, error) + GetTransactionLogs(hash common.Hash) ([]*ethtypes.Log, error) GetTransactionByBlockHashAndIndex(hash common.Hash, idx hexutil.Uint) (*rpctypes.RPCTransaction, error) GetTransactionByBlockNumberAndIndex(blockNum rpctypes.BlockNumber, idx hexutil.Uint) (*rpctypes.RPCTransaction, error) @@ -134,6 +126,7 @@ var _ BackendI = (*Backend)(nil) type Backend struct { ctx context.Context clientCtx client.Context + rpcClient tmrpcclient.SignClient queryClient *rpctypes.QueryClient // gRPC query client logger log.Logger chainID *big.Int @@ -160,9 +153,15 @@ func NewBackend( panic(err) } + rpcClient, ok := clientCtx.Client.(tmrpcclient.SignClient) + if !ok { + panic(fmt.Sprintf("invalid rpc client, expected: tmrpcclient.SignClient, got: %T", clientCtx.Client)) + } + return &Backend{ ctx: context.Background(), clientCtx: clientCtx, + rpcClient: rpcClient, queryClient: rpctypes.NewQueryClient(clientCtx), logger: logger.With("module", "backend"), chainID: chainID, diff --git a/rpc/backend/backend_suite_test.go b/rpc/backend/backend_suite_test.go index 54f6fde1..e3151240 100644 --- a/rpc/backend/backend_suite_test.go +++ b/rpc/backend/backend_suite_test.go @@ -76,7 +76,8 @@ func (suite *BackendTestSuite) SetupTest() { WithTxConfig(encodingConfig.TxConfig). WithKeyringDir(clientDir). WithKeyring(keyRing). - WithAccountRetriever(client.TestAccountRetriever{Accounts: accounts}) + WithAccountRetriever(client.TestAccountRetriever{Accounts: accounts}). + WithClient(mocks.NewClient(suite.T())) allowUnprotectedTxs := false idxer := indexer.NewKVIndexer(dbm.NewMemDB(), ctx.Logger, clientCtx) @@ -86,7 +87,6 @@ func (suite *BackendTestSuite) SetupTest() { suite.backend.cfg.JSONRPC.EVMTimeout = 0 suite.backend.cfg.JSONRPC.AllowInsecureUnlock = true suite.backend.queryClient.QueryClient = mocks.NewEVMQueryClient(suite.T()) - suite.backend.clientCtx.Client = mocks.NewClient(suite.T()) suite.backend.queryClient.FeeMarket = mocks.NewFeeMarketQueryClient(suite.T()) suite.backend.ctx = rpctypes.ContextWithHeight(1) @@ -175,15 +175,13 @@ func (suite *BackendTestSuite) signAndEncodeEthTx(msgEthereumTx *evmtypes.MsgEth from, priv := utiltx.NewAddrKey() signer := utiltx.NewSigner(priv) - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) - RegisterParamsWithoutHeader(queryClient, 1) - ethSigner := ethtypes.LatestSigner(suite.backend.ChainConfig()) msgEthereumTx.From = from.String() err := msgEthereumTx.Sign(ethSigner, signer) suite.Require().NoError(err) - tx, err := msgEthereumTx.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), ChainID) + evmDenom := evmtypes.GetEVMCoinDenom() + tx, err := msgEthereumTx.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), evmDenom) suite.Require().NoError(err) txEncoder := suite.backend.clientCtx.TxConfig.TxEncoder() diff --git a/rpc/backend/blocks.go b/rpc/backend/blocks.go index 6104221f..97da4256 100644 --- a/rpc/backend/blocks.go +++ b/rpc/backend/blocks.go @@ -8,7 +8,6 @@ import ( "math/big" "strconv" - tmrpcclient "github.com/cometbft/cometbft/rpc/client" tmrpctypes "github.com/cometbft/cometbft/rpc/core/types" sdk "github.com/cosmos/cosmos-sdk/types" grpctypes "github.com/cosmos/cosmos-sdk/types/grpc" @@ -66,7 +65,7 @@ func (b *Backend) GetBlockByNumber(blockNum rpctypes.BlockNumber, fullTx bool) ( return nil, nil } - blockRes, err := b.TendermintBlockResultByNumber(&resBlock.Block.Height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, &resBlock.Block.Height) if err != nil { b.logger.Debug("failed to fetch block result from Tendermint", "height", blockNum, "error", err.Error()) return nil, nil @@ -94,7 +93,7 @@ func (b *Backend) GetBlockByHash(hash common.Hash, fullTx bool) (map[string]inte return nil, nil } - blockRes, err := b.TendermintBlockResultByNumber(&resBlock.Block.Height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, &resBlock.Block.Height) if err != nil { b.logger.Debug("failed to fetch block result from Tendermint", "block-hash", hash.String(), "error", err.Error()) return nil, nil @@ -112,12 +111,7 @@ func (b *Backend) GetBlockByHash(hash common.Hash, fullTx bool) (map[string]inte // GetBlockTransactionCountByHash returns the number of Ethereum transactions in // the block identified by hash. func (b *Backend) GetBlockTransactionCountByHash(hash common.Hash) *hexutil.Uint { - sc, ok := b.clientCtx.Client.(tmrpcclient.SignClient) - if !ok { - b.logger.Error("invalid rpc client") - } - - block, err := sc.BlockByHash(b.ctx, hash.Bytes()) + block, err := b.rpcClient.BlockByHash(b.ctx, hash.Bytes()) if err != nil { b.logger.Debug("block not found", "hash", hash.Hex(), "error", err.Error()) return nil @@ -151,7 +145,7 @@ func (b *Backend) GetBlockTransactionCountByNumber(blockNum rpctypes.BlockNumber // GetBlockTransactionCount returns the number of Ethereum transactions in a // given block. func (b *Backend) GetBlockTransactionCount(block *tmrpctypes.ResultBlock) *hexutil.Uint { - blockRes, err := b.TendermintBlockResultByNumber(&block.Block.Height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, &block.Block.Height) if err != nil { return nil } @@ -173,7 +167,7 @@ func (b *Backend) TendermintBlockByNumber(blockNum rpctypes.BlockNumber) (*tmrpc } height = int64(n) //#nosec G115 -- checked for int overflow already } - resBlock, err := b.clientCtx.Client.Block(b.ctx, &height) + resBlock, err := b.rpcClient.Block(b.ctx, &height) if err != nil { b.logger.Debug("tendermint client failed to get block", "height", height, "error", err.Error()) return nil, err @@ -190,20 +184,12 @@ func (b *Backend) TendermintBlockByNumber(blockNum rpctypes.BlockNumber) (*tmrpc // TendermintBlockResultByNumber returns a Tendermint-formatted block result // by block number func (b *Backend) TendermintBlockResultByNumber(height *int64) (*tmrpctypes.ResultBlockResults, error) { - sc, ok := b.clientCtx.Client.(tmrpcclient.SignClient) - if !ok { - return nil, errors.New("invalid rpc client") - } - return sc.BlockResults(b.ctx, height) + return b.rpcClient.BlockResults(b.ctx, height) } // TendermintBlockByHash returns a Tendermint-formatted block by block number func (b *Backend) TendermintBlockByHash(blockHash common.Hash) (*tmrpctypes.ResultBlock, error) { - sc, ok := b.clientCtx.Client.(tmrpcclient.SignClient) - if !ok { - return nil, errors.New("invalid rpc client") - } - resBlock, err := sc.BlockByHash(b.ctx, blockHash.Bytes()) + resBlock, err := b.rpcClient.BlockByHash(b.ctx, blockHash.Bytes()) if err != nil { b.logger.Debug("tendermint client failed to get block", "blockHash", blockHash.Hex(), "error", err.Error()) return nil, err @@ -237,14 +223,16 @@ func (b *Backend) BlockNumberFromTendermint(blockNrOrHash rpctypes.BlockNumberOr // BlockNumberFromTendermintByHash returns the block height of given block hash func (b *Backend) BlockNumberFromTendermintByHash(blockHash common.Hash) (*big.Int, error) { - resBlock, err := b.TendermintBlockByHash(blockHash) + resBlock, err := b.rpcClient.HeaderByHash(b.ctx, blockHash.Bytes()) if err != nil { return nil, err } + if resBlock == nil { return nil, errors.Errorf("block not found for hash %s", blockHash.Hex()) } - return big.NewInt(resBlock.Block.Height), nil + + return big.NewInt(resBlock.Header.Height), nil } // EthMsgsFromTendermintBlock returns all real MsgEthereumTxs from a @@ -300,9 +288,9 @@ func (b *Backend) HeaderByNumber(blockNum rpctypes.BlockNumber) (*ethtypes.Heade return nil, errors.Errorf("block not found for height %d", blockNum) } - blockRes, err := b.TendermintBlockResultByNumber(&resBlock.Block.Height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, &resBlock.Block.Height) if err != nil { - return nil, fmt.Errorf("block result not found for height %d. %w", resBlock.Block.Height, err) + return nil, errors.Errorf("block result not found for height %d", resBlock.Block.Height) } bloom, err := b.BlockBloom(blockRes) @@ -322,31 +310,34 @@ func (b *Backend) HeaderByNumber(blockNum rpctypes.BlockNumber) (*ethtypes.Heade // HeaderByHash returns the block header identified by hash. func (b *Backend) HeaderByHash(blockHash common.Hash) (*ethtypes.Header, error) { - resBlock, err := b.TendermintBlockByHash(blockHash) + resHeader, err := b.rpcClient.HeaderByHash(b.ctx, blockHash.Bytes()) if err != nil { return nil, err } - if resBlock == nil { - return nil, errors.Errorf("block not found for hash %s", blockHash.Hex()) + + if resHeader == nil { + return nil, errors.Errorf("header not found for hash %s", blockHash.Hex()) } - blockRes, err := b.TendermintBlockResultByNumber(&resBlock.Block.Height) + height := resHeader.Header.Height + + blockRes, err := b.rpcClient.BlockResults(b.ctx, &resHeader.Header.Height) if err != nil { - return nil, errors.Errorf("block result not found for height %d", resBlock.Block.Height) + return nil, errors.Errorf("block result not found for height %d", height) } bloom, err := b.BlockBloom(blockRes) if err != nil { - b.logger.Debug("HeaderByHash BlockBloom failed", "height", resBlock.Block.Height) + b.logger.Debug("HeaderByHash BlockBloom failed", "height", height) } baseFee, err := b.BaseFee(blockRes) if err != nil { // handle the error for pruned node. - b.logger.Error("failed to fetch Base Fee from prunned block. Check node prunning configuration", "height", resBlock.Block.Height, "error", err) + b.logger.Error("failed to fetch Base Fee from prunned block. Check node prunning configuration", "height", height, "error", err) } - ethHeader := rpctypes.EthHeaderFromTendermint(resBlock.Block.Header, bloom, baseFee) + ethHeader := rpctypes.EthHeaderFromTendermint(*resHeader.Header, bloom, baseFee) return ethHeader, nil } @@ -469,12 +460,13 @@ func (b *Backend) EthBlockByNumber(blockNum rpctypes.BlockNumber) (*ethtypes.Blo if err != nil { return nil, err } + if resBlock == nil { // block not found return nil, fmt.Errorf("block not found for height %d", blockNum) } - blockRes, err := b.TendermintBlockResultByNumber(&resBlock.Block.Height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, &resBlock.Block.Height) if err != nil { return nil, fmt.Errorf("block result not found for height %d", resBlock.Block.Height) } diff --git a/rpc/backend/blocks_test.go b/rpc/backend/blocks_test.go index 51877268..ad2bfc7d 100644 --- a/rpc/backend/blocks_test.go +++ b/rpc/backend/blocks_test.go @@ -671,7 +671,8 @@ func (suite *BackendTestSuite) TestTendermintBlockResultByNumber() { suite.SetupTest() // reset test and queries tc.registerMock(tc.blockNumber) - blockRes, err := suite.backend.TendermintBlockResultByNumber(&tc.blockNumber) //#nosec G601 -- fine for tests + client := suite.backend.clientCtx.Client.(*mocks.Client) + blockRes, err := client.BlockResults(suite.backend.ctx, &tc.blockNumber) //#nosec G601 -- fine for tests if tc.expPass { suite.Require().NoError(err) @@ -684,7 +685,7 @@ func (suite *BackendTestSuite) TestTendermintBlockResultByNumber() { } func (suite *BackendTestSuite) TestBlockNumberFromTendermint() { - var resBlock *cmtrpctypes.ResultBlock + var resHeader *cmtrpctypes.ResultHeader _, bz := suite.buildEthereumTx() block := cmttypes.MakeBlock(1, []cmttypes.Tx{bz}, nil, nil) @@ -711,7 +712,7 @@ func (suite *BackendTestSuite) TestBlockNumberFromTendermint() { &blockHash, func(hash *common.Hash) { client := suite.backend.clientCtx.Client.(*mocks.Client) - RegisterBlockByHashError(client, *hash, bz) + RegisterHeaderByHashError(client, *hash, bz) }, false, }, @@ -721,7 +722,7 @@ func (suite *BackendTestSuite) TestBlockNumberFromTendermint() { &blockHash, func(hash *common.Hash) { client := suite.backend.clientCtx.Client.(*mocks.Client) - resBlock, _ = RegisterBlockByHash(client, *hash, bz) + resHeader, _ = RegisterHeaderByHash(client, *hash, bz) }, true, }, @@ -750,7 +751,7 @@ func (suite *BackendTestSuite) TestBlockNumberFromTendermint() { if tc.hash == nil { suite.Require().Equal(*tc.blockNum, blockNum) } else { - expHeight := ethrpc.NewBlockNumber(big.NewInt(resBlock.Block.Height)) + expHeight := ethrpc.NewBlockNumber(big.NewInt(resHeader.Header.Height)) suite.Require().Equal(expHeight, blockNum) } } else { @@ -761,7 +762,7 @@ func (suite *BackendTestSuite) TestBlockNumberFromTendermint() { } func (suite *BackendTestSuite) TestBlockNumberFromTendermintByHash() { - var resBlock *cmtrpctypes.ResultBlock + var resHeader *cmtrpctypes.ResultHeader _, bz := suite.buildEthereumTx() block := cmttypes.MakeBlock(1, []cmttypes.Tx{bz}, nil, nil) @@ -778,7 +779,7 @@ func (suite *BackendTestSuite) TestBlockNumberFromTendermintByHash() { common.BytesToHash(block.Hash()), func(hash common.Hash) { client := suite.backend.clientCtx.Client.(*mocks.Client) - RegisterBlockByHashError(client, hash, bz) + RegisterHeaderByHashError(client, hash, bz) }, false, }, @@ -787,7 +788,7 @@ func (suite *BackendTestSuite) TestBlockNumberFromTendermintByHash() { common.BytesToHash(emptyBlock.Hash()), func(hash common.Hash) { client := suite.backend.clientCtx.Client.(*mocks.Client) - resBlock, _ = RegisterBlockByHash(client, hash, bz) + resHeader, _ = RegisterHeaderByHash(client, hash, bz) }, true, }, @@ -796,7 +797,7 @@ func (suite *BackendTestSuite) TestBlockNumberFromTendermintByHash() { common.BytesToHash(block.Hash()), func(hash common.Hash) { client := suite.backend.clientCtx.Client.(*mocks.Client) - resBlock, _ = RegisterBlockByHash(client, hash, bz) + resHeader, _ = RegisterHeaderByHash(client, hash, bz) }, true, }, @@ -808,7 +809,7 @@ func (suite *BackendTestSuite) TestBlockNumberFromTendermintByHash() { tc.registerMock(tc.hash) blockNum, err := suite.backend.BlockNumberFromTendermintByHash(tc.hash) if tc.expPass { - expHeight := big.NewInt(resBlock.Block.Height) + expHeight := big.NewInt(resHeader.Header.Height) suite.Require().NoError(err) suite.Require().Equal(expHeight, blockNum) } else { @@ -1306,7 +1307,7 @@ func (suite *BackendTestSuite) TestHeaderByNumber() { } func (suite *BackendTestSuite) TestHeaderByHash() { - var expResultBlock *cmtrpctypes.ResultBlock + var expResultHeader *cmtrpctypes.ResultHeader _, bz := suite.buildEthereumTx() block := cmttypes.MakeBlock(1, []cmttypes.Tx{bz}, nil, nil) @@ -1325,7 +1326,7 @@ func (suite *BackendTestSuite) TestHeaderByHash() { math.NewInt(1).BigInt(), func(hash common.Hash, _ math.Int) { client := suite.backend.clientCtx.Client.(*mocks.Client) - RegisterBlockByHashError(client, hash, bz) + RegisterHeaderByHashError(client, hash, bz) }, false, }, @@ -1335,7 +1336,7 @@ func (suite *BackendTestSuite) TestHeaderByHash() { math.NewInt(1).BigInt(), func(hash common.Hash, _ math.Int) { client := suite.backend.clientCtx.Client.(*mocks.Client) - RegisterBlockByHashNotFound(client, hash, bz) + RegisterHeaderByHashNotFound(client, hash, bz) }, false, }, @@ -1346,7 +1347,7 @@ func (suite *BackendTestSuite) TestHeaderByHash() { func(hash common.Hash, _ math.Int) { height := int64(1) client := suite.backend.clientCtx.Client.(*mocks.Client) - _, err := RegisterBlockByHash(client, hash, bz) + _, err := RegisterHeaderByHash(client, hash, bz) suite.Require().NoError(err) RegisterBlockResultsError(client, height) }, @@ -1359,7 +1360,7 @@ func (suite *BackendTestSuite) TestHeaderByHash() { func(hash common.Hash, _ math.Int) { height := int64(1) client := suite.backend.clientCtx.Client.(*mocks.Client) - expResultBlock, _ = RegisterBlockByHash(client, hash, bz) + expResultHeader, _ = RegisterHeaderByHash(client, hash, bz) _, err := RegisterBlockResults(client, height) suite.Require().NoError(err) queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) @@ -1374,7 +1375,7 @@ func (suite *BackendTestSuite) TestHeaderByHash() { func(hash common.Hash, baseFee math.Int) { height := int64(1) client := suite.backend.clientCtx.Client.(*mocks.Client) - expResultBlock, _ = RegisterBlockByHash(client, hash, nil) + expResultHeader, _ = RegisterHeaderByHash(client, hash, nil) _, err := RegisterBlockResults(client, height) suite.Require().NoError(err) queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) @@ -1389,7 +1390,7 @@ func (suite *BackendTestSuite) TestHeaderByHash() { func(hash common.Hash, baseFee math.Int) { height := int64(1) client := suite.backend.clientCtx.Client.(*mocks.Client) - expResultBlock, _ = RegisterBlockByHash(client, hash, bz) + expResultHeader, _ = RegisterHeaderByHash(client, hash, bz) _, err := RegisterBlockResults(client, height) suite.Require().NoError(err) queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) @@ -1406,7 +1407,7 @@ func (suite *BackendTestSuite) TestHeaderByHash() { header, err := suite.backend.HeaderByHash(tc.hash) if tc.expPass { - expHeader := ethrpc.EthHeaderFromTendermint(expResultBlock.Block.Header, ethtypes.Bloom{}, tc.baseFee) + expHeader := ethrpc.EthHeaderFromTendermint(*expResultHeader.Header, ethtypes.Bloom{}, tc.baseFee) suite.Require().NoError(err) suite.Require().Equal(expHeader, header) } else { diff --git a/rpc/backend/call_tx.go b/rpc/backend/call_tx.go index 294eb345..b7d8aee3 100644 --- a/rpc/backend/call_tx.go +++ b/rpc/backend/call_tx.go @@ -16,7 +16,6 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" ethtypes "github.com/ethereum/go-ethereum/core/types" rpctypes "github.com/evmos/os/rpc/types" - "github.com/evmos/os/types" "github.com/evmos/os/x/evm/core/vm" evmtypes "github.com/evmos/os/x/evm/types" "github.com/pkg/errors" @@ -38,14 +37,9 @@ func (b *Backend) Resend(args evmtypes.TransactionArgs, gasPrice *hexutil.Big, g // The signer used should always be the 'latest' known one because we expect // signers to be backwards-compatible with old transactions. - eip155ChainID, err := types.ParseChainID(b.clientCtx.ChainID) - if err != nil { - return common.Hash{}, err - } - cfg := b.ChainConfig() if cfg == nil { - cfg = evmtypes.DefaultChainConfig().EthereumConfig(eip155ChainID) + cfg = evmtypes.DefaultChainConfig(b.clientCtx.ChainID).EthereumConfig(nil) } signer := ethtypes.LatestSigner(cfg) @@ -128,14 +122,9 @@ func (b *Backend) SendRawTransaction(data hexutil.Bytes) (common.Hash, error) { return common.Hash{}, err } - // Query params to use the EVM denomination - res, err := b.queryClient.QueryClient.Params(b.ctx, &evmtypes.QueryParamsRequest{}) - if err != nil { - b.logger.Error("failed to query evm params", "error", err.Error()) - return common.Hash{}, err - } + baseDenom := evmtypes.GetEVMCoinDenom() - cosmosTx, err := ethereumTx.BuildTx(b.clientCtx.TxConfig.NewTxBuilder(), res.Params.EvmDenom) + cosmosTx, err := ethereumTx.BuildTx(b.clientCtx.TxConfig.NewTxBuilder(), baseDenom) if err != nil { b.logger.Error("failed to build cosmos tx", "error", err.Error()) return common.Hash{}, err @@ -323,6 +312,9 @@ func (b *Backend) EstimateGas(args evmtypes.TransactionArgs, blockNrOptional *rp if err != nil { return 0, err } + if err = handleRevertError(res.VmError, res.Ret); err != nil { + return 0, err + } return hexutil.Uint64(res.Gas), nil } @@ -372,11 +364,8 @@ func (b *Backend) DoCall( return nil, err } - if res.Failed() { - if res.VmError != vm.ErrExecutionReverted.Error() { - return nil, status.Error(codes.Internal, res.VmError) - } - return nil, evmtypes.NewExecErrorWithReason(res.Ret) + if err = handleRevertError(res.VmError, res.Ret); err != nil { + return nil, err } return res, nil @@ -401,7 +390,7 @@ func (b *Backend) GasPrice() (*hexutil.Big, error) { } result = result.Add(result, head.BaseFee) } else { - result = big.NewInt(b.RPCMinGasPrice()) + result = b.RPCMinGasPrice() } // return at least GlobalMinGasPrice from FeeMarket module @@ -409,10 +398,23 @@ func (b *Backend) GasPrice() (*hexutil.Big, error) { if err != nil { return nil, err } - minGasPriceInt := minGasPrice.TruncateInt().BigInt() - if result.Cmp(minGasPriceInt) < 0 { - result = minGasPriceInt + if result.Cmp(minGasPrice) < 0 { + result = minGasPrice } return (*hexutil.Big)(result), nil } + +// handleRevertError returns revert related error. +func handleRevertError(vmError string, ret []byte) error { + if len(vmError) > 0 { + if vmError != vm.ErrExecutionReverted.Error() { + return status.Error(codes.Internal, vmError) + } + if len(ret) == 0 { + return errors.New(vmError) + } + return evmtypes.NewExecErrorWithReason(ret) + } + return nil +} diff --git a/rpc/backend/call_tx_test.go b/rpc/backend/call_tx_test.go index 1ee19309..acb79751 100644 --- a/rpc/backend/call_tx_test.go +++ b/rpc/backend/call_tx_test.go @@ -12,7 +12,6 @@ import ( "github.com/ethereum/go-ethereum/rlp" "github.com/evmos/os/rpc/backend/mocks" rpctypes "github.com/evmos/os/rpc/types" - "github.com/evmos/os/testutil/constants" utiltx "github.com/evmos/os/testutil/tx" evmtypes "github.com/evmos/os/x/evm/types" "google.golang.org/grpc/metadata" @@ -220,7 +219,6 @@ func (suite *BackendTestSuite) TestResend() { RegisterBaseFee(queryClient, baseFee) RegisterEstimateGas(queryClient, callArgs) RegisterParams(queryClient, &header, 1) - RegisterParamsWithoutHeader(queryClient, 1) RegisterUnconfirmedTxsError(client, nil) }, evmtypes.TransactionArgs{ @@ -250,7 +248,7 @@ func (suite *BackendTestSuite) TestResend() { RegisterBaseFee(queryClient, baseFee) RegisterEstimateGas(queryClient, callArgs) RegisterParams(queryClient, &header, 1) - RegisterParamsWithoutHeader(queryClient, 1) + RegisterUnconfirmedTxsEmpty(client, nil) }, evmtypes.TransactionArgs{ @@ -289,14 +287,13 @@ func (suite *BackendTestSuite) TestSendRawTransaction() { ethTx, bz := suite.buildEthereumTx() // Sign the ethTx - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) - RegisterParamsWithoutHeader(queryClient, 1) ethSigner := ethtypes.LatestSigner(suite.backend.ChainConfig()) err := ethTx.Sign(ethSigner, suite.signer) suite.Require().NoError(err) rlpEncodedBz, _ := rlp.EncodeToBytes(ethTx.AsTransaction()) - cosmosTx, _ := ethTx.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), constants.ExampleAttoDenom) + evmDenom := evmtypes.GetEVMCoinDenom() + cosmosTx, _ := ethTx.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), evmDenom) txBytes, _ := suite.backend.clientCtx.TxConfig.TxEncoder()(cosmosTx) testCases := []struct { @@ -323,20 +320,9 @@ func (suite *BackendTestSuite) TestSendRawTransaction() { { "fail - unprotected transactions", func() { - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) suite.backend.allowUnprotectedTxs = false - RegisterParamsWithoutHeaderError(queryClient, 1) - }, - rlpEncodedBz, - common.Hash{}, - false, - }, - { - "fail - failed to get evm params", - func() { - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) - suite.backend.allowUnprotectedTxs = true - RegisterParamsWithoutHeaderError(queryClient, 1) + client := suite.backend.clientCtx.Client.(*mocks.Client) + RegisterBroadcastTxError(client, txBytes) }, rlpEncodedBz, common.Hash{}, @@ -346,9 +332,7 @@ func (suite *BackendTestSuite) TestSendRawTransaction() { "fail - failed to broadcast transaction", func() { client := suite.backend.clientCtx.Client.(*mocks.Client) - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) suite.backend.allowUnprotectedTxs = true - RegisterParamsWithoutHeader(queryClient, 1) RegisterBroadcastTxError(client, txBytes) }, rlpEncodedBz, @@ -359,9 +343,7 @@ func (suite *BackendTestSuite) TestSendRawTransaction() { "pass - Gets the correct transaction hash of the eth transaction", func() { client := suite.backend.clientCtx.Client.(*mocks.Client) - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) suite.backend.allowUnprotectedTxs = true - RegisterParamsWithoutHeader(queryClient, 1) RegisterBroadcastTx(client, txBytes) }, rlpEncodedBz, @@ -479,6 +461,7 @@ func (suite *BackendTestSuite) TestGasPrice() { feeMarketClient := suite.backend.queryClient.FeeMarket.(*mocks.FeeMarketQueryClient) RegisterFeeMarketParams(feeMarketClient, 1) RegisterParams(queryClient, &header, 1) + RegisterGlobalMinGasPrice(queryClient, 1) _, err := RegisterBlock(client, 1, nil) suite.Require().NoError(err) _, err = RegisterBlockResults(client, 1) diff --git a/rpc/backend/chain_info.go b/rpc/backend/chain_info.go index 67373c6f..3fdb76f9 100644 --- a/rpc/backend/chain_info.go +++ b/rpc/backend/chain_info.go @@ -6,7 +6,6 @@ package backend import ( "fmt" "math/big" - "strconv" "cosmossdk.io/math" cmtrpcclient "github.com/cometbft/cometbft/rpc/client" @@ -45,21 +44,19 @@ func (b *Backend) ChainID() (*hexutil.Big, error) { // ChainConfig returns the latest ethereum chain configuration func (b *Backend) ChainConfig() *params.ChainConfig { - params, err := b.queryClient.Params(b.ctx, &evmtypes.QueryParamsRequest{}) - if err != nil { - return nil - } - - return params.Params.ChainConfig.EthereumConfig(b.chainID) + return evmtypes.GetEthChainConfig() } // GlobalMinGasPrice returns MinGasPrice param from FeeMarket -func (b *Backend) GlobalMinGasPrice() (math.LegacyDec, error) { - res, err := b.queryClient.FeeMarket.Params(b.ctx, &feemarkettypes.QueryParamsRequest{}) +func (b *Backend) GlobalMinGasPrice() (*big.Int, error) { + res, err := b.queryClient.GlobalMinGasPrice(b.ctx, &evmtypes.QueryGlobalMinGasPriceRequest{}) if err != nil { - return math.LegacyZeroDec(), err + return nil, err + } + if res == nil { + return nil, fmt.Errorf("GlobalMinGasPrice query returned a nil response") } - return res.Params.MinGasPrice, nil + return res.MinGasPrice.BigInt(), nil } // BaseFee returns the base fee tracked by the Fee Market module. @@ -75,10 +72,10 @@ func (b *Backend) BaseFee(blockRes *cmtrpctypes.ResultBlockResults) (*big.Int, e // faster to iterate reversely for i := len(blockRes.FinalizeBlockEvents) - 1; i >= 0; i-- { evt := blockRes.FinalizeBlockEvents[i] - if evt.Type == feemarkettypes.EventTypeFeeMarket && len(evt.Attributes) > 0 { - baseFee, err := strconv.ParseInt(evt.Attributes[0].Value, 10, 64) - if err == nil { - return big.NewInt(baseFee), nil + if evt.Type == evmtypes.EventTypeFeeMarket && len(evt.Attributes) > 0 { + baseFee, ok := math.NewIntFromString(evt.Attributes[0].Value) + if ok { + return baseFee.BigInt(), nil } break } @@ -208,7 +205,7 @@ func (b *Backend) FeeHistory( } // tendermint block result - tendermintBlockResult, err := b.TendermintBlockResultByNumber(&tendermintblock.Block.Height) + tendermintBlockResult, err := b.rpcClient.BlockResults(b.ctx, &tendermintblock.Block.Height) if tendermintBlockResult == nil { b.logger.Debug("block result not found", "height", tendermintblock.Block.Height, "error", err.Error()) return nil, err diff --git a/rpc/backend/chain_info_test.go b/rpc/backend/chain_info_test.go index d88815d6..a751c7f9 100644 --- a/rpc/backend/chain_info_test.go +++ b/rpc/backend/chain_info_test.go @@ -19,7 +19,6 @@ import ( rpc "github.com/evmos/os/rpc/types" utiltx "github.com/evmos/os/testutil/tx" evmtypes "github.com/evmos/os/x/evm/types" - feemarkettypes "github.com/evmos/os/x/feemarket/types" ) func (suite *BackendTestSuite) TestBaseFee() { @@ -65,7 +64,7 @@ func (suite *BackendTestSuite) TestBaseFee() { Height: 1, FinalizeBlockEvents: []types.Event{ { - Type: feemarkettypes.EventTypeFeeMarket, + Type: evmtypes.EventTypeFeeMarket, }, }, }, @@ -82,7 +81,7 @@ func (suite *BackendTestSuite) TestBaseFee() { Height: 1, FinalizeBlockEvents: []types.Event{ { - Type: feemarkettypes.EventTypeFeeMarket, + Type: evmtypes.EventTypeFeeMarket, Attributes: []types.EventAttribute{ {Value: "/1"}, }, @@ -102,7 +101,7 @@ func (suite *BackendTestSuite) TestBaseFee() { Height: 1, FinalizeBlockEvents: []types.Event{ { - Type: feemarkettypes.EventTypeFeeMarket, + Type: evmtypes.EventTypeFeeMarket, Attributes: []types.EventAttribute{ {Value: baseFee.String()}, }, @@ -291,17 +290,17 @@ func (suite *BackendTestSuite) TestGlobalMinGasPrice() { testCases := []struct { name string registerMock func() - expMinGasPrice math.LegacyDec + expMinGasPrice *big.Int expPass bool }{ { - "fail - Can't get FeeMarket params", + "pass - get GlobalMinGasPrice", func() { - feeMarketCleint := suite.backend.queryClient.FeeMarket.(*mocks.FeeMarketQueryClient) - RegisterFeeMarketParamsError(feeMarketCleint, int64(1)) + qc := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) + RegisterGlobalMinGasPrice(qc, 1) }, - math.LegacyZeroDec(), - false, + big.NewInt(1), + true, }, } @@ -424,7 +423,6 @@ func (suite *BackendTestSuite) TestFeeHistory() { RegisterValidatorAccount(queryClient, validator) RegisterConsensusParams(client, 1) RegisterParams(queryClient, &header, 1) - RegisterParamsWithoutHeader(queryClient, 1) }, 1, 1, diff --git a/rpc/backend/client_test.go b/rpc/backend/client_test.go index f1feb816..58173974 100644 --- a/rpc/backend/client_test.go +++ b/rpc/backend/client_test.go @@ -6,9 +6,11 @@ import ( abci "github.com/cometbft/cometbft/abci/types" "github.com/cometbft/cometbft/libs/bytes" + cmtversion "github.com/cometbft/cometbft/proto/tendermint/version" cmtrpcclient "github.com/cometbft/cometbft/rpc/client" cmtrpctypes "github.com/cometbft/cometbft/rpc/core/types" "github.com/cometbft/cometbft/types" + "github.com/cometbft/cometbft/version" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" errortypes "github.com/cosmos/cosmos-sdk/types/errors" @@ -254,6 +256,35 @@ func RegisterBlockByHashNotFound(client *mocks.Client, _ common.Hash, _ []byte) Return(nil, nil) } +// HeaderByHash +func RegisterHeaderByHash( + client *mocks.Client, + _ common.Hash, + _ []byte, +) (*cmtrpctypes.ResultHeader, error) { + header := &types.Header{ + Version: cmtversion.Consensus{Block: version.BlockProtocol, App: 0}, + Height: 1, + } + resHeader := &cmtrpctypes.ResultHeader{ + Header: header, + } + + client.On("HeaderByHash", rpc.ContextWithHeight(1), bytes.HexBytes{0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}). + Return(resHeader, nil) + return resHeader, nil +} + +func RegisterHeaderByHashError(client *mocks.Client, _ common.Hash, _ []byte) { + client.On("HeaderByHash", rpc.ContextWithHeight(1), bytes.HexBytes{0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}). + Return(nil, errortypes.ErrInvalidRequest) +} + +func RegisterHeaderByHashNotFound(client *mocks.Client, _ common.Hash, _ []byte) { + client.On("HeaderByHash", rpc.ContextWithHeight(1), bytes.HexBytes{0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}). + Return(nil, nil) +} + func RegisterABCIQueryWithOptions(client *mocks.Client, height int64, path string, data bytes.HexBytes, opts cmtrpcclient.ABCIQueryOptions) { client.On("ABCIQueryWithOptions", context.Background(), path, data, opts). Return(&cmtrpctypes.ResultABCIQuery{ diff --git a/rpc/backend/evm_query_client_test.go b/rpc/backend/evm_query_client_test.go index b73e93a0..6880eae0 100644 --- a/rpc/backend/evm_query_client_test.go +++ b/rpc/backend/evm_query_client_test.go @@ -7,8 +7,6 @@ import ( "strconv" "testing" - "github.com/evmos/os/testutil/constants" - "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" errortypes "github.com/cosmos/cosmos-sdk/types/errors" @@ -79,11 +77,8 @@ func RegisterParams(queryClient *mocks.EVMQueryClient, header *metadata.MD, heig } func RegisterParamsWithoutHeader(queryClient *mocks.EVMQueryClient, height int64) { - // NOTE: we need to register the EVM denomination for the example chain - evmParams := evmtypes.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom) - queryClient.On("Params", rpc.ContextWithHeight(height), &evmtypes.QueryParamsRequest{}). - Return(&evmtypes.QueryParamsResponse{Params: evmParams}, nil) + Return(&evmtypes.QueryParamsResponse{Params: evmtypes.DefaultParams()}, nil) } func RegisterParamsInvalidHeader(queryClient *mocks.EVMQueryClient, header *metadata.MD, height int64) { @@ -279,3 +274,9 @@ func RegisterBalanceError(queryClient *mocks.EVMQueryClient, addr common.Address queryClient.On("Balance", rpc.ContextWithHeight(height), &evmtypes.QueryBalanceRequest{Address: addr.String()}). Return(nil, errortypes.ErrInvalidRequest) } + +// GlobalMinGasPrice +func RegisterGlobalMinGasPrice(queryClient *mocks.EVMQueryClient, height int64) { + queryClient.On("GlobalMinGasPrice", rpc.ContextWithHeight(height), &evmtypes.QueryGlobalMinGasPriceRequest{}). + Return(&evmtypes.QueryGlobalMinGasPriceResponse{MinGasPrice: math.OneInt()}, nil) +} diff --git a/rpc/backend/filters.go b/rpc/backend/filters.go index 71cc805f..abb08f44 100644 --- a/rpc/backend/filters.go +++ b/rpc/backend/filters.go @@ -23,7 +23,7 @@ func (b *Backend) GetLogs(hash common.Hash) ([][]*ethtypes.Log, error) { // GetLogsByHeight returns all the logs from all the ethereum transactions in a block. func (b *Backend) GetLogsByHeight(height *int64) ([][]*ethtypes.Log, error) { // NOTE: we query the state in case the tx result logs are not persisted after an upgrade. - blockRes, err := b.TendermintBlockResultByNumber(height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, height) if err != nil { return nil, err } diff --git a/rpc/backend/mocks/evm_query_client.go b/rpc/backend/mocks/evm_query_client.go index 3dc07c8c..9a6b3496 100644 --- a/rpc/backend/mocks/evm_query_client.go +++ b/rpc/backend/mocks/evm_query_client.go @@ -1,4 +1,4 @@ -// Code generated by mockery v2.14.0. DO NOT EDIT. +// Code generated by mockery v2.43.2. DO NOT EDIT. package mocks @@ -28,7 +28,15 @@ func (_m *EVMQueryClient) Account(ctx context.Context, in *types.QueryAccountReq _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for Account") + } + var r0 *types.QueryAccountResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryAccountRequest, ...grpc.CallOption) (*types.QueryAccountResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryAccountRequest, ...grpc.CallOption) *types.QueryAccountResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -37,7 +45,6 @@ func (_m *EVMQueryClient) Account(ctx context.Context, in *types.QueryAccountReq } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryAccountRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -58,7 +65,15 @@ func (_m *EVMQueryClient) Balance(ctx context.Context, in *types.QueryBalanceReq _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for Balance") + } + var r0 *types.QueryBalanceResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryBalanceRequest, ...grpc.CallOption) (*types.QueryBalanceResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryBalanceRequest, ...grpc.CallOption) *types.QueryBalanceResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -67,7 +82,6 @@ func (_m *EVMQueryClient) Balance(ctx context.Context, in *types.QueryBalanceReq } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryBalanceRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -88,7 +102,15 @@ func (_m *EVMQueryClient) BaseFee(ctx context.Context, in *types.QueryBaseFeeReq _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for BaseFee") + } + var r0 *types.QueryBaseFeeResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryBaseFeeRequest, ...grpc.CallOption) (*types.QueryBaseFeeResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryBaseFeeRequest, ...grpc.CallOption) *types.QueryBaseFeeResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -97,7 +119,6 @@ func (_m *EVMQueryClient) BaseFee(ctx context.Context, in *types.QueryBaseFeeReq } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryBaseFeeRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -118,7 +139,15 @@ func (_m *EVMQueryClient) Code(ctx context.Context, in *types.QueryCodeRequest, _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for Code") + } + var r0 *types.QueryCodeResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryCodeRequest, ...grpc.CallOption) (*types.QueryCodeResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryCodeRequest, ...grpc.CallOption) *types.QueryCodeResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -127,7 +156,6 @@ func (_m *EVMQueryClient) Code(ctx context.Context, in *types.QueryCodeRequest, } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryCodeRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -148,7 +176,15 @@ func (_m *EVMQueryClient) CosmosAccount(ctx context.Context, in *types.QueryCosm _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for CosmosAccount") + } + var r0 *types.QueryCosmosAccountResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryCosmosAccountRequest, ...grpc.CallOption) (*types.QueryCosmosAccountResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryCosmosAccountRequest, ...grpc.CallOption) *types.QueryCosmosAccountResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -157,7 +193,6 @@ func (_m *EVMQueryClient) CosmosAccount(ctx context.Context, in *types.QueryCosm } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryCosmosAccountRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -178,7 +213,15 @@ func (_m *EVMQueryClient) EstimateGas(ctx context.Context, in *types.EthCallRequ _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for EstimateGas") + } + var r0 *types.EstimateGasResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.EthCallRequest, ...grpc.CallOption) (*types.EstimateGasResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.EthCallRequest, ...grpc.CallOption) *types.EstimateGasResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -187,7 +230,6 @@ func (_m *EVMQueryClient) EstimateGas(ctx context.Context, in *types.EthCallRequ } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.EthCallRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -197,6 +239,73 @@ func (_m *EVMQueryClient) EstimateGas(ctx context.Context, in *types.EthCallRequ return r0, r1 } +// GlobalMinGasPrice provides a mock function with given fields: ctx, in, opts +func (_m *EVMQueryClient) GlobalMinGasPrice(ctx context.Context, in *types.QueryGlobalMinGasPriceRequest, opts ...grpc.CallOption) (*types.QueryGlobalMinGasPriceResponse, error) { + _va := make([]interface{}, len(opts)) + for _i := range opts { + _va[_i] = opts[_i] + } + var _ca []interface{} + _ca = append(_ca, ctx, in) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) + + var r0 *types.QueryGlobalMinGasPriceResponse + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryGlobalMinGasPriceRequest, ...grpc.CallOption) *types.QueryGlobalMinGasPriceResponse); ok { + r0 = rf(ctx, in, opts...) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*types.QueryGlobalMinGasPriceResponse) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, *types.QueryGlobalMinGasPriceRequest, ...grpc.CallOption) error); ok { + r1 = rf(ctx, in, opts...) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// Config provides a mock function with given fields: ctx, in, opts +func (_m *EVMQueryClient) Config(ctx context.Context, in *types.QueryConfigRequest, opts ...grpc.CallOption) (*types.QueryConfigResponse, error) { + _va := make([]interface{}, len(opts)) + for _i := range opts { + _va[_i] = opts[_i] + } + var _ca []interface{} + _ca = append(_ca, ctx, in) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) + + if len(ret) == 0 { + panic("no return value specified for Config") + } + + var r0 *types.QueryConfigResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryConfigRequest, ...grpc.CallOption) (*types.QueryConfigResponse, error)); ok { + return rf(ctx, in, opts...) + } + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryConfigRequest, ...grpc.CallOption) *types.QueryConfigResponse); ok { + r0 = rf(ctx, in, opts...) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*types.QueryConfigResponse) + } + } + + if rf, ok := ret.Get(1).(func(context.Context, *types.QueryConfigRequest, ...grpc.CallOption) error); ok { + r1 = rf(ctx, in, opts...) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // EthCall provides a mock function with given fields: ctx, in, opts func (_m *EVMQueryClient) EthCall(ctx context.Context, in *types.EthCallRequest, opts ...grpc.CallOption) (*types.MsgEthereumTxResponse, error) { _va := make([]interface{}, len(opts)) @@ -208,7 +317,15 @@ func (_m *EVMQueryClient) EthCall(ctx context.Context, in *types.EthCallRequest, _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for EthCall") + } + var r0 *types.MsgEthereumTxResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.EthCallRequest, ...grpc.CallOption) (*types.MsgEthereumTxResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.EthCallRequest, ...grpc.CallOption) *types.MsgEthereumTxResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -217,7 +334,6 @@ func (_m *EVMQueryClient) EthCall(ctx context.Context, in *types.EthCallRequest, } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.EthCallRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -238,7 +354,15 @@ func (_m *EVMQueryClient) Params(ctx context.Context, in *types.QueryParamsReque _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for Params") + } + var r0 *types.QueryParamsResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryParamsRequest, ...grpc.CallOption) (*types.QueryParamsResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryParamsRequest, ...grpc.CallOption) *types.QueryParamsResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -247,7 +371,6 @@ func (_m *EVMQueryClient) Params(ctx context.Context, in *types.QueryParamsReque } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryParamsRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -268,7 +391,15 @@ func (_m *EVMQueryClient) Storage(ctx context.Context, in *types.QueryStorageReq _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for Storage") + } + var r0 *types.QueryStorageResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryStorageRequest, ...grpc.CallOption) (*types.QueryStorageResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryStorageRequest, ...grpc.CallOption) *types.QueryStorageResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -277,7 +408,6 @@ func (_m *EVMQueryClient) Storage(ctx context.Context, in *types.QueryStorageReq } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryStorageRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -298,7 +428,15 @@ func (_m *EVMQueryClient) TraceBlock(ctx context.Context, in *types.QueryTraceBl _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for TraceBlock") + } + var r0 *types.QueryTraceBlockResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryTraceBlockRequest, ...grpc.CallOption) (*types.QueryTraceBlockResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryTraceBlockRequest, ...grpc.CallOption) *types.QueryTraceBlockResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -307,7 +445,6 @@ func (_m *EVMQueryClient) TraceBlock(ctx context.Context, in *types.QueryTraceBl } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryTraceBlockRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -328,7 +465,15 @@ func (_m *EVMQueryClient) TraceTx(ctx context.Context, in *types.QueryTraceTxReq _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for TraceTx") + } + var r0 *types.QueryTraceTxResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryTraceTxRequest, ...grpc.CallOption) (*types.QueryTraceTxResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryTraceTxRequest, ...grpc.CallOption) *types.QueryTraceTxResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -337,7 +482,6 @@ func (_m *EVMQueryClient) TraceTx(ctx context.Context, in *types.QueryTraceTxReq } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryTraceTxRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -358,7 +502,15 @@ func (_m *EVMQueryClient) ValidatorAccount(ctx context.Context, in *types.QueryV _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for ValidatorAccount") + } + var r0 *types.QueryValidatorAccountResponse + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, *types.QueryValidatorAccountRequest, ...grpc.CallOption) (*types.QueryValidatorAccountResponse, error)); ok { + return rf(ctx, in, opts...) + } if rf, ok := ret.Get(0).(func(context.Context, *types.QueryValidatorAccountRequest, ...grpc.CallOption) *types.QueryValidatorAccountResponse); ok { r0 = rf(ctx, in, opts...) } else { @@ -367,7 +519,6 @@ func (_m *EVMQueryClient) ValidatorAccount(ctx context.Context, in *types.QueryV } } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, *types.QueryValidatorAccountRequest, ...grpc.CallOption) error); ok { r1 = rf(ctx, in, opts...) } else { @@ -377,13 +528,13 @@ func (_m *EVMQueryClient) ValidatorAccount(ctx context.Context, in *types.QueryV return r0, r1 } -type mockConstructorTestingTNewEVMQueryClient interface { +// NewEVMQueryClient creates a new instance of EVMQueryClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewEVMQueryClient(t interface { mock.TestingT Cleanup(func()) -} - -// NewEVMQueryClient creates a new instance of EVMQueryClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. -func NewEVMQueryClient(t mockConstructorTestingTNewEVMQueryClient) *EVMQueryClient { +}, +) *EVMQueryClient { mock := &EVMQueryClient{} mock.Mock.Test(t) diff --git a/rpc/backend/node_info.go b/rpc/backend/node_info.go index 1785b890..b237c00b 100644 --- a/rpc/backend/node_info.go +++ b/rpc/backend/node_info.go @@ -8,8 +8,6 @@ import ( "math/big" "time" - "github.com/evmos/os/testutil/constants" - errorsmod "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" cmttypes "github.com/cometbft/cometbft/types" @@ -27,6 +25,7 @@ import ( "github.com/evmos/os/crypto/ethsecp256k1" rpctypes "github.com/evmos/os/rpc/types" "github.com/evmos/os/server/config" + "github.com/evmos/os/testutil/constants" evmtypes "github.com/evmos/os/x/evm/types" ) @@ -269,28 +268,31 @@ func (b *Backend) SetGasPrice(gasPrice hexutil.Big) bool { b.logger.Debug("could not get the server config", "error", err.Error()) return false } + c := b.GenerateMinGasCoin(gasPrice, appConf) + + appConf.SetMinGasPrices(sdk.DecCoins{c}) + sdkconfig.WriteConfigFile(b.clientCtx.Viper.ConfigFileUsed(), appConf) + b.logger.Info("Your configuration file was modified. Please RESTART your node.", "gas-price", c.String()) + return true +} +func (b *Backend) GenerateMinGasCoin(gasPrice hexutil.Big, appConf config.Config) sdk.DecCoin { var unit string minGasPrices := appConf.GetMinGasPrices() // fetch the base denom from the sdk Config in case it's not currently defined on the node config if len(minGasPrices) == 0 || minGasPrices.Empty() { - var err error - unit, err = sdk.GetBaseDenom() - if err != nil { - b.logger.Debug("could not get the denom of smallest unit registered", "error", err.Error()) - return false - } + unit = evmtypes.GetEVMCoinDenom() } else { unit = minGasPrices[0].Denom } - c := sdk.NewDecCoin(unit, sdkmath.NewIntFromBigInt(gasPrice.ToInt())) + // The provided gasPrice has 18 decimals. + // We need to update to the denom's real precision + scaledAmt := evmtypes.ConvertBigIntFrom18DecimalsToLegacyDec(gasPrice.ToInt()) + c := sdk.DecCoin{Denom: unit, Amount: scaledAmt} - appConf.SetMinGasPrices(sdk.DecCoins{c}) - sdkconfig.WriteConfigFile(b.clientCtx.Viper.ConfigFileUsed(), appConf) - b.logger.Info("Your configuration file was modified. Please RESTART your node.", "gas-price", c.String()) - return true + return c } // UnprotectedAllowed returns the node configuration value for allowing @@ -336,18 +338,14 @@ func (b *Backend) RPCBlockRangeCap() int32 { // RPCMinGasPrice returns the minimum gas price for a transaction obtained from // the node config. If set value is 0, it will default to 20. - -func (b *Backend) RPCMinGasPrice() int64 { - evmParams, err := b.queryClient.Params(b.ctx, &evmtypes.QueryParamsRequest{}) - if err != nil { - return constants.DefaultGasPrice - } +func (b *Backend) RPCMinGasPrice() *big.Int { + baseDenom := evmtypes.GetEVMCoinDenom() minGasPrice := b.cfg.GetMinGasPrices() - amt := minGasPrice.AmountOf(evmParams.Params.EvmDenom).TruncateInt64() - if amt == 0 { - return constants.DefaultGasPrice + amt := minGasPrice.AmountOf(baseDenom) + if amt.IsNil() || amt.IsZero() { + return big.NewInt(constants.DefaultGasPrice) } - return amt + return evmtypes.ConvertAmountTo18DecimalsLegacy(amt).TruncateInt().BigInt() } diff --git a/rpc/backend/node_info_test.go b/rpc/backend/node_info_test.go index b0b5182c..32e312fa 100644 --- a/rpc/backend/node_info_test.go +++ b/rpc/backend/node_info_test.go @@ -4,7 +4,9 @@ import ( "fmt" "math/big" + "github.com/evmos/os/server/config" "github.com/evmos/os/testutil/constants" + evmtypes "github.com/evmos/os/x/evm/types" "cosmossdk.io/math" tmrpcclient "github.com/cometbft/cometbft/rpc/client" @@ -22,25 +24,19 @@ func (suite *BackendTestSuite) TestRPCMinGasPrice() { testCases := []struct { name string registerMock func() - expMinGasPrice int64 + expMinGasPrice *big.Int expPass bool }{ { "pass - default gas price", - func() { - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) - RegisterParamsWithoutHeaderError(queryClient, 1) - }, - constants.DefaultGasPrice, + func() {}, + big.NewInt(constants.DefaultGasPrice), true, }, { "pass - min gas price is 0", - func() { - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) - RegisterParamsWithoutHeader(queryClient, 1) - }, - constants.DefaultGasPrice, + func() {}, + big.NewInt(constants.DefaultGasPrice), true, }, } @@ -60,39 +56,44 @@ func (suite *BackendTestSuite) TestRPCMinGasPrice() { } } -func (suite *BackendTestSuite) TestSetGasPrice() { +func (suite *BackendTestSuite) TestGenerateMinGasCoin() { defaultGasPrice := (*hexutil.Big)(big.NewInt(1)) testCases := []struct { - name string - registerMock func() - gasPrice hexutil.Big - expOutput bool + name string + gasPrice hexutil.Big + minGas sdk.DecCoins + expectedOutput sdk.DecCoin }{ { - "pass - cannot get server config", - func() { - suite.backend.clientCtx.Viper = viper.New() - }, + "pass - empty min gas Coins (default denom)", *defaultGasPrice, - false, + sdk.DecCoins{}, + sdk.DecCoin{ + Denom: evmtypes.GetEVMCoinDenom(), + Amount: math.LegacyNewDecFromBigInt(defaultGasPrice.ToInt()), + }, }, { - "pass - cannot find coin denom", - func() { - suite.backend.clientCtx.Viper = viper.New() - suite.backend.clientCtx.Viper.Set("telemetry.global-labels", []interface{}{}) - }, + "pass - different min gas Coin", *defaultGasPrice, - false, + sdk.DecCoins{sdk.NewDecCoin("test", math.NewInt(1))}, + sdk.DecCoin{ + Denom: "test", + Amount: math.LegacyNewDecFromBigInt(defaultGasPrice.ToInt()), + }, }, } for _, tc := range testCases { suite.Run(fmt.Sprintf("case %s", tc.name), func() { suite.SetupTest() // reset test and queries - tc.registerMock() - output := suite.backend.SetGasPrice(tc.gasPrice) - suite.Require().Equal(tc.expOutput, output) + suite.backend.clientCtx.Viper = viper.New() + + appConf := config.DefaultConfig() + appConf.SetMinGasPrices(tc.minGas) + + output := suite.backend.GenerateMinGasCoin(tc.gasPrice, *appConf) + suite.Require().Equal(tc.expectedOutput, output) }) } } diff --git a/rpc/backend/sign_tx.go b/rpc/backend/sign_tx.go index dbe583f3..897fa143 100644 --- a/rpc/backend/sign_tx.go +++ b/rpc/backend/sign_tx.go @@ -68,15 +68,10 @@ func (b *Backend) SendTransaction(args evmtypes.TransactionArgs) (common.Hash, e return common.Hash{}, err } - // Query params to use the EVM denomination - res, err := b.queryClient.QueryClient.Params(b.ctx, &evmtypes.QueryParamsRequest{}) - if err != nil { - b.logger.Error("failed to query evm params", "error", err.Error()) - return common.Hash{}, err - } + baseDenom := evmtypes.GetEVMCoinDenom() // Assemble transaction from fields - tx, err := msg.BuildTx(b.clientCtx.TxConfig.NewTxBuilder(), res.Params.EvmDenom) + tx, err := msg.BuildTx(b.clientCtx.TxConfig.NewTxBuilder(), baseDenom) if err != nil { b.logger.Error("build cosmos tx failed", "error", err.Error()) return common.Hash{}, err diff --git a/rpc/backend/sign_tx_test.go b/rpc/backend/sign_tx_test.go index 229de568..0393ae51 100644 --- a/rpc/backend/sign_tx_test.go +++ b/rpc/backend/sign_tx_test.go @@ -4,7 +4,6 @@ import ( "fmt" signingtypes "github.com/cosmos/cosmos-sdk/types/tx/signing" - "github.com/evmos/os/testutil/constants" "cosmossdk.io/math" "github.com/cosmos/cosmos-sdk/crypto" @@ -85,7 +84,6 @@ func (suite *BackendTestSuite) TestSendTransaction() { _, err = RegisterBlockResults(client, 1) suite.Require().NoError(err) RegisterBaseFee(queryClient, baseFee) - RegisterParamsWithoutHeader(queryClient, 1) }, evmtypes.TransactionArgs{ From: &from, @@ -126,8 +124,7 @@ func (suite *BackendTestSuite) TestSendTransaction() { if tc.expPass { // Sign the transaction and get the hash - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) - RegisterParamsWithoutHeader(queryClient, 1) + ethSigner := ethtypes.LatestSigner(suite.backend.ChainConfig()) msg := callArgsDefault.ToTransaction() err := msg.Sign(ethSigner, suite.backend.clientCtx.Keyring) @@ -254,12 +251,12 @@ func broadcastTx(suite *BackendTestSuite, priv *ethsecp256k1.PrivKey, baseFee ma _, err = RegisterBlockResults(client, 1) suite.Require().NoError(err) RegisterBaseFee(queryClient, baseFee) - RegisterParamsWithoutHeader(queryClient, 1) ethSigner := ethtypes.LatestSigner(suite.backend.ChainConfig()) msg := callArgsDefault.ToTransaction() err = msg.Sign(ethSigner, suite.backend.clientCtx.Keyring) suite.Require().NoError(err) - tx, _ := msg.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), constants.ExampleAttoDenom) + baseDenom := evmtypes.GetEVMCoinDenom() + tx, _ := msg.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), baseDenom) txEncoder := suite.backend.clientCtx.TxConfig.TxEncoder() txBytes, _ = txEncoder(tx) return client, txBytes diff --git a/rpc/backend/tracing_test.go b/rpc/backend/tracing_test.go index 27c1051d..5af13749 100644 --- a/rpc/backend/tracing_test.go +++ b/rpc/backend/tracing_test.go @@ -3,8 +3,6 @@ package backend import ( "fmt" - "github.com/evmos/os/testutil/constants" - "cosmossdk.io/log" abci "github.com/cometbft/cometbft/abci/types" tmrpctypes "github.com/cometbft/cometbft/rpc/core/types" @@ -28,10 +26,6 @@ func (suite *BackendTestSuite) TestTraceTransaction() { priv, _ := ethsecp256k1.GenerateKey() from := common.BytesToAddress(priv.PubKey().Address().Bytes()) - - queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) - RegisterParamsWithoutHeader(queryClient, 1) - armor := crypto.EncryptArmorPrivKey(priv, "", "eth_secp256k1") _ = suite.backend.clientCtx.Keyring.ImportPrivKey("test_key", armor, "") @@ -42,13 +36,15 @@ func (suite *BackendTestSuite) TestTraceTransaction() { msgEthereumTx.From = from.String() _ = msgEthereumTx.Sign(ethSigner, suite.signer) - tx, _ := msgEthereumTx.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), constants.ExampleAttoDenom) + baseDenom := evmtypes.GetEVMCoinDenom() + + tx, _ := msgEthereumTx.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), baseDenom) txBz, _ := txEncoder(tx) msgEthereumTx2.From = from.String() _ = msgEthereumTx2.Sign(ethSigner, suite.signer) - tx2, _ := msgEthereumTx.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), constants.ExampleAttoDenom) + tx2, _ := msgEthereumTx.BuildTx(suite.backend.clientCtx.TxConfig.NewTxBuilder(), baseDenom) txBz2, _ := txEncoder(tx2) testCases := []struct { diff --git a/rpc/backend/tx_info.go b/rpc/backend/tx_info.go index 3339f199..60d8d588 100644 --- a/rpc/backend/tx_info.go +++ b/rpc/backend/tx_info.go @@ -47,7 +47,7 @@ func (b *Backend) GetTransactionByHash(txHash common.Hash) (*rpctypes.RPCTransac return nil, errors.New("invalid ethereum tx") } - blockRes, err := b.TendermintBlockResultByNumber(&block.Block.Height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, &block.Block.Height) if err != nil { b.logger.Debug("block result not found", "height", block.Block.Height, "error", err.Error()) return nil, nil @@ -148,16 +148,19 @@ func (b *Backend) GetTransactionReceipt(hash common.Hash) (map[string]interface{ b.logger.Debug("tx not found", "hash", hexTx, "error", err.Error()) return nil, nil } + resBlock, err := b.TendermintBlockByNumber(rpctypes.BlockNumber(res.Height)) if err != nil { b.logger.Debug("block not found", "height", res.Height, "error", err.Error()) return nil, nil } + tx, err := b.clientCtx.TxConfig.TxDecoder()(resBlock.Block.Txs[res.TxIndex]) if err != nil { b.logger.Debug("decoding failed", "error", err.Error()) return nil, fmt.Errorf("failed to decode tx: %w", err) } + ethMsg := tx.GetMsgs()[res.MsgIndex].(*evmtypes.MsgEthereumTx) txData, err := evmtypes.UnpackTxData(ethMsg.Data) @@ -167,14 +170,16 @@ func (b *Backend) GetTransactionReceipt(hash common.Hash) (map[string]interface{ } cumulativeGasUsed := uint64(0) - blockRes, err := b.TendermintBlockResultByNumber(&res.Height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, &res.Height) if err != nil { b.logger.Debug("failed to retrieve block results", "height", res.Height, "error", err.Error()) return nil, nil } + for _, txResult := range blockRes.TxsResults[0:res.TxIndex] { cumulativeGasUsed += uint64(txResult.GasUsed) // #nosec G115 -- checked for int overflow already } + cumulativeGasUsed += res.CumulativeGasUsed var status hexutil.Uint @@ -183,6 +188,7 @@ func (b *Backend) GetTransactionReceipt(hash common.Hash) (map[string]interface{ } else { status = hexutil.Uint(ethtypes.ReceiptStatusSuccessful) } + chainID, err := b.ChainID() if err != nil { return nil, err @@ -262,6 +268,32 @@ func (b *Backend) GetTransactionReceipt(hash common.Hash) (map[string]interface{ return receipt, nil } +// GetTransactionLogs returns the transaction logs identified by hash. +func (b *Backend) GetTransactionLogs(hash common.Hash) ([]*ethtypes.Log, error) { + hexTx := hash.Hex() + + res, err := b.GetTxByEthHash(hash) + if err != nil { + b.logger.Debug("tx not found", "hash", hexTx, "error", err.Error()) + return nil, nil + } + + if res.Failed { + // failed, return empty logs + return nil, nil + } + + resBlockResult, err := b.rpcClient.BlockResults(b.ctx, &res.Height) + if err != nil { + b.logger.Debug("block result not found", "number", res.Height, "error", err.Error()) + return nil, nil + } + + // parse tx logs from events + index := int(res.MsgIndex) // #nosec G701 + return TxLogsFromEvents(resBlockResult.TxsResults[res.TxIndex].Events, index) +} + // GetTransactionByBlockHashAndIndex returns the transaction identified by hash and index. func (b *Backend) GetTransactionByBlockHashAndIndex(hash common.Hash, idx hexutil.Uint) (*rpctypes.RPCTransaction, error) { b.logger.Debug("eth_getTransactionByBlockHashAndIndex", "hash", hash.Hex(), "index", idx) @@ -370,7 +402,7 @@ func (b *Backend) queryTendermintTxIndexer(query string, txGetter func(*rpctypes // GetTransactionByBlockAndIndex is the common code shared by `GetTransactionByBlockNumberAndIndex` and `GetTransactionByBlockHashAndIndex`. func (b *Backend) GetTransactionByBlockAndIndex(block *tmrpctypes.ResultBlock, idx hexutil.Uint) (*rpctypes.RPCTransaction, error) { - blockRes, err := b.TendermintBlockResultByNumber(&block.Block.Height) + blockRes, err := b.rpcClient.BlockResults(b.ctx, &block.Block.Height) if err != nil { return nil, nil } diff --git a/rpc/backend/tx_info_test.go b/rpc/backend/tx_info_test.go index 6bb56621..02892a94 100644 --- a/rpc/backend/tx_info_test.go +++ b/rpc/backend/tx_info_test.go @@ -564,7 +564,6 @@ func (suite *BackendTestSuite) TestGetTransactionReceipt() { queryClient := suite.backend.queryClient.QueryClient.(*mocks.EVMQueryClient) client := suite.backend.clientCtx.Client.(*mocks.Client) RegisterParams(queryClient, &header, 1) - RegisterParamsWithoutHeader(queryClient, 1) _, err := RegisterBlock(client, 1, txBz) suite.Require().NoError(err) _, err = RegisterBlockResults(client, 1) diff --git a/rpc/namespaces/ethereum/eth/api.go b/rpc/namespaces/ethereum/eth/api.go index 895350a2..b88a9fb3 100644 --- a/rpc/namespaces/ethereum/eth/api.go +++ b/rpc/namespaces/ethereum/eth/api.go @@ -412,27 +412,7 @@ func (e *PublicAPI) Sign(address common.Address, data hexutil.Bytes) (hexutil.By func (e *PublicAPI) GetTransactionLogs(txHash common.Hash) ([]*ethtypes.Log, error) { e.logger.Debug("eth_getTransactionLogs", "hash", txHash) - hexTx := txHash.Hex() - res, err := e.backend.GetTxByEthHash(txHash) - if err != nil { - e.logger.Debug("tx not found", "hash", hexTx, "error", err.Error()) - return nil, nil - } - - if res.Failed { - // failed, return empty logs - return nil, nil - } - - resBlockResult, err := e.backend.TendermintBlockResultByNumber(&res.Height) - if err != nil { - e.logger.Debug("block result not found", "number", res.Height, "error", err.Error()) - return nil, nil - } - - // parse tx logs from events - index := int(res.MsgIndex) // #nosec G115 - return backend.TxLogsFromEvents(resBlockResult.TxsResults[res.TxIndex].Events, index) + return e.backend.GetTransactionLogs(txHash) } // SignTypedData signs EIP-712 conformant typed data @@ -486,6 +466,13 @@ func (e *PublicAPI) GetPendingTransactions() ([]*rpctypes.RPCTransaction, error) return nil, err } + chainIDHex, err := e.backend.ChainID() + if err != nil { + return nil, err + } + + chainID := chainIDHex.ToInt() + result := make([]*rpctypes.RPCTransaction, 0, len(txs)) for _, tx := range txs { for _, msg := range (*tx).GetMsgs() { @@ -501,7 +488,7 @@ func (e *PublicAPI) GetPendingTransactions() ([]*rpctypes.RPCTransaction, error) uint64(0), uint64(0), nil, - e.backend.ChainConfig().ChainID, + chainID, ) if err != nil { return nil, err diff --git a/rpc/types/utils.go b/rpc/types/utils.go index 16a2cafc..976b1a08 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -10,6 +10,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdkmath "cosmossdk.io/math" abci "github.com/cometbft/cometbft/abci/types" cmtrpcclient "github.com/cometbft/cometbft/rpc/client" cmttypes "github.com/cometbft/cometbft/types" @@ -21,7 +22,6 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/params" evmtypes "github.com/evmos/os/x/evm/types" - feemarkettypes "github.com/evmos/os/x/feemarket/types" ) // ExceedBlockGasLimitError defines the error message when tx execution exceeds the block gas limit. @@ -165,7 +165,11 @@ func NewTransactionFromMsg( // NewTransactionFromData returns a transaction that will serialize to the RPC // representation, with the given location metadata set (if available). func NewRPCTransaction( - tx *ethtypes.Transaction, blockHash common.Hash, blockNumber, index uint64, baseFee *big.Int, + tx *ethtypes.Transaction, + blockHash common.Hash, + blockNumber, + index uint64, + baseFee, chainID *big.Int, ) (*RPCTransaction, error) { // Determine the signer. For replay-protected transactions, use the most permissive @@ -220,21 +224,22 @@ func NewRPCTransaction( result.GasPrice = (*hexutil.Big)(tx.GasFeeCap()) } } + return result, nil } // BaseFeeFromEvents parses the feemarket basefee from cosmos events func BaseFeeFromEvents(events []abci.Event) *big.Int { for _, event := range events { - if event.Type != feemarkettypes.EventTypeFeeMarket { + if event.Type != evmtypes.EventTypeFeeMarket { continue } for _, attr := range event.Attributes { - if attr.Key == feemarkettypes.AttributeKeyBaseFee { - result, success := new(big.Int).SetString(attr.Value, 10) + if attr.Key == evmtypes.AttributeKeyBaseFee { + result, success := sdkmath.NewIntFromString(attr.Value) if success { - return result + return result.BigInt() } return nil @@ -245,10 +250,10 @@ func BaseFeeFromEvents(events []abci.Event) *big.Int { } // CheckTxFee is an internal function used to check whether the fee of -// the given transaction is _reasonable_(under the cap). -func CheckTxFee(gasPrice *big.Int, gas uint64, cap float64) error { +// the given transaction is _reasonable_(under the minimum cap). +func CheckTxFee(gasPrice *big.Int, gas uint64, minCap float64) error { // Short circuit if there is no cap for transaction fee at all. - if cap == 0 { + if minCap == 0 { return nil } totalfee := new(big.Float).SetInt(new(big.Int).Mul(gasPrice, new(big.Int).SetUint64(gas))) @@ -258,8 +263,8 @@ func CheckTxFee(gasPrice *big.Int, gas uint64, cap float64) error { feeEth := new(big.Float).Quo(totalfee, oneToken) // no need to check error from parsing feeFloat, _ := feeEth.Float64() - if feeFloat > cap { - return fmt.Errorf("tx fee (%.2f ether) exceeds the configured cap (%.2f ether)", feeFloat, cap) + if feeFloat > minCap { + return fmt.Errorf("tx fee (%.2f ether) exceeds the configured cap (%.2f ether)", feeFloat, minCap) } return nil } diff --git a/scripts/compile_smart_contracts/compile_smart_contracts.py b/scripts/compile_smart_contracts/compile_smart_contracts.py index 82923215..14d6af5a 100644 --- a/scripts/compile_smart_contracts/compile_smart_contracts.py +++ b/scripts/compile_smart_contracts/compile_smart_contracts.py @@ -278,6 +278,8 @@ def is_relative_target(path: Path) -> bool: return path == RELATIVE_TARGET +# TODO: in the abi, the sourceName field refere to the path of the temporary +# directory for the compilation. It should be updated. def compile_files(repo_path: Path, added_contract: Union[str, None] = None): """ This function compiles the Solidity contracts in the repository diff --git a/server/config/migration/migration.go b/server/config/migration/migration.go index e0150998..52ae1890 100644 --- a/server/config/migration/migration.go +++ b/server/config/migration/migration.go @@ -39,7 +39,6 @@ func PlanBuilder(from *tomledit.Document, _ string) transform.Plan { diffs := confix.DiffKeys(from, target) for _, diff := range diffs { - diff := diff kv := diff.KV var step transform.Step diff --git a/server/indexer_cmd.go b/server/indexer_cmd.go index b9698f4e..dcd40db7 100644 --- a/server/indexer_cmd.go +++ b/server/indexer_cmd.go @@ -15,6 +15,7 @@ import ( "github.com/spf13/cobra" ) +// NewIndexTxCmd creates a new Cobra command to index historical Ethereum transactions. func NewIndexTxCmd() *cobra.Command { cmd := &cobra.Command{ Use: "index-eth-tx [backward|forward]", diff --git a/server/start.go b/server/start.go index 673e39f8..d8a26ac7 100644 --- a/server/start.go +++ b/server/start.go @@ -213,6 +213,10 @@ which accepts a path for the resulting pprof file. return cmd } +// startStandAlone starts an ABCI server in stand-alone mode. +// Parameters: +// - svrCtx: The context object that holds server configurations, logger, and other stateful information. +// - opts: Options for starting the server, including functions for creating the application and opening the database. func startStandAlone(svrCtx *server.Context, opts StartOptions) error { addr := svrCtx.Viper.GetString(srvflags.Address) transport := svrCtx.Viper.GetString(srvflags.Transport) @@ -492,6 +496,9 @@ func OpenIndexerDB(rootDir string, backendType dbm.BackendType) (dbm.DB, error) return dbm.NewDB("evmindexer", backendType, dataDir) } +// openTraceWriter opens a trace writer if a trace store file is specified. +// Parameters: +// - traceWriterFile: The path to the trace store file. If this is an empty string, no file will be opened. func openTraceWriter(traceWriterFile string) (w io.Writer, err error) { if traceWriterFile == "" { return @@ -520,6 +527,7 @@ func getCtx(svrCtx *server.Context, block bool) (*errgroup.Group, context.Contex return g, ctx } +// startGrpcServer starts a gRPC server based on the provided configuration. func startGrpcServer( ctx context.Context, svrCtx *server.Context, @@ -578,6 +586,16 @@ func startGrpcServer( return grpcSrv, clientCtx, nil } +// startAPIServer starts an API server based on the provided configuration and application context. +// Parameters: +// - ctx: The context used for managing the server's lifecycle, allowing for graceful shutdown. +// - svrCtx: The server context containing configuration, logger, and other stateful components. +// - clientCtx: The client context, which provides necessary information for API operations. +// - g: An errgroup.Group for managing goroutines and handling errors concurrently. +// - svrCfg: The server configuration that specifies whether the API server is enabled and other settings. +// - app: The application instance that registers API routes. +// - grpcSrv: A pointer to the gRPC server, which may be used by the API server. +// - metrics: A telemetry metrics instance for monitoring API server performance. func startAPIServer( ctx context.Context, svrCtx *server.Context, @@ -605,6 +623,15 @@ func startAPIServer( return apiSrv } +// startJSONRPCServer starts a JSON-RPC server based on the provided configuration. +// Parameters: +// - svrCtx: The server context containing configuration, logger, and stateful components. +// - clientCtx: The client context, which may be updated with additional chain information. +// - g: An errgroup.Group to manage concurrent goroutines and error handling. +// - config: The server configuration that specifies whether the JSON-RPC server is enabled and other settings. +// - genDocProvider: A function that provides the Genesis document, used to retrieve the chain ID. +// - cmtRPCAddr: The address of the CometBFT RPC server for WebSocket connections. +// - idxer: The EVM transaction indexer for indexing transactions. func startJSONRPCServer( svrCtx *server.Context, clientCtx client.Context, diff --git a/server/util.go b/server/util.go index 7c241b00..6642e50e 100644 --- a/server/util.go +++ b/server/util.go @@ -61,6 +61,11 @@ func AddCommands( ) } +// ConnectTmWS connects to a Tendermint WebSocket (WS) server. +// Parameters: +// - tmRPCAddr: The RPC address of the Tendermint server. +// - tmEndpoint: The WebSocket endpoint on the Tendermint server. +// - logger: A logger instance used to log debug and error messages. func ConnectTmWS(tmRPCAddr, tmEndpoint string, logger log.Logger) *rpcclient.WSClient { tmWsClient, err := rpcclient.NewWS(tmRPCAddr, tmEndpoint, rpcclient.MaxReconnectAttempts(256), @@ -89,6 +94,12 @@ func ConnectTmWS(tmRPCAddr, tmEndpoint string, logger log.Logger) *rpcclient.WSC return tmWsClient } +// MountGRPCWebServices mounts gRPC-Web services on specific HTTP POST routes. +// Parameters: +// - router: The HTTP router instance to mount the routes on (using mux.Router). +// - grpcWeb: The wrapped gRPC-Web server that will handle incoming gRPC-Web and WebSocket requests. +// - grpcResources: A list of resource endpoints (URLs) that should be mounted for gRPC-Web POST requests. +// - logger: A logger instance used to log information about the mounted resources. func MountGRPCWebServices( router *mux.Router, grpcWeb *grpcweb.WrappedGrpcServer, diff --git a/tests/integration/ledger/ledger_test.go b/tests/integration/ledger/ledger_test.go index e306921a..3433f265 100644 --- a/tests/integration/ledger/ledger_test.go +++ b/tests/integration/ledger/ledger_test.go @@ -46,6 +46,7 @@ var _ = Describe("Ledger CLI and keyring functionality: ", func() { cmd *cobra.Command krHome string keyRecord *keyring.Record + baseDenom string ) ledgerKey := "ledger_key" @@ -66,6 +67,10 @@ var _ = Describe("Ledger CLI and keyring functionality: ", func() { mocks.MClose(s.ledger) mocks.MGetAddressPubKeySECP256K1(s.ledger, s.accAddr, s.pubKey) + + var err error + baseDenom, err = sdk.GetBaseDenom() + s.Require().NoError(err) }) Context("with default algo", func() { It("should use eth_secp256k1 by default and pass", func() { @@ -173,7 +178,7 @@ var _ = Describe("Ledger CLI and keyring functionality: ", func() { s.app.BankKeeper, s.accAddr, sdk.NewCoins( - sdk.NewCoin("aevmos", math.NewInt(100000000000000)), + sdk.NewCoin(baseDenom, math.NewInt(100000000000000)), ), ) s.Require().NoError(err) @@ -198,7 +203,7 @@ var _ = Describe("Ledger CLI and keyring functionality: ", func() { cmd.SetArgs([]string{ ledgerKey, receiverAccAddr.String(), - sdk.NewCoin("aevmos", math.NewInt(1000)).String(), + sdk.NewCoin(baseDenom, math.NewInt(1000)).String(), s.FormatFlag(flags.FlagUseLedger), s.FormatFlag(flags.FlagSkipConfirmation), }) @@ -216,7 +221,7 @@ var _ = Describe("Ledger CLI and keyring functionality: ", func() { cmd.SetArgs([]string{ ledgerKey, receiverAccAddr.String(), - sdk.NewCoin("aevmos", math.NewInt(1000)).String(), + sdk.NewCoin(baseDenom, math.NewInt(1000)).String(), s.FormatFlag(flags.FlagUseLedger), s.FormatFlag(flags.FlagSkipConfirmation), }) diff --git a/tests/solidity/init-node.sh b/tests/solidity/init-node.sh index a3b56cbf..e7ed0fff 100755 --- a/tests/solidity/init-node.sh +++ b/tests/solidity/init-node.sh @@ -2,7 +2,7 @@ # TODO: remove this script and just use the local node script for it, add flag to start node in given directory -CHAINID="${CHAIN_ID:-evmos_9000-1}" +CHAINID="${CHAIN_ID:-evmos_9002-1}" MONIKER="localtestnet" KEYRING="test" # remember to change to other types of keyring like 'file' in-case exposing to outside world, otherwise your balance will be wiped quickly. The keyring test does not require private key to steal tokens from you KEYALGO="eth_secp256k1" #gitleaks:allow diff --git a/tests/solidity/suites/precompiles/hardhat.config.js b/tests/solidity/suites/precompiles/hardhat.config.js index 8d99f727..cd19d9ed 100644 --- a/tests/solidity/suites/precompiles/hardhat.config.js +++ b/tests/solidity/suites/precompiles/hardhat.config.js @@ -1,18 +1,26 @@ -require('@nomicfoundation/hardhat-toolbox') +require("@nomicfoundation/hardhat-toolbox"); /** @type import('hardhat/config').HardhatUserConfig */ module.exports = { solidity: { - compilers: [{ version: '0.8.18' }] + compilers: [ + { + version: "0.8.18", + }, + // This version is required to compile the werc9 contract. + { + version: "0.4.22", + }, + ], }, networks: { evmos: { - url: 'http://127.0.0.1:8545', - chainId: 9000, + url: "http://127.0.0.1:8545", + chainId: 9002, accounts: [ - '0x88CBEAD91AEE890D27BF06E003ADE3D4E952427E88F88D31D61D3EF5E5D54305', - '0x3B7955D25189C99A7468192FCBC6429205C158834053EBE3F78F4512AB432DB9' - ] - } - } -} + "0x88CBEAD91AEE890D27BF06E003ADE3D4E952427E88F88D31D61D3EF5E5D54305", + "0x3B7955D25189C99A7468192FCBC6429205C158834053EBE3F78F4512AB432DB9", + ], + }, + }, +}; diff --git a/tests/solidity/yarn.lock b/tests/solidity/yarn.lock index a5c04e98..c0feef80 100644 --- a/tests/solidity/yarn.lock +++ b/tests/solidity/yarn.lock @@ -4168,9 +4168,9 @@ cross-fetch@^3.1.4: node-fetch "^2.6.12" cross-spawn@^6.0.5: - version "6.0.5" - resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" - integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== + version "6.0.6" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.6.tgz#30d0efa0712ddb7eb5a76e1e8721bffafa6b5d57" + integrity sha512-VqCUuhcd1iB+dsv8gxPttb5iZh/D0iubSP21g36KXdEuf6I5JiioesUVjpCdHV9MZRUfVFlvwtIUyPfxo5trtw== dependencies: nice-try "^1.0.4" path-key "^2.0.1" diff --git a/testutil/constants/constants.go b/testutil/constants/constants.go index 7f3dc2a4..26c67d80 100644 --- a/testutil/constants/constants.go +++ b/testutil/constants/constants.go @@ -3,7 +3,11 @@ package constants -import "fmt" +import ( + "fmt" + + evmtypes "github.com/evmos/os/x/evm/types" +) const ( // DefaultGasPrice is used in testing as the default to use for transactions @@ -12,6 +16,12 @@ const ( // ExampleAttoDenom provides an example denom for use in tests ExampleAttoDenom = "aevmos" + // ExampleMicroDenom provides an example denom for use in tests + ExampleMicroDenom = "uevmos" + + // ExampleDisplayDenom provides an example display denom for use in tests + ExampleDisplayDenom = "evmos" + // ExampleBech32Prefix provides an example Bech32 prefix for use in tests ExampleBech32Prefix = "evmos" @@ -30,4 +40,25 @@ var ( // ExampleChainID provides a chain ID that can be used in tests ExampleChainID = ExampleChainIDPrefix + "-1" + + // SixDecimalsChainID provides a chain ID which is being set up with 6 decimals + SixDecimalsChainID = "ossix_9002-2" + + // ExampleChainCoinInfo provides the coin info for the example chain + // + // It is a map of the chain id and its corresponding EvmCoinInfo + // that allows initializing the app with different coin info based on the + // chain id + ExampleChainCoinInfo = map[string]evmtypes.EvmCoinInfo{ + ExampleChainID: { + Denom: ExampleAttoDenom, + DisplayDenom: ExampleDisplayDenom, + Decimals: evmtypes.EighteenDecimals, + }, + SixDecimalsChainID: { + Denom: ExampleMicroDenom, + DisplayDenom: ExampleDisplayDenom, + Decimals: evmtypes.SixDecimals, + }, + } ) diff --git a/testutil/fund.go b/testutil/fund.go index 5d3c53b4..e1d1a0a0 100644 --- a/testutil/fund.go +++ b/testutil/fund.go @@ -8,7 +8,6 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" - "github.com/evmos/os/testutil/constants" ) // FundAccount is a utility function that funds an account by minting and @@ -24,9 +23,15 @@ func FundAccount(ctx sdk.Context, bankKeeper bankkeeper.Keeper, addr sdk.AccAddr // FundAccountWithBaseDenom is a utility function that uses the FundAccount function // to fund an account with the default Evmos denomination. func FundAccountWithBaseDenom(ctx sdk.Context, bankKeeper bankkeeper.Keeper, addr sdk.AccAddress, amount int64) error { + baseDenom, err := sdk.GetBaseDenom() + if err != nil { + return err + } + coins := sdk.NewCoins( - sdk.NewCoin(constants.ExampleAttoDenom, math.NewInt(amount)), + sdk.NewCoin(baseDenom, math.NewInt(amount)), ) + return FundAccount(ctx, bankKeeper, addr, coins) } diff --git a/testutil/integration/common/factory/helper.go b/testutil/integration/common/factory/helper.go index 6950bd01..70e2bf53 100644 --- a/testutil/integration/common/factory/helper.go +++ b/testutil/integration/common/factory/helper.go @@ -79,7 +79,7 @@ func (tf *baseTxFactory) buildTx(privKey cryptotypes.PrivKey, txArgs CosmosTxArg // calculateFees calculates the fees for the transaction. func (tf *baseTxFactory) calculateFees(gasPrice *sdkmath.Int, gasLimit uint64) (sdktypes.Coins, error) { - denom := tf.network.GetDenom() + denom := tf.network.GetBaseDenom() var fees sdktypes.Coins if gasPrice != nil { fees = sdktypes.Coins{{Denom: denom, Amount: gasPrice.MulRaw(int64(gasLimit))}} //#nosec G115 @@ -89,7 +89,7 @@ func (tf *baseTxFactory) calculateFees(gasPrice *sdkmath.Int, gasLimit uint64) ( return sdktypes.Coins{}, errorsmod.Wrap(err, "failed to get base fee") } price := resp.BaseFee - fees = sdktypes.Coins{{Denom: denom, Amount: price.MulRaw(int64(gasLimit))}} //#nosec G115 + fees = sdktypes.Coins{{Denom: denom, Amount: price.MulInt64(int64(gasLimit)).TruncateInt()}} //#nosec G115 } return fees, nil } diff --git a/testutil/integration/common/grpc/bank.go b/testutil/integration/common/grpc/bank.go index 2d6675e9..c82f114e 100644 --- a/testutil/integration/common/grpc/bank.go +++ b/testutil/integration/common/grpc/bank.go @@ -10,8 +10,8 @@ import ( banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" ) -// GetBalance returns the balance for the given address and denom. -func (gqh *IntegrationHandler) GetBalance(address sdktypes.AccAddress, denom string) (*banktypes.QueryBalanceResponse, error) { +// GetBalanceFromBank returns the balance for the given address and denom. +func (gqh *IntegrationHandler) GetBalanceFromBank(address sdktypes.AccAddress, denom string) (*banktypes.QueryBalanceResponse, error) { bankClient := gqh.network.GetBankClient() return bankClient.Balance(context.Background(), &banktypes.QueryBalanceRequest{ Address: address.String(), diff --git a/testutil/integration/common/grpc/grpc.go b/testutil/integration/common/grpc/grpc.go index 1d0ba86e..a0a9736a 100644 --- a/testutil/integration/common/grpc/grpc.go +++ b/testutil/integration/common/grpc/grpc.go @@ -27,7 +27,7 @@ type Handler interface { GetGrantsByGranter(granter string) ([]*authz.GrantAuthorization, error) // Bank methods - GetBalance(address sdk.AccAddress, denom string) (*banktypes.QueryBalanceResponse, error) + GetBalanceFromBank(address sdk.AccAddress, denom string) (*banktypes.QueryBalanceResponse, error) GetSpendableBalance(address sdk.AccAddress, denom string) (*banktypes.QuerySpendableBalanceByDenomResponse, error) GetAllBalances(address sdk.AccAddress) (*banktypes.QueryAllBalancesResponse, error) GetTotalSupply() (*banktypes.QueryTotalSupplyResponse, error) diff --git a/testutil/integration/common/network/network.go b/testutil/integration/common/network/network.go index b75cf2c8..26d4c5b0 100644 --- a/testutil/integration/common/network/network.go +++ b/testutil/integration/common/network/network.go @@ -26,7 +26,7 @@ import ( type Network interface { GetContext() sdktypes.Context GetChainID() string - GetDenom() string + GetBaseDenom() string GetOtherDenoms() []string GetValidators() []stakingtypes.Validator diff --git a/testutil/integration/os/factory/factory.go b/testutil/integration/os/factory/factory.go index b27ab5af..0a97c449 100644 --- a/testutil/integration/os/factory/factory.go +++ b/testutil/integration/os/factory/factory.go @@ -141,7 +141,7 @@ func (tf *IntegrationTxFactory) populateEvmTxArgsWithDefault( txArgs.GasTipCap = big.NewInt(1) } if txArgs.GasFeeCap == nil { - baseFeeResp, err := tf.grpcHandler.GetBaseFee() + baseFeeResp, err := tf.grpcHandler.GetEvmBaseFee() if err != nil { return evmtypes.EvmTxArgs{}, errorsmod.Wrap(err, "failed to get base fee") } @@ -174,7 +174,7 @@ func (tf *IntegrationTxFactory) encodeTx(tx sdktypes.Tx) ([]byte, error) { func (tf *IntegrationTxFactory) buildSignedTx(msg evmtypes.MsgEthereumTx) (signing.Tx, error) { txConfig := tf.ec.TxConfig txBuilder := txConfig.NewTxBuilder() - return msg.BuildTx(txBuilder, tf.network.GetDenom()) + return msg.BuildTx(txBuilder, tf.network.GetBaseDenom()) } // checkEthTxResponse checks if the response is valid and returns the MsgEthereumTxResponse diff --git a/testutil/integration/os/grpc/evm.go b/testutil/integration/os/grpc/evm.go index 8b041d77..f3ed64ed 100644 --- a/testutil/integration/os/grpc/evm.go +++ b/testutil/integration/os/grpc/evm.go @@ -4,8 +4,13 @@ package grpc import ( "context" + "errors" + + sdktypes "github.com/cosmos/cosmos-sdk/types" "github.com/ethereum/go-ethereum/common" + + "github.com/evmos/os/x/evm/core/vm" evmtypes "github.com/evmos/os/x/evm/types" ) @@ -20,10 +25,23 @@ func (gqh *IntegrationHandler) GetEvmAccount(address common.Address) (*evmtypes. // EstimateGas returns the estimated gas for the given call args. func (gqh *IntegrationHandler) EstimateGas(args []byte, gasCap uint64) (*evmtypes.EstimateGasResponse, error) { evmClient := gqh.network.GetEvmClient() - return evmClient.EstimateGas(context.Background(), &evmtypes.EthCallRequest{ + res, err := evmClient.EstimateGas(context.Background(), &evmtypes.EthCallRequest{ Args: args, GasCap: gasCap, }) + if err != nil { + return nil, err + } + + // handle case where there's a revert related error + if res.Failed() { + if (res.VmError != vm.ErrExecutionReverted.Error()) || len(res.Ret) == 0 { + return nil, errors.New(res.VmError) + } + return nil, evmtypes.NewExecErrorWithReason(res.Ret) + } + + return res, err } // GetEvmParams returns the EVM module params. @@ -31,3 +49,17 @@ func (gqh *IntegrationHandler) GetEvmParams() (*evmtypes.QueryParamsResponse, er evmClient := gqh.network.GetEvmClient() return evmClient.Params(context.Background(), &evmtypes.QueryParamsRequest{}) } + +// GetEvmParams returns the EVM module params. +func (gqh *IntegrationHandler) GetEvmBaseFee() (*evmtypes.QueryBaseFeeResponse, error) { + evmClient := gqh.network.GetEvmClient() + return evmClient.BaseFee(context.Background(), &evmtypes.QueryBaseFeeRequest{}) +} + +// GetBalanceFromEVM returns the balance for the given address. +func (gqh *IntegrationHandler) GetBalanceFromEVM(address sdktypes.AccAddress) (*evmtypes.QueryBalanceResponse, error) { + evmClient := gqh.network.GetEvmClient() + return evmClient.Balance(context.Background(), &evmtypes.QueryBalanceRequest{ + Address: common.BytesToAddress(address).Hex(), + }) +} diff --git a/testutil/integration/os/grpc/grpc.go b/testutil/integration/os/grpc/grpc.go index de1ec89f..fde918f8 100644 --- a/testutil/integration/os/grpc/grpc.go +++ b/testutil/integration/os/grpc/grpc.go @@ -4,6 +4,7 @@ package grpc import ( + sdk "github.com/cosmos/cosmos-sdk/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1" "github.com/ethereum/go-ethereum/common" commongrpc "github.com/evmos/os/testutil/integration/common/grpc" @@ -21,6 +22,8 @@ type Handler interface { GetEvmAccount(address common.Address) (*evmtypes.QueryAccountResponse, error) EstimateGas(args []byte, GasCap uint64) (*evmtypes.EstimateGasResponse, error) GetEvmParams() (*evmtypes.QueryParamsResponse, error) + GetEvmBaseFee() (*evmtypes.QueryBaseFeeResponse, error) + GetBalanceFromEVM(address sdk.AccAddress) (*evmtypes.QueryBalanceResponse, error) // FeeMarket methods GetBaseFee() (*feemarkettypes.QueryBaseFeeResponse, error) diff --git a/testutil/integration/os/network/chain_id_modifiers.go b/testutil/integration/os/network/chain_id_modifiers.go new file mode 100644 index 00000000..88d09998 --- /dev/null +++ b/testutil/integration/os/network/chain_id_modifiers.go @@ -0,0 +1,76 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +// +// This files contains handler for the testing suite that has to be run to +// modify the chain configuration depending on the chainID + +package network + +import ( + banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + testconstants "github.com/evmos/os/testutil/constants" + erc20types "github.com/evmos/os/x/erc20/types" +) + +// updateErc20GenesisStateForChainID modify the default genesis state for the +// bank module of the testing suite depending on the chainID. +func updateBankGenesisStateForChainID(bankGenesisState banktypes.GenesisState) banktypes.GenesisState { + metadata := generateBankGenesisMetadata() + bankGenesisState.DenomMetadata = []banktypes.Metadata{metadata} + + return bankGenesisState +} + +// generateBankGenesisMetadata generates the metadata +// for the Evm coin depending on the chainID. +func generateBankGenesisMetadata() banktypes.Metadata { + return banktypes.Metadata{ + Description: "The native EVM, governance and staking token of the evmOS example chain", + Base: "aevmos", + DenomUnits: []*banktypes.DenomUnit{ + { + Denom: testconstants.ExampleAttoDenom, + Exponent: 0, + }, + { + Denom: testconstants.ExampleDisplayDenom, + Exponent: 18, + }, + }, + Name: "evmOS", + Symbol: "EVMOS", + Display: testconstants.ExampleDisplayDenom, + } +} + +// updateErc20GenesisStateForChainID modify the default genesis state for the +// erc20 module on the testing suite depending on the chainID. +func updateErc20GenesisStateForChainID(chainID string, erc20GenesisState erc20types.GenesisState) erc20types.GenesisState { + erc20GenesisState.TokenPairs = updateErc20TokenPairs(chainID, erc20GenesisState.TokenPairs) + + return erc20GenesisState +} + +// updateErc20TokenPairs modifies the erc20 token pairs to use the correct +// WEVMOS depending on ChainID +func updateErc20TokenPairs(chainID string, tokenPairs []erc20types.TokenPair) []erc20types.TokenPair { + testnetAddress := GetWEVMOSContractHex(chainID) + coinInfo := testconstants.ExampleChainCoinInfo[chainID] + + mainnetAddress := GetWEVMOSContractHex(testconstants.ExampleChainID) + + updatedTokenPairs := make([]erc20types.TokenPair, len(tokenPairs)) + for i, tokenPair := range tokenPairs { + if tokenPair.Erc20Address == mainnetAddress { + updatedTokenPairs[i] = erc20types.TokenPair{ + Erc20Address: testnetAddress, + Denom: coinInfo.Denom, + Enabled: tokenPair.Enabled, + ContractOwner: tokenPair.ContractOwner, + } + } else { + updatedTokenPairs[i] = tokenPair + } + } + return updatedTokenPairs +} diff --git a/testutil/integration/os/network/coins.go b/testutil/integration/os/network/coins.go new file mode 100644 index 00000000..773acd29 --- /dev/null +++ b/testutil/integration/os/network/coins.go @@ -0,0 +1,83 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package network + +import ( + testconstants "github.com/evmos/os/testutil/constants" + evmtypes "github.com/evmos/os/x/evm/types" +) + +type CoinInfo struct { + Denom string + Decimals evmtypes.Decimals +} + +// ChainCoins information for the coins required from the chian to operate: +// - baseCoin: represents the base coin used to pay gas fees and staking in the +// Cosmos context. +// - evmCoin: represents the evm coin used to pay Ethereum +// transactions fees. +type ChainCoins struct { + // TODO: not sure if this is an overkill. Do we want to customize the + // decimals of the base denom? Maybe not.. + baseCoin *CoinInfo + evmCoin *CoinInfo +} + +// DefaultChainCoins returns the default values used for the ChainCoins in which +// base and evm denom are the same. +func DefaultChainCoins() ChainCoins { + baseCoinInfo := testconstants.ExampleChainCoinInfo[testconstants.ExampleChainID] + // baseCoin is used for both base and evm coin as default.. + baseCoin := CoinInfo{ + Denom: baseCoinInfo.Denom, + Decimals: baseCoinInfo.Decimals, + } + evmCoin := baseCoin + return ChainCoins{ + baseCoin: &baseCoin, + evmCoin: &evmCoin, + } +} + +func (cc ChainCoins) BaseCoin() CoinInfo { + return *cc.baseCoin +} + +func (cc ChainCoins) EVMCoin() CoinInfo { + return *cc.evmCoin +} + +func (cc ChainCoins) BaseDenom() string { + return cc.baseCoin.Denom +} + +func (cc ChainCoins) EVMDenom() string { + return cc.evmCoin.Denom +} + +func (cc ChainCoins) BaseDecimals() evmtypes.Decimals { + return cc.baseCoin.Decimals +} + +func (cc ChainCoins) EVMDecimals() evmtypes.Decimals { + return cc.evmCoin.Decimals +} + +func (cc ChainCoins) IsBaseEqualToEVM() bool { + return cc.BaseDenom() == cc.EVMDenom() +} + +// DenomDecimalsMap returns a map of Denom -> Decimals for the chain coin. +func (cc ChainCoins) DenomDecimalsMap() map[string]evmtypes.Decimals { + chainDenomDecimals := map[string]evmtypes.Decimals{ + cc.BaseDenom(): cc.BaseDecimals(), + } + + // Insert also the evm denom if base and evm denom are different. + if !cc.IsBaseEqualToEVM() { + chainDenomDecimals[cc.EVMDenom()] = cc.EVMDecimals() + } + return chainDenomDecimals +} diff --git a/testutil/integration/os/network/config.go b/testutil/integration/os/network/config.go index 21276337..8b202bb2 100644 --- a/testutil/integration/os/network/config.go +++ b/testutil/integration/os/network/config.go @@ -7,14 +7,17 @@ import ( "fmt" "math/big" + "golang.org/x/exp/maps" + "github.com/cosmos/cosmos-sdk/baseapp" sdktypes "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/evmos/os/testutil/constants" + testconstants "github.com/evmos/os/testutil/constants" testtx "github.com/evmos/os/testutil/tx" evmostypes "github.com/evmos/os/types" + evmtypes "github.com/evmos/os/x/evm/types" ) // Config defines the configuration for a chain. @@ -26,7 +29,7 @@ type Config struct { amountOfValidators int preFundedAccounts []sdktypes.AccAddress balances []banktypes.Balance - denom string + chainCoins ChainCoins customGenesisState CustomGenesisState otherCoinDenom []string operatorsAddrs []sdktypes.AccAddress @@ -40,14 +43,14 @@ func DefaultConfig() Config { account, _ := testtx.NewAccAddressAndKey() return Config{ - chainID: constants.ExampleChainID, - eip155ChainID: big.NewInt(constants.ExampleEIP155ChainID), + chainID: testconstants.ExampleChainID, + eip155ChainID: big.NewInt(testconstants.ExampleEIP155ChainID), + chainCoins: DefaultChainCoins(), amountOfValidators: 3, // No funded accounts besides the validators by default preFundedAccounts: []sdktypes.AccAddress{account}, // NOTE: Per default, the balances are left empty, and the pre-funded accounts are used. balances: nil, - denom: constants.ExampleAttoDenom, customGenesisState: nil, } } @@ -63,7 +66,10 @@ func getGenAccountsAndBalances(cfg Config, validators []stakingtypes.Validator) genAccounts = createGenesisAccounts(accounts) } else { genAccounts = createGenesisAccounts(cfg.preFundedAccounts) - balances = createBalances(cfg.preFundedAccounts, append(cfg.otherCoinDenom, cfg.denom)) + + denomDecimals := cfg.chainCoins.DenomDecimalsMap() + denoms := maps.Keys(denomDecimals) + balances = createBalances(cfg.preFundedAccounts, append(cfg.otherCoinDenom, denoms...), denomDecimals) } // append validators to genesis accounts and balances @@ -85,15 +91,33 @@ func getGenAccountsAndBalances(cfg Config, validators []stakingtypes.Validator) // requires to be changed. type ConfigOption func(*Config) -// WithChainID sets a custom chainID for the network. It panics if the chainID is invalid. +// WithChainID sets a custom chainID for the network. Changing the chainID +// change automatically also the EVM coin used. It panics if the chainID is invalid. func WithChainID(chainID string) ConfigOption { - chainIDNum, err := evmostypes.ParseChainID(chainID) + eip155ChainID, err := evmostypes.ParseChainID(chainID) if err != nil { panic(err) } + + evmCoinInfo, found := testconstants.ExampleChainCoinInfo[chainID] + if !found { + panic(fmt.Sprintf( + "chain id %q not found in chain coin info; available: %v", + chainID, + testconstants.ExampleChainCoinInfo, + )) + } + return func(cfg *Config) { cfg.chainID = chainID - cfg.eip155ChainID = chainIDNum + cfg.eip155ChainID = eip155ChainID + + if cfg.chainCoins.IsBaseEqualToEVM() { + cfg.chainCoins.baseCoin.Denom = evmCoinInfo.Denom + cfg.chainCoins.baseCoin.Decimals = evmCoinInfo.Decimals + } + cfg.chainCoins.evmCoin.Denom = evmCoinInfo.Denom + cfg.chainCoins.evmCoin.Decimals = evmCoinInfo.Decimals } } @@ -119,13 +143,21 @@ func WithBalances(balances ...banktypes.Balance) ConfigOption { } } -// WithDenom sets the denom for the network. -func WithDenom(denom string) ConfigOption { +// WithBaseCoin sets the denom and decimals for the base coin in the network. +func WithBaseCoin(denom string, decimals uint8) ConfigOption { return func(cfg *Config) { - cfg.denom = denom + cfg.chainCoins.baseCoin.Denom = denom + cfg.chainCoins.baseCoin.Decimals = evmtypes.Decimals(decimals) } } +// WithEVMCoin sets the denom and decimals for the evm coin in the network. +func WithEVMCoin(_ string, _ uint8) ConfigOption { + // The evm config can be changed only via chain ID because it should be + // handled properly from the configurator. + panic("EVM coin can be changed only via ChainID: se WithChainID method") +} + // WithCustomGenesis sets the custom genesis of the network for specific modules. func WithCustomGenesis(customGenesis CustomGenesisState) ConfigOption { return func(cfg *Config) { diff --git a/testutil/integration/os/network/config_test.go b/testutil/integration/os/network/config_test.go index 194c9b87..d7670682 100644 --- a/testutil/integration/os/network/config_test.go +++ b/testutil/integration/os/network/config_test.go @@ -6,19 +6,76 @@ package network_test import ( "testing" + "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/evmos/os/testutil/constants" + testconstants "github.com/evmos/os/testutil/constants" grpchandler "github.com/evmos/os/testutil/integration/os/grpc" testkeyring "github.com/evmos/os/testutil/integration/os/keyring" "github.com/evmos/os/testutil/integration/os/network" + evmtypes "github.com/evmos/os/x/evm/types" "github.com/stretchr/testify/require" ) +func TestWithChainID(t *testing.T) { + testCases := []struct { + name string + chainID string + denom string + decimals evmtypes.Decimals + expBalanceCosmos math.Int + }{ + { + name: "18 decimals", + chainID: testconstants.ExampleChainID, + denom: testconstants.ExampleAttoDenom, + decimals: evmtypes.EighteenDecimals, + expBalanceCosmos: network.PrefundedAccountInitialBalance, + }, + { + name: "6 decimals", + chainID: testconstants.SixDecimalsChainID, + denom: testconstants.ExampleMicroDenom, + decimals: evmtypes.SixDecimals, + expBalanceCosmos: network.PrefundedAccountInitialBalance.QuoRaw(1e12), + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + // Create a new network with 2 pre-funded accounts + keyring := testkeyring.New(1) + + opts := []network.ConfigOption{ + network.WithChainID(tc.chainID), + network.WithPreFundedAccounts(keyring.GetAllAccAddrs()...), + } + nw := network.New(opts...) + + handler := grpchandler.NewIntegrationHandler(nw) //nolint:staticcheck // Somehow the linter marks this as not being used, even though it's used below to get balances + + // reset configuration to use the correct decimals coin info + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + require.NoError(t, configurator.WithEVMCoinInfo(tc.denom, uint8(tc.decimals)).Configure()) + + // Evm balance should always be in 18 decimals + req, err := handler.GetBalanceFromEVM(keyring.GetAccAddr(0)) + require.NoError(t, err, "error getting balances") + require.Equal(t, network.PrefundedAccountInitialBalance.String(), req.Balance, "expected amount to be in 18 decimals") + + // Bank balance should always be in the original amount + cReq, err := handler.GetBalanceFromBank(keyring.GetAccAddr(0), tc.denom) + require.NoError(t, err, "error getting balances") + require.Equal(t, tc.expBalanceCosmos.String(), cReq.Balance.Amount.String(), "expected amount to be in original decimals") + }) + } +} + func TestWithBalances(t *testing.T) { - key1Balance := sdk.NewCoins(sdk.NewInt64Coin(constants.ExampleAttoDenom, 1e18)) + key1Balance := sdk.NewCoins(sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 1e18)) key2Balance := sdk.NewCoins( - sdk.NewInt64Coin(constants.ExampleAttoDenom, 2e18), + sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 2e18), sdk.NewInt64Coin("other", 3e18), ) diff --git a/testutil/integration/os/network/example_contracts.go b/testutil/integration/os/network/example_contracts.go new file mode 100644 index 00000000..429034e5 --- /dev/null +++ b/testutil/integration/os/network/example_contracts.go @@ -0,0 +1,30 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package network + +import ( + testconstants "github.com/evmos/os/testutil/constants" +) + +// chainsWEVMOSHex is an utility map used to retrieve the WEVMOS contract +// address in hex format from the chain ID. +// +// TODO: refactor to define this in the example chain initialization and pass as function argument +var chainsWEVMOSHex = map[string]string{ + testconstants.ExampleChainID: testconstants.WEVMOSContractMainnet, +} + +// GetWEVMOSContractHex returns the hex format of address for the WEVMOS contract +// given the chainID. If the chainID is not found, it defaults to the mainnet +// address. +func GetWEVMOSContractHex(chainID string) string { + address, found := chainsWEVMOSHex[chainID] + + // default to mainnet address + if !found { + address = chainsWEVMOSHex[testconstants.ExampleChainID] + } + + return address +} diff --git a/testutil/integration/os/network/network.go b/testutil/integration/os/network/network.go index 1583ac1d..3cb1f6ab 100644 --- a/testutil/integration/os/network/network.go +++ b/testutil/integration/os/network/network.go @@ -93,20 +93,29 @@ func New(opts ...ConfigOption) *IntegrationNetwork { var ( // DefaultBondedAmount is the amount of tokens that each validator will have initially bonded DefaultBondedAmount = sdktypes.TokensFromConsensusPower(1, types.AttoPowerReduction) - // PrefundedAccountInitialBalance is the amount of tokens that each prefunded account has at genesis - PrefundedAccountInitialBalance, _ = sdkmath.NewIntFromString("100000000000000000000000") // 100k + // PrefundedAccountInitialBalance is the amount of tokens that each + // prefunded account has at genesis. It represents a 100k amount expressed + // in the 18 decimals representation. + PrefundedAccountInitialBalance, _ = sdkmath.NewIntFromString("100_000_000_000_000_000_000_000") ) // configureAndInitChain initializes the network with the given configuration. // It creates the genesis state and starts the network. func (n *IntegrationNetwork) configureAndInitChain() error { + // The bonded denom should be updated to reflect the actual base denom + // decimals. + baseDecimals := n.cfg.chainCoins.BaseDecimals() + // 1e18/1e18 = 1 + // 1e6/1e18 * 1e12 = 1e6/1e6 = 1 + InitialBondedAmount := DefaultBondedAmount.Mul(baseDecimals.ConversionFactor()) + // Create validator set with the amount of validators specified in the config // with the default power of 1. valSet, valSigners := createValidatorSetAndSigners(n.cfg.amountOfValidators) - totalBonded := DefaultBondedAmount.Mul(sdkmath.NewInt(int64(n.cfg.amountOfValidators))) + totalBonded := InitialBondedAmount.Mul(sdkmath.NewInt(int64(n.cfg.amountOfValidators))) // Build staking type validators and delegations - validators, err := createStakingValidators(valSet.Validators, DefaultBondedAmount, n.cfg.operatorsAddrs) + validators, err := createStakingValidators(valSet.Validators, InitialBondedAmount, n.cfg.operatorsAddrs) if err != nil { return err } @@ -116,7 +125,7 @@ func (n *IntegrationNetwork) configureAndInitChain() error { fundedAccountBalances = addBondedModuleAccountToFundedBalances( fundedAccountBalances, - sdktypes.NewCoin(n.cfg.denom, totalBonded), + sdktypes.NewCoin(n.cfg.chainCoins.BaseDenom(), totalBonded), ) delegations := createDelegations(validators, genAccounts[0].GetAddress()) @@ -125,16 +134,16 @@ func (n *IntegrationNetwork) configureAndInitChain() error { exampleApp := createTestingApp(n.cfg.chainID, n.cfg.customBaseAppOpts...) stakingParams := StakingCustomGenesisState{ - denom: n.cfg.denom, + denom: n.cfg.chainCoins.BaseDenom(), validators: validators, delegations: delegations, } govParams := GovCustomGenesisState{ - denom: n.cfg.denom, + denom: n.cfg.chainCoins.BaseDenom(), } mintParams := MintCustomGenesisState{ - denom: n.cfg.denom, + denom: n.cfg.chainCoins.BaseDenom(), inflationMax: sdkmath.LegacyNewDecWithPrec(0, 1), inflationMin: sdkmath.LegacyNewDecWithPrec(0, 1), } @@ -259,13 +268,17 @@ func (n *IntegrationNetwork) GetEIP155ChainID() *big.Int { // GetEVMChainConfig returns the network's EVM chain config func (n *IntegrationNetwork) GetEVMChainConfig() *gethparams.ChainConfig { - params := n.app.EVMKeeper.GetParams(n.ctx) - return params.ChainConfig.EthereumConfig(n.cfg.eip155ChainID) + return evmtypes.GetEthChainConfig() +} + +// GetBaseDenom returns the network's base denom +func (n *IntegrationNetwork) GetBaseDenom() string { + return n.cfg.chainCoins.baseCoin.Denom } -// GetDenom returns the network's denom -func (n *IntegrationNetwork) GetDenom() string { - return n.cfg.denom +// GetEVMDenom returns the network's evm denom +func (n *IntegrationNetwork) GetEVMDenom() string { + return n.cfg.chainCoins.evmCoin.Denom } // GetOtherDenoms returns network's other supported denoms diff --git a/testutil/integration/os/network/setup.go b/testutil/integration/os/network/setup.go index f2c2679b..4da4862b 100644 --- a/testutil/integration/os/network/setup.go +++ b/testutil/integration/os/network/setup.go @@ -126,13 +126,29 @@ func getAccAddrsFromBalances(balances []banktypes.Balance) []sdktypes.AccAddress return genAccounts } -// createBalances creates balances for the given accounts and coin -func createBalances(accounts []sdktypes.AccAddress, denoms []string) []banktypes.Balance { - slices.Sort(denoms) +// createBalances creates balances for the given accounts and coin. Depending on +// the decimal representation of the denom, the amount is scaled to have the +// same value for all denoms. +func createBalances( + accounts []sdktypes.AccAddress, + denoms []string, + denomsDecimals map[string]evmtypes.Decimals, +) []banktypes.Balance { numberOfAccounts := len(accounts) + + slices.Sort(denoms) + coins := make([]sdktypes.Coin, len(denoms)) for i, denom := range denoms { - coins[i] = sdktypes.NewCoin(denom, PrefundedAccountInitialBalance) + amount := PrefundedAccountInitialBalance + dec, found := denomsDecimals[denom] + // If the denom is not in the map, the 18 decimals representation is + // used. + if found { + // amount is expressed in 18 decimals so it should be scaled down. + amount = amount.Quo(dec.ConversionFactor()) + } + coins[i] = sdktypes.NewCoin(denom, amount) } fundedAccountBalances := make([]banktypes.Balance, 0, numberOfAccounts) for _, acc := range accounts { @@ -320,7 +336,8 @@ func setDefaultBankGenesisState(evmosApp *exampleapp.ExampleChain, genesisState []banktypes.Metadata{}, []banktypes.SendEnabled{}, ) - genesisState[banktypes.ModuleName] = evmosApp.AppCodec().MustMarshalJSON(bankGenesis) + updatedBankGen := updateBankGenesisStateForChainID(*bankGenesis) + genesisState[banktypes.ModuleName] = evmosApp.AppCodec().MustMarshalJSON(&updatedBankGen) return genesisState } @@ -462,7 +479,9 @@ func setDefaultMintGenesisState(evmosApp *exampleapp.ExampleChain, genesisState func setDefaultErc20GenesisState(evmosApp *exampleapp.ExampleChain, genesisState evmostypes.GenesisState) evmostypes.GenesisState { // NOTE: here we are using the setup from the example chain erc20Gen := exampleapp.NewErc20GenesisState() - genesisState[erc20types.ModuleName] = evmosApp.AppCodec().MustMarshalJSON(erc20Gen) + updatedErc20Gen := updateErc20GenesisStateForChainID(evmosApp.ChainID(), *erc20Gen) + + genesisState[erc20types.ModuleName] = evmosApp.AppCodec().MustMarshalJSON(&updatedErc20Gen) return genesisState } diff --git a/testutil/integration/os/utils/bank.go b/testutil/integration/os/utils/bank.go index 36cc2c3c..d9e4c516 100644 --- a/testutil/integration/os/utils/bank.go +++ b/testutil/integration/os/utils/bank.go @@ -18,7 +18,7 @@ import ( // FundAccountWithBaseDenom funds the given account with the given amount of the network's // base denomination. func FundAccountWithBaseDenom(tf cmnfactory.CoreTxFactory, nw cmnnet.Network, sender keyring.Key, receiver sdk.AccAddress, amount math.Int) error { - return tf.FundAccount(sender, receiver, sdk.NewCoins(sdk.NewCoin(nw.GetDenom(), amount))) + return tf.FundAccount(sender, receiver, sdk.NewCoins(sdk.NewCoin(nw.GetBaseDenom(), amount))) } // CheckBalances checks that the given accounts have the expected balances and diff --git a/testutil/integration/os/utils/bank_test.go b/testutil/integration/os/utils/bank_test.go index 2afc8495..1d3a1658 100644 --- a/testutil/integration/os/utils/bank_test.go +++ b/testutil/integration/os/utils/bank_test.go @@ -15,42 +15,49 @@ import ( func TestCheckBalances(t *testing.T) { testDenom := "atest" keyring := testkeyring.New(1) - nw := network.New( - network.WithDenom(testDenom), - network.WithPreFundedAccounts(keyring.GetAllAccAddrs()...), - ) + address := keyring.GetAccAddr(0).String() testcases := []struct { name string - address string + decimals uint8 expAmount math.Int expPass bool errContains string }{ { - name: "pass", - address: keyring.GetAccAddr(0).String(), + name: "pass - eighteen decimals", + decimals: 18, expAmount: network.PrefundedAccountInitialBalance, expPass: true, }, + { + name: "pass - six decimals", + decimals: 6, + expAmount: network.PrefundedAccountInitialBalance.Quo(math.NewInt(1e12)), + expPass: true, + }, { name: "fail - wrong amount", - address: keyring.GetAccAddr(0).String(), + decimals: 18, expAmount: math.NewInt(1), errContains: "expected balance", }, } for _, tc := range testcases { - tc := tc t.Run(tc.name, func(t *testing.T) { balances := []banktypes.Balance{{ - Address: tc.address, + Address: address, Coins: sdk.NewCoins( sdk.NewCoin(testDenom, tc.expAmount), ), }} + nw := network.New( + network.WithBaseCoin(testDenom, tc.decimals), + network.WithPreFundedAccounts(keyring.GetAllAccAddrs()...), + ) + err := utils.CheckBalances(nw.GetContext(), nw.GetBankClient(), balances) if tc.expPass { require.NoError(t, err, "unexpected error checking balances") diff --git a/testutil/integration/os/utils/gov.go b/testutil/integration/os/utils/gov.go index e3d75ffc..317a1132 100644 --- a/testutil/integration/os/utils/gov.go +++ b/testutil/integration/os/utils/gov.go @@ -27,7 +27,7 @@ func SubmitProposal(tf factory.TxFactory, network network.Network, proposerPriv proposerAccAddr := sdk.AccAddress(proposerPriv.PubKey().Address()).String() proposal, err := govv1.NewMsgSubmitProposal( msgs, - sdk.NewCoins(sdk.NewCoin(network.GetDenom(), math.NewInt(1e18))), + sdk.NewCoins(sdk.NewCoin(network.GetBaseDenom(), math.NewInt(1e18))), proposerAccAddr, "", title, @@ -52,7 +52,7 @@ func SubmitLegacyProposal(tf factory.TxFactory, network network.Network, propose msgSubmitProposal, err := govv1beta1.NewMsgSubmitProposal( proposal, - sdk.NewCoins(sdk.NewCoin(network.GetDenom(), math.NewInt(1e18))), + sdk.NewCoins(sdk.NewCoin(network.GetBaseDenom(), math.NewInt(1e18))), proposerAccAddr, ) if err != nil { diff --git a/testutil/integration/os/utils/staking.go b/testutil/integration/os/utils/staking.go index 74d6a253..2226426b 100644 --- a/testutil/integration/os/utils/staking.go +++ b/testutil/integration/os/utils/staking.go @@ -27,8 +27,8 @@ func WaitToAccrueRewards(n network.Network, gh grpc.Handler, delegatorAddr strin return nil, err } - expAmt := expRewards.AmountOf(n.GetDenom()) - for rewards.AmountOf(n.GetDenom()).LT(expAmt) { + expAmt := expRewards.AmountOf(n.GetBaseDenom()) + for rewards.AmountOf(n.GetBaseDenom()).LT(expAmt) { rewards, err = checkRewardsAfter(n, gh, delegatorAddr, lapse) if err != nil { return nil, errorsmod.Wrap(err, "error checking rewards") @@ -67,8 +67,8 @@ func WaitToAccrueCommission(n network.Network, gh grpc.Handler, validatorAddr st return nil, err } - expAmt := expCommission.AmountOf(n.GetDenom()) - for commission.AmountOf(n.GetDenom()).LT(expAmt) { + expAmt := expCommission.AmountOf(n.GetBaseDenom()) + for commission.AmountOf(n.GetBaseDenom()).LT(expAmt) { commission, err = checkCommissionAfter(n, gh, validatorAddr, lapse) if err != nil { return nil, errorsmod.Wrap(err, "error checking commission") diff --git a/testutil/network/network.go b/testutil/network/network.go index a376c5ec..63b93d86 100644 --- a/testutil/network/network.go +++ b/testutil/network/network.go @@ -120,7 +120,7 @@ func DefaultConfig() Config { TimeoutCommit: 3 * time.Second, ChainID: chainID, NumValidators: 4, - BondDenom: "aevmos", + BondDenom: testconstants.ExampleAttoDenom, MinGasPrices: fmt.Sprintf("0.000006%s", testconstants.ExampleAttoDenom), AccountTokens: sdk.TokensFromConsensusPower(1000000000000000000, evmostypes.AttoPowerReduction), StakingTokens: sdk.TokensFromConsensusPower(500000000000000000, evmostypes.AttoPowerReduction), @@ -429,7 +429,7 @@ func New(l Logger, baseDir string, cfg Config) (*Network, error) { } createValMsg, err := stakingtypes.NewMsgCreateValidator( - addr.String(), + sdk.ValAddress(addr).String(), valPubKeys[i], sdk.NewCoin(cfg.BondDenom, cfg.BondedTokens), stakingtypes.NewDescription(nodeDirName, "", "", "", ""), diff --git a/testutil/network/util.go b/testutil/network/util.go index 792f1b8d..daa23a42 100644 --- a/testutil/network/util.go +++ b/testutil/network/util.go @@ -229,9 +229,6 @@ func initGenFiles(cfg Config, genAccounts []authtypes.GenesisAccount, genBalance var evmGenState evmtypes.GenesisState cfg.Codec.MustUnmarshalJSON(cfg.GenesisState[evmtypes.ModuleName], &evmGenState) - evmGenState.Params.EvmDenom = cfg.BondDenom - cfg.GenesisState[evmtypes.ModuleName] = cfg.Codec.MustMarshalJSON(&evmGenState) - appGenStateJSON, err := json.MarshalIndent(cfg.GenesisState, "", " ") if err != nil { return err diff --git a/testutil/tx/eth.go b/testutil/tx/eth.go index 40e39803..475cc20f 100644 --- a/testutil/tx/eth.go +++ b/testutil/tx/eth.go @@ -8,8 +8,6 @@ import ( "encoding/json" "math/big" - testconstants "github.com/evmos/os/testutil/constants" - errorsmod "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" "github.com/cosmos/cosmos-sdk/client" @@ -30,16 +28,17 @@ import ( // It returns the signed transaction and an error func PrepareEthTx( txCfg client.TxConfig, - exampleApp *exampleapp.ExampleChain, priv cryptotypes.PrivKey, msgs ...sdk.Msg, ) (authsigning.Tx, error) { txBuilder := txCfg.NewTxBuilder() - signer := ethtypes.LatestSignerForChainID(exampleApp.EVMKeeper.ChainID()) + signer := ethtypes.LatestSignerForChainID(evmtypes.GetEthChainConfig().ChainID) txFee := sdk.Coins{} txGasLimit := uint64(0) + baseDenom := evmtypes.GetEVMCoinDenom() + // Sign messages and compute gas/fees. for _, m := range msgs { msg, ok := m.(*evmtypes.MsgEthereumTx) @@ -57,7 +56,7 @@ func PrepareEthTx( msg.From = "" txGasLimit += msg.GetGas() - txFee = txFee.Add(sdk.Coin{Denom: testconstants.ExampleAttoDenom, Amount: sdkmath.NewIntFromBigInt(msg.GetFee())}) + txFee = txFee.Add(sdk.Coin{Denom: baseDenom, Amount: sdkmath.NewIntFromBigInt(msg.GetFee())}) } if err := txBuilder.SetMsgs(msgs...); err != nil { @@ -102,7 +101,13 @@ func CreateEthTx( ) (*evmtypes.MsgEthereumTx, error) { toAddr := common.BytesToAddress(dest.Bytes()) fromAddr := common.BytesToAddress(from.Bytes()) - chainID := exampleApp.EVMKeeper.ChainID() + chainID := evmtypes.GetEthChainConfig().ChainID + + baseFeeRes, err := exampleApp.EVMKeeper.BaseFee(ctx, &evmtypes.QueryBaseFeeRequest{}) + if err != nil { + return nil, err + } + baseFee := baseFeeRes.BaseFee.BigInt() // When we send multiple Ethereum Tx's in one Cosmos Tx, we need to increment the nonce for each one. nonce := exampleApp.EVMKeeper.GetNonce(ctx, fromAddr) + uint64(nonceIncrement) //#nosec G115 -- will not exceed uint64 @@ -112,7 +117,7 @@ func CreateEthTx( To: &toAddr, Amount: amount, GasLimit: 100000, - GasFeeCap: exampleApp.FeeMarketKeeper.GetBaseFee(ctx), + GasFeeCap: baseFee, GasTipCap: big.NewInt(1), Accesses: ðtypes.AccessList{}, } @@ -121,7 +126,7 @@ func CreateEthTx( // If we are creating multiple eth Tx's with different senders, we need to sign here rather than later. if privKey != nil { - signer := ethtypes.LatestSignerForChainID(exampleApp.EVMKeeper.ChainID()) + signer := ethtypes.LatestSignerForChainID(evmtypes.GetEthChainConfig().ChainID) err := msgEthereumTx.Sign(signer, NewSigner(privKey)) if err != nil { return nil, err diff --git a/types/dynamic_fee.go b/types/dynamic_fee.go index 75f399d2..6c69d813 100644 --- a/types/dynamic_fee.go +++ b/types/dynamic_fee.go @@ -7,7 +7,7 @@ import ( ) // HasDynamicFeeExtensionOption returns true if the tx implements the `ExtensionOptionDynamicFeeTx` extension option. -func HasDynamicFeeExtensionOption(any *codectypes.Any) bool { - _, ok := any.GetCachedValue().(*ExtensionOptionDynamicFeeTx) +func HasDynamicFeeExtensionOption(anyType *codectypes.Any) bool { + _, ok := anyType.GetCachedValue().(*ExtensionOptionDynamicFeeTx) return ok } diff --git a/types/dynamic_fee.pb.go b/types/dynamic_fee.pb.go index 42ec6674..3edfd15d 100644 --- a/types/dynamic_fee.pb.go +++ b/types/dynamic_fee.pb.go @@ -30,7 +30,7 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type ExtensionOptionDynamicFeeTx struct { // max_priority_price is the same as `max_priority_fee_per_gas` in eip-1559 // spec - MaxPriorityPrice cosmossdk_io_math.Int `protobuf:"bytes,1,opt,name=max_priority_price,json=maxPriorityPrice,proto3,customtype=cosmossdk.io/math.Int" json:"max_priority_price"` + MaxPriorityPrice cosmossdk_io_math.LegacyDec `protobuf:"bytes,1,opt,name=max_priority_price,json=maxPriorityPrice,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"max_priority_price"` } func (m *ExtensionOptionDynamicFeeTx) Reset() { *m = ExtensionOptionDynamicFeeTx{} } @@ -73,23 +73,23 @@ func init() { func init() { proto.RegisterFile("os/types/v1/dynamic_fee.proto", fileDescriptor_a9afa21b8d75b43a) } var fileDescriptor_a9afa21b8d75b43a = []byte{ - // 244 bytes of a gzipped FileDescriptorProto + // 250 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xcd, 0x2f, 0xd6, 0x2f, 0xa9, 0x2c, 0x48, 0x2d, 0xd6, 0x2f, 0x33, 0xd4, 0x4f, 0xa9, 0xcc, 0x4b, 0xcc, 0xcd, 0x4c, 0x8e, 0x4f, 0x4b, 0x4d, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0xce, 0x2f, 0xd6, 0x03, 0x4b, 0xeb, 0x95, 0x19, 0x4a, 0x09, 0x26, 0xe6, 0x66, 0xe6, 0xe5, 0xeb, 0x83, 0x49, 0x88, 0xbc, 0x94, - 0x48, 0x7a, 0x7e, 0x7a, 0x3e, 0x98, 0xa9, 0x0f, 0x62, 0x41, 0x44, 0x95, 0xf2, 0xb9, 0xa4, 0x5d, + 0x48, 0x7a, 0x7e, 0x7a, 0x3e, 0x98, 0xa9, 0x0f, 0x62, 0x41, 0x44, 0x95, 0x4a, 0xb9, 0xa4, 0x5d, 0x2b, 0x4a, 0x52, 0xf3, 0x8a, 0x33, 0xf3, 0xf3, 0xfc, 0x0b, 0x4a, 0x32, 0xf3, 0xf3, 0x5c, 0x20, - 0x26, 0xbb, 0xa5, 0xa6, 0x86, 0x54, 0x08, 0x05, 0x70, 0x09, 0xe5, 0x26, 0x56, 0xc4, 0x17, 0x14, + 0x26, 0xbb, 0xa5, 0xa6, 0x86, 0x54, 0x08, 0x85, 0x71, 0x09, 0xe5, 0x26, 0x56, 0xc4, 0x17, 0x14, 0x65, 0xe6, 0x17, 0x65, 0x96, 0x54, 0x82, 0x18, 0xc9, 0xa9, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x9c, - 0x4e, 0x4a, 0x27, 0xee, 0xc9, 0x33, 0xdc, 0xba, 0x27, 0x2f, 0x9a, 0x9c, 0x5f, 0x9c, 0x9b, 0x5f, - 0x5c, 0x9c, 0x92, 0xad, 0x97, 0x99, 0xaf, 0x9f, 0x9b, 0x58, 0x92, 0xa1, 0xe7, 0x99, 0x57, 0xb2, - 0xe2, 0xf9, 0x06, 0x2d, 0xc6, 0x20, 0x81, 0xdc, 0xc4, 0x8a, 0x00, 0xa8, 0xe6, 0x00, 0x90, 0x5e, - 0x27, 0xe3, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, - 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, 0x88, 0x92, 0x4c, 0xcf, 0x2c, - 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0x2d, 0xcb, 0xcd, 0x2f, 0xd6, 0x87, 0x79, - 0x38, 0x89, 0x0d, 0xec, 0x58, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x10, 0x52, 0x32, 0xb9, - 0x03, 0x01, 0x00, 0x00, + 0x4e, 0x1a, 0x27, 0xee, 0xc9, 0x33, 0xdc, 0xba, 0x27, 0x2f, 0x9d, 0x9c, 0x5f, 0x9c, 0x9b, 0x5f, + 0x5c, 0x9c, 0x92, 0xad, 0x97, 0x99, 0xaf, 0x9f, 0x9b, 0x58, 0x92, 0xa1, 0xe7, 0x93, 0x9a, 0x9e, + 0x98, 0x5c, 0xe9, 0x92, 0x9a, 0xbc, 0xe2, 0xf9, 0x06, 0x2d, 0xc6, 0x20, 0x81, 0xdc, 0xc4, 0x8a, + 0x00, 0xa8, 0x11, 0x01, 0x20, 0x13, 0x9c, 0x8c, 0x4f, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, + 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, + 0x8e, 0x21, 0x4a, 0x32, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x3f, 0xb5, + 0x2c, 0x37, 0xbf, 0x58, 0x1f, 0xe6, 0xed, 0x24, 0x36, 0xb0, 0x93, 0x8d, 0x01, 0x01, 0x00, 0x00, + 0xff, 0xff, 0x7d, 0x41, 0x30, 0xfe, 0x09, 0x01, 0x00, 0x00, } func (m *ExtensionOptionDynamicFeeTx) Marshal() (dAtA []byte, err error) { diff --git a/utils/utils_test.go b/utils/utils_test.go index adc29bd9..07b16540 100644 --- a/utils/utils_test.go +++ b/utils/utils_test.go @@ -215,7 +215,7 @@ func TestAccAddressFromBech32(t *testing.T) { } for _, tc := range testCases { - tc := tc + tc := tc //nolint:copyloopvar // Needed to work correctly with concurrent tests t.Run(tc.address, func(t *testing.T) { t.Parallel() diff --git a/wallets/ledger/ledger.go b/wallets/ledger/ledger.go index 6e89cd29..c74248b1 100644 --- a/wallets/ledger/ledger.go +++ b/wallets/ledger/ledger.go @@ -151,6 +151,7 @@ func (e EvmosSECP256K1) displayEIP712Hash(typedData apitypes.TypedData) error { return nil } +// connectToLedgerApp connects to the Ledger hardware wallet and initializes the wallet instance. func (e *EvmosSECP256K1) connectToLedgerApp() (sdkledger.SECP256K1, error) { // Instantiate new Ledger object ledger, err := usbwallet.NewLedgerHub() diff --git a/x/erc20/keeper/dynamic_precompiles.go b/x/erc20/keeper/dynamic_precompiles.go index 6ad2b59b..78856a38 100644 --- a/x/erc20/keeper/dynamic_precompiles.go +++ b/x/erc20/keeper/dynamic_precompiles.go @@ -38,7 +38,7 @@ func (k Keeper) RegisterERC20Extension(ctx sdk.Context, denom string) (*types.To // RegisterERC20CodeHash sets the codehash for the erc20 precompile account // if the bytecode for the erc20 codehash does not exists, it stores it. -func (k Keeper) RegisterERC20CodeHash(ctx sdk.Context, address common.Address) error { +func (k Keeper) RegisterERC20CodeHash(ctx sdk.Context, erc20Addr common.Address) error { var ( // bytecode and codeHash is the same for all IBC coins // cause they're all using the same contract @@ -56,12 +56,12 @@ func (k Keeper) RegisterERC20CodeHash(ctx sdk.Context, address common.Address) e balance = common.Big0 ) // keep balance and nonce if account exists - if acc := k.evmKeeper.GetAccount(ctx, address); acc != nil { + if acc := k.evmKeeper.GetAccount(ctx, erc20Addr); acc != nil { nonce = acc.Nonce balance = acc.Balance } - return k.evmKeeper.SetAccount(ctx, address, statedb.Account{ + return k.evmKeeper.SetAccount(ctx, erc20Addr, statedb.Account{ CodeHash: codeHash, Nonce: nonce, Balance: balance, @@ -69,21 +69,20 @@ func (k Keeper) RegisterERC20CodeHash(ctx sdk.Context, address common.Address) e } // UnRegisterERC20CodeHash sets the codehash for the account to an empty one -func (k Keeper) UnRegisterERC20CodeHash(ctx sdk.Context, erc20Address string) error { +func (k Keeper) UnRegisterERC20CodeHash(ctx sdk.Context, erc20Addr common.Address) error { emptyCodeHash := crypto.Keccak256(nil) - contractAddr := common.HexToAddress(erc20Address) var ( nonce uint64 balance = common.Big0 ) // keep balance and nonce if account exists - if acc := k.evmKeeper.GetAccount(ctx, contractAddr); acc != nil { + if acc := k.evmKeeper.GetAccount(ctx, erc20Addr); acc != nil { nonce = acc.Nonce balance = acc.Balance } - return k.evmKeeper.SetAccount(ctx, contractAddr, statedb.Account{ + return k.evmKeeper.SetAccount(ctx, erc20Addr, statedb.Account{ CodeHash: emptyCodeHash, Nonce: nonce, Balance: balance, diff --git a/x/erc20/keeper/dynamic_precompiles_test.go b/x/erc20/keeper/dynamic_precompiles_test.go index 170300b6..4b4cffea 100644 --- a/x/erc20/keeper/dynamic_precompiles_test.go +++ b/x/erc20/keeper/dynamic_precompiles_test.go @@ -70,7 +70,7 @@ func (suite *KeeperTestSuite) TestRegisterERC20CodeHash() { suite.Require().Equal(uint64(0), acc.Nonce) } - err = suite.network.App.Erc20Keeper.UnRegisterERC20CodeHash(ctx, account.Hex()) + err = suite.network.App.Erc20Keeper.UnRegisterERC20CodeHash(ctx, account) suite.Require().NoError(err) acc = suite.network.App.EVMKeeper.GetAccount(ctx, account) diff --git a/x/erc20/keeper/ibc_callbacks_test.go b/x/erc20/keeper/ibc_callbacks_test.go index a2834d76..fc4161cf 100644 --- a/x/erc20/keeper/ibc_callbacks_test.go +++ b/x/erc20/keeper/ibc_callbacks_test.go @@ -5,8 +5,6 @@ import ( "fmt" "math/big" - testconstants "github.com/evmos/os/testutil/constants" - "cosmossdk.io/math" "github.com/evmos/os/x/erc20/keeper" @@ -58,9 +56,11 @@ func (suite *KeeperTestSuite) TestOnRecvPacket() { packet := mockPacket expAck := ibcmock.MockAcknowledgement + baseDenom, err := sdk.GetBaseDenom() + suite.Require().NoError(err, "failed to get base denom") registeredDenom := cosmosTokenBase coins := sdk.NewCoins( - sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(1000)), + sdk.NewCoin(baseDenom, math.NewInt(1000)), sdk.NewCoin(registeredDenom, math.NewInt(1000)), // some ERC20 token sdk.NewCoin(ibcBase, math.NewInt(1000)), // some IBC coin with a registered token pair ) @@ -213,7 +213,7 @@ func (suite *KeeperTestSuite) TestOnRecvPacket() { receiver: ethsecpAddr, expErc20s: big.NewInt(0), expCoins: sdk.NewCoins( - sdk.NewCoin(testconstants.ExampleAttoDenom, math.NewInt(1000)), + sdk.NewCoin(baseDenom, math.NewInt(1000)), sdk.NewCoin(registeredDenom, math.NewInt(0)), sdk.NewCoin(ibcBase, math.NewInt(1000)), ), @@ -316,6 +316,9 @@ func (suite *KeeperTestSuite) TestConvertCoinToERC20FromPacket() { var ctx sdk.Context senderAddr := "evmos1x2w87cvt5mqjncav4lxy8yfreynn273xn5335v" + baseDenom, err := sdk.GetBaseDenom() + suite.Require().NoError(err) + testCases := []struct { name string malleate func() transfertypes.FungibleTokenPacketData @@ -325,14 +328,14 @@ func (suite *KeeperTestSuite) TestConvertCoinToERC20FromPacket() { { name: "error - invalid sender", malleate: func() transfertypes.FungibleTokenPacketData { - return transfertypes.NewFungibleTokenPacketData("aevmos", "10", "", "", "") + return transfertypes.NewFungibleTokenPacketData(baseDenom, "10", "", "", "") }, expPass: false, }, { name: "pass - is base denom", malleate: func() transfertypes.FungibleTokenPacketData { - return transfertypes.NewFungibleTokenPacketData("aevmos", "10", senderAddr, "", "") + return transfertypes.NewFungibleTokenPacketData(baseDenom, "10", senderAddr, "", "") }, expPass: true, }, @@ -424,7 +427,6 @@ func (suite *KeeperTestSuite) TestOnAcknowledgementPacket() { receiverPk := secp256k1.GenPrivKey() receiver := sdk.AccAddress(receiverPk.PubKey().Address()) - fmt.Println(receiver) testCases := []struct { name string malleate func() diff --git a/x/erc20/keeper/integration_test.go b/x/erc20/keeper/integration_test.go index e384ab25..73e09e76 100644 --- a/x/erc20/keeper/integration_test.go +++ b/x/erc20/keeper/integration_test.go @@ -181,7 +181,7 @@ var _ = Describe("ERC20:", Ordered, func() { }) It("should send coins to the receiver account", func() { - balRes, err := s.handler.GetBalance(s.keyring.GetAccAddr(0), fmt.Sprintf("erc20/%s", contract.Hex())) + balRes, err := s.handler.GetBalanceFromBank(s.keyring.GetAccAddr(0), fmt.Sprintf("erc20/%s", contract.Hex())) Expect(err).To(BeNil()) balanceCoin := balRes.Balance Expect(balanceCoin.Amount).To(Equal(amt)) diff --git a/x/erc20/keeper/params.go b/x/erc20/keeper/params.go index 31e0846e..7dbab85e 100644 --- a/x/erc20/keeper/params.go +++ b/x/erc20/keeper/params.go @@ -23,43 +23,71 @@ func (k Keeper) GetParams(ctx sdk.Context) (params types.Params) { return types.NewParams(enableErc20, nativePrecompiles, dynamicPrecompiles) } -func (k Keeper) UpdateCodeHash(ctx sdk.Context, updatedDynamicPrecompiles []string) error { - // if a precompile is disabled or deleted in the params, we should remove the codehash +// UpdateCodeHash takes in the updated parameters and +// compares the new set of native and dynamic precompiles to the current +// parameter set. +// +// If there is a diff, the ERC-20 code hash for all precompiles that are removed from the list +// will be removed from the store. Meanwhile, for all newly added precompiles the code hash will be +// registered. +func (k Keeper) UpdateCodeHash(ctx sdk.Context, newParams types.Params) error { + oldNativePrecompiles := k.getNativePrecompiles(ctx) oldDynamicPrecompiles := k.getDynamicPrecompiles(ctx) - disabledPrecompiles, enabledPrecompiles := types.GetDisabledAndEnabledPrecompiles(oldDynamicPrecompiles, updatedDynamicPrecompiles) - for _, precompile := range disabledPrecompiles { - if err := k.UnRegisterERC20CodeHash(ctx, precompile); err != nil { + + if err := k.RegisterOrUnregisterERC20CodeHashes(ctx, oldDynamicPrecompiles, newParams.DynamicPrecompiles); err != nil { + return err + } + + return k.RegisterOrUnregisterERC20CodeHashes(ctx, oldNativePrecompiles, newParams.NativePrecompiles) +} + +// RegisterOrUnregisterERC20CodeHashes takes two arrays of precompiles as its argument: +// - previously registered precompiles +// - new set of precompiles to be registered +// +// It then compares the two arrays and registers the code hash for all precompiles that are newly added +// and unregisters the code hash for all precompiles that are removed from the list. +func (k Keeper) RegisterOrUnregisterERC20CodeHashes(ctx sdk.Context, oldPrecompiles, newPrecompiles []string) error { + for _, precompile := range oldPrecompiles { + if slices.Contains(newPrecompiles, precompile) { + continue + } + + if err := k.UnRegisterERC20CodeHash(ctx, common.HexToAddress(precompile)); err != nil { return err } } - // if a precompile is added we should register the account with the erc20 codehash - for _, precompile := range enabledPrecompiles { + for _, precompile := range newPrecompiles { + if slices.Contains(oldPrecompiles, precompile) { + continue + } + if err := k.RegisterERC20CodeHash(ctx, common.HexToAddress(precompile)); err != nil { return err } } + return nil } // SetParams sets the erc20 parameters to the param space. -func (k Keeper) SetParams(ctx sdk.Context, params types.Params) error { - // and keep params equal between different executions - slices.Sort(params.DynamicPrecompiles) - slices.Sort(params.NativePrecompiles) +func (k Keeper) SetParams(ctx sdk.Context, newParams types.Params) error { + // sort to keep params equal between different executions + slices.Sort(newParams.DynamicPrecompiles) + slices.Sort(newParams.NativePrecompiles) - if err := params.Validate(); err != nil { + if err := newParams.Validate(); err != nil { return err } - // update the codehash for enabled or disabled dynamic precompiles - if err := k.UpdateCodeHash(ctx, params.DynamicPrecompiles); err != nil { + if err := k.UpdateCodeHash(ctx, newParams); err != nil { return err } - k.setERC20Enabled(ctx, params.EnableErc20) - k.setDynamicPrecompiles(ctx, params.DynamicPrecompiles) - k.setNativePrecompiles(ctx, params.NativePrecompiles) + k.setERC20Enabled(ctx, newParams.EnableErc20) + k.setDynamicPrecompiles(ctx, newParams.DynamicPrecompiles) + k.setNativePrecompiles(ctx, newParams.NativePrecompiles) return nil } diff --git a/x/erc20/keeper/precompiles.go b/x/erc20/keeper/precompiles.go index 35e0314b..c22dd44b 100644 --- a/x/erc20/keeper/precompiles.go +++ b/x/erc20/keeper/precompiles.go @@ -5,15 +5,14 @@ package keeper import ( "fmt" - "slices" errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/ethereum/go-ethereum/common" "github.com/evmos/os/precompiles/erc20" + "github.com/evmos/os/precompiles/werc20" "github.com/evmos/os/x/erc20/types" "github.com/evmos/os/x/evm/core/vm" - evmkeeper "github.com/evmos/os/x/evm/keeper" ) // GetERC20PrecompileInstance returns the precompile instance for the given address. @@ -23,18 +22,25 @@ func (k Keeper) GetERC20PrecompileInstance( ) (contract vm.PrecompiledContract, found bool, err error) { params := k.GetParams(ctx) - if k.IsAvailableERC20Precompile(¶ms, address) { - precompile, err := k.InstantiateERC20Precompile(ctx, address) - if err != nil { - return nil, false, errorsmod.Wrapf(err, "precompiled contract not initialized: %s", address.String()) - } - return precompile, true, nil + if !k.IsAvailableERC20Precompile(¶ms, address) { + return nil, false, nil } - return nil, false, nil + + isNative := params.IsNativePrecompile(address) + + precompile, err := k.InstantiateERC20Precompile(ctx, address, isNative) + if err != nil { + return nil, false, errorsmod.Wrapf(err, "precompiled contract not initialized: %s", address.String()) + } + + return precompile, true, nil } -// InstantiateERC20Precompile returns an ERC20 precompile instance for the given contract address -func (k Keeper) InstantiateERC20Precompile(ctx sdk.Context, contractAddr common.Address) (vm.PrecompiledContract, error) { +// InstantiateERC20Precompile returns an ERC20 precompile instance for the given +// contract address. +// If the `hasWrappedMethods` boolean is true, the ERC20 instance returned +// exposes methods for `withdraw` and `deposit` as it is common for wrapped tokens. +func (k Keeper) InstantiateERC20Precompile(ctx sdk.Context, contractAddr common.Address, hasWrappedMethods bool) (vm.PrecompiledContract, error) { address := contractAddr.String() // check if the precompile is an ERC20 contract id := k.GetTokenPairID(ctx, address) @@ -46,21 +52,18 @@ func (k Keeper) InstantiateERC20Precompile(ctx sdk.Context, contractAddr common. return nil, fmt.Errorf("token pair not found: %s", address) } - ek, ok := k.evmKeeper.(*evmkeeper.Keeper) - if !ok { - return nil, fmt.Errorf( - "invalid evm keeper in erc20 keeper; expected: %T; got: %T", - k.evmKeeper, - evmkeeper.Keeper{}, - ) + if hasWrappedMethods { + return werc20.NewPrecompile(pair, k.bankKeeper, k.authzKeeper, *k.transferKeeper) } - return erc20.NewPrecompile(pair, k.bankKeeper, k.authzKeeper, *k.transferKeeper, ek) + return erc20.NewPrecompile(pair, k.bankKeeper, k.authzKeeper, *k.transferKeeper) } -// IsAvailableDynamicPrecompile returns true if the given precompile address is contained in the -// EVM keeper's available dynamic precompiles precompiles params. +// IsAvailableERC20Precompile returns true if the given precompile address +// is contained in the params of the erc20 module. +// The available ERC-20 precompiles consist of the dynamic precompiles and the native +// ones. func (k Keeper) IsAvailableERC20Precompile(params *types.Params, address common.Address) bool { - return slices.Contains(params.NativePrecompiles, address.Hex()) || - slices.Contains(params.DynamicPrecompiles, address.Hex()) + return params.IsNativePrecompile(address) || + params.IsDynamicPrecompile(address) } diff --git a/x/erc20/keeper/setup_test.go b/x/erc20/keeper/setup_test.go index 79ccfd3f..282f30ef 100644 --- a/x/erc20/keeper/setup_test.go +++ b/x/erc20/keeper/setup_test.go @@ -8,7 +8,6 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/ethereum/go-ethereum/params" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/os/factory" "github.com/evmos/os/testutil/integration/os/grpc" "github.com/evmos/os/testutil/integration/os/keyring" @@ -40,8 +39,11 @@ func (suite *KeeperTestSuite) SetupTest() { customGenesis := network.CustomGenesisState{} if suite.mintFeeCollector { + baseDenom, err := sdk.GetBaseDenom() + suite.Require().NoError(err, "failed to get base denom") + // mint some coin to fee collector - coins := sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, sdkmath.NewInt(int64(params.TxGas)-1))) + coins := sdk.NewCoins(sdk.NewCoin(baseDenom, sdkmath.NewInt(int64(params.TxGas)-1))) balances := []banktypes.Balance{ { Address: authtypes.NewModuleAddress(authtypes.FeeCollectorName).String(), diff --git a/x/erc20/keeper/token_pairs_test.go b/x/erc20/keeper/token_pairs_test.go index b1beb06e..bad6b7e5 100644 --- a/x/erc20/keeper/token_pairs_test.go +++ b/x/erc20/keeper/token_pairs_test.go @@ -6,7 +6,6 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/ethereum/go-ethereum/common" exampleapp "github.com/evmos/os/example_chain" - testconstants "github.com/evmos/os/testutil/constants" utiltx "github.com/evmos/os/testutil/tx" "github.com/evmos/os/x/erc20/types" ) @@ -59,7 +58,10 @@ func (suite *KeeperTestSuite) TestGetTokenPairs() { } func (suite *KeeperTestSuite) TestGetTokenPairID() { - pair := types.NewTokenPair(utiltx.GenerateAddress(), testconstants.ExampleAttoDenom, types.OWNER_MODULE) + baseDenom, err := sdk.GetBaseDenom() + suite.Require().NoError(err, "failed to get base denom") + + pair := types.NewTokenPair(utiltx.GenerateAddress(), baseDenom, types.OWNER_MODULE) testCases := []struct { name string @@ -86,7 +88,10 @@ func (suite *KeeperTestSuite) TestGetTokenPairID() { } func (suite *KeeperTestSuite) TestGetTokenPair() { - pair := types.NewTokenPair(utiltx.GenerateAddress(), testconstants.ExampleAttoDenom, types.OWNER_MODULE) + baseDenom, err := sdk.GetBaseDenom() + suite.Require().NoError(err, "failed to get base denom") + + pair := types.NewTokenPair(utiltx.GenerateAddress(), baseDenom, types.OWNER_MODULE) testCases := []struct { name string @@ -113,8 +118,11 @@ func (suite *KeeperTestSuite) TestGetTokenPair() { } func (suite *KeeperTestSuite) TestDeleteTokenPair() { + baseDenom, err := sdk.GetBaseDenom() + suite.Require().NoError(err, "failed to get base denom") + var ctx sdk.Context - pair := types.NewTokenPair(utiltx.GenerateAddress(), testconstants.ExampleAttoDenom, types.OWNER_MODULE) + pair := types.NewTokenPair(utiltx.GenerateAddress(), baseDenom, types.OWNER_MODULE) id := pair.GetID() testCases := []struct { @@ -152,8 +160,11 @@ func (suite *KeeperTestSuite) TestDeleteTokenPair() { } func (suite *KeeperTestSuite) TestIsTokenPairRegistered() { + baseDenom, err := sdk.GetBaseDenom() + suite.Require().NoError(err, "failed to get base denom") + var ctx sdk.Context - pair := types.NewTokenPair(utiltx.GenerateAddress(), testconstants.ExampleAttoDenom, types.OWNER_MODULE) + pair := types.NewTokenPair(utiltx.GenerateAddress(), baseDenom, types.OWNER_MODULE) testCases := []struct { name string diff --git a/x/erc20/types/codec.go b/x/erc20/types/codec.go index f6995410..ccedf865 100644 --- a/x/erc20/types/codec.go +++ b/x/erc20/types/codec.go @@ -28,6 +28,7 @@ var ( const ( // Amino names convertERC20Name = "evmos/MsgConvertERC20" + convertCoinName = "evmos/MsgConvertCoin" // keep it for backwards compatibility when querying txs updateParams = "evmos/erc20/MsgUpdateParams" registerERC20 = "evmos/erc20/MsgRegisterERC20" toggleConversion = "evmos/erc20/MsgToggleConversion" @@ -43,6 +44,7 @@ func init() { func RegisterInterfaces(registry codectypes.InterfaceRegistry) { registry.RegisterImplementations( (*sdk.Msg)(nil), + &MsgConvertCoin{}, // keep it for backwards compatibility when querying txs &MsgConvertERC20{}, &MsgUpdateParams{}, &MsgRegisterERC20{}, @@ -64,6 +66,7 @@ func RegisterInterfaces(registry codectypes.InterfaceRegistry) { func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { cdc.RegisterConcrete(&MsgUpdateParams{}, updateParams, nil) cdc.RegisterConcrete(&MsgConvertERC20{}, convertERC20Name, nil) + cdc.RegisterConcrete(&MsgConvertCoin{}, convertCoinName, nil) cdc.RegisterConcrete(&MsgRegisterERC20{}, registerERC20, nil) cdc.RegisterConcrete(&MsgToggleConversion{}, toggleConversion, nil) } diff --git a/x/erc20/types/genesis_test.go b/x/erc20/types/genesis_test.go index 8ad166ab..02fb4cf5 100644 --- a/x/erc20/types/genesis_test.go +++ b/x/erc20/types/genesis_test.go @@ -180,7 +180,6 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { } for _, tc := range testCases { - tc := tc err := tc.genState.Validate() if tc.expPass { suite.Require().NoError(err, tc.name) diff --git a/x/erc20/types/utils.go b/x/erc20/types/utils.go index 509288f5..96819e36 100644 --- a/x/erc20/types/utils.go +++ b/x/erc20/types/utils.go @@ -6,7 +6,6 @@ package types import ( "fmt" "regexp" - "slices" "strings" sdk "github.com/cosmos/cosmos-sdk/types" @@ -92,19 +91,3 @@ func IsModuleAccount(acc sdk.AccountI) bool { _, isModuleAccount := acc.(sdk.ModuleAccountI) return isModuleAccount } - -func GetDisabledAndEnabledPrecompiles(oldDynamicPrecompiles, newDynamicPrecompiles []string) (disabledPrecompiles, enabledPrecompiles []string) { - for _, precompile := range oldDynamicPrecompiles { - if !slices.Contains(newDynamicPrecompiles, precompile) { - disabledPrecompiles = append(disabledPrecompiles, precompile) - } - } - - for _, precompile := range newDynamicPrecompiles { - if !slices.Contains(oldDynamicPrecompiles, precompile) { - enabledPrecompiles = append(enabledPrecompiles, precompile) - } - } - - return disabledPrecompiles, enabledPrecompiles -} diff --git a/x/evm/client/cli/query.go b/x/evm/client/cli/query.go index 112807f9..28c7c446 100644 --- a/x/evm/client/cli/query.go +++ b/x/evm/client/cli/query.go @@ -26,6 +26,7 @@ func GetQueryCmd() *cobra.Command { GetCodeCmd(), GetAccountCmd(), GetParamsCmd(), + GetConfigCmd(), ) return cmd } @@ -171,3 +172,31 @@ func GetParamsCmd() *cobra.Command { flags.AddQueryFlagsToCmd(cmd) return cmd } + +// GetConfigCmd queries the evm configuration +func GetConfigCmd() *cobra.Command { + cmd := &cobra.Command{ + Use: "config", + Short: "Get the evm config", + Long: "Get the evm configuration values.", + Args: cobra.NoArgs, + RunE: func(cmd *cobra.Command, _ []string) error { + clientCtx, err := client.GetClientQueryContext(cmd) + if err != nil { + return err + } + + queryClient := types.NewQueryClient(clientCtx) + + res, err := queryClient.Config(cmd.Context(), &types.QueryConfigRequest{}) + if err != nil { + return err + } + + return clientCtx.PrintProto(res) + }, + } + + flags.AddQueryFlagsToCmd(cmd) + return cmd +} diff --git a/x/evm/client/cli/tx.go b/x/evm/client/cli/tx.go index 33e261bb..b52f634c 100644 --- a/x/evm/client/cli/tx.go +++ b/x/evm/client/cli/tx.go @@ -14,7 +14,6 @@ import ( "github.com/pkg/errors" "github.com/spf13/cobra" - rpctypes "github.com/evmos/os/rpc/types" "github.com/evmos/os/x/evm/types" ) @@ -60,12 +59,9 @@ func NewRawTxCmd() *cobra.Command { return err } - rsp, err := rpctypes.NewQueryClient(clientCtx).Params(cmd.Context(), &types.QueryParamsRequest{}) - if err != nil { - return err - } + baseDenom := types.GetEVMCoinDenom() - tx, err := msg.BuildTx(clientCtx.TxConfig.NewTxBuilder(), rsp.Params.EvmDenom) + tx, err := msg.BuildTx(clientCtx.TxConfig.NewTxBuilder(), baseDenom) if err != nil { return err } diff --git a/x/evm/client/cli/utils_test.go b/x/evm/client/cli/utils_test.go index 2445ac9a..b20a42e2 100644 --- a/x/evm/client/cli/utils_test.go +++ b/x/evm/client/cli/utils_test.go @@ -43,7 +43,6 @@ func TestAddressFormats(t *testing.T) { } for _, tc := range testCases { - tc := tc t.Run(tc.name, func(t *testing.T) { hex, err := accountToHex(tc.addrString) require.Equal(t, tc.expectErr, err != nil, err) diff --git a/x/evm/core/vm/custom_eip_testing.go b/x/evm/core/vm/custom_eip_testing.go new file mode 100644 index 00000000..20860a31 --- /dev/null +++ b/x/evm/core/vm/custom_eip_testing.go @@ -0,0 +1,33 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +//go:build test +// +build test + +// This file is used to allow the testing of EVM configuration initialization +// without the need to introduce testing requirements in the final binary. In +// this case, the file provides the possibility to restore the EIP activator +// functions to the initial state without the need to compile ResetActivators +// in the final binary. + +package vm + +var originalActivators = make(map[string]func(*JumpTable)) + +func init() { + keys := GetActivatorsEipNames() + + originalActivators = make(map[string]func(*JumpTable), len(keys)) + + for _, k := range keys { + originalActivators[k] = activators[k] + } +} + +// ResetActivators resets activators to the original go ethereum activators map +func ResetActivators() { + activators = make(map[string]func(*JumpTable)) + for k, v := range originalActivators { + activators[k] = v + } +} diff --git a/x/evm/genesis.go b/x/evm/genesis.go index 9f3b5c53..a7b8064a 100644 --- a/x/evm/genesis.go +++ b/x/evm/genesis.go @@ -20,8 +20,6 @@ func InitGenesis( accountKeeper types.AccountKeeper, data types.GenesisState, ) []abci.ValidatorUpdate { - k.WithChainID(ctx) - err := k.SetParams(ctx, data.Params) if err != nil { panic(fmt.Errorf("error setting params %s", err)) diff --git a/x/evm/genesis_test.go b/x/evm/genesis_test.go index 29a17e46..f1308ff3 100644 --- a/x/evm/genesis_test.go +++ b/x/evm/genesis_test.go @@ -5,12 +5,12 @@ import ( "testing" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/evmos/os/testutil/constants" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" "github.com/evmos/os/contracts" "github.com/evmos/os/crypto/ethsecp256k1" + testconstants "github.com/evmos/os/testutil/constants" testfactory "github.com/evmos/os/testutil/integration/os/factory" testhandler "github.com/evmos/os/testutil/integration/os/grpc" testkeyring "github.com/evmos/os/testutil/integration/os/keyring" @@ -50,9 +50,6 @@ func TestInitGenesis(t *testing.T) { address := common.HexToAddress(privkey.PubKey().Address().String()) - defaultGenesisWithEVMDenom := types.DefaultGenesisState() - defaultGenesisWithEVMDenom.Params.EvmDenom = constants.ExampleAttoDenom - var ( vmdb *statedb.StateDB ctx sdk.Context @@ -66,15 +63,9 @@ func TestInitGenesis(t *testing.T) { expPanic bool }{ { - name: "fail - default", + name: "pass - default", malleate: func(_ *testnetwork.UnitTestNetwork) {}, genState: types.DefaultGenesisState(), - expPanic: true, // NOTE: we're expecting a panic here because the EVM denom needs to be set - }, - { - name: "pass - default with EVM denom", - malleate: func(_ *testnetwork.UnitTestNetwork) {}, - genState: defaultGenesisWithEVMDenom, expPanic: false, }, { @@ -83,7 +74,7 @@ func TestInitGenesis(t *testing.T) { vmdb.AddBalance(address, big.NewInt(1)) }, genState: &types.GenesisState{ - Params: types.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom), + Params: types.DefaultParams(), Accounts: []types.GenesisAccount{ { Address: address.String(), @@ -99,7 +90,7 @@ func TestInitGenesis(t *testing.T) { name: "account not found", malleate: func(_ *testnetwork.UnitTestNetwork) {}, genState: &types.GenesisState{ - Params: types.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom), + Params: types.DefaultParams(), Accounts: []types.GenesisAccount{ { Address: address.String(), @@ -115,7 +106,7 @@ func TestInitGenesis(t *testing.T) { network.App.AccountKeeper.SetAccount(ctx, acc) }, genState: &types.GenesisState{ - Params: types.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom), + Params: types.DefaultParams(), Accounts: []types.GenesisAccount{ { Address: address.String(), @@ -132,7 +123,7 @@ func TestInitGenesis(t *testing.T) { network.App.AccountKeeper.SetAccount(ctx, acc) }, genState: &types.GenesisState{ - Params: types.DefaultParamsWithEVMDenom(constants.ExampleAttoDenom), + Params: types.DefaultParams(), Accounts: []types.GenesisAccount{ { Address: address.String(), @@ -245,7 +236,7 @@ func TestExportGenesis(t *testing.T) { require.NoError(t, ts.network.NextBlock(), "failed to advance block") genState := evm.ExportGenesis(ts.network.GetContext(), ts.network.App.EVMKeeper) - require.Len(t, genState.Accounts, 2, "expected only one smart contract in the exported genesis") + require.Len(t, genState.Accounts, 3, "expected 3 smart contracts in the exported genesis") // NOTE: 2 deployed above + 1 for the aevmos denomination ERC-20 pair genAddresses := make([]string, 0, len(genState.Accounts)) for _, acc := range genState.Accounts { @@ -253,4 +244,5 @@ func TestExportGenesis(t *testing.T) { } require.Contains(t, genAddresses, contractAddr.Hex(), "expected contract 1 address in exported genesis") require.Contains(t, genAddresses, contractAddr2.Hex(), "expected contract 2 address in exported genesis") + require.Contains(t, genAddresses, testconstants.WEVMOSContractMainnet, "expected mainnet aevmos contract address in exported genesis") } diff --git a/x/evm/keeper/abci.go b/x/evm/keeper/abci.go index 2a082d3f..686ee313 100644 --- a/x/evm/keeper/abci.go +++ b/x/evm/keeper/abci.go @@ -7,12 +7,30 @@ import ( storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" ethtypes "github.com/ethereum/go-ethereum/core/types" + evmtypes "github.com/evmos/os/x/evm/types" ) -// BeginBlock sets the sdk Context and EIP155 chain id to the Keeper. +// BeginBlock emits a base fee event which will be adjusted to the evm decimals func (k *Keeper) BeginBlock(ctx sdk.Context) error { - k.WithChainID(ctx) + logger := ctx.Logger().With("begin_block", "evm") + // Base fee is already set on FeeMarket BeginBlock + // that runs before this one + // We emit this event on the EVM and FeeMarket modules + // because they can be different if the evm denom has 6 decimals + res, err := k.BaseFee(ctx, &evmtypes.QueryBaseFeeRequest{}) + if err != nil { + logger.Error("error when getting base fee", "error", err.Error()) + } + if res != nil && res.BaseFee != nil && !res.BaseFee.IsNil() { + // Store current base fee in event + ctx.EventManager().EmitEvents(sdk.Events{ + sdk.NewEvent( + evmtypes.EventTypeFeeMarket, + sdk.NewAttribute(evmtypes.AttributeKeyBaseFee, res.BaseFee.String()), + ), + }) + } return nil } diff --git a/x/evm/keeper/benchmark_test.go b/x/evm/keeper/benchmark_test.go index df90b6e6..5753de62 100644 --- a/x/evm/keeper/benchmark_test.go +++ b/x/evm/keeper/benchmark_test.go @@ -58,7 +58,7 @@ func DoBenchmark(b *testing.B, txBuilder TxBuilder) { krSigner := utiltx.NewSigner(suite.keyring.GetPrivKey(0)) msg := txBuilder(suite, contractAddr) msg.From = suite.keyring.GetAddr(0).Hex() - err := msg.Sign(ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()), krSigner) + err := msg.Sign(ethtypes.LatestSignerForChainID(types.GetEthChainConfig().ChainID), krSigner) require.NoError(b, err) b.ResetTimer() @@ -80,7 +80,7 @@ func DoBenchmark(b *testing.B, txBuilder TxBuilder) { } } -func BenchmarkTokenTransfer(b *testing.B) { //nolint:dupl +func BenchmarkTokenTransfer(b *testing.B) { erc20Contract, err := testdata.LoadERC20Contract() require.NoError(b, err, "failed to load erc20 contract") @@ -89,7 +89,7 @@ func BenchmarkTokenTransfer(b *testing.B) { //nolint:dupl require.NoError(b, err) nonce := suite.network.App.EVMKeeper.GetNonce(suite.network.GetContext(), suite.keyring.GetAddr(0)) ethTxParams := &types.EvmTxArgs{ - ChainID: suite.network.App.EVMKeeper.ChainID(), + ChainID: types.GetEthChainConfig().ChainID, Nonce: nonce, To: &contract, Amount: big.NewInt(0), @@ -110,7 +110,7 @@ func BenchmarkEmitLogs(b *testing.B) { require.NoError(b, err) nonce := suite.network.App.EVMKeeper.GetNonce(suite.network.GetContext(), suite.keyring.GetAddr(0)) ethTxParams := &types.EvmTxArgs{ - ChainID: suite.network.App.EVMKeeper.ChainID(), + ChainID: types.GetEthChainConfig().ChainID, Nonce: nonce, To: &contract, Amount: big.NewInt(0), @@ -131,7 +131,7 @@ func BenchmarkTokenTransferFrom(b *testing.B) { require.NoError(b, err) nonce := suite.network.App.EVMKeeper.GetNonce(suite.network.GetContext(), suite.keyring.GetAddr(0)) ethTxParams := &types.EvmTxArgs{ - ChainID: suite.network.App.EVMKeeper.ChainID(), + ChainID: types.GetEthChainConfig().ChainID, Nonce: nonce, To: &contract, Amount: big.NewInt(0), @@ -143,7 +143,7 @@ func BenchmarkTokenTransferFrom(b *testing.B) { }) } -func BenchmarkTokenMint(b *testing.B) { //nolint:dupl +func BenchmarkTokenMint(b *testing.B) { erc20Contract, err := testdata.LoadERC20Contract() require.NoError(b, err, "failed to load erc20 contract") @@ -152,7 +152,7 @@ func BenchmarkTokenMint(b *testing.B) { //nolint:dupl require.NoError(b, err) nonce := suite.network.App.EVMKeeper.GetNonce(suite.network.GetContext(), suite.keyring.GetAddr(0)) ethTxParams := &types.EvmTxArgs{ - ChainID: suite.network.App.EVMKeeper.ChainID(), + ChainID: types.GetEthChainConfig().ChainID, Nonce: nonce, To: &contract, Amount: big.NewInt(0), @@ -173,8 +173,9 @@ func BenchmarkMessageCall(b *testing.B) { input, err := messageCallContract.ABI.Pack("benchmarkMessageCall", big.NewInt(10000)) require.NoError(b, err) nonce := suite.network.App.EVMKeeper.GetNonce(suite.network.GetContext(), suite.keyring.GetAddr(0)) + ethCfg := types.GetEthChainConfig() ethTxParams := &types.EvmTxArgs{ - ChainID: suite.network.App.EVMKeeper.ChainID(), + ChainID: ethCfg.ChainID, Nonce: nonce, To: &contract, Amount: big.NewInt(0), @@ -186,7 +187,7 @@ func BenchmarkMessageCall(b *testing.B) { msg.From = suite.keyring.GetAddr(0).Hex() krSigner := utiltx.NewSigner(suite.keyring.GetPrivKey(0)) - err = msg.Sign(ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()), krSigner) + err = msg.Sign(ethtypes.LatestSignerForChainID(ethCfg.ChainID), krSigner) require.NoError(b, err) b.ResetTimer() diff --git a/x/evm/keeper/call_evm.go b/x/evm/keeper/call_evm.go index 74568491..277e4ffb 100644 --- a/x/evm/keeper/call_evm.go +++ b/x/evm/keeper/call_evm.go @@ -18,7 +18,7 @@ import ( "github.com/evmos/os/x/evm/types" ) -// CallEVM performs a smart contract method call using given args +// CallEVM performs a smart contract method call using given args. func (k Keeper) CallEVM( ctx sdk.Context, abi abi.ABI, @@ -42,7 +42,7 @@ func (k Keeper) CallEVM( return resp, nil } -// CallEVMWithData performs a smart contract method call using contract data +// CallEVMWithData performs a smart contract method call using contract data. func (k Keeper) CallEVMWithData( ctx sdk.Context, from common.Address, diff --git a/x/evm/keeper/call_evm_test.go b/x/evm/keeper/call_evm_test.go index be7124e8..9455aa60 100644 --- a/x/evm/keeper/call_evm_test.go +++ b/x/evm/keeper/call_evm_test.go @@ -55,7 +55,7 @@ func (suite *KeeperTestSuite) TestCallEVMWithData() { expPass bool }{ { - "unknown method", + "pass with unknown method", types.ModuleAddress, func() []byte { account := utiltx.GenerateAddress() @@ -63,7 +63,7 @@ func (suite *KeeperTestSuite) TestCallEVMWithData() { return data }, false, - false, + true, }, { "pass", @@ -77,13 +77,13 @@ func (suite *KeeperTestSuite) TestCallEVMWithData() { true, }, { - "fail empty data", + "pass with empty data", types.ModuleAddress, func() []byte { return []byte{} }, false, - false, + true, }, { diff --git a/x/evm/keeper/config.go b/x/evm/keeper/config.go index 229f1266..9cf2a5c5 100644 --- a/x/evm/keeper/config.go +++ b/x/evm/keeper/config.go @@ -4,8 +4,6 @@ package keeper import ( - "math/big" - errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/ethereum/go-ethereum/common" @@ -16,9 +14,9 @@ import ( ) // EVMConfig creates the EVMConfig based on current state -func (k *Keeper) EVMConfig(ctx sdk.Context, proposerAddress sdk.ConsAddress, chainID *big.Int) (*statedb.EVMConfig, error) { +func (k *Keeper) EVMConfig(ctx sdk.Context, proposerAddress sdk.ConsAddress) (*statedb.EVMConfig, error) { params := k.GetParams(ctx) - ethCfg := params.ChainConfig.EthereumConfig(chainID) + ethCfg := types.GetEthChainConfig() // get the coinbase address from the block proposer coinbase, err := k.GetCoinbaseAddress(ctx, proposerAddress) @@ -26,7 +24,7 @@ func (k *Keeper) EVMConfig(ctx sdk.Context, proposerAddress sdk.ConsAddress, cha return nil, errorsmod.Wrap(err, "failed to obtain coinbase address") } - baseFee := k.GetBaseFee(ctx, ethCfg) + baseFee := k.GetBaseFee(ctx) return &statedb.EVMConfig{ Params: params, ChainConfig: ethCfg, @@ -50,7 +48,7 @@ func (k *Keeper) TxConfig(ctx sdk.Context, txHash common.Hash) statedb.TxConfig func (k Keeper) VMConfig(ctx sdk.Context, _ core.Message, cfg *statedb.EVMConfig, tracer vm.EVMLogger) vm.Config { noBaseFee := true if types.IsLondon(cfg.ChainConfig, ctx.BlockHeight()) { - noBaseFee = k.feeMarketKeeper.GetParams(ctx).NoBaseFee + noBaseFee = k.feeMarketWrapper.GetParams(ctx).NoBaseFee } var debug bool diff --git a/x/evm/keeper/fees.go b/x/evm/keeper/fees.go index 58aff1e0..fd31f0bb 100644 --- a/x/evm/keeper/fees.go +++ b/x/evm/keeper/fees.go @@ -36,14 +36,13 @@ func CheckSenderBalance( if balance.IsNegative() || balance.BigInt().Cmp(cost) < 0 { return errorsmod.Wrapf( errortypes.ErrInsufficientFunds, - "sender balance < tx cost (%s < %s)", balance, txData.Cost(), + "sender balance < tx cost (%s < %s)", balance, cost, ) } return nil } -// DeductTxCostsFromUserBalance deducts the fees from the user balance. Returns an -// error if the specified sender address does not exist or the account balance is not sufficient. +// DeductTxCostsFromUserBalance deducts the fees from the user balance. func (k *Keeper) DeductTxCostsFromUserBalance( ctx sdk.Context, fees sdk.Coins, @@ -55,8 +54,10 @@ func (k *Keeper) DeductTxCostsFromUserBalance( return errorsmod.Wrapf(err, "account not found for sender %s", from) } - // deduct the full gas cost from the user balance - if err := authante.DeductFees(k.bankKeeper, ctx, signerAcc, fees); err != nil { + // Deduct fees from the user balance. Notice that it is used + // the bankWrapper to properly convert fees from the 18 decimals + // representation to the original one before calling into the bank keeper. + if err := authante.DeductFees(k.bankWrapper, ctx, signerAcc, fees); err != nil { return errorsmod.Wrapf(err, "failed to deduct full gas cost %s from the user %s balance", fees, from) } diff --git a/x/evm/keeper/fees_test.go b/x/evm/keeper/fees_test.go index 1ceeabcd..9078d87d 100644 --- a/x/evm/keeper/fees_test.go +++ b/x/evm/keeper/fees_test.go @@ -8,7 +8,6 @@ import ( "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" ethparams "github.com/ethereum/go-ethereum/params" - testconstants "github.com/evmos/os/testutil/constants" utiltx "github.com/evmos/os/testutil/tx" "github.com/evmos/os/x/evm/keeper" evmtypes "github.com/evmos/os/x/evm/types" @@ -500,12 +499,12 @@ func (suite *KeeperTestSuite) TestVerifyFeeAndDeductTxCostsFromUserBalance() { txData, _ := evmtypes.UnpackTxData(tx.Data) - evmParams := suite.network.App.EVMKeeper.GetParams(suite.network.GetContext()) - ethCfg := evmParams.GetChainConfig().EthereumConfig(nil) - baseFee := suite.network.App.EVMKeeper.GetBaseFee(suite.network.GetContext(), ethCfg) + baseFee := suite.network.App.EVMKeeper.GetBaseFee(suite.network.GetContext()) priority := evmtypes.GetTxPriority(txData, baseFee) - fees, err := keeper.VerifyFee(txData, testconstants.ExampleAttoDenom, baseFee, false, false, suite.network.GetContext().IsCheckTx()) + baseDenom := evmtypes.GetEVMCoinDenom() + + fees, err := keeper.VerifyFee(txData, baseDenom, baseFee, false, false, suite.network.GetContext().IsCheckTx()) if tc.expectPassVerify { suite.Require().NoError(err, "valid test %d failed - '%s'", i, tc.name) if tc.enableFeemarket { @@ -513,7 +512,7 @@ func (suite *KeeperTestSuite) TestVerifyFeeAndDeductTxCostsFromUserBalance() { suite.Require().Equal( fees, sdk.NewCoins( - sdk.NewCoin(testconstants.ExampleAttoDenom, sdkmath.NewIntFromBigInt(txData.EffectiveFee(baseFee))), + sdk.NewCoin(baseDenom, sdkmath.NewIntFromBigInt(txData.EffectiveFee(baseFee.TruncateInt().BigInt()))), ), "valid test %d failed, fee value is wrong - '%s'", i, tc.name, ) @@ -522,7 +521,7 @@ func (suite *KeeperTestSuite) TestVerifyFeeAndDeductTxCostsFromUserBalance() { suite.Require().Equal( fees, sdk.NewCoins( - sdk.NewCoin(testconstants.ExampleAttoDenom, tc.gasPrice.Mul(sdkmath.NewIntFromUint64(tc.gasLimit))), + sdk.NewCoin(baseDenom, tc.gasPrice.Mul(sdkmath.NewIntFromUint64(tc.gasLimit))), ), "valid test %d failed, fee value is wrong - '%s'", i, tc.name, ) diff --git a/x/evm/keeper/gas.go b/x/evm/keeper/gas.go index 3c09c462..ea81d223 100644 --- a/x/evm/keeper/gas.go +++ b/x/evm/keeper/gas.go @@ -43,8 +43,7 @@ func (k *Keeper) RefundGas(ctx sdk.Context, msg core.Message, leftoverGas uint64 refundedCoins := sdk.Coins{sdk.NewCoin(denom, sdkmath.NewIntFromBigInt(remaining))} // refund to sender from the fee collector module account, which is the escrow account in charge of collecting tx fees - - err := k.bankKeeper.SendCoinsFromModuleToAccount(ctx, authtypes.FeeCollectorName, msg.From().Bytes(), refundedCoins) + err := k.bankWrapper.SendCoinsFromModuleToAccount(ctx, authtypes.FeeCollectorName, msg.From().Bytes(), refundedCoins) if err != nil { err = errorsmod.Wrapf(errortypes.ErrInsufficientFunds, "fee collector account failed to refund fees: %s", err.Error()) return errorsmod.Wrapf(err, "failed to refund %d leftover gas (%s)", leftoverGas, refundedCoins.String()) diff --git a/x/evm/keeper/grpc_query.go b/x/evm/keeper/grpc_query.go index 9d753fd8..b4ab6a58 100644 --- a/x/evm/keeper/grpc_query.go +++ b/x/evm/keeper/grpc_query.go @@ -40,7 +40,8 @@ const ( defaultTraceTimeout = 5 * time.Second ) -// Account implements the Query/Account gRPC method +// Account implements the Query/Account gRPC method. The method returns the +// balance of the account in 18 decimals representation. func (k Keeper) Account(c context.Context, req *types.QueryAccountRequest) (*types.QueryAccountResponse, error) { if req == nil { return nil, status.Error(codes.InvalidArgument, "empty request") @@ -132,7 +133,8 @@ func (k Keeper) ValidatorAccount(c context.Context, req *types.QueryValidatorAcc return &res, nil } -// Balance implements the Query/Balance gRPC method +// Balance implements the Query/Balance gRPC method. The method returns the 18 +// decimal representation of the account balance. func (k Keeper) Balance(c context.Context, req *types.QueryBalanceRequest) (*types.QueryBalanceResponse, error) { if req == nil { return nil, status.Error(codes.InvalidArgument, "empty request") @@ -231,11 +233,8 @@ func (k Keeper) EthCall(c context.Context, req *types.EthCallRequest) (*types.Ms if err != nil { return nil, status.Error(codes.InvalidArgument, err.Error()) } - chainID, err := getChainID(ctx, req.ChainId) - if err != nil { - return nil, status.Error(codes.InvalidArgument, err.Error()) - } - cfg, err := k.EVMConfig(ctx, GetProposerAddress(ctx, req.ProposerAddress), chainID) + + cfg, err := k.EVMConfig(ctx, GetProposerAddress(ctx, req.ProposerAddress)) if err != nil { return nil, status.Error(codes.Internal, err.Error()) } @@ -276,17 +275,13 @@ func (k Keeper) EstimateGasInternal(c context.Context, req *types.EthCallRequest } ctx := sdk.UnwrapSDKContext(c) - chainID, err := getChainID(ctx, req.ChainId) - if err != nil { - return nil, status.Error(codes.InvalidArgument, err.Error()) - } if req.GasCap < ethparams.TxGas { return nil, status.Errorf(codes.InvalidArgument, "gas cap cannot be lower than %d", ethparams.TxGas) } var args types.TransactionArgs - err = json.Unmarshal(req.Args, &args) + err := json.Unmarshal(req.Args, &args) if err != nil { return nil, status.Error(codes.InvalidArgument, err.Error()) } @@ -317,7 +312,7 @@ func (k Keeper) EstimateGasInternal(c context.Context, req *types.EthCallRequest } gasCap = hi - cfg, err := k.EVMConfig(ctx, GetProposerAddress(ctx, req.ProposerAddress), chainID) + cfg, err := k.EVMConfig(ctx, GetProposerAddress(ctx, req.ProposerAddress)) if err != nil { return nil, status.Error(codes.Internal, "failed to load evm config") } @@ -336,7 +331,9 @@ func (k Keeper) EstimateGasInternal(c context.Context, req *types.EthCallRequest // Recap the highest gas limit with account's available balance. if msg.GasFeeCap().BitLen() != 0 { - balance := k.bankKeeper.GetBalance(ctx, sdk.AccAddress(args.From.Bytes()), k.GetParams(ctx).EvmDenom) + baseDenom := types.GetEVMCoinDenom() + + balance := k.bankWrapper.GetBalance(ctx, sdk.AccAddress(args.From.Bytes()), baseDenom) available := balance.Amount transfer := "0" if args.Value != nil { @@ -429,7 +426,10 @@ func (k Keeper) EstimateGasInternal(c context.Context, req *types.EthCallRequest if failed { if result != nil && result.VmError != vm.ErrOutOfGas.Error() { if result.VmError == vm.ErrExecutionReverted.Error() { - return nil, types.NewExecErrorWithReason(result.Ret) + return &types.EstimateGasResponse{ + Ret: result.Ret, + VmError: result.VmError, + }, nil } return nil, errors.New(result.VmError) } @@ -469,17 +469,13 @@ func (k Keeper) TraceTx(c context.Context, req *types.QueryTraceTxRequest) (*typ Block: &tmproto.BlockParams{MaxGas: req.BlockMaxGas}, }) - chainID, err := getChainID(ctx, req.ChainId) - if err != nil { - return nil, status.Error(codes.InvalidArgument, err.Error()) - } - cfg, err := k.EVMConfig(ctx, GetProposerAddress(ctx, req.ProposerAddress), chainID) + cfg, err := k.EVMConfig(ctx, GetProposerAddress(ctx, req.ProposerAddress)) if err != nil { return nil, status.Errorf(codes.Internal, "failed to load evm config: %s", err.Error()) } // compute and use base fee of the height that is being traced - baseFee := k.feeMarketKeeper.CalculateBaseFee(ctx) + baseFee := k.feeMarketWrapper.CalculateBaseFee(ctx) if baseFee != nil { cfg.BaseFee = baseFee } @@ -567,18 +563,13 @@ func (k Keeper) TraceBlock(c context.Context, req *types.QueryTraceBlockRequest) Block: &tmproto.BlockParams{MaxGas: req.BlockMaxGas}, }) - chainID, err := getChainID(ctx, req.ChainId) - if err != nil { - return nil, status.Error(codes.InvalidArgument, err.Error()) - } - - cfg, err := k.EVMConfig(ctx, GetProposerAddress(ctx, req.ProposerAddress), chainID) + cfg, err := k.EVMConfig(ctx, GetProposerAddress(ctx, req.ProposerAddress)) if err != nil { return nil, status.Error(codes.Internal, "failed to load evm config") } // compute and use base fee of height that is being traced - baseFee := k.feeMarketKeeper.CalculateBaseFee(ctx) + baseFee := k.feeMarketWrapper.CalculateBaseFee(ctx) if baseFee != nil { cfg.BaseFee = baseFee } @@ -708,9 +699,7 @@ func (k *Keeper) traceTx( func (k Keeper) BaseFee(c context.Context, _ *types.QueryBaseFeeRequest) (*types.QueryBaseFeeResponse, error) { ctx := sdk.UnwrapSDKContext(c) - params := k.GetParams(ctx) - ethCfg := params.ChainConfig.EthereumConfig(k.eip155ChainID) - baseFee := k.GetBaseFee(ctx, ethCfg) + baseFee := k.GetBaseFee(ctx) res := &types.QueryBaseFeeResponse{} if baseFee != nil { @@ -721,10 +710,18 @@ func (k Keeper) BaseFee(c context.Context, _ *types.QueryBaseFeeRequest) (*types return res, nil } -// getChainID parse chainID from current context if not provided -func getChainID(ctx sdk.Context, chainID int64) (*big.Int, error) { - if chainID == 0 { - return evmostypes.ParseChainID(ctx.ChainID()) - } - return big.NewInt(chainID), nil +// GlobalMinGasPrice implements the Query/GlobalMinGasPrice gRPC method +func (k Keeper) GlobalMinGasPrice(c context.Context, _ *types.QueryGlobalMinGasPriceRequest) (*types.QueryGlobalMinGasPriceResponse, error) { + ctx := sdk.UnwrapSDKContext(c) + minGasPrice := k.GetMinGasPrice(ctx).TruncateInt() + return &types.QueryGlobalMinGasPriceResponse{MinGasPrice: minGasPrice}, nil +} + +// Config implements the Query/Config gRPC method +func (k Keeper) Config(_ context.Context, _ *types.QueryConfigRequest) (*types.QueryConfigResponse, error) { + config := types.GetChainConfig() + config.Denom = types.GetEVMCoinDenom() + config.Decimals = uint64(types.GetEVMCoinDecimals()) + + return &types.QueryConfigResponse{Config: config}, nil } diff --git a/x/evm/keeper/grpc_query_test.go b/x/evm/keeper/grpc_query_test.go index ad83d5c5..7af6938b 100644 --- a/x/evm/keeper/grpc_query_test.go +++ b/x/evm/keeper/grpc_query_test.go @@ -30,6 +30,7 @@ import ( const invalidAddress = "0x0000" func (suite *KeeperTestSuite) TestQueryAccount() { + baseDenom := types.GetEVMCoinDenom() testCases := []struct { msg string getReq func() *types.QueryAccountRequest @@ -49,7 +50,7 @@ func (suite *KeeperTestSuite) TestQueryAccount() { { "success", func() *types.QueryAccountRequest { - amt := sdk.Coins{sdk.NewInt64Coin(testconstants.ExampleAttoDenom, 100)} + amt := sdk.Coins{sdk.NewInt64Coin(baseDenom, 100)} // Add new unfunded key index := suite.keyring.AddKey() @@ -187,6 +188,8 @@ func (suite *KeeperTestSuite) TestQueryCosmosAccount() { } func (suite *KeeperTestSuite) TestQueryBalance() { + baseDenom := types.GetEVMCoinDenom() + testCases := []struct { msg string getReqAndResp func() (*types.QueryBalanceRequest, *types.QueryBalanceResponse) @@ -209,7 +212,7 @@ func (suite *KeeperTestSuite) TestQueryBalance() { addr := suite.keyring.GetAddr(newIndex) balance := int64(100) - amt := sdk.Coins{sdk.NewInt64Coin(testconstants.ExampleAttoDenom, balance)} + amt := sdk.Coins{sdk.NewInt64Coin(baseDenom, balance)} err := suite.network.App.BankKeeper.MintCoins(suite.network.GetContext(), types.ModuleName, amt) suite.Require().NoError(err) @@ -434,7 +437,7 @@ func (suite *KeeperTestSuite) TestQueryTxLogs() { func (suite *KeeperTestSuite) TestQueryParams() { ctx := suite.network.GetContext() - expParams := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + expParams := types.DefaultParams() expParams.ActiveStaticPrecompiles = types.AvailableStaticPrecompiles res, err := suite.network.GetEvmClient().Params(ctx, &types.QueryParamsRequest{}) @@ -609,7 +612,7 @@ func (suite *KeeperTestSuite) TestEstimateGas() { func() types.TransactionArgs { addr := suite.keyring.GetAddr(0) hexBigInt := hexutil.Big(*big.NewInt(1)) - balance := suite.network.App.BankKeeper.GetBalance(suite.network.GetContext(), sdk.AccAddress(addr.Bytes()), "aevmos") + balance := suite.network.App.BankKeeper.GetBalance(suite.network.GetContext(), sdk.AccAddress(addr.Bytes()), types.GetEVMCoinDenom()) value := balance.Amount.Add(sdkmath.NewInt(1)) return types.TransactionArgs{ To: &common.Address{}, @@ -628,7 +631,7 @@ func (suite *KeeperTestSuite) TestEstimateGas() { func() types.TransactionArgs { addr := suite.keyring.GetAddr(0) hexBigInt := hexutil.Big(*big.NewInt(1)) - balance := suite.network.App.BankKeeper.GetBalance(suite.network.GetContext(), sdk.AccAddress(addr.Bytes()), "aevmos") + balance := suite.network.App.BankKeeper.GetBalance(suite.network.GetContext(), sdk.AccAddress(addr.Bytes()), types.GetEVMCoinDenom()) value := balance.Amount.Sub(sdkmath.NewInt(1)) return types.TransactionArgs{ To: &common.Address{}, @@ -1151,25 +1154,12 @@ func (suite *KeeperTestSuite) TestTraceTx() { expectedTrace: "{\"gas\":34780,\"failed\":false,\"returnValue\":\"0000000000000000000000000000000000000000000000000000000000000001\",\"structLogs\":[{\"pc\":0,\"op\":\"PUSH1\",\"gas\":", // expFinalGas: 26744, // gas consumed in traceTx setup (GetProposerAddr + CalculateBaseFee) + gas consumed in malleate func }, - { - msg: "invalid chain id", - getRequest: func() types.QueryTraceTxRequest { - defaultRequest := getDefaultTraceTxRequest(suite.network) - defaultRequest.ChainId = -1 - return defaultRequest - }, - getPredecessors: func() []*types.MsgEthereumTx { - return nil - }, - expPass: false, - }, } for _, tc := range testCases { - tc := tc suite.Run(fmt.Sprintf("Case %s", tc.msg), func() { // Clean up per test - defaultEvmParams := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultEvmParams := types.DefaultParams() err := suite.network.App.EVMKeeper.SetParams(suite.network.GetContext(), defaultEvmParams) suite.Require().NoError(err) @@ -1349,23 +1339,9 @@ func (suite *KeeperTestSuite) TestTraceBlock() { expPass: true, traceResponse: "[{\"error\":\"rpc error: code = Internal desc = tracer not found\"}]", }, - { - msg: "invalid chain id", - getRequest: func() types.QueryTraceBlockRequest { - defaultReq := getDefaultTraceBlockRequest(suite.network) - defaultReq.ChainId = -1 - return defaultReq - }, - getAdditionalTxs: func() []*types.MsgEthereumTx { - return nil - }, - expPass: true, - traceResponse: "[{\"error\":\"rpc error: code = Internal desc = invalid chain id for signer\"}]", - }, } for _, tc := range testCases { - tc := tc suite.Run(fmt.Sprintf("Case %s", tc.msg), func() { // Start from fresh block suite.Require().NoError(suite.network.NextBlock()) @@ -1491,7 +1467,7 @@ func (suite *KeeperTestSuite) TestQueryBaseFee() { feemarketDefault := feemarkettypes.DefaultParams() suite.Require().NoError(suite.network.App.FeeMarketKeeper.SetParams(suite.network.GetContext(), feemarketDefault)) - evmDefault := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + evmDefault := types.DefaultParams() suite.Require().NoError(suite.network.App.EVMKeeper.SetParams(suite.network.GetContext(), evmDefault)) }, @@ -1506,16 +1482,22 @@ func (suite *KeeperTestSuite) TestQueryBaseFee() { feemarketDefault := feemarkettypes.DefaultParams() suite.Require().NoError(suite.network.App.FeeMarketKeeper.SetParams(suite.network.GetContext(), feemarketDefault)) - evmDefault := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + chainConfig := types.DefaultChainConfig(suite.network.GetChainID()) maxInt := sdkmath.NewInt(math.MaxInt64) - evmDefault.ChainConfig.LondonBlock = &maxInt - evmDefault.ChainConfig.LondonBlock = &maxInt - evmDefault.ChainConfig.ArrowGlacierBlock = &maxInt - evmDefault.ChainConfig.GrayGlacierBlock = &maxInt - evmDefault.ChainConfig.MergeNetsplitBlock = &maxInt - evmDefault.ChainConfig.ShanghaiBlock = &maxInt - evmDefault.ChainConfig.CancunBlock = &maxInt - suite.Require().NoError(suite.network.App.EVMKeeper.SetParams(suite.network.GetContext(), evmDefault)) + chainConfig.LondonBlock = &maxInt + chainConfig.ArrowGlacierBlock = &maxInt + chainConfig.GrayGlacierBlock = &maxInt + chainConfig.MergeNetsplitBlock = &maxInt + chainConfig.ShanghaiBlock = &maxInt + chainConfig.CancunBlock = &maxInt + + configurator := types.NewEVMConfigurator() + configurator.ResetTestConfig() + err := configurator. + WithChainConfig(chainConfig). + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(types.EighteenDecimals)). + Configure() + suite.Require().NoError(err) }, true, }, @@ -1530,27 +1512,29 @@ func (suite *KeeperTestSuite) TestQueryBaseFee() { feemarketDefault.NoBaseFee = true suite.Require().NoError(suite.network.App.FeeMarketKeeper.SetParams(suite.network.GetContext(), feemarketDefault)) - evmDefault := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + evmDefault := types.DefaultParams() suite.Require().NoError(suite.network.App.EVMKeeper.SetParams(suite.network.GetContext(), evmDefault)) }, true, }, } + + // Save initial configure to restore it between tests + denom := types.GetEVMCoinDenom() + decimals := types.GetEVMCoinDecimals() + chainConfig := types.DefaultChainConfig(suite.network.GetChainID()) + for _, tc := range testCases { - tc := tc suite.Run(tc.name, func() { // Set necessary params tc.setParams() - // Get the expected response expResp := tc.getExpResp() - // Function under test res, err := suite.network.GetEvmClient().BaseFee( suite.network.GetContext(), &types.QueryBaseFeeRequest{}, ) - if tc.expPass { suite.Require().NotNil(res) suite.Require().Equal(expResp, res, tc.name) @@ -1558,8 +1542,14 @@ func (suite *KeeperTestSuite) TestQueryBaseFee() { } else { suite.Require().Error(err) } - suite.Require().NoError(suite.network.NextBlock()) + configurator := types.NewEVMConfigurator() + configurator.ResetTestConfig() + err = configurator. + WithChainConfig(chainConfig). + WithEVMCoinInfo(denom, uint8(decimals)). + Configure() + suite.Require().NoError(err) }) } } @@ -1666,7 +1656,7 @@ func (suite *KeeperTestSuite) TestEthCall() { } // Reset params - defaultEvmParams := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultEvmParams := types.DefaultParams() err = suite.network.App.EVMKeeper.SetParams(suite.network.GetContext(), defaultEvmParams) suite.Require().NoError(err) }) diff --git a/x/evm/keeper/integration_test.go b/x/evm/keeper/integration_test.go index 75ce1561..6d81b832 100644 --- a/x/evm/keeper/integration_test.go +++ b/x/evm/keeper/integration_test.go @@ -17,7 +17,6 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/evmos/os/contracts" "github.com/evmos/os/precompiles/staking" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/os/factory" "github.com/evmos/os/testutil/integration/os/grpc" testkeyring "github.com/evmos/os/testutil/integration/os/keyring" @@ -69,7 +68,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func When("the params have default values", Ordered, func() { BeforeAll(func() { // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() err := integrationutils.UpdateEvmParams( integrationutils.UpdateParamsInput{ Tf: s.factory, @@ -83,13 +82,13 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func DescribeTable("Executes a transfer transaction", func(getTxArgs func() evmtypes.EvmTxArgs) { senderKey := s.keyring.GetKey(0) receiverKey := s.keyring.GetKey(1) - denom := s.network.GetDenom() + denom := s.network.GetBaseDenom() - senderPrevBalanceResponse, err := s.grpcHandler.GetBalance(senderKey.AccAddr, denom) + senderPrevBalanceResponse, err := s.grpcHandler.GetBalanceFromBank(senderKey.AccAddr, denom) Expect(err).To(BeNil()) senderPrevBalance := senderPrevBalanceResponse.GetBalance().Amount - receiverPrevBalanceResponse, err := s.grpcHandler.GetBalance(receiverKey.AccAddr, denom) + receiverPrevBalanceResponse, err := s.grpcHandler.GetBalanceFromBank(receiverKey.AccAddr, denom) Expect(err).To(BeNil()) receiverPrevBalance := receiverPrevBalanceResponse.GetBalance().Amount @@ -109,13 +108,13 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func // Check sender balance after transaction senderBalanceResultBeforeFees := senderPrevBalance.Sub(math.NewInt(transferAmount)) - senderAfterBalance, err := s.grpcHandler.GetBalance(senderKey.AccAddr, denom) + senderAfterBalance, err := s.grpcHandler.GetBalanceFromBank(senderKey.AccAddr, denom) Expect(err).To(BeNil()) Expect(senderAfterBalance.GetBalance().Amount.LTE(senderBalanceResultBeforeFees)).To(BeTrue()) // Check receiver balance after transaction receiverBalanceResult := receiverPrevBalance.Add(math.NewInt(transferAmount)) - receverAfterBalanceResponse, err := s.grpcHandler.GetBalance(receiverKey.AccAddr, denom) + receverAfterBalanceResponse, err := s.grpcHandler.GetBalanceFromBank(receiverKey.AccAddr, denom) Expect(err).To(BeNil()) Expect(receverAfterBalanceResponse.GetBalance().Amount).To(Equal(receiverBalanceResult)) }, @@ -380,7 +379,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func }, // Entry("transfer and call fail with CALL permission policy set to restricted", func() evmtypes.Params { // // Set params to default values - // defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + // defaultParams := evmtypes.DefaultParams() // defaultParams.AccessControl.Call = evmtypes.AccessControlType{ // AccessType: evmtypes.AccessTypeRestricted, // } @@ -392,7 +391,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("transfer and call succeed with CALL permission policy set to default and CREATE permission policy set to restricted", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Create = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypeRestricted, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -405,7 +404,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("transfer and call are successful with CALL permission policy set to permissionless and address not blocked", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissionless, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -418,7 +417,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("transfer fails with signer blocked and call succeeds with signer NOT blocked permission policy set to permissionless", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissionless, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -431,7 +430,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("transfer succeeds with signer NOT blocked and call fails with signer blocked permission policy set to permissionless", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissionless, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -444,7 +443,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("transfer and call succeeds with CALL permission policy set to permissioned and signer whitelisted on both", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissioned, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -457,7 +456,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("transfer and call fails with CALL permission policy set to permissioned and signer not whitelisted on both", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissioned, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -530,7 +529,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("Create and call is successful with create permission policy set to permissionless and address not blocked ", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Create = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissionless, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -543,7 +542,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("Create fails with create permission policy set to permissionless and signer is blocked ", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Create = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissionless, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -556,7 +555,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("Create and call is successful with call permission policy set to permissionless and address not blocked ", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissionless, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -569,7 +568,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("Create is successful and call fails with call permission policy set to permissionless and address blocked ", func() evmtypes.Params { blockedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissionless, AccessControlList: []string{s.keyring.GetAddr(blockedSignerIndex).String()}, @@ -581,7 +580,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func ), Entry("Create fails create permission policy set to restricted", func() evmtypes.Params { // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Create = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypeRestricted, } @@ -592,7 +591,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func ), Entry("Create succeeds and call fails when call permission policy set to restricted", func() evmtypes.Params { // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypeRestricted, } @@ -604,7 +603,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("Create and call are successful with create permission policy set to permissioned and signer whitelisted", func() evmtypes.Params { whitelistedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Create = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissioned, AccessControlList: []string{s.keyring.GetAddr(whitelistedSignerIndex).String()}, @@ -617,7 +616,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("Create fails with create permission policy set to permissioned and signer NOT whitelisted", func() evmtypes.Params { whitelistedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Create = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissioned, AccessControlList: []string{s.keyring.GetAddr(whitelistedSignerIndex).String()}, @@ -630,7 +629,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("Create and call are successful with call permission policy set to permissioned and signer whitelisted", func() evmtypes.Params { whitelistedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissioned, AccessControlList: []string{s.keyring.GetAddr(whitelistedSignerIndex).String()}, @@ -643,7 +642,7 @@ var _ = Describe("Handling a MsgEthereumTx message", Label("EVM"), Ordered, func Entry("Create succeeds and call fails with call permission policy set to permissioned and signer NOT whitelisted", func() evmtypes.Params { whitelistedSignerIndex := 1 // Set params to default values - defaultParams := evmtypes.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := evmtypes.DefaultParams() defaultParams.AccessControl.Call = evmtypes.AccessControlType{ AccessType: evmtypes.AccessTypePermissioned, AccessControlList: []string{s.keyring.GetAddr(whitelistedSignerIndex).String()}, diff --git a/x/evm/keeper/keeper.go b/x/evm/keeper/keeper.go index ecc905f6..412d1835 100644 --- a/x/evm/keeper/keeper.go +++ b/x/evm/keeper/keeper.go @@ -4,7 +4,6 @@ package keeper import ( - "fmt" "math/big" errorsmod "cosmossdk.io/errors" @@ -19,10 +18,10 @@ import ( "github.com/ethereum/go-ethereum/core" ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/params" - evmostypes "github.com/evmos/os/types" "github.com/evmos/os/x/evm/core/vm" "github.com/evmos/os/x/evm/statedb" "github.com/evmos/os/x/evm/types" + "github.com/evmos/os/x/evm/wrappers" ) // Keeper grants access to the EVM module state and implements the go-ethereum StateDB interface. @@ -44,18 +43,18 @@ type Keeper struct { // access to account state accountKeeper types.AccountKeeper - // update balance and accounting operations with coins - bankKeeper types.BankKeeper + + // bankWrapper is used to convert the Cosmos SDK coin used in the EVM to the + // proper decimal representation. + bankWrapper types.BankWrapper + // access historical headers for EVM state transition execution stakingKeeper types.StakingKeeper // fetch EIP1559 base fee and parameters - feeMarketKeeper types.FeeMarketKeeper + feeMarketWrapper *wrappers.FeeMarketWrapper // erc20Keeper interface needed to instantiate erc20 precompiles erc20Keeper types.Erc20Keeper - // chain ID number obtained from the context's chain id - eip155ChainID *big.Int - // Tracer used to collect execution traces from the EVM transaction execution tracer string @@ -63,7 +62,7 @@ type Keeper struct { ss paramstypes.Subspace // precompiles defines the map of all available precompiled smart contracts. - // Some these precompiled contracts might not be active depending on the EVM + // Some of these precompiled contracts might not be active depending on the EVM // parameters. precompiles map[common.Address]vm.PrecompiledContract } @@ -91,19 +90,22 @@ func NewKeeper( panic(err) } + bankWrapper := wrappers.NewBankWrapper(bankKeeper) + feeMarketWrapper := wrappers.NewFeeMarketWrapper(fmk) + // NOTE: we pass in the parameter space to the CommitStateDB in order to use custom denominations for the EVM operations return &Keeper{ - cdc: cdc, - authority: authority, - accountKeeper: ak, - bankKeeper: bankKeeper, - stakingKeeper: sk, - feeMarketKeeper: fmk, - storeKey: storeKey, - transientKey: transientKey, - tracer: tracer, - erc20Keeper: erc20Keeper, - ss: ss, + cdc: cdc, + authority: authority, + accountKeeper: ak, + bankWrapper: bankWrapper, + stakingKeeper: sk, + feeMarketWrapper: feeMarketWrapper, + storeKey: storeKey, + transientKey: transientKey, + tracer: tracer, + erc20Keeper: erc20Keeper, + ss: ss, } } @@ -112,25 +114,6 @@ func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", types.ModuleName) } -// WithChainID sets the chain id to the local variable in the keeper -func (k *Keeper) WithChainID(ctx sdk.Context) { - chainID, err := evmostypes.ParseChainID(ctx.ChainID()) - if err != nil { - panic(err) - } - - if k.eip155ChainID != nil && k.eip155ChainID.Cmp(chainID) != 0 { - panic(fmt.Sprintf("eip-155 chain id already set (%s); cannot change to %s", k.eip155ChainID, chainID)) - } - - k.eip155ChainID = chainID -} - -// ChainID returns the EIP155 chain ID for the EVM context -func (k Keeper) ChainID() *big.Int { - return k.eip155ChainID -} - // ---------------------------------------------------------------------------- // Block Bloom // Required by Web3 API. @@ -184,12 +167,7 @@ func (k Keeper) SetTxIndexTransient(ctx sdk.Context, index uint64) { // GetTxIndexTransient returns EVM transaction index on the current block. func (k Keeper) GetTxIndexTransient(ctx sdk.Context) uint64 { store := ctx.TransientStore(k.transientKey) - bz := store.Get(types.KeyPrefixTransientTxIndex) - if len(bz) == 0 { - return 0 - } - - return sdk.BigEndianToUint64(bz) + return sdk.BigEndianToUint64(store.Get(types.KeyPrefixTransientTxIndex)) } // ---------------------------------------------------------------------------- @@ -199,12 +177,7 @@ func (k Keeper) GetTxIndexTransient(ctx sdk.Context) uint64 { // GetLogSizeTransient returns EVM log index on the current block. func (k Keeper) GetLogSizeTransient(ctx sdk.Context) uint64 { store := ctx.TransientStore(k.transientKey) - bz := store.Get(types.KeyPrefixTransientLogSize) - if len(bz) == 0 { - return 0 - } - - return sdk.BigEndianToUint64(bz) + return sdk.BigEndianToUint64(store.Get(types.KeyPrefixTransientLogSize)) } // SetLogSizeTransient fetches the current EVM log index from the transient store, increases its @@ -256,7 +229,7 @@ func (k *Keeper) GetAccountWithoutBalance(ctx sdk.Context, addr common.Address) } } -// GetAccountOrEmpty returns empty account if not exist +// GetAccountOrEmpty returns empty account if not exist. func (k *Keeper) GetAccountOrEmpty(ctx sdk.Context, addr common.Address) statedb.Account { acct := k.GetAccount(ctx, addr) if acct != nil { @@ -281,17 +254,13 @@ func (k *Keeper) GetNonce(ctx sdk.Context, addr common.Address) uint64 { return acct.GetSequence() } -// GetBalance load account's balance of gas token +// GetBalance load account's balance of gas token. func (k *Keeper) GetBalance(ctx sdk.Context, addr common.Address) *big.Int { cosmosAddr := sdk.AccAddress(addr.Bytes()) - evmParams := k.GetParams(ctx) - evmDenom := evmParams.GetEvmDenom() - // if node is pruned, params is empty. Return invalid value - // TODO: if the params are empty, why not return an error here instead of an "invalid value"? - if evmDenom == "" { - return big.NewInt(-1) - } - coin := k.bankKeeper.GetBalance(ctx, cosmosAddr, evmDenom) + + // Get the balance via bank wrapper to convert it to 18 decimals if needed. + coin := k.bankWrapper.GetBalance(ctx, cosmosAddr, types.GetEVMCoinDenom()) + return coin.Amount.BigInt() } @@ -299,15 +268,12 @@ func (k *Keeper) GetBalance(ctx sdk.Context, addr common.Address) *big.Int { // - `nil`: london hardfork not enabled. // - `0`: london hardfork enabled but feemarket is not enabled. // - `n`: both london hardfork and feemarket are enabled. -func (k Keeper) GetBaseFee(ctx sdk.Context, ethCfg *params.ChainConfig) *big.Int { - return k.getBaseFee(ctx, types.IsLondon(ethCfg, ctx.BlockHeight())) -} - -func (k Keeper) getBaseFee(ctx sdk.Context, london bool) *big.Int { - if !london { +func (k Keeper) GetBaseFee(ctx sdk.Context) *big.Int { + ethCfg := types.GetEthChainConfig() + if !types.IsLondon(ethCfg, ctx.BlockHeight()) { return nil } - baseFee := k.feeMarketKeeper.GetBaseFee(ctx) + baseFee := k.feeMarketWrapper.GetBaseFee(ctx) if baseFee == nil { // return 0 if feemarket not enabled. baseFee = big.NewInt(0) @@ -317,7 +283,13 @@ func (k Keeper) getBaseFee(ctx sdk.Context, london bool) *big.Int { // GetMinGasMultiplier returns the MinGasMultiplier param from the fee market module func (k Keeper) GetMinGasMultiplier(ctx sdk.Context) math.LegacyDec { - return k.feeMarketKeeper.GetParams(ctx).MinGasMultiplier + return k.feeMarketWrapper.GetParams(ctx).MinGasMultiplier +} + +// GetMinGasPrice returns the MinGasPrice param from the fee market module +// adapted according to the evm denom decimals +func (k Keeper) GetMinGasPrice(ctx sdk.Context) math.LegacyDec { + return k.feeMarketWrapper.GetParams(ctx).MinGasPrice } // ResetTransientGasUsed reset gas used to prepare for execution of current cosmos tx, called in ante handler. @@ -329,11 +301,7 @@ func (k Keeper) ResetTransientGasUsed(ctx sdk.Context) { // GetTransientGasUsed returns the gas used by current cosmos tx. func (k Keeper) GetTransientGasUsed(ctx sdk.Context) uint64 { store := ctx.TransientStore(k.transientKey) - bz := store.Get(types.KeyPrefixTransientGasUsed) - if len(bz) == 0 { - return 0 - } - return sdk.BigEndianToUint64(bz) + return sdk.BigEndianToUint64(store.Get(types.KeyPrefixTransientGasUsed)) } // SetTransientGasUsed sets the gas used by current cosmos tx. diff --git a/x/evm/keeper/keeper_test.go b/x/evm/keeper/keeper_test.go index 09aa3eb0..1a0e3ee2 100644 --- a/x/evm/keeper/keeper_test.go +++ b/x/evm/keeper/keeper_test.go @@ -8,59 +8,12 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/evmos/os/utils" - "github.com/evmos/os/x/evm/keeper" "github.com/evmos/os/x/evm/statedb" evmtypes "github.com/evmos/os/x/evm/types" "github.com/ethereum/go-ethereum/common" ) -func (suite *KeeperTestSuite) TestWithChainID() { - testCases := []struct { - name string - chainID string - expChainID int64 - expPanic bool - }{ - { - "fail - chainID is empty", - "", - 0, - true, - }, - { - "success - Evmos mainnet chain ID", - "evmos_9001-2", - 9001, - false, - }, - { - "success - Evmos testnet chain ID", - "evmos_9000-4", - 9000, - false, - }, - } - - for _, tc := range testCases { - suite.Run(tc.name, func() { - keeper := keeper.Keeper{} - ctx := suite.network.GetContext().WithChainID(tc.chainID) - - if tc.expPanic { - suite.Require().Panics(func() { - keeper.WithChainID(ctx) - }) - } else { - suite.Require().NotPanics(func() { - keeper.WithChainID(ctx) - suite.Require().Equal(tc.expChainID, keeper.ChainID().Int64()) - }) - } - }) - } -} - func (suite *KeeperTestSuite) TestBaseFee() { testCases := []struct { name string @@ -79,10 +32,8 @@ func (suite *KeeperTestSuite) TestBaseFee() { suite.enableFeemarket = tc.enableFeemarket suite.enableLondonHF = tc.enableLondonHF suite.SetupTest() - suite.Require().NoError(suite.network.App.EVMKeeper.BeginBlock(suite.network.GetContext())) - params := suite.network.App.EVMKeeper.GetParams(suite.network.GetContext()) - ethCfg := params.ChainConfig.EthereumConfig(suite.network.App.EVMKeeper.ChainID()) - baseFee := suite.network.App.EVMKeeper.GetBaseFee(suite.network.GetContext(), ethCfg) + + baseFee := suite.network.App.EVMKeeper.GetBaseFee(suite.network.GetContext()) suite.Require().Equal(tc.expectBaseFee, baseFee) }) } diff --git a/x/evm/keeper/msg_server_test.go b/x/evm/keeper/msg_server_test.go index 66ec3c92..60e7232c 100644 --- a/x/evm/keeper/msg_server_test.go +++ b/x/evm/keeper/msg_server_test.go @@ -8,7 +8,6 @@ import ( sdktypes "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/os/utils" "github.com/evmos/os/x/evm/types" ) @@ -52,7 +51,6 @@ func (suite *KeeperTestSuite) TestEthereumTx() { } for _, tc := range testCases { - tc := tc suite.Run(tc.name, func() { msg := tc.getMsg() @@ -101,7 +99,7 @@ func (suite *KeeperTestSuite) TestUpdateParams() { getMsg: func() *types.MsgUpdateParams { return &types.MsgUpdateParams{ Authority: authtypes.NewModuleAddress(govtypes.ModuleName).String(), - Params: types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom), + Params: types.DefaultParams(), } }, expectedErr: nil, @@ -109,7 +107,6 @@ func (suite *KeeperTestSuite) TestUpdateParams() { } for _, tc := range testCases { - tc := tc suite.Run("MsgUpdateParams", func() { msg := tc.getMsg() _, err := suite.network.App.EVMKeeper.UpdateParams(suite.network.GetContext(), msg) diff --git a/x/evm/keeper/params_benchmark_test.go b/x/evm/keeper/params_benchmark_test.go index 8c1bd02f..b70241e2 100644 --- a/x/evm/keeper/params_benchmark_test.go +++ b/x/evm/keeper/params_benchmark_test.go @@ -3,14 +3,13 @@ package keeper_test import ( "testing" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/x/evm/types" ) func BenchmarkSetParams(b *testing.B) { suite := KeeperTestSuite{} suite.SetupTest() - params := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + params := types.DefaultParams() b.ReportAllocs() b.ResetTimer() diff --git a/x/evm/keeper/params_test.go b/x/evm/keeper/params_test.go index 7c86d02e..dd1e221f 100644 --- a/x/evm/keeper/params_test.go +++ b/x/evm/keeper/params_test.go @@ -25,21 +25,6 @@ func (suite *KeeperTestSuite) TestParams() { }, true, }, - { - "success - EvmDenom param is set to \"inj\" and can be retrieved correctly", - func() interface{} { - params := defaultChainEVMParams - params.EvmDenom = "inj" - err := suite.network.App.EVMKeeper.SetParams(suite.network.GetContext(), params) - suite.Require().NoError(err) - return params.EvmDenom - }, - func() interface{} { - evmParams := suite.network.App.EVMKeeper.GetParams(suite.network.GetContext()) - return evmParams.GetEvmDenom() - }, - true, - }, { "success - Check Access Control Create param is set to restricted and can be retrieved correctly", func() interface{} { @@ -93,21 +78,6 @@ func (suite *KeeperTestSuite) TestParams() { }, true, }, - { - "success - Check ChainConfig param is set to the default value and can be retrieved correctly", - func() interface{} { - params := defaultChainEVMParams - params.ChainConfig = types.DefaultChainConfig() - err := suite.network.App.EVMKeeper.SetParams(suite.network.GetContext(), params) - suite.Require().NoError(err) - return params.ChainConfig - }, - func() interface{} { - evmParams := suite.network.App.EVMKeeper.GetParams(suite.network.GetContext()) - return evmParams.GetChainConfig() - }, - true, - }, { name: "success - Active precompiles are sorted when setting params", paramsFun: func() interface{} { diff --git a/x/evm/keeper/precompiles.go b/x/evm/keeper/precompiles.go index d1c9cd90..8acfca7e 100644 --- a/x/evm/keeper/precompiles.go +++ b/x/evm/keeper/precompiles.go @@ -57,9 +57,13 @@ func (k *Keeper) GetPrecompilesCallHook(ctx sdktypes.Context) types.CallHook { return err } + // If the precompile instance is created, we have to update the EVM with + // only the recipient precompile and add it's address to the access list. if found { evm.WithPrecompiles(precompiles.Map, precompiles.Addresses) + evm.StateDB.AddAddressToAccessList(recipient) } + return nil } } diff --git a/x/evm/keeper/setup_test.go b/x/evm/keeper/setup_test.go index 25e555a4..5723e834 100644 --- a/x/evm/keeper/setup_test.go +++ b/x/evm/keeper/setup_test.go @@ -9,7 +9,6 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/ethereum/go-ethereum/params" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/os/factory" "github.com/evmos/os/testutil/integration/os/grpc" "github.com/evmos/os/testutil/integration/os/keyring" @@ -62,22 +61,9 @@ func (suite *KeeperTestSuite) SetupTest() { } customGenesis[feemarkettypes.ModuleName] = feemarketGenesis - if !s.enableLondonHF { - evmGenesis := evmtypes.DefaultGenesisState() - maxInt := sdkmath.NewInt(math.MaxInt64) - evmGenesis.Params.EvmDenom = testconstants.ExampleAttoDenom - evmGenesis.Params.ChainConfig.LondonBlock = &maxInt - evmGenesis.Params.ChainConfig.ArrowGlacierBlock = &maxInt - evmGenesis.Params.ChainConfig.GrayGlacierBlock = &maxInt - evmGenesis.Params.ChainConfig.MergeNetsplitBlock = &maxInt - evmGenesis.Params.ChainConfig.ShanghaiBlock = &maxInt - evmGenesis.Params.ChainConfig.CancunBlock = &maxInt - customGenesis[evmtypes.ModuleName] = evmGenesis - } - if s.mintFeeCollector { // mint some coin to fee collector - coins := sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, sdkmath.NewInt(int64(params.TxGas)-1))) + coins := sdk.NewCoins(sdk.NewCoin(evmtypes.GetEVMCoinDenom(), sdkmath.NewInt(int64(params.TxGas)-1))) balances := []banktypes.Balance{ { Address: authtypes.NewModuleAddress(authtypes.FeeCollectorName).String(), @@ -100,4 +86,27 @@ func (suite *KeeperTestSuite) SetupTest() { s.factory = tf s.handler = gh s.keyring = keys + + chainConfig := evmtypes.DefaultChainConfig(suite.network.GetChainID()) + if !s.enableLondonHF { + maxInt := sdkmath.NewInt(math.MaxInt64) + chainConfig.LondonBlock = &maxInt + chainConfig.ArrowGlacierBlock = &maxInt + chainConfig.GrayGlacierBlock = &maxInt + chainConfig.MergeNetsplitBlock = &maxInt + chainConfig.ShanghaiBlock = &maxInt + chainConfig.CancunBlock = &maxInt + } + // get the denom and decimals set on chain initialization + // because we'll need to set them again when resetting the chain config + denom := evmtypes.GetEVMCoinDenom() //nolint:staticcheck + decimals := evmtypes.GetEVMCoinDecimals() //nolint:staticcheck + + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + err := configurator. + WithChainConfig(chainConfig). + WithEVMCoinInfo(denom, uint8(decimals)). + Configure() + suite.Require().NoError(err) } diff --git a/x/evm/keeper/state_transition.go b/x/evm/keeper/state_transition.go index 2fcbaeef..af824009 100644 --- a/x/evm/keeper/state_transition.go +++ b/x/evm/keeper/state_transition.go @@ -32,7 +32,6 @@ import ( // NOTE: the RANDOM opcode is currently not supported since it requires // RANDAO implementation. See https://github.com/evmos/ethermint/pull/1520#pullrequestreview-1200504697 // for more information. - func (k *Keeper) NewEVM( ctx sdk.Context, msg core.Message, @@ -150,7 +149,7 @@ func (k Keeper) GetHashFn(ctx sdk.Context) vm.GetHashFunc { func (k *Keeper) ApplyTransaction(ctx sdk.Context, tx *ethtypes.Transaction) (*types.MsgEthereumTxResponse, error) { var bloom *big.Int - cfg, err := k.EVMConfig(ctx, sdk.ConsAddress(ctx.BlockHeader().ProposerAddress), k.eip155ChainID) + cfg, err := k.EVMConfig(ctx, sdk.ConsAddress(ctx.BlockHeader().ProposerAddress)) if err != nil { return nil, errorsmod.Wrap(err, "failed to load evm config") } @@ -189,8 +188,10 @@ func (k *Keeper) ApplyTransaction(ctx sdk.Context, tx *ethtypes.Transaction) (*t commit() } + evmDenom := types.GetEVMCoinDenom() + // refund gas in order to match the Ethereum gas consumption instead of the default SDK one. - if err = k.RefundGas(ctx, msg, msg.Gas()-res.GasUsed, cfg.Params.EvmDenom); err != nil { + if err = k.RefundGas(ctx, msg, msg.Gas()-res.GasUsed, evmDenom); err != nil { return nil, errorsmod.Wrapf(err, "failed to refund gas leftover gas to sender %s", msg.From()) } @@ -214,7 +215,7 @@ func (k *Keeper) ApplyTransaction(ctx sdk.Context, tx *ethtypes.Transaction) (*t // ApplyMessage calls ApplyMessageWithConfig with an empty TxConfig. func (k *Keeper) ApplyMessage(ctx sdk.Context, msg core.Message, tracer vm.EVMLogger, commit bool) (*types.MsgEthereumTxResponse, error) { - cfg, err := k.EVMConfig(ctx, sdk.ConsAddress(ctx.BlockHeader().ProposerAddress), k.eip155ChainID) + cfg, err := k.EVMConfig(ctx, sdk.ConsAddress(ctx.BlockHeader().ProposerAddress)) if err != nil { return nil, errorsmod.Wrap(err, "failed to load evm config") } @@ -308,7 +309,10 @@ func (k *Keeper) ApplyMessageWithConfig( // access list preparation is moved from ante handler to here, because it's needed when `ApplyMessage` is called // under contexts where ante handlers are not run, for example `eth_call` and `eth_estimateGas`. if rules := cfg.ChainConfig.Rules(big.NewInt(ctx.BlockHeight()), cfg.ChainConfig.MergeNetsplitBlock != nil); rules.IsBerlin { - stateDB.PrepareAccessList(msg.From(), msg.To(), evm.ActivePrecompiles(rules), msg.AccessList()) + // The access list is prepared without any precompile because it is + // filled with only the recipient precompile address in the EVM'hook + // call. + stateDB.PrepareAccessList(msg.From(), msg.To(), []common.Address{}, msg.AccessList()) } if contractCreation { diff --git a/x/evm/keeper/state_transition_benchmark_test.go b/x/evm/keeper/state_transition_benchmark_test.go index 4892fdb4..56370bf2 100644 --- a/x/evm/keeper/state_transition_benchmark_test.go +++ b/x/evm/keeper/state_transition_benchmark_test.go @@ -163,7 +163,7 @@ func BenchmarkApplyTransaction(b *testing.B) { //nolint:dupl suite := KeeperTestSuite{enableLondonHF: true} suite.SetupTest() - ethSigner := ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()) + ethSigner := ethtypes.LatestSignerForChainID(evmtypes.GetEthChainConfig().ChainID) b.ResetTimer() b.ReportAllocs() @@ -192,7 +192,7 @@ func BenchmarkApplyTransactionWithLegacyTx(b *testing.B) { //nolint:dupl suite := KeeperTestSuite{enableLondonHF: true} suite.SetupTest() - ethSigner := ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()) + ethSigner := ethtypes.LatestSignerForChainID(evmtypes.GetEthChainConfig().ChainID) b.ResetTimer() b.ReportAllocs() @@ -221,7 +221,7 @@ func BenchmarkApplyTransactionWithDynamicFeeTx(b *testing.B) { suite := KeeperTestSuite{enableFeemarket: true, enableLondonHF: true} suite.SetupTest() - ethSigner := ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()) + ethSigner := ethtypes.LatestSignerForChainID(evmtypes.GetEthChainConfig().ChainID) b.ResetTimer() b.ReportAllocs() @@ -251,9 +251,8 @@ func BenchmarkApplyMessage(b *testing.B) { suite := KeeperTestSuite{enableLondonHF: true} suite.SetupTest() - params := suite.network.App.EVMKeeper.GetParams(suite.network.GetContext()) - ethCfg := params.ChainConfig.EthereumConfig(suite.network.App.EVMKeeper.ChainID()) - signer := ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()) + ethCfg := evmtypes.GetEthChainConfig() + signer := ethtypes.LatestSignerForChainID(ethCfg.ChainID) b.ResetTimer() b.ReportAllocs() @@ -288,9 +287,8 @@ func BenchmarkApplyMessageWithLegacyTx(b *testing.B) { suite := KeeperTestSuite{enableLondonHF: true} suite.SetupTest() - params := suite.network.App.EVMKeeper.GetParams(suite.network.GetContext()) - ethCfg := params.ChainConfig.EthereumConfig(suite.network.App.EVMKeeper.ChainID()) - signer := ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()) + ethCfg := evmtypes.GetEthChainConfig() + signer := ethtypes.LatestSignerForChainID(ethCfg.ChainID) b.ResetTimer() b.ReportAllocs() @@ -305,7 +303,7 @@ func BenchmarkApplyMessageWithLegacyTx(b *testing.B) { ethCfg, krSigner, signer, - ethtypes.LegacyTxType, + ethtypes.AccessListTxType, nil, nil, ) @@ -324,9 +322,8 @@ func BenchmarkApplyMessageWithDynamicFeeTx(b *testing.B) { suite := KeeperTestSuite{enableFeemarket: true, enableLondonHF: true} suite.SetupTest() - params := suite.network.App.EVMKeeper.GetParams(suite.network.GetContext()) - ethCfg := params.ChainConfig.EthereumConfig(suite.network.App.EVMKeeper.ChainID()) - signer := ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()) + ethCfg := evmtypes.GetEthChainConfig() + signer := ethtypes.LatestSignerForChainID(ethCfg.ChainID) b.ResetTimer() b.ReportAllocs() diff --git a/x/evm/keeper/state_transition_test.go b/x/evm/keeper/state_transition_test.go index a00b3fa1..d9385375 100644 --- a/x/evm/keeper/state_transition_test.go +++ b/x/evm/keeper/state_transition_test.go @@ -19,7 +19,6 @@ import ( gethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/params" exampleapp "github.com/evmos/os/example_chain" - testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/testutil/integration/os/factory" "github.com/evmos/os/testutil/integration/os/grpc" testkeyring "github.com/evmos/os/testutil/integration/os/keyring" @@ -255,15 +254,10 @@ func (suite *KeeperTestSuite) TestGetEthIntrinsicGas() { for _, tc := range testCases { suite.Run(fmt.Sprintf("Case %s", tc.name), func() { - params := suite.network.App.EVMKeeper.GetParams( - suite.network.GetContext(), - ) - ethCfg := params.ChainConfig.EthereumConfig( - suite.network.App.EVMKeeper.ChainID(), - ) + ethCfg := types.GetEthChainConfig() ethCfg.HomesteadBlock = big.NewInt(2) ethCfg.IstanbulBlock = big.NewInt(3) - signer := gethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()) + signer := gethtypes.LatestSignerForChainID(ethCfg.ChainID) ctx := suite.network.GetContext().WithBlockHeight(tc.height) @@ -365,8 +359,10 @@ func (suite *KeeperTestSuite) TestRefundGas() { // for refund to work // NOTE: everything should happen within the same block for // feecollector account to remain funded + baseDenom := types.GetEVMCoinDenom() + coins := sdk.NewCoins(sdk.NewCoin( - testconstants.ExampleAttoDenom, + baseDenom, sdkmath.NewInt(6e18), )) balances := []banktypes.Balance{ @@ -465,7 +461,7 @@ func (suite *KeeperTestSuite) TestRefundGas() { unitNetwork.GetContext(), coreMsg, refund, - unitNetwork.GetDenom(), + unitNetwork.GetBaseDenom(), ) if tc.noError { @@ -541,25 +537,19 @@ func (suite *KeeperTestSuite) TestEVMConfig() { defaultChainEVMParams := exampleapp.NewEVMGenesisState().Params proposerAddress := suite.network.GetContext().BlockHeader().ProposerAddress - eip155ChainID := suite.network.GetEIP155ChainID() cfg, err := suite.network.App.EVMKeeper.EVMConfig( suite.network.GetContext(), proposerAddress, - eip155ChainID, ) suite.Require().NoError(err) suite.Require().Equal(defaultChainEVMParams, cfg.Params) // london hardfork is enabled by default suite.Require().Equal(big.NewInt(0), cfg.BaseFee) - suite.Require().Equal(defaultChainEVMParams.ChainConfig.EthereumConfig(big.NewInt(testconstants.ExampleEIP155ChainID)), cfg.ChainConfig) + suite.Require().Equal(types.GetEthChainConfig(), cfg.ChainConfig) validators := suite.network.GetValidators() proposerHextAddress := utils.ValidatorConsAddressToHex(validators[0].OperatorAddress) suite.Require().Equal(proposerHextAddress, cfg.CoinBase) - - networkChainID := suite.network.GetEIP155ChainID() - networkConfig := defaultChainEVMParams.ChainConfig.EthereumConfig(networkChainID) - suite.Require().Equal(networkConfig, cfg.ChainConfig) } func (suite *KeeperTestSuite) TestApplyMessage() { @@ -571,7 +561,6 @@ func (suite *KeeperTestSuite) TestApplyMessage() { config, err := suite.network.App.EVMKeeper.EVMConfig( suite.network.GetContext(), proposerAddress, - suite.network.GetEIP155ChainID(), ) suite.Require().NoError(err) @@ -632,9 +621,7 @@ func (suite *KeeperTestSuite) TestApplyMessageWithConfig() { suite.Require().NoError(err) return msg }, - func() types.Params { - return types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) - }, + types.DefaultParams, feemarkettypes.DefaultParams, false, false, @@ -654,7 +641,7 @@ func (suite *KeeperTestSuite) TestApplyMessageWithConfig() { return msg }, func() types.Params { - defaultParams := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := types.DefaultParams() defaultParams.AccessControl = types.AccessControl{ Call: types.AccessControlType{ AccessType: types.AccessTypeRestricted, @@ -679,7 +666,7 @@ func (suite *KeeperTestSuite) TestApplyMessageWithConfig() { return msg }, func() types.Params { - defaultParams := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) + defaultParams := types.DefaultParams() defaultParams.AccessControl = types.AccessControl{ Create: types.AccessControlType{ AccessType: types.AccessTypeRestricted, @@ -704,9 +691,7 @@ func (suite *KeeperTestSuite) TestApplyMessageWithConfig() { suite.Require().NoError(err) return msg }, - func() types.Params { - return types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom) - }, + types.DefaultParams, func() feemarkettypes.Params { paramsRes, err := suite.handler.GetFeeMarketParams() suite.Require().NoError(err) @@ -744,7 +729,6 @@ func (suite *KeeperTestSuite) TestApplyMessageWithConfig() { config, err := suite.network.App.EVMKeeper.EVMConfig( suite.network.GetContext(), proposerAddress, - suite.network.GetEIP155ChainID(), ) suite.Require().NoError(err) diff --git a/x/evm/keeper/statedb.go b/x/evm/keeper/statedb.go index 9ea81b90..802baf7a 100644 --- a/x/evm/keeper/statedb.go +++ b/x/evm/keeper/statedb.go @@ -7,7 +7,6 @@ import ( "errors" "math/big" - sdkmath "cosmossdk.io/math" "cosmossdk.io/store/prefix" storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" @@ -111,27 +110,18 @@ func (k *Keeper) ForEachStorage(ctx sdk.Context, addr common.Address, cb func(ke func (k *Keeper) SetBalance(ctx sdk.Context, addr common.Address, amount *big.Int) error { cosmosAddr := sdk.AccAddress(addr.Bytes()) - params := k.GetParams(ctx) - coin := k.bankKeeper.GetBalance(ctx, cosmosAddr, params.EvmDenom) - balance := coin.Amount.BigInt() - delta := new(big.Int).Sub(amount, balance) + coin := k.bankWrapper.GetBalance(ctx, cosmosAddr, types.GetEVMCoinDenom()) + + delta := new(big.Int).Sub(amount, coin.Amount.BigInt()) switch delta.Sign() { case 1: // mint - coins := sdk.NewCoins(sdk.NewCoin(params.EvmDenom, sdkmath.NewIntFromBigInt(delta))) - if err := k.bankKeeper.MintCoins(ctx, types.ModuleName, coins); err != nil { - return err - } - if err := k.bankKeeper.SendCoinsFromModuleToAccount(ctx, types.ModuleName, cosmosAddr, coins); err != nil { + if err := k.bankWrapper.MintAmountToAccount(ctx, cosmosAddr, delta); err != nil { return err } case -1: // burn - coins := sdk.NewCoins(sdk.NewCoin(params.EvmDenom, sdkmath.NewIntFromBigInt(new(big.Int).Neg(delta)))) - if err := k.bankKeeper.SendCoinsFromAccountToModule(ctx, cosmosAddr, types.ModuleName, coins); err != nil { - return err - } - if err := k.bankKeeper.BurnCoins(ctx, types.ModuleName, coins); err != nil { + if err := k.bankWrapper.BurnAmountFromAccount(ctx, cosmosAddr, new(big.Int).Neg(delta)); err != nil { return err } default: diff --git a/x/evm/keeper/statedb_test.go b/x/evm/keeper/statedb_test.go index 3b33765d..f6feb146 100644 --- a/x/evm/keeper/statedb_test.go +++ b/x/evm/keeper/statedb_test.go @@ -1,6 +1,7 @@ package keeper_test import ( + "bytes" "fmt" "math/big" "testing" @@ -402,6 +403,11 @@ func TestIterateContracts(t *testing.T) { ) network.App.EVMKeeper.IterateContracts(network.GetContext(), func(addr common.Address, codeHash common.Hash) bool { + // NOTE: we only care about the 2 contracts deployed above, not the ERC20 native precompile for the aevmos denomination + if bytes.Equal(addr.Bytes(), common.HexToAddress(testconstants.WEVMOSContractMainnet).Bytes()) { + return false + } + foundAddrs = append(foundAddrs, addr) foundHashes = append(foundHashes, codeHash) return false @@ -689,7 +695,7 @@ func (suite *KeeperTestSuite) CreateTestTx(msg *types.MsgEthereumTx, priv crypto suite.Require().NoError(err) clientCtx := client.Context{}.WithTxConfig(suite.network.App.GetTxConfig()) - ethSigner := ethtypes.LatestSignerForChainID(suite.network.App.EVMKeeper.ChainID()) + ethSigner := ethtypes.LatestSignerForChainID(types.GetEthChainConfig().ChainID) txBuilder := clientCtx.TxConfig.NewTxBuilder() builder, ok := txBuilder.(authtx.ExtensionOptionsTxBuilder) diff --git a/x/evm/keeper/utils_test.go b/x/evm/keeper/utils_test.go index a36b19bd..a2ca28de 100644 --- a/x/evm/keeper/utils_test.go +++ b/x/evm/keeper/utils_test.go @@ -4,23 +4,24 @@ import ( "encoding/json" "math/big" + "github.com/stretchr/testify/require" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" - "github.com/evmos/os/server/config" + + servercfg "github.com/evmos/os/server/config" utiltx "github.com/evmos/os/testutil/tx" "github.com/evmos/os/x/evm/keeper/testdata" "github.com/evmos/os/x/evm/statedb" evmtypes "github.com/evmos/os/x/evm/types" - "github.com/stretchr/testify/require" ) func (suite *KeeperTestSuite) EvmDenom() string { - ctx := suite.network.GetContext() - rsp, _ := suite.network.GetEvmClient().Params(ctx, &evmtypes.QueryParamsRequest{}) - return rsp.Params.EvmDenom + return evmtypes.GetEVMCoinDenom() } func (suite *KeeperTestSuite) StateDB() *statedb.StateDB { @@ -29,7 +30,7 @@ func (suite *KeeperTestSuite) StateDB() *statedb.StateDB { // DeployTestContract deploy a test erc20 contract and returns the contract address func (suite *KeeperTestSuite) DeployTestContract(t require.TestingT, ctx sdk.Context, owner common.Address, supply *big.Int) common.Address { - chainID := suite.network.App.EVMKeeper.ChainID() + chainID := evmtypes.GetEthChainConfig().ChainID erc20Contract, err := testdata.LoadERC20Contract() require.NoError(t, err, "failed to load contract") @@ -49,18 +50,21 @@ func (suite *KeeperTestSuite) DeployTestContract(t require.TestingT, ctx sdk.Con require.NoError(t, err) res, err := suite.network.GetEvmClient().EstimateGas(ctx, &evmtypes.EthCallRequest{ Args: args, - GasCap: config.DefaultGasCap, + GasCap: servercfg.DefaultGasCap, ProposerAddress: suite.network.GetContext().BlockHeader().ProposerAddress, }) require.NoError(t, err) + baseFeeRes, err := suite.network.GetEvmClient().BaseFee(ctx, &evmtypes.QueryBaseFeeRequest{}) + require.NoError(t, err) + var erc20DeployTx *evmtypes.MsgEthereumTx if suite.enableFeemarket { ethTxParams := &evmtypes.EvmTxArgs{ ChainID: chainID, Nonce: nonce, GasLimit: res.Gas, - GasFeeCap: suite.network.App.FeeMarketKeeper.GetBaseFee(suite.network.GetContext()), + GasFeeCap: baseFeeRes.BaseFee.BigInt(), GasTipCap: big.NewInt(1), Input: data, Accesses: ðtypes.AccessList{}, @@ -88,7 +92,7 @@ func (suite *KeeperTestSuite) DeployTestContract(t require.TestingT, ctx sdk.Con func (suite *KeeperTestSuite) TransferERC20Token(t require.TestingT, contractAddr, from, to common.Address, amount *big.Int) *evmtypes.MsgEthereumTx { ctx := suite.network.GetContext() - chainID := suite.network.App.EVMKeeper.ChainID() + chainID := evmtypes.GetEthChainConfig().ChainID erc20Contract, err := testdata.LoadERC20Contract() require.NoError(t, err, "failed to load contract") @@ -105,6 +109,8 @@ func (suite *KeeperTestSuite) TransferERC20Token(t require.TestingT, contractAdd require.NoError(t, err) nonce := suite.network.App.EVMKeeper.GetNonce(suite.network.GetContext(), suite.keyring.GetAddr(0)) + baseFeeRes, err := suite.network.GetEvmClient().BaseFee(ctx, &evmtypes.QueryBaseFeeRequest{}) + require.NoError(t, err, "failed to get base fee") var ercTransferTx *evmtypes.MsgEthereumTx if suite.enableFeemarket { @@ -113,7 +119,7 @@ func (suite *KeeperTestSuite) TransferERC20Token(t require.TestingT, contractAdd Nonce: nonce, To: &contractAddr, GasLimit: res.Gas, - GasFeeCap: suite.network.App.FeeMarketKeeper.GetBaseFee(suite.network.GetContext()), + GasFeeCap: baseFeeRes.BaseFee.BigInt(), GasTipCap: big.NewInt(1), Input: transferData, Accesses: ðtypes.AccessList{}, @@ -144,7 +150,7 @@ func (suite *KeeperTestSuite) TransferERC20Token(t require.TestingT, contractAdd // DeployTestMessageCall deploy a test erc20 contract and returns the contract address func (suite *KeeperTestSuite) DeployTestMessageCall(t require.TestingT) common.Address { ctx := suite.network.GetContext() - chainID := suite.network.App.EVMKeeper.ChainID() + chainID := evmtypes.GetEthChainConfig().ChainID testMsgCall, err := testdata.LoadMessageCallContract() require.NoError(t, err) @@ -159,12 +165,14 @@ func (suite *KeeperTestSuite) DeployTestMessageCall(t require.TestingT) common.A res, err := suite.network.GetEvmClient().EstimateGas(ctx, &evmtypes.EthCallRequest{ Args: args, - GasCap: config.DefaultGasCap, + GasCap: servercfg.DefaultGasCap, ProposerAddress: suite.network.GetContext().BlockHeader().ProposerAddress, }) require.NoError(t, err) nonce := suite.network.App.EVMKeeper.GetNonce(suite.network.GetContext(), addr) + baseFeeRes, err := suite.network.GetEvmClient().BaseFee(ctx, &evmtypes.QueryBaseFeeRequest{}) + require.NoError(t, err, "failed to get base fee") var erc20DeployTx *evmtypes.MsgEthereumTx if suite.enableFeemarket { @@ -173,7 +181,7 @@ func (suite *KeeperTestSuite) DeployTestMessageCall(t require.TestingT) common.A Nonce: nonce, GasLimit: res.Gas, Input: data, - GasFeeCap: suite.network.App.FeeMarketKeeper.GetBaseFee(suite.network.GetContext()), + GasFeeCap: baseFeeRes.BaseFee.BigInt(), Accesses: ðtypes.AccessList{}, GasTipCap: big.NewInt(1), } diff --git a/x/evm/module.go b/x/evm/module.go index 120c7175..55e5869f 100644 --- a/x/evm/module.go +++ b/x/evm/module.go @@ -25,7 +25,7 @@ import ( ) // consensusVersion defines the current x/evm module consensus version. -const consensusVersion = 7 +const consensusVersion = 8 var ( _ module.AppModule = AppModule{} @@ -134,7 +134,7 @@ func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterQueryServer(cfg.QueryServer(), am.keeper) } -// BeginBlock returns the begin block for the evm module. +// BeginBlock returns the begin blocker for the evm module. func (am AppModule) BeginBlock(ctx context.Context) error { c := sdk.UnwrapSDKContext(ctx) return am.keeper.BeginBlock(c) diff --git a/x/evm/statedb/state_object.go b/x/evm/statedb/state_object.go index 19d9646a..4a307f0c 100644 --- a/x/evm/statedb/state_object.go +++ b/x/evm/statedb/state_object.go @@ -101,6 +101,7 @@ func (s *stateObject) markSuicided() { // AddBalance adds amount to s's balance. // It is used to add funds to the destination account of a transfer. func (s *stateObject) AddBalance(amount *big.Int) { + amount = types.AdjustExtraDecimalsBigInt(amount) if amount.Sign() == 0 { return } @@ -110,6 +111,7 @@ func (s *stateObject) AddBalance(amount *big.Int) { // SubBalance removes amount from s's balance. // It is used to remove funds from the origin account of a transfer. func (s *stateObject) SubBalance(amount *big.Int) { + amount = types.AdjustExtraDecimalsBigInt(amount) if amount.Sign() == 0 { return } diff --git a/x/evm/types/chain_config.go b/x/evm/types/chain_config.go index 4f13edf6..9aefb1fc 100644 --- a/x/evm/types/chain_config.go +++ b/x/evm/types/chain_config.go @@ -3,20 +3,33 @@ package types import ( + "errors" "math/big" "strings" errorsmod "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/params" + gethparams "github.com/ethereum/go-ethereum/params" + "github.com/evmos/os/types" ) +// testChainID represents the ChainID used for the purpose of testing. +const testChainID string = "evmos_9002-1" + +// chainConfig is the chain configuration used in the EVM to defined which +// opcodes are active based on Ethereum upgrades. +var chainConfig *ChainConfig + // EthereumConfig returns an Ethereum ChainConfig for EVM state transitions. // All the negative or nil values are converted to nil -func (cc ChainConfig) EthereumConfig(chainID *big.Int) *params.ChainConfig { - return ¶ms.ChainConfig{ - ChainID: chainID, +func (cc ChainConfig) EthereumConfig(chainID *big.Int) *gethparams.ChainConfig { + cID := new(big.Int).SetUint64(cc.ChainId) + if chainID != nil { + cID = chainID + } + return &gethparams.ChainConfig{ + ChainID: cID, HomesteadBlock: getBlockValue(cc.HomesteadBlock), DAOForkBlock: getBlockValue(cc.DAOForkBlock), DAOForkSupport: cc.DAOForkSupport, @@ -42,8 +55,16 @@ func (cc ChainConfig) EthereumConfig(chainID *big.Int) *params.ChainConfig { } } -// DefaultChainConfig returns default evm parameters. -func DefaultChainConfig() ChainConfig { +func DefaultChainConfig(chainID string) *ChainConfig { + if chainID == "" { + chainID = testChainID + } + + eip155ChainID, err := types.ParseChainID(chainID) + if err != nil { + panic(err) + } + homesteadBlock := sdkmath.ZeroInt() daoForkBlock := sdkmath.ZeroInt() eip150Block := sdkmath.ZeroInt() @@ -61,8 +82,8 @@ func DefaultChainConfig() ChainConfig { mergeNetsplitBlock := sdkmath.ZeroInt() shanghaiBlock := sdkmath.ZeroInt() cancunBlock := sdkmath.ZeroInt() - - return ChainConfig{ + cfg := &ChainConfig{ + ChainId: eip155ChainID.Uint64(), HomesteadBlock: &homesteadBlock, DAOForkBlock: &daoForkBlock, DAOForkSupport: true, @@ -83,6 +104,26 @@ func DefaultChainConfig() ChainConfig { ShanghaiBlock: &shanghaiBlock, CancunBlock: &cancunBlock, } + return cfg +} + +// setChainConfig allows to set the `chainConfig` variable modifying the +// default values. The method is private because it should only be called once +// in the EVMConfigurator. +func setChainConfig(cc *ChainConfig) error { + if chainConfig != nil { + return errors.New("chainConfig already set. Cannot set again the chainConfig") + } + config := DefaultChainConfig("") + if cc != nil { + config = cc + } + if err := config.Validate(); err != nil { + return err + } + chainConfig = config + + return nil } func getBlockValue(block *sdkmath.Int) *big.Int { diff --git a/x/evm/types/chain_config_test.go b/x/evm/types/chain_config_test.go index 50457019..1907823b 100644 --- a/x/evm/types/chain_config_test.go +++ b/x/evm/types/chain_config_test.go @@ -1,9 +1,10 @@ -package types +package types_test import ( "testing" sdkmath "cosmossdk.io/math" + "github.com/evmos/os/x/evm/types" "github.com/stretchr/testify/require" "github.com/ethereum/go-ethereum/common" @@ -19,13 +20,13 @@ func newIntPtr(i int64) *sdkmath.Int { func TestChainConfigValidate(t *testing.T) { testCases := []struct { name string - config ChainConfig + config types.ChainConfig expError bool }{ - {"default", DefaultChainConfig(), false}, + {"default", *types.DefaultChainConfig(""), false}, { "valid", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -46,7 +47,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "valid with nil values", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: nil, DAOForkBlock: nil, EIP150Block: nil, @@ -67,19 +68,19 @@ func TestChainConfigValidate(t *testing.T) { }, { "empty", - ChainConfig{}, + types.ChainConfig{}, false, }, { "invalid HomesteadBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(-1), }, true, }, { "invalid DAOForkBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(-1), }, @@ -87,7 +88,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid EIP150Block", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(-1), @@ -96,7 +97,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid EIP150Hash", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -106,7 +107,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid EIP155Block", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -117,7 +118,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid EIP158Block", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -129,7 +130,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid ByzantiumBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -142,7 +143,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid ConstantinopleBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -156,7 +157,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid PetersburgBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -171,7 +172,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid IstanbulBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -187,7 +188,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid MuirGlacierBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -204,7 +205,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid BerlinBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -222,7 +223,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid LondonBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -241,7 +242,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid ArrowGlacierBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -261,7 +262,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid GrayGlacierBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -282,7 +283,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid MergeNetsplitBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -304,7 +305,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid fork order - skip HomesteadBlock", - ChainConfig{ + types.ChainConfig{ DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), EIP150Hash: defaultEIP150Hash, @@ -322,7 +323,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid ShanghaiBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), @@ -345,7 +346,7 @@ func TestChainConfigValidate(t *testing.T) { }, { "invalid CancunBlock", - ChainConfig{ + types.ChainConfig{ HomesteadBlock: newIntPtr(0), DAOForkBlock: newIntPtr(0), EIP150Block: newIntPtr(0), diff --git a/x/evm/types/codec.go b/x/evm/types/codec.go index f1fca16d..20726ded 100644 --- a/x/evm/types/codec.go +++ b/x/evm/types/codec.go @@ -76,14 +76,14 @@ func PackTxData(txData TxData) (*codectypes.Any, error) { // UnpackTxData unpacks an Any into a TxData. It returns an error if the // client state can't be unpacked into a TxData. -func UnpackTxData(any *codectypes.Any) (TxData, error) { - if any == nil { +func UnpackTxData(anyTxData *codectypes.Any) (TxData, error) { + if anyTxData == nil { return nil, errorsmod.Wrap(errortypes.ErrUnpackAny, "protobuf Any message cannot be nil") } - txData, ok := any.GetCachedValue().(TxData) + txData, ok := anyTxData.GetCachedValue().(TxData) if !ok { - return nil, errorsmod.Wrapf(errortypes.ErrUnpackAny, "cannot unpack Any into TxData %T", any) + return nil, errorsmod.Wrapf(errortypes.ErrUnpackAny, "cannot unpack Any into TxData %T", anyTxData) } return txData, nil diff --git a/x/evm/types/config.go b/x/evm/types/config.go new file mode 100644 index 00000000..db43ccbc --- /dev/null +++ b/x/evm/types/config.go @@ -0,0 +1,62 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +// +// The config package provides a convenient way to modify x/evm params and values. +// Its primary purpose is to be used during application initialization. + +//go:build !test +// +build !test + +package types + +import ( + "fmt" + + geth "github.com/ethereum/go-ethereum/params" + "github.com/evmos/os/x/evm/core/vm" +) + +// Configure applies the changes to the virtual machine configuration. +func (ec *EVMConfigurator) Configure() error { + // If Configure method has been already used in the object, return + // an error to avoid overriding configuration. + if ec.sealed { + return fmt.Errorf("error configuring EVMConfigurator: already sealed and cannot be modified") + } + + if err := setChainConfig(ec.chainConfig); err != nil { + return err + } + + if err := setEVMCoinInfo(ec.evmCoinInfo); err != nil { + return err + } + + if err := extendDefaultExtraEIPs(ec.extendedDefaultExtraEIPs); err != nil { + return err + } + + if err := vm.ExtendActivators(ec.extendedEIPs); err != nil { + return err + } + + // After applying modifiers the configurator is sealed. This way, it is not possible + // to call the configure method twice. + ec.sealed = true + + return nil +} + +func (ec *EVMConfigurator) ResetTestConfig() { + panic("this is only implemented with the 'test' build flag. Make sure you're running your tests using the '-tags=test' flag.") +} + +// GetEthChainConfig returns the `chainConfig` used in the EVM (geth type). +func GetEthChainConfig() *geth.ChainConfig { + return chainConfig.EthereumConfig(nil) +} + +// GetChainConfig returns the `chainConfig`. +func GetChainConfig() *ChainConfig { + return chainConfig +} diff --git a/x/evm/types/config_testing.go b/x/evm/types/config_testing.go new file mode 100644 index 00000000..330c28cb --- /dev/null +++ b/x/evm/types/config_testing.go @@ -0,0 +1,84 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +// +// The config package provides a convenient way to modify x/evm params and values. +// Its primary purpose is to be used during application initialization. + +//go:build test +// +build test + +package types + +import ( + "errors" + "fmt" + + geth "github.com/ethereum/go-ethereum/params" + "github.com/evmos/os/x/evm/core/vm" +) + +// testChainConfig is the chain configuration used in the EVM to defined which +// opcodes are active based on Ethereum upgrades. +var testChainConfig *ChainConfig + +// Configure applies the changes to the virtual machine configuration. +func (ec *EVMConfigurator) Configure() error { + // If Configure method has been already used in the object, return + // an error to avoid overriding configuration. + if ec.sealed { + return fmt.Errorf("error configuring EVMConfigurator: already sealed and cannot be modified") + } + + if err := setTestChainConfig(ec.chainConfig); err != nil { + return err + } + + if err := setTestingEVMCoinInfo(ec.evmCoinInfo); err != nil { + return err + } + + if err := extendDefaultExtraEIPs(ec.extendedDefaultExtraEIPs); err != nil { + return err + } + + if err := vm.ExtendActivators(ec.extendedEIPs); err != nil { + return err + } + + // After applying modifications, the configurator is sealed. This way, it is not possible + // to call the configure method twice. + ec.sealed = true + + return nil +} + +func (ec *EVMConfigurator) ResetTestConfig() { + vm.ResetActivators() + resetEVMCoinInfo() + testChainConfig = nil +} + +func setTestChainConfig(cc *ChainConfig) error { + if testChainConfig != nil { + return errors.New("chainConfig already set. Cannot set again the chainConfig. Call the configurators ResetTestConfig method before configuring a new chain.") + } + config := DefaultChainConfig("") + if cc != nil { + config = cc + } + if err := config.Validate(); err != nil { + return err + } + testChainConfig = config + return nil +} + +// GetEthChainConfig returns the `chainConfig` used in the EVM (geth type). +func GetEthChainConfig() *geth.ChainConfig { + return testChainConfig.EthereumConfig(nil) +} + +// GetChainConfig returns the `chainConfig`. +func GetChainConfig() *ChainConfig { + return testChainConfig +} diff --git a/x/evm/config/configurator.go b/x/evm/types/configurator.go similarity index 64% rename from x/evm/config/configurator.go rename to x/evm/types/configurator.go index c71152e7..61984376 100644 --- a/x/evm/config/configurator.go +++ b/x/evm/types/configurator.go @@ -4,23 +4,24 @@ // The config package provides a convenient way to modify x/evm params and values. // Its primary purpose is to be used during application initialization. -package config +package types import ( "fmt" "slices" "github.com/evmos/os/x/evm/core/vm" - "github.com/evmos/os/x/evm/types" ) // EVMConfigurator allows to extend x/evm module configurations. The configurator modifies // the EVM before starting the node. This means that all init genesis validations will be // applied to each change. type EVMConfigurator struct { + sealed bool extendedEIPs map[string]func(*vm.JumpTable) extendedDefaultExtraEIPs []string - sealed bool + chainConfig *ChainConfig + evmCoinInfo EvmCoinInfo } // NewEVMConfigurator returns a pointer to a new EVMConfigurator object. @@ -42,33 +43,31 @@ func (ec *EVMConfigurator) WithExtendedDefaultExtraEIPs(eips ...string) *EVMConf return ec } -// Configure apply the changes to the virtual machine configuration. -func (ec *EVMConfigurator) Configure() error { - // If Configure method has been already used in the object, return - // an error to avoid overriding configuration. - if ec.sealed { - return fmt.Errorf("error configuring EVMConfigurator: already sealed and cannot be modified") - } +// WithChainConfig allows to define a custom `chainConfig` to be used in the +// EVM. +func (ec *EVMConfigurator) WithChainConfig(cc *ChainConfig) *EVMConfigurator { + ec.chainConfig = cc + return ec +} - if err := vm.ExtendActivators(ec.extendedEIPs); err != nil { - return err - } +// WithEVMCoinInfo allows to define the denom and decimals of the token used as the +// EVM token. +func (ec *EVMConfigurator) WithEVMCoinInfo(denom string, decimals uint8) *EVMConfigurator { + ec.evmCoinInfo = EvmCoinInfo{Denom: denom, Decimals: Decimals(decimals)} + return ec +} - for _, eip := range ec.extendedDefaultExtraEIPs { - if slices.Contains(types.DefaultExtraEIPs, eip) { - return fmt.Errorf("error configuring EVMConfigurator: EIP %s is already present in the default list: %v", eip, types.DefaultExtraEIPs) +func extendDefaultExtraEIPs(extraEIPs []string) error { + for _, eip := range extraEIPs { + if slices.Contains(DefaultExtraEIPs, eip) { + return fmt.Errorf("error configuring EVMConfigurator: EIP %s is already present in the default list: %v", eip, DefaultExtraEIPs) } if err := vm.ValidateEIPName(eip); err != nil { return fmt.Errorf("error configuring EVMConfigurator: %s", err) } - types.DefaultExtraEIPs = append(types.DefaultExtraEIPs, eip) + DefaultExtraEIPs = append(DefaultExtraEIPs, eip) } - - // After applying modifier the configurator is sealed. This way, it is not possible - // to call the configure method twice. - ec.sealed = true - return nil } diff --git a/x/evm/config/configurator_test.go b/x/evm/types/configurator_test.go similarity index 65% rename from x/evm/config/configurator_test.go rename to x/evm/types/configurator_test.go index deacb0e9..9579a0df 100644 --- a/x/evm/config/configurator_test.go +++ b/x/evm/types/configurator_test.go @@ -1,20 +1,20 @@ // Copyright Tharsis Labs Ltd.(Evmos) // SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) -package config_test +package types_test import ( "testing" - "github.com/evmos/os/x/evm/config" + testconstants "github.com/evmos/os/testutil/constants" "github.com/evmos/os/x/evm/core/vm" - "github.com/stretchr/testify/require" - "github.com/evmos/os/x/evm/types" + "github.com/stretchr/testify/require" ) func TestEVMConfigurator(t *testing.T) { - evmConfigurator := config.NewEVMConfigurator() + evmConfigurator := types.NewEVMConfigurator(). + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(types.EighteenDecimals)) err := evmConfigurator.Configure() require.NoError(t, err) @@ -26,17 +26,19 @@ func TestEVMConfigurator(t *testing.T) { func TestExtendedEips(t *testing.T) { testCases := []struct { name string - malleate func() *config.EVMConfigurator + malleate func() *types.EVMConfigurator expPass bool errContains string }{ { "fail - eip already present in activators return an error", - func() *config.EVMConfigurator { + func() *types.EVMConfigurator { extendedEIPs := map[string]func(*vm.JumpTable){ "ethereum_3855": func(_ *vm.JumpTable) {}, } - ec := config.NewEVMConfigurator().WithExtendedEips(extendedEIPs) + ec := types.NewEVMConfigurator(). + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(types.EighteenDecimals)). + WithExtendedEips(extendedEIPs) return ec }, false, @@ -44,11 +46,13 @@ func TestExtendedEips(t *testing.T) { }, { "success - new default extra eips without duplication added", - func() *config.EVMConfigurator { + func() *types.EVMConfigurator { extendedEIPs := map[string]func(*vm.JumpTable){ "evmos_0": func(_ *vm.JumpTable) {}, } - ec := config.NewEVMConfigurator().WithExtendedEips(extendedEIPs) + ec := types.NewEVMConfigurator(). + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(types.EighteenDecimals)). + WithExtendedEips(extendedEIPs) return ec }, true, @@ -58,6 +62,7 @@ func TestExtendedEips(t *testing.T) { for _, tc := range testCases { ec := tc.malleate() + ec.ResetTestConfig() err := ec.Configure() if tc.expPass { @@ -73,16 +78,18 @@ func TestExtendedDefaultExtraEips(t *testing.T) { defaultExtraEIPsSnapshot := types.DefaultExtraEIPs testCases := []struct { name string - malleate func() *config.EVMConfigurator + malleate func() *types.EVMConfigurator postCheck func() expPass bool errContains string }{ { "fail - invalid eip name", - func() *config.EVMConfigurator { + func() *types.EVMConfigurator { extendedDefaultExtraEIPs := []string{"os_1_000"} - ec := config.NewEVMConfigurator().WithExtendedDefaultExtraEIPs(extendedDefaultExtraEIPs...) + ec := types.NewEVMConfigurator(). + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(types.EighteenDecimals)). + WithExtendedDefaultExtraEIPs(extendedDefaultExtraEIPs...) return ec }, func() { @@ -94,10 +101,12 @@ func TestExtendedDefaultExtraEips(t *testing.T) { }, { "fail - duplicate default EIP entiries", - func() *config.EVMConfigurator { + func() *types.EVMConfigurator { extendedDefaultExtraEIPs := []string{"os_1000"} types.DefaultExtraEIPs = append(types.DefaultExtraEIPs, "os_1000") - ec := config.NewEVMConfigurator().WithExtendedDefaultExtraEIPs(extendedDefaultExtraEIPs...) + ec := types.NewEVMConfigurator(). + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(types.EighteenDecimals)). + WithExtendedDefaultExtraEIPs(extendedDefaultExtraEIPs...) return ec }, func() { @@ -109,9 +118,11 @@ func TestExtendedDefaultExtraEips(t *testing.T) { }, { "success - empty default extra eip", - func() *config.EVMConfigurator { + func() *types.EVMConfigurator { var extendedDefaultExtraEIPs []string - ec := config.NewEVMConfigurator().WithExtendedDefaultExtraEIPs(extendedDefaultExtraEIPs...) + ec := types.NewEVMConfigurator(). + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(types.EighteenDecimals)). + WithExtendedDefaultExtraEIPs(extendedDefaultExtraEIPs...) return ec }, func() { @@ -122,9 +133,11 @@ func TestExtendedDefaultExtraEips(t *testing.T) { }, { "success - extra default eip added", - func() *config.EVMConfigurator { + func() *types.EVMConfigurator { extendedDefaultExtraEIPs := []string{"os_1001"} - ec := config.NewEVMConfigurator().WithExtendedDefaultExtraEIPs(extendedDefaultExtraEIPs...) + ec := types.NewEVMConfigurator(). + WithEVMCoinInfo(testconstants.ExampleAttoDenom, uint8(types.EighteenDecimals)). + WithExtendedDefaultExtraEIPs(extendedDefaultExtraEIPs...) return ec }, func() { @@ -139,6 +152,7 @@ func TestExtendedDefaultExtraEips(t *testing.T) { for _, tc := range testCases { t.Run(tc.name, func(t *testing.T) { ec := tc.malleate() + ec.ResetTestConfig() err := ec.Configure() if tc.expPass { diff --git a/x/evm/types/denom.go b/x/evm/types/denom.go new file mode 100644 index 00000000..cac8824f --- /dev/null +++ b/x/evm/types/denom.go @@ -0,0 +1,62 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +// +// The config package provides a convenient way to modify x/evm params and values. +// Its primary purpose is to be used during application initialization. + +package types + +import ( + "fmt" + + "cosmossdk.io/math" +) + +// NOTE: Remember to add the ConversionFactor associated with constants. +const ( + // SixDecimals is the Decimals used for Cosmos coin with 6 decimals. + SixDecimals Decimals = 6 + // EighteenDecimals is the Decimals used for Cosmos coin with 18 decimals. + EighteenDecimals Decimals = 18 +) + +// Decimals represents the decimal representation of a Cosmos coin. +type Decimals uint8 + +// Validate checks if the Decimals instance represent a supported decimals value +// or not. +func (d Decimals) Validate() error { + switch d { + case SixDecimals: + return nil + case EighteenDecimals: + return nil + default: + return fmt.Errorf("received unsupported decimals: %d", d) + } +} + +// ConversionFactor returns the conversion factor between the Decimals value and +// the 18 decimals representation, i.e. `EighteenDecimals`. +// +// NOTE: This function does not check if the Decimal instance is valid or +// not and by default returns the conversion factor of 1, i.e. from 18 decimals +// to 18 decimals. We cannot have a non supported Decimal since it is checked +// and validated. +func (d Decimals) ConversionFactor() math.Int { + if d == SixDecimals { + return math.NewInt(1e12) + } + + return math.NewInt(1) +} + +// EvmCoinInfo struct holds the name and decimals of the EVM denom. The EVM denom +// is the token used to pay fees in the EVM. +// +// TODO: move to own file? at least rename file because it's unclear to use "denom" +type EvmCoinInfo struct { + Denom string + DisplayDenom string + Decimals Decimals +} diff --git a/x/evm/types/denom_config.go b/x/evm/types/denom_config.go new file mode 100644 index 00000000..74c52a82 --- /dev/null +++ b/x/evm/types/denom_config.go @@ -0,0 +1,66 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +// +// The config package provides a convenient way to modify x/evm params and values. +// Its primary purpose is to be used during application initialization. + +//go:build !test +// +build !test + +package types + +import ( + "errors" + "fmt" + + sdk "github.com/cosmos/cosmos-sdk/types" +) + +// evmCoinInfo hold the information of the coin used in the EVM as gas token. It +// can only be set via `EVMConfigurator` before starting the app. +var evmCoinInfo *EvmCoinInfo + +// setEVMCoinDecimals allows to define the decimals used in the representation +// of the EVM coin. +func setEVMCoinDecimals(d Decimals) error { + if err := d.Validate(); err != nil { + return fmt.Errorf("setting EVM coin decimals: %w", err) + } + + evmCoinInfo.Decimals = d + return nil +} + +// setEVMCoinDenom allows to define the denom of the coin used in the EVM. +func setEVMCoinDenom(denom string) error { + if err := sdk.ValidateDenom(denom); err != nil { + return fmt.Errorf("setting EVM coin denom: %w", err) + } + evmCoinInfo.Denom = denom + return nil +} + +// GetEVMCoinDecimals returns the decimals used in the representation of the EVM +// coin. +func GetEVMCoinDecimals() Decimals { + return evmCoinInfo.Decimals +} + +// GetEVMCoinDenom returns the denom used for the EVM coin. +func GetEVMCoinDenom() string { + return evmCoinInfo.Denom +} + +// setEVMCoinInfo allows to define denom and decimals of the coin used in the EVM. +func setEVMCoinInfo(eci EvmCoinInfo) error { + if evmCoinInfo != nil { + return errors.New("EVM coin info already set") + } + + evmCoinInfo = new(EvmCoinInfo) + + if err := setEVMCoinDenom(eci.Denom); err != nil { + return err + } + return setEVMCoinDecimals(eci.Decimals) +} diff --git a/x/evm/types/denom_config_testing.go b/x/evm/types/denom_config_testing.go new file mode 100644 index 00000000..cc9a0b20 --- /dev/null +++ b/x/evm/types/denom_config_testing.go @@ -0,0 +1,74 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) +// +// The config package provides a convenient way to modify x/evm params and values. +// Its primary purpose is to be used during application initialization. + +//go:build test +// +build test + +package types + +import ( + "errors" + "fmt" + + sdk "github.com/cosmos/cosmos-sdk/types" +) + +// testingEvmCoinInfo hold the information of the coin used in the EVM as gas token. It +// can only be set via `EVMConfigurator` before starting the app. +var testingEvmCoinInfo *EvmCoinInfo + +// setEVMCoinDecimals allows to define the decimals used in the representation +// of the EVM coin. +func setEVMCoinDecimals(d Decimals) error { + if err := d.Validate(); err != nil { + return fmt.Errorf("setting EVM coin decimals: %w", err) + } + + testingEvmCoinInfo.Decimals = d + return nil +} + +// setEVMCoinDenom allows to define the denom of the coin used in the EVM. +func setEVMCoinDenom(denom string) error { + if err := sdk.ValidateDenom(denom); err != nil { + return err + } + testingEvmCoinInfo.Denom = denom + return nil +} + +// GetEVMCoinDecimals returns the decimals used in the representation of the EVM +// coin. +func GetEVMCoinDecimals() Decimals { + return testingEvmCoinInfo.Decimals +} + +// GetEVMCoinDenom returns the denom used for the EVM coin. +func GetEVMCoinDenom() string { + return testingEvmCoinInfo.Denom +} + +// SetEVMCoinInfo allows to define denom and decimals of the coin used in the EVM. +func setTestingEVMCoinInfo(eci EvmCoinInfo) error { + if testingEvmCoinInfo != nil { + return errors.New("testing EVM coin info already set. Make sure you run the configurator's ResetTestConfig before trying to set a new evm coin info") + } + testingEvmCoinInfo = new(EvmCoinInfo) + // fill up the denom with default values + // if EvmCoinInfo is not defined + if eci.Denom == "" { + panic("evm coin denom is not set") + } + if err := setEVMCoinDenom(eci.Denom); err != nil { + return err + } + return setEVMCoinDecimals(eci.Decimals) +} + +// resetEVMCoinInfo resets to nil the testingEVMCoinInfo +func resetEVMCoinInfo() { + testingEvmCoinInfo = nil +} diff --git a/x/evm/types/dynamic_fee_tx.go b/x/evm/types/dynamic_fee_tx.go index d050722f..2ff23e69 100644 --- a/x/evm/types/dynamic_fee_tx.go +++ b/x/evm/types/dynamic_fee_tx.go @@ -259,7 +259,7 @@ func (tx DynamicFeeTx) Validate() error { // Fee returns gasprice * gaslimit. func (tx DynamicFeeTx) Fee() *big.Int { - return fee(tx.GetGasFeeCap(), tx.GasLimit) + return fee(tx.GetGasFeeCap(), tx.GetGas()) } // Cost returns amount + gasprice * gaslimit. @@ -274,7 +274,7 @@ func (tx *DynamicFeeTx) EffectiveGasPrice(baseFee *big.Int) *big.Int { // EffectiveFee returns effective_gasprice * gaslimit. func (tx DynamicFeeTx) EffectiveFee(baseFee *big.Int) *big.Int { - return fee(tx.EffectiveGasPrice(baseFee), tx.GasLimit) + return fee(tx.EffectiveGasPrice(baseFee), tx.GetGas()) } // EffectiveCost returns amount + effective_gasprice * gaslimit. diff --git a/x/evm/types/events.go b/x/evm/types/events.go index 8c300bf6..16134eb1 100644 --- a/x/evm/types/events.go +++ b/x/evm/types/events.go @@ -7,7 +7,9 @@ const ( EventTypeEthereumTx = TypeMsgEthereumTx EventTypeBlockBloom = "block_bloom" EventTypeTxLog = "tx_log" + EventTypeFeeMarket = "evm_fee_market" + AttributeKeyBaseFee = "base_fee" AttributeKeyContractAddress = "contract" AttributeKeyRecipient = "recipient" AttributeKeyTxHash = "txHash" @@ -16,6 +18,7 @@ const ( AttributeKeyTxGasUsed = "txGasUsed" AttributeKeyTxType = "txType" AttributeKeyTxLog = "txLog" + // tx failed in eth vm execution AttributeKeyEthereumTxFailed = "ethereumTxFailed" AttributeValueCategory = ModuleName diff --git a/x/evm/types/evm.pb.go b/x/evm/types/evm.pb.go index b0642725..9afb6737 100644 --- a/x/evm/types/evm.pb.go +++ b/x/evm/types/evm.pb.go @@ -328,6 +328,12 @@ type ChainConfig struct { ShanghaiBlock *cosmossdk_io_math.Int `protobuf:"bytes,22,opt,name=shanghai_block,json=shanghaiBlock,proto3,customtype=cosmossdk.io/math.Int" json:"shanghai_block,omitempty" yaml:"shanghai_block"` // cancun_block switch block (nil = no fork, 0 = already on cancun) CancunBlock *cosmossdk_io_math.Int `protobuf:"bytes,23,opt,name=cancun_block,json=cancunBlock,proto3,customtype=cosmossdk.io/math.Int" json:"cancun_block,omitempty" yaml:"cancun_block"` + // chain_id is the id of the chain (EIP-155) + ChainId uint64 `protobuf:"varint,24,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"` + // denom is the denomination used on the EVM + Denom string `protobuf:"bytes,25,opt,name=denom,proto3" json:"denom,omitempty"` + // decimals is the real decimal precision of the denomination used on the EVM + Decimals uint64 `protobuf:"varint,26,opt,name=decimals,proto3" json:"decimals,omitempty"` } func (m *ChainConfig) Reset() { *m = ChainConfig{} } @@ -377,6 +383,27 @@ func (m *ChainConfig) GetEIP150Hash() string { return "" } +func (m *ChainConfig) GetChainId() uint64 { + if m != nil { + return m.ChainId + } + return 0 +} + +func (m *ChainConfig) GetDenom() string { + if m != nil { + return m.Denom + } + return "" +} + +func (m *ChainConfig) GetDecimals() uint64 { + if m != nil { + return m.Decimals + } + return 0 +} + // State represents a single Storage key value pair item. type State struct { // key is the stored key @@ -861,127 +888,130 @@ func init() { func init() { proto.RegisterFile("os/evm/v1/evm.proto", fileDescriptor_e8c4b25eb041133a) } var fileDescriptor_e8c4b25eb041133a = []byte{ - // 1916 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x58, 0xcd, 0x6f, 0x1b, 0xc7, - 0xd9, 0x17, 0xa5, 0x95, 0xb4, 0x1c, 0x52, 0xe4, 0x6a, 0x44, 0xc9, 0x34, 0x1d, 0x68, 0x85, 0xc5, - 0x7b, 0x30, 0x8c, 0xbc, 0x92, 0x2d, 0x5b, 0xa9, 0xeb, 0x16, 0x2d, 0x4c, 0x89, 0x69, 0xa5, 0xca, - 0x8e, 0x30, 0x54, 0x52, 0xa4, 0x0d, 0xb0, 0x18, 0xee, 0x4e, 0xc8, 0x8d, 0x76, 0x77, 0x88, 0x9d, - 0x21, 0x4d, 0xf6, 0xd8, 0x5e, 0x52, 0x9f, 0x7a, 0xed, 0xc1, 0x40, 0x81, 0x5e, 0x7a, 0xcc, 0x9f, - 0xd0, 0x63, 0xd0, 0x53, 0x4e, 0x45, 0xd1, 0xc3, 0xa2, 0xa0, 0x0f, 0x01, 0x74, 0xd4, 0xbd, 0x40, - 0x31, 0x1f, 0x24, 0x97, 0x94, 0x22, 0xe8, 0x22, 0xcd, 0xf3, 0xf5, 0xfb, 0x3d, 0xcf, 0xcc, 0xb3, - 0xf3, 0x41, 0xb0, 0x41, 0xd9, 0x1e, 0xe9, 0x47, 0x7b, 0xfd, 0x27, 0xe2, 0xdf, 0x6e, 0x37, 0xa1, - 0x9c, 0xc2, 0x3c, 0x65, 0xbb, 0x42, 0xea, 0x3f, 0xa9, 0xad, 0xe3, 0x28, 0x88, 0xe9, 0x9e, 0xfc, - 0xab, 0xac, 0xb5, 0x4a, 0x9b, 0xb6, 0xa9, 0x1c, 0xee, 0x89, 0x91, 0xd2, 0x3a, 0xbf, 0x37, 0xc0, - 0xca, 0x19, 0x4e, 0x70, 0xc4, 0xe0, 0x13, 0x90, 0x27, 0xfd, 0xc8, 0xf5, 0x49, 0x4c, 0xa3, 0x6a, - 0x6e, 0x27, 0xf7, 0x30, 0x5f, 0xaf, 0x5c, 0xa5, 0xb6, 0x35, 0xc4, 0x51, 0xf8, 0xc2, 0x99, 0x98, - 0x1c, 0x64, 0x92, 0x7e, 0x74, 0x24, 0x86, 0xf0, 0x25, 0x00, 0x64, 0xc0, 0x13, 0xec, 0x92, 0xa0, - 0xcb, 0xaa, 0xc6, 0xce, 0xd2, 0xc3, 0x7c, 0xdd, 0x19, 0xa5, 0x76, 0xbe, 0x21, 0xb4, 0x8d, 0xe3, - 0x33, 0x76, 0x95, 0xda, 0xeb, 0x1a, 0x60, 0xe2, 0xe8, 0xa0, 0xbc, 0x14, 0x1a, 0x41, 0x97, 0xc1, - 0xdf, 0x82, 0xa2, 0xd7, 0xc1, 0x41, 0xec, 0x7a, 0x34, 0xfe, 0x32, 0x68, 0x57, 0x97, 0x77, 0x72, - 0x0f, 0x0b, 0xfb, 0x5b, 0xbb, 0x93, 0x5a, 0x76, 0x0f, 0x85, 0xf9, 0x50, 0x5a, 0xeb, 0x3b, 0xdf, - 0xa6, 0xf6, 0xc2, 0x55, 0x6a, 0x6f, 0x28, 0xcc, 0x6c, 0xa4, 0xf3, 0xb7, 0xef, 0xbf, 0x79, 0x94, - 0x43, 0x05, 0x6f, 0xea, 0x0e, 0xf7, 0xc1, 0x26, 0x0e, 0x43, 0xfa, 0xc6, 0xed, 0xc5, 0xa2, 0x5c, - 0xe2, 0x71, 0xe2, 0xbb, 0x7c, 0xc0, 0xaa, 0x2b, 0x3b, 0xb9, 0x87, 0x26, 0xda, 0x90, 0xc6, 0x4f, - 0xa7, 0xb6, 0xf3, 0x01, 0x83, 0xfb, 0xa0, 0x28, 0x6a, 0xf5, 0x3a, 0x38, 0x8e, 0x49, 0xc8, 0xaa, - 0xa6, 0xac, 0xaa, 0x3c, 0x4a, 0xed, 0x42, 0xe3, 0xb3, 0x57, 0x87, 0x5a, 0x8d, 0x0a, 0xa4, 0x1f, - 0x8d, 0x05, 0xf8, 0x19, 0x28, 0x61, 0xcf, 0x23, 0x8c, 0x89, 0x5c, 0x78, 0x42, 0xc3, 0x6a, 0x5e, - 0x96, 0x51, 0xcd, 0x94, 0xf1, 0x52, 0x3a, 0x1c, 0x2a, 0x7b, 0x7d, 0x53, 0x14, 0x32, 0x4a, 0xed, - 0xb5, 0x19, 0x35, 0x5a, 0xc3, 0x59, 0x11, 0xbe, 0x00, 0xf7, 0xb1, 0xc7, 0x83, 0x3e, 0x71, 0x19, - 0xc7, 0x3c, 0xf0, 0xdc, 0x6e, 0x42, 0x3c, 0x1a, 0x75, 0x83, 0x90, 0xb0, 0x2a, 0x10, 0x89, 0xa1, - 0x7b, 0xca, 0xa1, 0x29, 0xed, 0x67, 0x53, 0xf3, 0x8b, 0x7b, 0x6f, 0xbf, 0xff, 0xe6, 0x11, 0x24, - 0xfd, 0x88, 0xb2, 0xbd, 0x81, 0x6c, 0x16, 0xb5, 0xce, 0x27, 0x86, 0xb9, 0x68, 0x2d, 0x9d, 0x18, - 0xe6, 0x92, 0x65, 0x9c, 0x18, 0xe6, 0xaa, 0x65, 0x3a, 0x7f, 0xc8, 0x81, 0xd9, 0x3c, 0xe0, 0x0b, - 0xb0, 0xe2, 0x25, 0x04, 0x73, 0x22, 0x1b, 0xa1, 0xb0, 0xff, 0xc1, 0x0f, 0x15, 0x72, 0x3e, 0xec, - 0x92, 0xba, 0x21, 0x8a, 0x41, 0x3a, 0x02, 0x7e, 0x04, 0x0c, 0x0f, 0x87, 0x61, 0x75, 0xf1, 0xce, - 0x91, 0xd2, 0xdf, 0xf9, 0x67, 0x0e, 0xac, 0x5f, 0xf3, 0x80, 0x5f, 0x80, 0x82, 0x9e, 0x5a, 0x3e, - 0xec, 0xaa, 0x74, 0x4a, 0xfb, 0x9b, 0xd7, 0x40, 0x25, 0xda, 0xff, 0x8d, 0x52, 0x1b, 0x4c, 0xe5, - 0xab, 0xd4, 0x86, 0xaa, 0x4f, 0x32, 0x08, 0x0e, 0x02, 0x78, 0xe2, 0x01, 0x3d, 0xb0, 0x31, 0xbb, - 0x70, 0x6e, 0x18, 0x30, 0x5e, 0x5d, 0x94, 0x6b, 0xfe, 0x74, 0x94, 0xda, 0xb3, 0x19, 0x9d, 0x06, - 0x8c, 0x5f, 0xa5, 0x76, 0x6d, 0x06, 0x35, 0x1b, 0xe9, 0xa0, 0x75, 0x3c, 0x1f, 0xe0, 0xfc, 0xb7, - 0x04, 0x0a, 0x99, 0x26, 0x86, 0x5f, 0x80, 0x72, 0x87, 0x46, 0x84, 0x71, 0x82, 0x7d, 0xb7, 0x15, - 0x52, 0xef, 0x42, 0x7f, 0x6e, 0x4f, 0xff, 0x9d, 0xda, 0x9b, 0x1e, 0x65, 0x11, 0x65, 0xcc, 0xbf, - 0xd8, 0x0d, 0xe8, 0x5e, 0x84, 0x79, 0x67, 0xf7, 0x38, 0x16, 0xa4, 0x5b, 0x8a, 0x74, 0x2e, 0xd2, - 0x41, 0xa5, 0x89, 0xa6, 0x2e, 0x14, 0xb0, 0x03, 0x4a, 0x3e, 0xa6, 0xee, 0x97, 0x34, 0xb9, 0xd0, - 0xe0, 0x8b, 0x12, 0xbc, 0xfe, 0x83, 0xe0, 0xa3, 0xd4, 0x2e, 0x1e, 0xbd, 0xfc, 0xe4, 0x63, 0x9a, - 0x5c, 0x48, 0x88, 0xab, 0xd4, 0xde, 0x54, 0x64, 0xb3, 0x40, 0x0e, 0x2a, 0xfa, 0x98, 0x4e, 0xdc, - 0xe0, 0xaf, 0x81, 0x35, 0x71, 0x60, 0xbd, 0x6e, 0x97, 0x26, 0xbc, 0xba, 0x24, 0x3e, 0xac, 0xfa, - 0xff, 0x8f, 0x52, 0xbb, 0xa4, 0x21, 0x9b, 0xca, 0x72, 0x95, 0xda, 0xf7, 0xe6, 0x40, 0x75, 0x8c, - 0x83, 0x4a, 0x1a, 0x56, 0xbb, 0xc2, 0x16, 0x28, 0x92, 0xa0, 0xfb, 0xe4, 0xe0, 0xb1, 0x2e, 0xc0, - 0x90, 0x05, 0xfc, 0xfc, 0xb6, 0x02, 0x0a, 0x8d, 0xe3, 0xb3, 0x27, 0x07, 0x8f, 0xc7, 0xf9, 0xeb, - 0xfd, 0x21, 0x8b, 0xe2, 0xa0, 0x82, 0x12, 0x55, 0xf2, 0xc7, 0x40, 0x8b, 0x6e, 0x07, 0xb3, 0x8e, - 0xdc, 0x76, 0xf2, 0xf5, 0x87, 0xa2, 0x81, 0x14, 0xd2, 0x2f, 0x31, 0xeb, 0x4c, 0x67, 0xbd, 0x35, - 0xfc, 0x1d, 0x8e, 0x79, 0xd0, 0x8b, 0xc6, 0x58, 0x40, 0x05, 0x0b, 0xaf, 0x49, 0xba, 0x07, 0x3a, - 0xdd, 0x95, 0xbb, 0xa6, 0x7b, 0x70, 0x53, 0xba, 0x07, 0xb3, 0xe9, 0x2a, 0x9f, 0x09, 0xc7, 0x73, - 0xcd, 0xb1, 0x7a, 0x57, 0x8e, 0xe7, 0x37, 0x71, 0x3c, 0x9f, 0xe5, 0x50, 0x3e, 0xa2, 0x2f, 0xe7, - 0xea, 0xac, 0x9a, 0x77, 0xee, 0xcb, 0x6b, 0x33, 0x54, 0x9a, 0x68, 0x14, 0xfa, 0x05, 0xa8, 0x78, - 0x34, 0x66, 0x5c, 0xe8, 0x62, 0xda, 0x0d, 0x89, 0xa6, 0xc8, 0x4b, 0x8a, 0xe7, 0xb7, 0x51, 0x3c, - 0xd0, 0xbb, 0xfd, 0x0d, 0xe1, 0x0e, 0xda, 0x98, 0x55, 0x2b, 0x32, 0x17, 0x58, 0x5d, 0xc2, 0x49, - 0xc2, 0x5a, 0xbd, 0xa4, 0xad, 0x89, 0x80, 0x24, 0x7a, 0x76, 0x1b, 0x91, 0xee, 0xd0, 0xf9, 0x50, - 0x07, 0x95, 0xa7, 0x2a, 0x45, 0xf0, 0x39, 0x28, 0x05, 0x82, 0xb5, 0xd5, 0x0b, 0x35, 0x7c, 0x41, - 0xc2, 0xef, 0xdf, 0x06, 0xaf, 0xbf, 0xaa, 0xd9, 0x40, 0x07, 0xad, 0x8d, 0x15, 0x0a, 0xda, 0x07, - 0x30, 0xea, 0x05, 0x89, 0xdb, 0x0e, 0xb1, 0x17, 0x90, 0x44, 0xc3, 0x17, 0x25, 0xfc, 0x47, 0xb7, - 0xc1, 0xdf, 0x57, 0xf0, 0xd7, 0x83, 0x1d, 0x64, 0x09, 0xe5, 0x2f, 0x94, 0x4e, 0xb1, 0x34, 0x41, - 0xb1, 0x45, 0x92, 0x30, 0x88, 0x35, 0xfe, 0x9a, 0xc4, 0x7f, 0x7c, 0x1b, 0xbe, 0xee, 0xa0, 0x6c, - 0x98, 0x83, 0x0a, 0x4a, 0x9c, 0x80, 0x86, 0x34, 0xf6, 0xe9, 0x18, 0x74, 0xfd, 0xce, 0xa0, 0xd9, - 0x30, 0x07, 0x15, 0x94, 0xa8, 0x40, 0xdb, 0x60, 0x03, 0x27, 0x09, 0x7d, 0x33, 0x37, 0x21, 0x50, - 0x62, 0xff, 0xe8, 0x36, 0xec, 0xf1, 0x3e, 0x7d, 0x3d, 0x5a, 0xec, 0xd3, 0x42, 0x3b, 0x33, 0x25, - 0x3e, 0x80, 0xed, 0x04, 0x0f, 0xe7, 0x78, 0x2a, 0x77, 0x9e, 0xf8, 0xeb, 0xc1, 0x0e, 0xb2, 0x84, - 0x72, 0x86, 0xe5, 0x2b, 0x50, 0x89, 0x48, 0xd2, 0x26, 0x6e, 0x4c, 0x38, 0xeb, 0x86, 0x01, 0xd7, - 0x3c, 0x9b, 0x77, 0xfe, 0x0e, 0x6e, 0x0a, 0x77, 0x10, 0x94, 0xea, 0xd7, 0x5a, 0x3b, 0xe9, 0x52, - 0xd6, 0xc1, 0x71, 0xbb, 0x83, 0x03, 0xcd, 0xb2, 0x75, 0xe7, 0x2e, 0x9d, 0x0d, 0x74, 0xd0, 0xda, - 0x58, 0x31, 0x59, 0x6a, 0x0f, 0xc7, 0x5e, 0x6f, 0xbc, 0xd4, 0xf7, 0xee, 0xbc, 0xd4, 0xd9, 0x30, - 0x07, 0x15, 0x94, 0x28, 0x41, 0x4f, 0x0c, 0xb3, 0x64, 0x95, 0x4f, 0x0c, 0xb3, 0x6c, 0x59, 0x27, - 0x86, 0x69, 0x59, 0xeb, 0x27, 0x86, 0xb9, 0x61, 0x55, 0xd0, 0xda, 0x90, 0x86, 0xd4, 0xed, 0x3f, - 0x55, 0x41, 0xa8, 0x40, 0xde, 0x60, 0xa6, 0x37, 0x1a, 0x54, 0xf2, 0x30, 0xc7, 0xe1, 0x90, 0xe9, - 0x89, 0x40, 0x96, 0x9a, 0x9e, 0xcc, 0xb1, 0xb5, 0x07, 0x96, 0xc5, 0xf5, 0x88, 0x40, 0x0b, 0x2c, - 0x5d, 0x90, 0xa1, 0x3a, 0x6c, 0x91, 0x18, 0xc2, 0x0a, 0x58, 0xee, 0xe3, 0xb0, 0x47, 0xd4, 0x19, - 0x89, 0x94, 0xe0, 0x1c, 0x83, 0xf2, 0x79, 0x82, 0x63, 0x26, 0xae, 0x56, 0x34, 0x3e, 0xa5, 0x6d, - 0x06, 0x21, 0x30, 0xe4, 0x39, 0xa1, 0x62, 0xe5, 0x18, 0x3a, 0xc0, 0x08, 0x69, 0x9b, 0xc9, 0xdb, - 0x42, 0x61, 0xbf, 0x94, 0xb9, 0x93, 0x9c, 0xd2, 0x36, 0x92, 0x36, 0xe7, 0x1f, 0x8b, 0x60, 0xe9, - 0x94, 0xb6, 0x61, 0x15, 0xac, 0x62, 0xdf, 0x4f, 0x08, 0x63, 0x1a, 0x62, 0x2c, 0xc2, 0x2d, 0xb0, - 0xc2, 0x69, 0x37, 0xf0, 0x14, 0x4e, 0x1e, 0x69, 0x49, 0x30, 0xfa, 0x98, 0x63, 0x79, 0xa2, 0x16, - 0x91, 0x1c, 0x8b, 0xbb, 0xa9, 0x2c, 0xc9, 0x8d, 0x7b, 0x51, 0x8b, 0x24, 0xf2, 0x60, 0x34, 0xea, - 0xe5, 0xcb, 0xd4, 0x2e, 0x48, 0xfd, 0x6b, 0xa9, 0x46, 0x59, 0x01, 0x7e, 0x08, 0x56, 0xf9, 0x20, - 0x7b, 0xc8, 0x6d, 0x5c, 0xa6, 0x76, 0x99, 0x4f, 0xeb, 0x13, 0x67, 0x18, 0x5a, 0xe1, 0x03, 0x79, - 0x96, 0xed, 0x01, 0x93, 0x0f, 0xdc, 0x20, 0xf6, 0xc9, 0x40, 0x9e, 0x63, 0x46, 0xbd, 0x72, 0x99, - 0xda, 0x56, 0xc6, 0xfd, 0x58, 0xd8, 0xd0, 0x2a, 0x1f, 0xc8, 0x01, 0xfc, 0x10, 0x00, 0x95, 0x92, - 0x64, 0x50, 0xc7, 0xd2, 0xda, 0x65, 0x6a, 0xe7, 0xa5, 0x56, 0x62, 0x4f, 0x87, 0xd0, 0x01, 0xcb, - 0x0a, 0xdb, 0x94, 0xd8, 0xc5, 0xcb, 0xd4, 0x36, 0x43, 0xda, 0x56, 0x98, 0xca, 0x24, 0xa6, 0x2a, - 0x21, 0x11, 0xed, 0x13, 0x5f, 0x9e, 0x0d, 0x26, 0x1a, 0x8b, 0xce, 0x1f, 0x17, 0x81, 0x79, 0x3e, - 0x40, 0x84, 0xf5, 0x42, 0x0e, 0x3f, 0x06, 0x96, 0xbc, 0x79, 0x61, 0x8f, 0xbb, 0x33, 0x53, 0x5b, - 0x7f, 0x30, 0xdd, 0xc9, 0xe7, 0x3d, 0x1c, 0x54, 0x1e, 0xab, 0x5e, 0xea, 0xf9, 0xaf, 0x80, 0xe5, - 0x56, 0x48, 0x69, 0x24, 0x5b, 0xa0, 0x88, 0x94, 0x00, 0xcf, 0xe4, 0xac, 0xc9, 0xe5, 0x5d, 0x92, - 0xf7, 0xd8, 0x5a, 0x66, 0x79, 0xe7, 0x9a, 0xa3, 0xfe, 0x40, 0xbf, 0x4a, 0x4a, 0x8a, 0x54, 0x07, - 0xea, 0x07, 0xc9, 0x0a, 0x1f, 0xc8, 0x0e, 0xb2, 0xc0, 0x52, 0x42, 0xb8, 0x5c, 0xb2, 0x22, 0x12, - 0x43, 0x58, 0x03, 0x66, 0x42, 0xfa, 0x24, 0xe1, 0xc4, 0x97, 0x4b, 0x63, 0xa2, 0x89, 0x0c, 0xef, - 0x03, 0xb3, 0x8d, 0x99, 0xdb, 0x63, 0xc4, 0x57, 0xeb, 0x80, 0x56, 0xdb, 0x98, 0x7d, 0xca, 0x88, - 0xff, 0xc2, 0xf8, 0xfa, 0x2f, 0xf6, 0x82, 0x83, 0x41, 0x41, 0xdf, 0x74, 0x7b, 0xdd, 0x90, 0xdc, - 0xd2, 0x5f, 0xfb, 0xa0, 0xc8, 0x38, 0x4d, 0x70, 0x9b, 0xb8, 0x17, 0x64, 0xa8, 0xbb, 0x4c, 0xf5, - 0x8c, 0xd6, 0xff, 0x8a, 0x0c, 0x19, 0xca, 0x0a, 0x9a, 0xe2, 0xcf, 0x06, 0x28, 0x9c, 0x27, 0xd8, - 0x23, 0xfa, 0xde, 0x2a, 0x3a, 0x55, 0x88, 0x89, 0xa6, 0xd0, 0x92, 0xe0, 0xe6, 0x41, 0x44, 0x68, - 0x8f, 0xeb, 0xcf, 0x68, 0x2c, 0x8a, 0x88, 0x84, 0x90, 0x01, 0xf1, 0xe4, 0x24, 0x1a, 0x48, 0x4b, - 0xf0, 0x00, 0xac, 0xf9, 0x01, 0xc3, 0xad, 0x50, 0x3e, 0x6c, 0xbc, 0x0b, 0x55, 0x7e, 0xdd, 0xba, - 0x4c, 0xed, 0xa2, 0x36, 0x34, 0x85, 0x1e, 0xcd, 0x48, 0xf0, 0x27, 0xa0, 0x3c, 0x0d, 0x93, 0xd9, - 0xaa, 0x87, 0x5c, 0x1d, 0x5e, 0xa6, 0x76, 0x69, 0xe2, 0x2a, 0x2d, 0x68, 0x4e, 0x16, 0xeb, 0xec, - 0x93, 0x56, 0xaf, 0x2d, 0x5b, 0xcf, 0x44, 0x4a, 0x10, 0xda, 0x30, 0x88, 0x02, 0x2e, 0x5b, 0x6d, - 0x19, 0x29, 0x01, 0x3e, 0x03, 0x79, 0xda, 0x27, 0x49, 0x12, 0xf8, 0xf2, 0x9d, 0x75, 0xcb, 0x8b, - 0x14, 0x4d, 0x1d, 0x45, 0x55, 0x24, 0x96, 0xd9, 0x45, 0x24, 0xa2, 0xc9, 0x50, 0x5e, 0x09, 0x74, - 0x55, 0xca, 0xf0, 0x4a, 0xea, 0xd1, 0x8c, 0x04, 0xeb, 0x00, 0xea, 0xb0, 0x84, 0xf0, 0x5e, 0x12, - 0xbb, 0xf2, 0xb3, 0x2f, 0xca, 0x58, 0xf9, 0xf1, 0x29, 0x2b, 0x92, 0xc6, 0x23, 0xcc, 0x31, 0xba, - 0xa6, 0x81, 0x3f, 0x03, 0x50, 0x2d, 0x86, 0xfb, 0x15, 0xa3, 0x93, 0xb7, 0xb4, 0x3a, 0xd3, 0x25, - 0xbf, 0xb2, 0xea, 0x9c, 0x2d, 0x25, 0x9d, 0x30, 0xaa, 0xab, 0x38, 0x31, 0x4c, 0xc3, 0x5a, 0x56, - 0xaf, 0xc1, 0xc9, 0xc4, 0xe9, 0x2a, 0xd0, 0xc6, 0x58, 0xce, 0xa4, 0xf7, 0xe8, 0xef, 0x39, 0x90, - 0x79, 0x69, 0xc1, 0x9f, 0x82, 0xda, 0xcb, 0xc3, 0xc3, 0x46, 0xb3, 0xe9, 0x9e, 0x7f, 0x7e, 0xd6, - 0x70, 0xcf, 0x1a, 0xe8, 0xd5, 0x71, 0xb3, 0x79, 0xfc, 0xc9, 0xeb, 0xd3, 0x46, 0xb3, 0x69, 0x2d, - 0xd4, 0x3e, 0x78, 0xfb, 0x6e, 0xa7, 0x3a, 0xf5, 0x3f, 0x23, 0x49, 0x14, 0x30, 0x16, 0xd0, 0x38, - 0x14, 0x2d, 0xfa, 0x0c, 0x6c, 0x65, 0xa3, 0x51, 0xa3, 0x79, 0x8e, 0x8e, 0x0f, 0xcf, 0x1b, 0x47, - 0x56, 0xae, 0x56, 0x7d, 0xfb, 0x6e, 0xa7, 0x32, 0x8d, 0x44, 0x84, 0xf1, 0x24, 0x10, 0x6f, 0x75, - 0xf8, 0x1c, 0x54, 0x6f, 0xe6, 0x6c, 0x1c, 0x59, 0x8b, 0xb5, 0xda, 0xdb, 0x77, 0x3b, 0x5b, 0x37, - 0x31, 0x12, 0xbf, 0x66, 0x7c, 0xfd, 0xd7, 0xed, 0x85, 0xfa, 0x8f, 0xbf, 0x1d, 0x6d, 0xe7, 0xbe, - 0x1b, 0x6d, 0xe7, 0xfe, 0x33, 0xda, 0xce, 0xfd, 0xe9, 0xfd, 0xf6, 0xc2, 0x77, 0xef, 0xb7, 0x17, - 0xfe, 0xf5, 0x7e, 0x7b, 0xe1, 0x37, 0x76, 0x3b, 0xe0, 0x9d, 0x5e, 0x6b, 0xd7, 0xa3, 0xd1, 0x9e, - 0x7a, 0x40, 0x4f, 0xde, 0xd0, 0xe2, 0x09, 0xc9, 0x5a, 0x2b, 0xf2, 0xc7, 0x93, 0xa7, 0xff, 0x0b, - 0x00, 0x00, 0xff, 0xff, 0xc9, 0x23, 0x48, 0x4e, 0x87, 0x11, 0x00, 0x00, + // 1953 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x58, 0x4d, 0x6f, 0x1b, 0xc7, + 0xf9, 0x17, 0xa5, 0x95, 0xb4, 0x1c, 0x52, 0xe4, 0x6a, 0xf4, 0x62, 0x9a, 0x0e, 0xb4, 0xc2, 0xe2, + 0x7f, 0x10, 0x8c, 0xfc, 0x25, 0x5b, 0xb6, 0x52, 0xd7, 0x2d, 0x5a, 0x98, 0x32, 0xd3, 0x52, 0x95, + 0x1d, 0x61, 0xa8, 0xa4, 0x48, 0x1b, 0x60, 0x31, 0xdc, 0x9d, 0x90, 0x1b, 0xed, 0xee, 0x10, 0x3b, + 0x43, 0x9a, 0xec, 0xb1, 0xbd, 0xa4, 0x3e, 0xf5, 0xda, 0x83, 0x81, 0x02, 0xbd, 0xf4, 0x98, 0x8f, + 0xd0, 0x63, 0x90, 0x53, 0x4e, 0x45, 0xd1, 0xc3, 0xa2, 0xa0, 0x0f, 0x01, 0x74, 0xd4, 0x27, 0x28, + 0xe6, 0x85, 0xe4, 0x92, 0x52, 0x04, 0x5d, 0xa4, 0x79, 0xde, 0x7e, 0xbf, 0xe7, 0x99, 0x79, 0x66, + 0x67, 0x86, 0x60, 0x83, 0xb2, 0x03, 0xd2, 0x8f, 0x0e, 0xfa, 0x8f, 0xc5, 0xbf, 0xfd, 0x6e, 0x42, + 0x39, 0x85, 0x79, 0xca, 0xf6, 0x85, 0xd4, 0x7f, 0x5c, 0x5d, 0xc7, 0x51, 0x10, 0xd3, 0x03, 0xf9, + 0x57, 0x59, 0xab, 0x9b, 0x6d, 0xda, 0xa6, 0x72, 0x78, 0x20, 0x46, 0x4a, 0xeb, 0xfc, 0xd1, 0x00, + 0x2b, 0x67, 0x38, 0xc1, 0x11, 0x83, 0x8f, 0x41, 0x9e, 0xf4, 0x23, 0xd7, 0x27, 0x31, 0x8d, 0x2a, + 0xb9, 0xdd, 0xdc, 0x5e, 0xbe, 0xb6, 0x79, 0x95, 0xda, 0xd6, 0x10, 0x47, 0xe1, 0x73, 0x67, 0x62, + 0x72, 0x90, 0x49, 0xfa, 0xd1, 0x4b, 0x31, 0x84, 0x2f, 0x00, 0x20, 0x03, 0x9e, 0x60, 0x97, 0x04, + 0x5d, 0x56, 0x31, 0x76, 0x97, 0xf6, 0xf2, 0x35, 0x67, 0x94, 0xda, 0xf9, 0xba, 0xd0, 0xd6, 0x1b, + 0x67, 0xec, 0x2a, 0xb5, 0xd7, 0x35, 0xc0, 0xc4, 0xd1, 0x41, 0x79, 0x29, 0xd4, 0x83, 0x2e, 0x83, + 0xbf, 0x07, 0x45, 0xaf, 0x83, 0x83, 0xd8, 0xf5, 0x68, 0xfc, 0x65, 0xd0, 0xae, 0x2c, 0xef, 0xe6, + 0xf6, 0x0a, 0x87, 0xdb, 0xfb, 0x93, 0x5a, 0xf6, 0x8f, 0x85, 0xf9, 0x58, 0x5a, 0x6b, 0xbb, 0xdf, + 0xa6, 0xf6, 0xc2, 0x55, 0x6a, 0x6f, 0x28, 0xcc, 0x6c, 0xa4, 0xf3, 0x8f, 0x1f, 0xbe, 0x79, 0x98, + 0x43, 0x05, 0x6f, 0xea, 0x0e, 0x0f, 0xc1, 0x16, 0x0e, 0x43, 0xfa, 0xc6, 0xed, 0xc5, 0xa2, 0x5c, + 0xe2, 0x71, 0xe2, 0xbb, 0x7c, 0xc0, 0x2a, 0x2b, 0xbb, 0xb9, 0x3d, 0x13, 0x6d, 0x48, 0xe3, 0xa7, + 0x53, 0xdb, 0xf9, 0x80, 0xc1, 0x43, 0x50, 0x14, 0xb5, 0x7a, 0x1d, 0x1c, 0xc7, 0x24, 0x64, 0x15, + 0x53, 0x56, 0x55, 0x1e, 0xa5, 0x76, 0xa1, 0xfe, 0xd9, 0xab, 0x63, 0xad, 0x46, 0x05, 0xd2, 0x8f, + 0xc6, 0x02, 0xfc, 0x0c, 0x94, 0xb0, 0xe7, 0x11, 0xc6, 0x44, 0x2e, 0x3c, 0xa1, 0x61, 0x25, 0x2f, + 0xcb, 0xa8, 0x64, 0xca, 0x78, 0x21, 0x1d, 0x8e, 0x95, 0xbd, 0xb6, 0x25, 0x0a, 0x19, 0xa5, 0xf6, + 0xda, 0x8c, 0x1a, 0xad, 0xe1, 0xac, 0x08, 0x9f, 0x83, 0xfb, 0xd8, 0xe3, 0x41, 0x9f, 0xb8, 0x8c, + 0x63, 0x1e, 0x78, 0x6e, 0x37, 0x21, 0x1e, 0x8d, 0xba, 0x41, 0x48, 0x58, 0x05, 0x88, 0xc4, 0xd0, + 0x3d, 0xe5, 0xd0, 0x94, 0xf6, 0xb3, 0xa9, 0xf9, 0xf9, 0xbd, 0xb7, 0x3f, 0x7c, 0xf3, 0x10, 0x92, + 0x7e, 0x44, 0xd9, 0xc1, 0x40, 0x36, 0x8b, 0x5a, 0xe7, 0x13, 0xc3, 0x5c, 0xb4, 0x96, 0x4e, 0x0c, + 0x73, 0xc9, 0x32, 0x4e, 0x0c, 0x73, 0xd5, 0x32, 0x9d, 0x3f, 0xe5, 0xc0, 0x6c, 0x1e, 0xf0, 0x39, + 0x58, 0xf1, 0x12, 0x82, 0x39, 0x91, 0x8d, 0x50, 0x38, 0xfc, 0xe0, 0xc7, 0x0a, 0x39, 0x1f, 0x76, + 0x49, 0xcd, 0x10, 0xc5, 0x20, 0x1d, 0x01, 0x3f, 0x02, 0x86, 0x87, 0xc3, 0xb0, 0xb2, 0x78, 0xe7, + 0x48, 0xe9, 0xef, 0xfc, 0x2b, 0x07, 0xd6, 0xaf, 0x79, 0xc0, 0x2f, 0x40, 0x41, 0x4f, 0x2d, 0x1f, + 0x76, 0x55, 0x3a, 0xa5, 0xc3, 0xad, 0x6b, 0xa0, 0x12, 0xed, 0xff, 0x46, 0xa9, 0x0d, 0xa6, 0xf2, + 0x55, 0x6a, 0x43, 0xd5, 0x27, 0x19, 0x04, 0x07, 0x01, 0x3c, 0xf1, 0x80, 0x1e, 0xd8, 0x98, 0x5d, + 0x38, 0x37, 0x0c, 0x18, 0xaf, 0x2c, 0xca, 0x35, 0x7f, 0x32, 0x4a, 0xed, 0xd9, 0x8c, 0x4e, 0x03, + 0xc6, 0xaf, 0x52, 0xbb, 0x3a, 0x83, 0x9a, 0x8d, 0x74, 0xd0, 0x3a, 0x9e, 0x0f, 0x70, 0xbe, 0x2b, + 0x83, 0x42, 0xa6, 0x89, 0xe1, 0x17, 0xa0, 0xdc, 0xa1, 0x11, 0x61, 0x9c, 0x60, 0xdf, 0x6d, 0x85, + 0xd4, 0xbb, 0xd0, 0xdb, 0xed, 0xc9, 0x7f, 0x52, 0x7b, 0xcb, 0xa3, 0x2c, 0xa2, 0x8c, 0xf9, 0x17, + 0xfb, 0x01, 0x3d, 0x88, 0x30, 0xef, 0xec, 0x37, 0x62, 0x41, 0xba, 0xad, 0x48, 0xe7, 0x22, 0x1d, + 0x54, 0x9a, 0x68, 0x6a, 0x42, 0x01, 0x3b, 0xa0, 0xe4, 0x63, 0xea, 0x7e, 0x49, 0x93, 0x0b, 0x0d, + 0xbe, 0x28, 0xc1, 0x6b, 0x3f, 0x0a, 0x3e, 0x4a, 0xed, 0xe2, 0xcb, 0x17, 0x9f, 0x7c, 0x4c, 0x93, + 0x0b, 0x09, 0x71, 0x95, 0xda, 0x5b, 0x8a, 0x6c, 0x16, 0xc8, 0x41, 0x45, 0x1f, 0xd3, 0x89, 0x1b, + 0xfc, 0x2d, 0xb0, 0x26, 0x0e, 0xac, 0xd7, 0xed, 0xd2, 0x84, 0x57, 0x96, 0xc4, 0xc6, 0xaa, 0xfd, + 0xff, 0x28, 0xb5, 0x4b, 0x1a, 0xb2, 0xa9, 0x2c, 0x57, 0xa9, 0x7d, 0x6f, 0x0e, 0x54, 0xc7, 0x38, + 0xa8, 0xa4, 0x61, 0xb5, 0x2b, 0x6c, 0x81, 0x22, 0x09, 0xba, 0x8f, 0x8f, 0x1e, 0xe9, 0x02, 0x0c, + 0x59, 0xc0, 0x2f, 0x6f, 0x2b, 0xa0, 0x50, 0x6f, 0x9c, 0x3d, 0x3e, 0x7a, 0x34, 0xce, 0x5f, 0x7f, + 0x1f, 0xb2, 0x28, 0x0e, 0x2a, 0x28, 0x51, 0x25, 0xdf, 0x00, 0x5a, 0x74, 0x3b, 0x98, 0x75, 0xe4, + 0x67, 0x27, 0x5f, 0xdb, 0x13, 0x0d, 0xa4, 0x90, 0x7e, 0x8d, 0x59, 0x67, 0x3a, 0xeb, 0xad, 0xe1, + 0x1f, 0x70, 0xcc, 0x83, 0x5e, 0x34, 0xc6, 0x02, 0x2a, 0x58, 0x78, 0x4d, 0xd2, 0x3d, 0xd2, 0xe9, + 0xae, 0xdc, 0x35, 0xdd, 0xa3, 0x9b, 0xd2, 0x3d, 0x9a, 0x4d, 0x57, 0xf9, 0x4c, 0x38, 0x9e, 0x69, + 0x8e, 0xd5, 0xbb, 0x72, 0x3c, 0xbb, 0x89, 0xe3, 0xd9, 0x2c, 0x87, 0xf2, 0x11, 0x7d, 0x39, 0x57, + 0x67, 0xc5, 0xbc, 0x73, 0x5f, 0x5e, 0x9b, 0xa1, 0xd2, 0x44, 0xa3, 0xd0, 0x2f, 0xc0, 0xa6, 0x47, + 0x63, 0xc6, 0x85, 0x2e, 0xa6, 0xdd, 0x90, 0x68, 0x8a, 0xbc, 0xa4, 0x78, 0x76, 0x1b, 0xc5, 0x03, + 0xfd, 0xb5, 0xbf, 0x21, 0xdc, 0x41, 0x1b, 0xb3, 0x6a, 0x45, 0xe6, 0x02, 0xab, 0x4b, 0x38, 0x49, + 0x58, 0xab, 0x97, 0xb4, 0x35, 0x11, 0x90, 0x44, 0x4f, 0x6f, 0x23, 0xd2, 0x1d, 0x3a, 0x1f, 0xea, + 0xa0, 0xf2, 0x54, 0xa5, 0x08, 0x3e, 0x07, 0xa5, 0x40, 0xb0, 0xb6, 0x7a, 0xa1, 0x86, 0x2f, 0x48, + 0xf8, 0xc3, 0xdb, 0xe0, 0xf5, 0xae, 0x9a, 0x0d, 0x74, 0xd0, 0xda, 0x58, 0xa1, 0xa0, 0x7d, 0x00, + 0xa3, 0x5e, 0x90, 0xb8, 0xed, 0x10, 0x7b, 0x01, 0x49, 0x34, 0x7c, 0x51, 0xc2, 0x7f, 0x74, 0x1b, + 0xfc, 0x7d, 0x05, 0x7f, 0x3d, 0xd8, 0x41, 0x96, 0x50, 0xfe, 0x4a, 0xe9, 0x14, 0x4b, 0x13, 0x14, + 0x5b, 0x24, 0x09, 0x83, 0x58, 0xe3, 0xaf, 0x49, 0xfc, 0x47, 0xb7, 0xe1, 0xeb, 0x0e, 0xca, 0x86, + 0x39, 0xa8, 0xa0, 0xc4, 0x09, 0x68, 0x48, 0x63, 0x9f, 0x8e, 0x41, 0xd7, 0xef, 0x0c, 0x9a, 0x0d, + 0x73, 0x50, 0x41, 0x89, 0x0a, 0xb4, 0x0d, 0x36, 0x70, 0x92, 0xd0, 0x37, 0x73, 0x13, 0x02, 0x25, + 0xf6, 0x4f, 0x6e, 0xc3, 0x1e, 0x7f, 0xa7, 0xaf, 0x47, 0x8b, 0xef, 0xb4, 0xd0, 0xce, 0x4c, 0x89, + 0x0f, 0x60, 0x3b, 0xc1, 0xc3, 0x39, 0x9e, 0xcd, 0x3b, 0x4f, 0xfc, 0xf5, 0x60, 0x07, 0x59, 0x42, + 0x39, 0xc3, 0xf2, 0x15, 0xd8, 0x8c, 0x48, 0xd2, 0x26, 0x6e, 0x4c, 0x38, 0xeb, 0x86, 0x01, 0xd7, + 0x3c, 0x5b, 0x77, 0xde, 0x07, 0x37, 0x85, 0x3b, 0x08, 0x4a, 0xf5, 0x6b, 0xad, 0x9d, 0x74, 0x29, + 0xeb, 0xe0, 0xb8, 0xdd, 0xc1, 0x81, 0x66, 0xd9, 0xbe, 0x73, 0x97, 0xce, 0x06, 0x3a, 0x68, 0x6d, + 0xac, 0x98, 0x2c, 0xb5, 0x87, 0x63, 0xaf, 0x37, 0x5e, 0xea, 0x7b, 0x77, 0x5e, 0xea, 0x6c, 0x98, + 0x83, 0x0a, 0x4a, 0x54, 0xa0, 0xf7, 0x81, 0xa9, 0xae, 0x74, 0x81, 0x5f, 0xa9, 0xec, 0xe6, 0xf6, + 0x0c, 0xb4, 0x2a, 0xe5, 0x86, 0x0f, 0x37, 0xc1, 0xb2, 0xba, 0x99, 0xde, 0x17, 0x44, 0x48, 0x09, + 0xb0, 0x0a, 0x4c, 0x9f, 0x78, 0x41, 0x84, 0x43, 0x56, 0xa9, 0xca, 0x80, 0x89, 0x7c, 0x62, 0x98, + 0x25, 0xab, 0x7c, 0x62, 0x98, 0x65, 0xcb, 0x3a, 0x31, 0x4c, 0xcb, 0x5a, 0x3f, 0x31, 0xcc, 0x0d, + 0x6b, 0x13, 0xad, 0x0d, 0x69, 0x48, 0xdd, 0xfe, 0x13, 0x95, 0x01, 0x2a, 0x90, 0x37, 0x98, 0xe9, + 0xaf, 0x16, 0x2a, 0x79, 0x98, 0xe3, 0x70, 0xc8, 0xf4, 0xac, 0x22, 0x4b, 0xcd, 0x75, 0xe6, 0x0c, + 0x3c, 0x00, 0xcb, 0xe2, 0xae, 0x45, 0xa0, 0x05, 0x96, 0x2e, 0xc8, 0x50, 0x9d, 0xdc, 0x48, 0x0c, + 0x45, 0x8a, 0x7d, 0x1c, 0xf6, 0x88, 0x3a, 0x70, 0x91, 0x12, 0x9c, 0x06, 0x28, 0x9f, 0x27, 0x38, + 0x66, 0xe2, 0x9e, 0x46, 0xe3, 0x53, 0xda, 0x66, 0x10, 0x02, 0x43, 0x1e, 0x3a, 0x2a, 0x56, 0x8e, + 0xa1, 0x03, 0x8c, 0x90, 0xb6, 0x99, 0xbc, 0x7a, 0x14, 0x0e, 0x4b, 0x99, 0x0b, 0xce, 0x29, 0x6d, + 0x23, 0x69, 0x73, 0xbe, 0x5b, 0x04, 0x4b, 0xa7, 0xb4, 0x0d, 0x2b, 0x60, 0x15, 0xfb, 0x7e, 0x42, + 0x18, 0xd3, 0x10, 0x63, 0x11, 0x6e, 0x83, 0x15, 0x4e, 0xbb, 0x81, 0xa7, 0x70, 0xf2, 0x48, 0x4b, + 0x82, 0xd1, 0xc7, 0x1c, 0xcb, 0xe3, 0xb9, 0x88, 0xe4, 0x58, 0x5c, 0x74, 0x65, 0x49, 0x6e, 0xdc, + 0x8b, 0x5a, 0x24, 0x91, 0xa7, 0xac, 0x51, 0x2b, 0x5f, 0xa6, 0x76, 0x41, 0xea, 0x5f, 0x4b, 0x35, + 0xca, 0x0a, 0xf0, 0x43, 0xb0, 0xca, 0x07, 0xd9, 0x13, 0x73, 0xe3, 0x32, 0xb5, 0xcb, 0x7c, 0x5a, + 0x9f, 0x38, 0x10, 0xd1, 0x0a, 0x1f, 0xc8, 0x83, 0xf1, 0x00, 0x98, 0x7c, 0xe0, 0x06, 0xb1, 0x4f, + 0x06, 0xf2, 0x50, 0x34, 0x6a, 0x9b, 0x97, 0xa9, 0x6d, 0x65, 0xdc, 0x1b, 0xc2, 0x86, 0x56, 0xf9, + 0x40, 0x0e, 0xe0, 0x87, 0x00, 0xa8, 0x94, 0x24, 0x83, 0x3a, 0xe3, 0xd6, 0x2e, 0x53, 0x3b, 0x2f, + 0xb5, 0x12, 0x7b, 0x3a, 0x84, 0x0e, 0x58, 0x56, 0xd8, 0xa6, 0xc4, 0x2e, 0x5e, 0xa6, 0xb6, 0x19, + 0xd2, 0xb6, 0xc2, 0x54, 0x26, 0x31, 0x55, 0x09, 0x89, 0x68, 0x9f, 0xf8, 0xf2, 0xa0, 0x31, 0xd1, + 0x58, 0x74, 0xfe, 0xbc, 0x08, 0xcc, 0xf3, 0x01, 0x22, 0xac, 0x17, 0x72, 0xf8, 0x31, 0xb0, 0xe4, + 0x35, 0x0e, 0x7b, 0xdc, 0x9d, 0x99, 0xda, 0xda, 0x83, 0xe9, 0xb1, 0x30, 0xef, 0xe1, 0xa0, 0xf2, + 0x58, 0xf5, 0x42, 0xcf, 0xff, 0x26, 0x58, 0x6e, 0x85, 0x94, 0x46, 0xb2, 0x05, 0x8a, 0x48, 0x09, + 0xf0, 0x4c, 0xce, 0x9a, 0x5c, 0xde, 0x25, 0x79, 0x29, 0xae, 0x66, 0x96, 0x77, 0xae, 0x39, 0x6a, + 0x0f, 0xf4, 0x13, 0xa7, 0xa4, 0x48, 0x75, 0xa0, 0x7e, 0xdd, 0xac, 0xf0, 0x81, 0xec, 0x20, 0x0b, + 0x2c, 0x25, 0x84, 0xcb, 0x25, 0x2b, 0x22, 0x31, 0x14, 0x3b, 0x21, 0x21, 0x7d, 0x92, 0x70, 0xe2, + 0xcb, 0xa5, 0x31, 0xd1, 0x44, 0x16, 0xdb, 0xaa, 0x8d, 0x99, 0xdb, 0x63, 0xc4, 0x57, 0xeb, 0x80, + 0x56, 0xdb, 0x98, 0x7d, 0xca, 0x88, 0xff, 0xdc, 0xf8, 0xfa, 0x6f, 0xf6, 0x82, 0x83, 0x41, 0x41, + 0x5f, 0x9b, 0x7b, 0xdd, 0x90, 0xdc, 0xd2, 0x5f, 0x87, 0xa0, 0xc8, 0x38, 0x4d, 0x70, 0x9b, 0xb8, + 0x17, 0x64, 0xa8, 0xbb, 0x4c, 0xf5, 0x8c, 0xd6, 0xff, 0x86, 0x0c, 0x19, 0xca, 0x0a, 0x9a, 0xe2, + 0xaf, 0x06, 0x28, 0x9c, 0x27, 0xd8, 0x23, 0xfa, 0x12, 0x2c, 0x3a, 0x55, 0x88, 0x89, 0xa6, 0xd0, + 0x92, 0xe0, 0xe6, 0x41, 0x44, 0x68, 0x8f, 0xeb, 0x6d, 0x34, 0x16, 0x45, 0x44, 0x42, 0xc8, 0x80, + 0x78, 0x72, 0x12, 0x0d, 0xa4, 0x25, 0x78, 0x04, 0xd6, 0xfc, 0x80, 0xe1, 0x56, 0x28, 0x5f, 0x49, + 0xde, 0x85, 0x2a, 0xbf, 0x66, 0x5d, 0xa6, 0x76, 0x51, 0x1b, 0x9a, 0x42, 0x8f, 0x66, 0x24, 0xf8, + 0x33, 0x50, 0x9e, 0x86, 0xc9, 0x6c, 0xd5, 0xab, 0xb0, 0x06, 0x2f, 0x53, 0xbb, 0x34, 0x71, 0x95, + 0x16, 0x34, 0x27, 0xab, 0xaf, 0x51, 0xab, 0xd7, 0x96, 0xad, 0x67, 0x22, 0x25, 0x08, 0x6d, 0x18, + 0x44, 0x01, 0x97, 0xad, 0xb6, 0x8c, 0x94, 0x00, 0x9f, 0x82, 0x3c, 0xed, 0x93, 0x24, 0x09, 0x7c, + 0xf9, 0x68, 0xbb, 0xe5, 0x79, 0x8b, 0xa6, 0x8e, 0xa2, 0x2a, 0x12, 0xcb, 0xec, 0x22, 0x12, 0xd1, + 0x64, 0x28, 0xef, 0x17, 0xba, 0x2a, 0x65, 0x78, 0x25, 0xf5, 0x68, 0x46, 0x82, 0x35, 0x00, 0x75, + 0x58, 0x42, 0x78, 0x2f, 0x89, 0x5d, 0xb9, 0xed, 0x8b, 0x32, 0x56, 0x6e, 0x3e, 0x65, 0x45, 0xd2, + 0xf8, 0x12, 0x73, 0x8c, 0xae, 0x69, 0xe0, 0x2f, 0x00, 0x54, 0x8b, 0xe1, 0x7e, 0xc5, 0xe8, 0xe4, + 0x61, 0xae, 0x2e, 0x08, 0x92, 0x5f, 0x59, 0x75, 0xce, 0x96, 0x92, 0x4e, 0x18, 0xd5, 0x55, 0x9c, + 0x18, 0xa6, 0x61, 0x2d, 0xab, 0xa7, 0xe5, 0x64, 0xe2, 0x74, 0x15, 0x68, 0x63, 0x2c, 0x67, 0xd2, + 0x7b, 0xf8, 0xcf, 0x1c, 0xc8, 0x3c, 0xdb, 0xe0, 0xcf, 0x41, 0xf5, 0xc5, 0xf1, 0x71, 0xbd, 0xd9, + 0x74, 0xcf, 0x3f, 0x3f, 0xab, 0xbb, 0x67, 0x75, 0xf4, 0xaa, 0xd1, 0x6c, 0x36, 0x3e, 0x79, 0x7d, + 0x5a, 0x6f, 0x36, 0xad, 0x85, 0xea, 0x07, 0x6f, 0xdf, 0xed, 0x56, 0xa6, 0xfe, 0x67, 0x24, 0x89, + 0x02, 0xc6, 0x02, 0x1a, 0x87, 0xa2, 0x45, 0x9f, 0x82, 0xed, 0x6c, 0x34, 0xaa, 0x37, 0xcf, 0x51, + 0xe3, 0xf8, 0xbc, 0xfe, 0xd2, 0xca, 0x55, 0x2b, 0x6f, 0xdf, 0xed, 0x6e, 0x4e, 0x23, 0x11, 0x61, + 0x3c, 0x09, 0xc4, 0xc3, 0x1f, 0x3e, 0x03, 0x95, 0x9b, 0x39, 0xeb, 0x2f, 0xad, 0xc5, 0x6a, 0xf5, + 0xed, 0xbb, 0xdd, 0xed, 0x9b, 0x18, 0x89, 0x5f, 0x35, 0xbe, 0xfe, 0xfb, 0xce, 0x42, 0xed, 0xa7, + 0xdf, 0x8e, 0x76, 0x72, 0xdf, 0x8f, 0x76, 0x72, 0xff, 0x1d, 0xed, 0xe4, 0xfe, 0xf2, 0x7e, 0x67, + 0xe1, 0xfb, 0xf7, 0x3b, 0x0b, 0xff, 0x7e, 0xbf, 0xb3, 0xf0, 0x3b, 0xbb, 0x1d, 0xf0, 0x4e, 0xaf, + 0xb5, 0xef, 0xd1, 0xe8, 0x40, 0xbd, 0xc6, 0x27, 0x0f, 0x72, 0xf1, 0x1e, 0x65, 0xad, 0x15, 0xf9, + 0x4b, 0xcc, 0x93, 0xff, 0x05, 0x00, 0x00, 0xff, 0xff, 0x6e, 0x77, 0x71, 0x7e, 0xd4, 0x11, 0x00, + 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { @@ -1171,6 +1201,29 @@ func (m *ChainConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + if m.Decimals != 0 { + i = encodeVarintEvm(dAtA, i, uint64(m.Decimals)) + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0xd0 + } + if len(m.Denom) > 0 { + i -= len(m.Denom) + copy(dAtA[i:], m.Denom) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Denom))) + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0xca + } + if m.ChainId != 0 { + i = encodeVarintEvm(dAtA, i, uint64(m.ChainId)) + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0xc0 + } if m.CancunBlock != nil { { size := m.CancunBlock.Size() @@ -1958,6 +2011,16 @@ func (m *ChainConfig) Size() (n int) { l = m.CancunBlock.Size() n += 2 + l + sovEvm(uint64(l)) } + if m.ChainId != 0 { + n += 2 + sovEvm(uint64(m.ChainId)) + } + l = len(m.Denom) + if l > 0 { + n += 2 + l + sovEvm(uint64(l)) + } + if m.Decimals != 0 { + n += 2 + sovEvm(uint64(m.Decimals)) + } return n } @@ -3314,6 +3377,76 @@ func (m *ChainConfig) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex + case 24: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType) + } + m.ChainId = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.ChainId |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 25: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Denom = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 26: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Decimals", wireType) + } + m.Decimals = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Decimals |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } default: iNdEx = preIndex skippy, err := skipEvm(dAtA[iNdEx:]) diff --git a/x/evm/types/genesis_test.go b/x/evm/types/genesis_test.go index 60328f6d..88879a84 100644 --- a/x/evm/types/genesis_test.go +++ b/x/evm/types/genesis_test.go @@ -5,7 +5,6 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/evmos/os/crypto/ethsecp256k1" - testconstants "github.com/evmos/os/testutil/constants" "github.com/stretchr/testify/suite" ) @@ -72,7 +71,6 @@ func (suite *GenesisTestSuite) TestValidateGenesisAccount() { } for _, tc := range testCases { - tc := tc err := tc.genesisAccount.Validate() if tc.expPass { suite.Require().NoError(err, tc.name) @@ -83,8 +81,7 @@ func (suite *GenesisTestSuite) TestValidateGenesisAccount() { } func (suite *GenesisTestSuite) TestValidateGenesis() { - defaultGenesisWithEVMDenom := DefaultGenesisState() - defaultGenesisWithEVMDenom.Params.EvmDenom = testconstants.ExampleAttoDenom + defaultGenesis := DefaultGenesisState() testCases := []struct { name string @@ -94,7 +91,7 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { { name: "default", genState: DefaultGenesisState(), - expPass: false, + expPass: true, }, { name: "valid genesis", @@ -109,31 +106,15 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { }, }, }, - Params: DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom), + Params: DefaultParams(), }, expPass: true, }, - { - name: "empty genesis", - genState: &GenesisState{}, - expPass: false, - }, { name: "copied genesis", - genState: NewGenesisState(defaultGenesisWithEVMDenom.Params, DefaultGenesisState().Accounts), + genState: NewGenesisState(defaultGenesis.Params, defaultGenesis.Accounts), expPass: true, }, - { - name: "invalid genesis", - genState: &GenesisState{ - Accounts: []GenesisAccount{ - { - Address: common.Address{}.String(), - }, - }, - }, - expPass: false, - }, { name: "invalid genesis account", genState: &GenesisState{ @@ -147,7 +128,7 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { }, }, }, - Params: DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom), + Params: DefaultParams(), }, expPass: false, }, @@ -175,50 +156,9 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { }, expPass: false, }, - { - name: "duplicated tx log", - genState: &GenesisState{ - Accounts: []GenesisAccount{ - { - Address: suite.address, - - Code: suite.code, - Storage: Storage{ - {Key: suite.hash.String()}, - }, - }, - }, - }, - expPass: false, - }, - { - name: "invalid tx log", - genState: &GenesisState{ - Accounts: []GenesisAccount{ - { - Address: suite.address, - - Code: suite.code, - Storage: Storage{ - {Key: suite.hash.String()}, - }, - }, - }, - }, - expPass: false, - }, - { - name: "invalid params", - genState: &GenesisState{ - Params: Params{}, - }, - expPass: false, - }, } for _, tc := range testCases { - tc := tc - suite.Run(tc.name, func() { err := tc.genState.Validate() if tc.expPass { diff --git a/x/evm/types/interfaces.go b/x/evm/types/interfaces.go index a247cf64..1b8b4b9a 100644 --- a/x/evm/types/interfaces.go +++ b/x/evm/types/interfaces.go @@ -7,6 +7,7 @@ import ( "math/big" "cosmossdk.io/core/address" + "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" @@ -31,6 +32,7 @@ type AccountKeeper interface { // BankKeeper defines the expected interface needed to retrieve account balances. type BankKeeper interface { authtypes.BankKeeper + GetAllBalances(ctx context.Context, addr sdk.AccAddress) sdk.Coins GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error MintCoins(ctx context.Context, moduleName string, amt sdk.Coins) error @@ -44,11 +46,11 @@ type StakingKeeper interface { ValidatorAddressCodec() address.Codec } -// FeeMarketKeeper +// FeeMarketKeeper defines the expected interfaces needed for the feemarket type FeeMarketKeeper interface { - GetBaseFee(ctx sdk.Context) *big.Int + GetBaseFee(ctx sdk.Context) math.LegacyDec GetParams(ctx sdk.Context) feemarkettypes.Params - CalculateBaseFee(ctx sdk.Context) *big.Int + CalculateBaseFee(ctx sdk.Context) math.LegacyDec } // Erc20Keeper defines the expected interface needed to instantiate ERC20 precompiles. @@ -64,3 +66,13 @@ type ( GetParamSetIfExists(ctx sdk.Context, ps LegacyParams) } ) + +// BankWrapper defines the methods required by the wrapper around +// the Cosmos SDK x/bank keeper that is used to manage an EVM coin +// with a configurable value for decimals. +type BankWrapper interface { + BankKeeper + + MintAmountToAccount(ctx context.Context, recipientAddr sdk.AccAddress, amt *big.Int) error + BurnAmountFromAccount(ctx context.Context, account sdk.AccAddress, amt *big.Int) error +} diff --git a/x/evm/types/logs_test.go b/x/evm/types/logs_test.go index 2455dd45..f5e01693 100644 --- a/x/evm/types/logs_test.go +++ b/x/evm/types/logs_test.go @@ -85,7 +85,6 @@ func TestTransactionLogsValidate(t *testing.T) { } for _, tc := range testCases { - tc := tc err := tc.txLogs.Validate() if tc.expPass { require.NoError(t, err, tc.name) @@ -158,7 +157,6 @@ func TestValidateLog(t *testing.T) { } for _, tc := range testCases { - tc := tc err := tc.log.Validate() if tc.expPass { require.NoError(t, err, tc.name) diff --git a/x/evm/types/msg.go b/x/evm/types/msg.go index 3c03348d..d4b21721 100644 --- a/x/evm/types/msg.go +++ b/x/evm/types/msg.go @@ -339,10 +339,11 @@ func (msg *MsgEthereumTx) BuildTx(b client.TxBuilder, evmDenom string) (signing. if err != nil { return nil, err } - fees := make(sdk.Coins, 0) + fees := make(sdk.Coins, 0, 1) feeAmt := sdkmath.NewIntFromBigInt(txData.Fee()) if feeAmt.Sign() > 0 { fees = append(fees, sdk.NewCoin(evmDenom, feeAmt)) + fees = ConvertCoinsFrom18Decimals(fees) } builder.SetExtensionOptions(option) diff --git a/x/evm/types/msg_test.go b/x/evm/types/msg_test.go index 9347c6a8..9c7febcc 100644 --- a/x/evm/types/msg_test.go +++ b/x/evm/types/msg_test.go @@ -17,6 +17,7 @@ import ( "github.com/ethereum/go-ethereum/crypto" "github.com/evmos/os/crypto/ethsecp256k1" "github.com/evmos/os/encoding" + exampleapp "github.com/evmos/os/example_chain" testconstants "github.com/evmos/os/testutil/constants" utiltx "github.com/evmos/os/testutil/tx" "github.com/evmos/os/x/evm/types" @@ -52,6 +53,9 @@ func (suite *MsgsTestSuite) SetupTest() { encodingConfig := encoding.MakeConfig() suite.clientCtx = client.Context{}.WithTxConfig(encodingConfig.TxConfig) + + err := exampleapp.InitializeAppConfiguration("evmos_9001-1") + suite.Require().NoError(err) } func (suite *MsgsTestSuite) TestMsgEthereumTx_Constructor() { @@ -86,8 +90,8 @@ func (suite *MsgsTestSuite) TestMsgEthereumTx_BuildTx() { Nonce: 0, To: &suite.to, GasLimit: 100000, - GasPrice: big.NewInt(1), - GasFeeCap: big.NewInt(1), + GasPrice: big.NewInt(1e18), + GasFeeCap: big.NewInt(1e18), GasTipCap: big.NewInt(0), Input: []byte("test"), } @@ -107,22 +111,38 @@ func (suite *MsgsTestSuite) TestMsgEthereumTx_BuildTx() { true, }, } + for _, cfg := range []types.EvmCoinInfo{ + {Denom: testconstants.ExampleMicroDenom, Decimals: types.SixDecimals}, + {Denom: testconstants.ExampleAttoDenom, Decimals: types.EighteenDecimals}, + } { + for _, tc := range testCases { + configurator := types.NewEVMConfigurator() + configurator.ResetTestConfig() + suite.Require().NoError(configurator.WithEVMCoinInfo(cfg.Denom, uint8(cfg.Decimals)).Configure()) + if strings.Contains(tc.name, "nil data") { + tc.msg.Data = nil + } - for _, tc := range testCases { - if strings.Contains(tc.name, "nil data") { - tc.msg.Data = nil - } + baseDenom := types.GetEVMCoinDenom() - tx, err := tc.msg.BuildTx(suite.clientCtx.TxConfig.NewTxBuilder(), testconstants.ExampleAttoDenom) - if tc.expError { - suite.Require().Error(err) - } else { - suite.Require().NoError(err) + tx, err := tc.msg.BuildTx(suite.clientCtx.TxConfig.NewTxBuilder(), baseDenom) + if tc.expError { + suite.Require().Error(err) + } else { + suite.Require().NoError(err) - suite.Require().Empty(tx.GetMemo()) - suite.Require().Empty(tx.GetTimeoutHeight()) - suite.Require().Equal(uint64(100000), tx.GetGas()) - suite.Require().Equal(sdk.NewCoins(sdk.NewCoin(testconstants.ExampleAttoDenom, sdkmath.NewInt(100000))), tx.GetFee()) + suite.Require().Empty(tx.GetMemo()) + suite.Require().Empty(tx.GetTimeoutHeight()) + suite.Require().Equal(uint64(100000), tx.GetGas()) + + expFeeAmt := sdkmath.NewIntFromBigInt(evmTx.GasPrice).MulRaw(int64(evmTx.GasLimit)) //#nosec + expFee := sdk.NewCoins(sdk.NewCoin(baseDenom, expFeeAmt)) + if cfg.Decimals == types.SixDecimals { + scaledAmt := expFeeAmt.QuoRaw(1e12) + expFee = sdk.NewCoins(sdk.NewCoin(baseDenom, scaledAmt)) + } + suite.Require().Equal(expFee, tx.GetFee()) + } } } } diff --git a/x/evm/types/params.go b/x/evm/types/params.go index 6930f658..b26a2914 100644 --- a/x/evm/types/params.go +++ b/x/evm/types/params.go @@ -9,7 +9,6 @@ import ( "slices" errorsmod "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" channeltypes "github.com/cosmos/ibc-go/v8/modules/core/04-channel/types" host "github.com/cosmos/ibc-go/v8/modules/core/24-host" @@ -20,10 +19,6 @@ import ( ) var ( - // DefaultEVMDenom defines the default EVM denomination on Evmos. - // - // TODO: improve handling here to accept Default parameters and not have Evmos native things in OS repo - DefaultEVMDenom = "" // DefaultAllowUnprotectedTxs rejects all unprotected txs (i.e false) DefaultAllowUnprotectedTxs = false // DefaultStaticPrecompiles defines the default active precompiles. @@ -51,19 +46,15 @@ var ( // NewParams creates a new Params instance func NewParams( - evmDenom string, allowUnprotectedTxs bool, - config ChainConfig, extraEIPs []string, activeStaticPrecompiles, evmChannels []string, accessControl AccessControl, ) Params { return Params{ - EvmDenom: evmDenom, AllowUnprotectedTxs: allowUnprotectedTxs, ExtraEIPs: extraEIPs, - ChainConfig: config, ActiveStaticPrecompiles: activeStaticPrecompiles, EVMChannels: evmChannels, AccessControl: accessControl, @@ -73,8 +64,6 @@ func NewParams( // DefaultParams returns default evm parameters func DefaultParams() Params { return Params{ - EvmDenom: DefaultEVMDenom, - ChainConfig: DefaultChainConfig(), ExtraEIPs: DefaultExtraEIPs, AllowUnprotectedTxs: DefaultAllowUnprotectedTxs, ActiveStaticPrecompiles: DefaultStaticPrecompiles, @@ -83,14 +72,6 @@ func DefaultParams() Params { } } -// DefaultParamsWithEVMDenom returns default evm parameters with the provided EVM denomination -func DefaultParamsWithEVMDenom(evmDenom string) Params { - evmParams := DefaultParams() - evmParams.EvmDenom = evmDenom - - return evmParams -} - // validateChannels checks if channels ids are valid func validateChannels(i interface{}) error { channels, ok := i.([]string) @@ -111,10 +92,6 @@ func validateChannels(i interface{}) error { // Validate performs basic validation on evm parameters. func (p Params) Validate() error { - if err := validateEVMDenom(p.EvmDenom); err != nil { - return err - } - if err := validateEIPs(p.ExtraEIPs); err != nil { return err } @@ -123,10 +100,6 @@ func (p Params) Validate() error { return err } - if err := validateChainConfig(p.ChainConfig); err != nil { - return err - } - if err := ValidatePrecompiles(p.ActiveStaticPrecompiles); err != nil { return err } @@ -212,15 +185,6 @@ func validateAllowlistAddresses(i interface{}) error { return nil } -func validateEVMDenom(i interface{}) error { - denom, ok := i.(string) - if !ok { - return fmt.Errorf("invalid parameter EVM denom type: %T", i) - } - - return sdk.ValidateDenom(denom) -} - func validateBool(i interface{}) error { _, ok := i.(bool) if !ok { @@ -256,15 +220,6 @@ func validateEIPs(i interface{}) error { return nil } -func validateChainConfig(i interface{}) error { - cfg, ok := i.(ChainConfig) - if !ok { - return fmt.Errorf("invalid chain config type: %T", i) - } - - return cfg.Validate() -} - // ValidatePrecompiles checks if the precompile addresses are valid and unique. func ValidatePrecompiles(i interface{}) error { precompiles, ok := i.([]string) diff --git a/x/evm/types/params_legacy.go b/x/evm/types/params_legacy.go index 4cf1b767..51e7b278 100644 --- a/x/evm/types/params_legacy.go +++ b/x/evm/types/params_legacy.go @@ -28,9 +28,7 @@ func ParamKeyTable() paramtypes.KeyTable { // for migration purposes and will be removed in a future release. func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { return paramtypes.ParamSetPairs{ - paramtypes.NewParamSetPair(ParamStoreKeyEVMDenom, &p.EvmDenom, validateEVMDenom), paramtypes.NewParamSetPair(ParamStoreKeyExtraEIPs, &p.ExtraEIPs, validateEIPs), - paramtypes.NewParamSetPair(ParamStoreKeyChainConfig, &p.ChainConfig, validateChainConfig), paramtypes.NewParamSetPair(ParamStoreKeyAllowUnprotectedTxs, &p.AllowUnprotectedTxs, validateBool), } } diff --git a/x/evm/types/params_test.go b/x/evm/types/params_test.go index 6286abda..adb65487 100644 --- a/x/evm/types/params_test.go +++ b/x/evm/types/params_test.go @@ -4,7 +4,6 @@ import ( "testing" ethparams "github.com/ethereum/go-ethereum/params" - testconstants "github.com/evmos/os/testutil/constants" "github.com/stretchr/testify/require" ) @@ -19,36 +18,23 @@ func TestParamsValidate(t *testing.T) { errContains string }{ { - name: "default", - params: DefaultParams(), - errContains: "invalid denom", - }, - { - name: "default with denom", - params: DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom), + name: "default", + params: DefaultParams(), expPass: true, }, { name: "valid", - params: NewParams(testconstants.ExampleAttoDenom, false, DefaultChainConfig(), extraEips, nil, nil, DefaultAccessControl), + params: NewParams(false, extraEips, nil, nil, DefaultAccessControl), expPass: true, }, { - name: "empty", - params: Params{}, - errContains: "invalid denom: ", // NOTE: this returns the first error that occurs - }, - { - name: "invalid evm denom", - params: Params{ - EvmDenom: "@!#!@$!@5^32", - }, - errContains: "invalid denom: @!#!@$!@5^32", + name: "empty", + params: Params{}, + expPass: true, }, { name: "invalid eip", params: Params{ - EvmDenom: testconstants.ExampleAttoDenom, ExtraEIPs: []string{"os_1000000"}, }, errContains: "EIP os_1000000 is not activateable, valid EIPs are", @@ -56,7 +42,6 @@ func TestParamsValidate(t *testing.T) { { name: "unsorted precompiles", params: Params{ - EvmDenom: testconstants.ExampleAttoDenom, ActiveStaticPrecompiles: []string{ "0x0000000000000000000000000000000000000801", "0x0000000000000000000000000000000000000800", @@ -67,7 +52,7 @@ func TestParamsValidate(t *testing.T) { } for _, tc := range testCases { - tc := tc + tc := tc //nolint:copyloopvar // Needed to work correctly with concurrent tests t.Run(tc.name, func(t *testing.T) { t.Parallel() @@ -92,15 +77,13 @@ func TestParamsValidate(t *testing.T) { func TestParamsEIPs(t *testing.T) { extraEips := []string{"ethereum_2929", "ethereum_1884", "ethereum_1344"} - params := NewParams("ara", false, DefaultChainConfig(), extraEips, nil, nil, DefaultAccessControl) + params := NewParams(false, extraEips, nil, nil, DefaultAccessControl) actual := params.EIPs() require.Equal(t, []string{"ethereum_2929", "ethereum_1884", "ethereum_1344"}, actual) } func TestParamsValidatePriv(t *testing.T) { - require.Error(t, validateEVMDenom(false)) - require.NoError(t, validateEVMDenom("inj")) require.Error(t, validateBool("")) require.NoError(t, validateBool(true)) require.Error(t, validateEIPs("")) @@ -113,34 +96,6 @@ func TestParamsValidatePriv(t *testing.T) { require.Error(t, validateChannels("")) } -func TestValidateChainConfig(t *testing.T) { - testCases := []struct { - name string - i interface{} - expError bool - }{ - { - "invalid chain config type", - "string", - true, - }, - { - "valid chain config type", - DefaultChainConfig(), - false, - }, - } - for _, tc := range testCases { - err := validateChainConfig(tc.i) - - if tc.expError { - require.Error(t, err, tc.name) - } else { - require.NoError(t, err, tc.name) - } - } -} - func TestIsLondon(t *testing.T) { testCases := []struct { name string diff --git a/x/evm/types/permissions_test.go b/x/evm/types/permissions_test.go index 05b7b788..3e59ba8e 100644 --- a/x/evm/types/permissions_test.go +++ b/x/evm/types/permissions_test.go @@ -7,7 +7,6 @@ import ( "testing" "github.com/ethereum/go-ethereum/common" - testconstants "github.com/evmos/os/testutil/constants" testkeyring "github.com/evmos/os/testutil/integration/os/keyring" "github.com/evmos/os/x/evm/types" "github.com/stretchr/testify/suite" @@ -36,7 +35,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should allow call and create with default accessControl", getAccessControl: func() types.AccessControl { - return types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + return types.DefaultParams().AccessControl }, canCall: true, canCreate: true, @@ -47,7 +46,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should not allow call and create with nobody accessControl", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Create.AccessType = types.AccessTypeRestricted p.Call.AccessType = types.AccessTypeRestricted return p @@ -61,7 +60,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should not allow call with permissionless policy and signer in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Call.AccessType = types.AccessTypePermissionless p.Call.AccessControlList = []string{keyring.GetAddr(0).String()} return p @@ -75,7 +74,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should not allow call with permissionless policy and signer not in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Call.AccessType = types.AccessTypePermissionless p.Call.AccessControlList = []string{keyring.GetAddr(0).String()} return p @@ -89,7 +88,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should allow call with permissionless policy while caller nor signer are in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Call.AccessType = types.AccessTypePermissionless p.Call.AccessControlList = []string{keyring.GetAddr(0).String()} return p @@ -103,7 +102,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should allow call with permissionless policy and caller not in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Call.AccessType = types.AccessTypePermissionless p.Call.AccessControlList = []string{keyring.GetAddr(1).String()} return p @@ -117,7 +116,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should not allow create with permissionless policy and signer in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Create.AccessType = types.AccessTypePermissionless p.Create.AccessControlList = []string{keyring.GetAddr(0).String()} return p @@ -131,7 +130,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should not allow create with permissionless policy and signer not in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Create.AccessType = types.AccessTypePermissionless p.Create.AccessControlList = []string{keyring.GetAddr(0).String()} return p @@ -145,7 +144,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should allow create with permissionless policy while caller nor signer are in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Create.AccessType = types.AccessTypePermissionless p.Create.AccessControlList = []string{keyring.GetAddr(0).String()} return p @@ -159,7 +158,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should allow create with permissionless policy and caller not in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Create.AccessType = types.AccessTypePermissionless p.Create.AccessControlList = []string{keyring.GetAddr(1).String()} return p @@ -173,7 +172,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should not allow call with permissioned policy and not in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Call.AccessType = types.AccessTypePermissioned p.Call.AccessControlList = []string{keyring.GetAddr(1).String()} return p @@ -187,7 +186,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should not allow create with permissioned policy and not in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Create.AccessType = types.AccessTypePermissioned p.Create.AccessControlList = []string{keyring.GetAddr(1).String()} return p @@ -201,7 +200,7 @@ func (suite *UnitTestSuite) TestAccessControl() { { name: "should allow call and create with permissioned policy and address in AccessControlList", getAccessControl: func() types.AccessControl { - p := types.DefaultParamsWithEVMDenom(testconstants.ExampleAttoDenom).AccessControl + p := types.DefaultParams().AccessControl p.Create.AccessType = types.AccessTypePermissioned p.Create.AccessControlList = []string{keyring.GetAddr(0).String()} p.Call.AccessType = types.AccessTypePermissioned diff --git a/x/evm/types/precompiles.go b/x/evm/types/precompiles.go index 3fcef41e..f7319a00 100644 --- a/x/evm/types/precompiles.go +++ b/x/evm/types/precompiles.go @@ -14,6 +14,8 @@ const ( ICS20PrecompileAddress = "0x0000000000000000000000000000000000000802" VestingPrecompileAddress = "0x0000000000000000000000000000000000000803" BankPrecompileAddress = "0x0000000000000000000000000000000000000804" + GovPrecompileAddress = "0x0000000000000000000000000000000000000805" + SlashingPrecompileAddress = "0x0000000000000000000000000000000000000806" ) // AvailableStaticPrecompiles defines the full list of all available EVM extension addresses. @@ -28,4 +30,6 @@ var AvailableStaticPrecompiles = []string{ ICS20PrecompileAddress, VestingPrecompileAddress, BankPrecompileAddress, + GovPrecompileAddress, + SlashingPrecompileAddress, } diff --git a/x/evm/types/query.go b/x/evm/types/query.go index 062e3b8d..7fb4b0e5 100644 --- a/x/evm/types/query.go +++ b/x/evm/types/query.go @@ -24,3 +24,8 @@ func (m QueryTraceBlockRequest) UnpackInterfaces(unpacker codectypes.AnyUnpacker } return nil } + +// Failed returns if the contract execution failed in vm errors +func (egr EstimateGasResponse) Failed() bool { + return len(egr.VmError) > 0 +} diff --git a/x/evm/types/query.pb.go b/x/evm/types/query.pb.go index 3daa5776..ac935bba 100644 --- a/x/evm/types/query.pb.go +++ b/x/evm/types/query.pb.go @@ -37,6 +37,89 @@ var _ = time.Kitchen // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package +// QueryConfigRequest defines the request type for querying the config +type QueryConfigRequest struct { +} + +func (m *QueryConfigRequest) Reset() { *m = QueryConfigRequest{} } +func (m *QueryConfigRequest) String() string { return proto.CompactTextString(m) } +func (*QueryConfigRequest) ProtoMessage() {} +func (*QueryConfigRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_03991b98eceb9743, []int{0} +} +func (m *QueryConfigRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *QueryConfigRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_QueryConfigRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *QueryConfigRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryConfigRequest.Merge(m, src) +} +func (m *QueryConfigRequest) XXX_Size() int { + return m.Size() +} +func (m *QueryConfigRequest) XXX_DiscardUnknown() { + xxx_messageInfo_QueryConfigRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryConfigRequest proto.InternalMessageInfo + +// QueryConfigResponse returns the EVM config. +type QueryConfigResponse struct { + // config is the evm configuration + Config *ChainConfig `protobuf:"bytes,1,opt,name=config,proto3" json:"config,omitempty"` +} + +func (m *QueryConfigResponse) Reset() { *m = QueryConfigResponse{} } +func (m *QueryConfigResponse) String() string { return proto.CompactTextString(m) } +func (*QueryConfigResponse) ProtoMessage() {} +func (*QueryConfigResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_03991b98eceb9743, []int{1} +} +func (m *QueryConfigResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *QueryConfigResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_QueryConfigResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *QueryConfigResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryConfigResponse.Merge(m, src) +} +func (m *QueryConfigResponse) XXX_Size() int { + return m.Size() +} +func (m *QueryConfigResponse) XXX_DiscardUnknown() { + xxx_messageInfo_QueryConfigResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryConfigResponse proto.InternalMessageInfo + +func (m *QueryConfigResponse) GetConfig() *ChainConfig { + if m != nil { + return m.Config + } + return nil +} + // QueryAccountRequest is the request type for the Query/Account RPC method. type QueryAccountRequest struct { // address is the ethereum hex address to query the account for. @@ -47,7 +130,7 @@ func (m *QueryAccountRequest) Reset() { *m = QueryAccountRequest{} } func (m *QueryAccountRequest) String() string { return proto.CompactTextString(m) } func (*QueryAccountRequest) ProtoMessage() {} func (*QueryAccountRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{0} + return fileDescriptor_03991b98eceb9743, []int{2} } func (m *QueryAccountRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -90,7 +173,7 @@ func (m *QueryAccountResponse) Reset() { *m = QueryAccountResponse{} } func (m *QueryAccountResponse) String() string { return proto.CompactTextString(m) } func (*QueryAccountResponse) ProtoMessage() {} func (*QueryAccountResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{1} + return fileDescriptor_03991b98eceb9743, []int{3} } func (m *QueryAccountResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -151,7 +234,7 @@ func (m *QueryCosmosAccountRequest) Reset() { *m = QueryCosmosAccountReq func (m *QueryCosmosAccountRequest) String() string { return proto.CompactTextString(m) } func (*QueryCosmosAccountRequest) ProtoMessage() {} func (*QueryCosmosAccountRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{2} + return fileDescriptor_03991b98eceb9743, []int{4} } func (m *QueryCosmosAccountRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -195,7 +278,7 @@ func (m *QueryCosmosAccountResponse) Reset() { *m = QueryCosmosAccountRe func (m *QueryCosmosAccountResponse) String() string { return proto.CompactTextString(m) } func (*QueryCosmosAccountResponse) ProtoMessage() {} func (*QueryCosmosAccountResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{3} + return fileDescriptor_03991b98eceb9743, []int{5} } func (m *QueryCosmosAccountResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -256,7 +339,7 @@ func (m *QueryValidatorAccountRequest) Reset() { *m = QueryValidatorAcco func (m *QueryValidatorAccountRequest) String() string { return proto.CompactTextString(m) } func (*QueryValidatorAccountRequest) ProtoMessage() {} func (*QueryValidatorAccountRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{4} + return fileDescriptor_03991b98eceb9743, []int{6} } func (m *QueryValidatorAccountRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -300,7 +383,7 @@ func (m *QueryValidatorAccountResponse) Reset() { *m = QueryValidatorAcc func (m *QueryValidatorAccountResponse) String() string { return proto.CompactTextString(m) } func (*QueryValidatorAccountResponse) ProtoMessage() {} func (*QueryValidatorAccountResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{5} + return fileDescriptor_03991b98eceb9743, []int{7} } func (m *QueryValidatorAccountResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -360,7 +443,7 @@ func (m *QueryBalanceRequest) Reset() { *m = QueryBalanceRequest{} } func (m *QueryBalanceRequest) String() string { return proto.CompactTextString(m) } func (*QueryBalanceRequest) ProtoMessage() {} func (*QueryBalanceRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{6} + return fileDescriptor_03991b98eceb9743, []int{8} } func (m *QueryBalanceRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -399,7 +482,7 @@ func (m *QueryBalanceResponse) Reset() { *m = QueryBalanceResponse{} } func (m *QueryBalanceResponse) String() string { return proto.CompactTextString(m) } func (*QueryBalanceResponse) ProtoMessage() {} func (*QueryBalanceResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{7} + return fileDescriptor_03991b98eceb9743, []int{9} } func (m *QueryBalanceResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -447,7 +530,7 @@ func (m *QueryStorageRequest) Reset() { *m = QueryStorageRequest{} } func (m *QueryStorageRequest) String() string { return proto.CompactTextString(m) } func (*QueryStorageRequest) ProtoMessage() {} func (*QueryStorageRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{8} + return fileDescriptor_03991b98eceb9743, []int{10} } func (m *QueryStorageRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -487,7 +570,7 @@ func (m *QueryStorageResponse) Reset() { *m = QueryStorageResponse{} } func (m *QueryStorageResponse) String() string { return proto.CompactTextString(m) } func (*QueryStorageResponse) ProtoMessage() {} func (*QueryStorageResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{9} + return fileDescriptor_03991b98eceb9743, []int{11} } func (m *QueryStorageResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -533,7 +616,7 @@ func (m *QueryCodeRequest) Reset() { *m = QueryCodeRequest{} } func (m *QueryCodeRequest) String() string { return proto.CompactTextString(m) } func (*QueryCodeRequest) ProtoMessage() {} func (*QueryCodeRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{10} + return fileDescriptor_03991b98eceb9743, []int{12} } func (m *QueryCodeRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -573,7 +656,7 @@ func (m *QueryCodeResponse) Reset() { *m = QueryCodeResponse{} } func (m *QueryCodeResponse) String() string { return proto.CompactTextString(m) } func (*QueryCodeResponse) ProtoMessage() {} func (*QueryCodeResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{11} + return fileDescriptor_03991b98eceb9743, []int{13} } func (m *QueryCodeResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -621,7 +704,7 @@ func (m *QueryTxLogsRequest) Reset() { *m = QueryTxLogsRequest{} } func (m *QueryTxLogsRequest) String() string { return proto.CompactTextString(m) } func (*QueryTxLogsRequest) ProtoMessage() {} func (*QueryTxLogsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{12} + return fileDescriptor_03991b98eceb9743, []int{14} } func (m *QueryTxLogsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -662,7 +745,7 @@ func (m *QueryTxLogsResponse) Reset() { *m = QueryTxLogsResponse{} } func (m *QueryTxLogsResponse) String() string { return proto.CompactTextString(m) } func (*QueryTxLogsResponse) ProtoMessage() {} func (*QueryTxLogsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{13} + return fileDescriptor_03991b98eceb9743, []int{15} } func (m *QueryTxLogsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -713,7 +796,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{14} + return fileDescriptor_03991b98eceb9743, []int{16} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -752,7 +835,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{15} + return fileDescriptor_03991b98eceb9743, []int{17} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -804,7 +887,7 @@ func (m *EthCallRequest) Reset() { *m = EthCallRequest{} } func (m *EthCallRequest) String() string { return proto.CompactTextString(m) } func (*EthCallRequest) ProtoMessage() {} func (*EthCallRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{16} + return fileDescriptor_03991b98eceb9743, []int{18} } func (m *EthCallRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -865,13 +948,18 @@ func (m *EthCallRequest) GetChainId() int64 { type EstimateGasResponse struct { // gas returns the estimated gas Gas uint64 `protobuf:"varint,1,opt,name=gas,proto3" json:"gas,omitempty"` + // ret is the returned data from evm function (result or data supplied with + // revert opcode) + Ret []byte `protobuf:"bytes,2,opt,name=ret,proto3" json:"ret,omitempty"` + // vm_error is the error returned by vm execution + VmError string `protobuf:"bytes,3,opt,name=vm_error,json=vmError,proto3" json:"vm_error,omitempty"` } func (m *EstimateGasResponse) Reset() { *m = EstimateGasResponse{} } func (m *EstimateGasResponse) String() string { return proto.CompactTextString(m) } func (*EstimateGasResponse) ProtoMessage() {} func (*EstimateGasResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{17} + return fileDescriptor_03991b98eceb9743, []int{19} } func (m *EstimateGasResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -907,6 +995,20 @@ func (m *EstimateGasResponse) GetGas() uint64 { return 0 } +func (m *EstimateGasResponse) GetRet() []byte { + if m != nil { + return m.Ret + } + return nil +} + +func (m *EstimateGasResponse) GetVmError() string { + if m != nil { + return m.VmError + } + return "" +} + // QueryTraceTxRequest defines TraceTx request type QueryTraceTxRequest struct { // msg is the MsgEthereumTx for the requested transaction @@ -934,7 +1036,7 @@ func (m *QueryTraceTxRequest) Reset() { *m = QueryTraceTxRequest{} } func (m *QueryTraceTxRequest) String() string { return proto.CompactTextString(m) } func (*QueryTraceTxRequest) ProtoMessage() {} func (*QueryTraceTxRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{18} + return fileDescriptor_03991b98eceb9743, []int{20} } func (m *QueryTraceTxRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1036,7 +1138,7 @@ func (m *QueryTraceTxResponse) Reset() { *m = QueryTraceTxResponse{} } func (m *QueryTraceTxResponse) String() string { return proto.CompactTextString(m) } func (*QueryTraceTxResponse) ProtoMessage() {} func (*QueryTraceTxResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{19} + return fileDescriptor_03991b98eceb9743, []int{21} } func (m *QueryTraceTxResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1096,7 +1198,7 @@ func (m *QueryTraceBlockRequest) Reset() { *m = QueryTraceBlockRequest{} func (m *QueryTraceBlockRequest) String() string { return proto.CompactTextString(m) } func (*QueryTraceBlockRequest) ProtoMessage() {} func (*QueryTraceBlockRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{20} + return fileDescriptor_03991b98eceb9743, []int{22} } func (m *QueryTraceBlockRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1191,7 +1293,7 @@ func (m *QueryTraceBlockResponse) Reset() { *m = QueryTraceBlockResponse func (m *QueryTraceBlockResponse) String() string { return proto.CompactTextString(m) } func (*QueryTraceBlockResponse) ProtoMessage() {} func (*QueryTraceBlockResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{21} + return fileDescriptor_03991b98eceb9743, []int{23} } func (m *QueryTraceBlockResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1236,7 +1338,7 @@ func (m *QueryBaseFeeRequest) Reset() { *m = QueryBaseFeeRequest{} } func (m *QueryBaseFeeRequest) String() string { return proto.CompactTextString(m) } func (*QueryBaseFeeRequest) ProtoMessage() {} func (*QueryBaseFeeRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{22} + return fileDescriptor_03991b98eceb9743, []int{24} } func (m *QueryBaseFeeRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1275,7 +1377,7 @@ func (m *QueryBaseFeeResponse) Reset() { *m = QueryBaseFeeResponse{} } func (m *QueryBaseFeeResponse) String() string { return proto.CompactTextString(m) } func (*QueryBaseFeeResponse) ProtoMessage() {} func (*QueryBaseFeeResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_03991b98eceb9743, []int{23} + return fileDescriptor_03991b98eceb9743, []int{25} } func (m *QueryBaseFeeResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1304,7 +1406,86 @@ func (m *QueryBaseFeeResponse) XXX_DiscardUnknown() { var xxx_messageInfo_QueryBaseFeeResponse proto.InternalMessageInfo +// QueryGlobalMinGasPriceRequest defines the request type for querying the +// GlobalMinGasPrice +type QueryGlobalMinGasPriceRequest struct { +} + +func (m *QueryGlobalMinGasPriceRequest) Reset() { *m = QueryGlobalMinGasPriceRequest{} } +func (m *QueryGlobalMinGasPriceRequest) String() string { return proto.CompactTextString(m) } +func (*QueryGlobalMinGasPriceRequest) ProtoMessage() {} +func (*QueryGlobalMinGasPriceRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_03991b98eceb9743, []int{26} +} +func (m *QueryGlobalMinGasPriceRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *QueryGlobalMinGasPriceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_QueryGlobalMinGasPriceRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *QueryGlobalMinGasPriceRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryGlobalMinGasPriceRequest.Merge(m, src) +} +func (m *QueryGlobalMinGasPriceRequest) XXX_Size() int { + return m.Size() +} +func (m *QueryGlobalMinGasPriceRequest) XXX_DiscardUnknown() { + xxx_messageInfo_QueryGlobalMinGasPriceRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryGlobalMinGasPriceRequest proto.InternalMessageInfo + +// QueryGlobalMinGasPriceResponse returns the GlobalMinGasPrice +type QueryGlobalMinGasPriceResponse struct { + // min_gas_price is the feemarket's min_gas_price + MinGasPrice cosmossdk_io_math.Int `protobuf:"bytes,1,opt,name=min_gas_price,json=minGasPrice,proto3,customtype=cosmossdk.io/math.Int" json:"min_gas_price"` +} + +func (m *QueryGlobalMinGasPriceResponse) Reset() { *m = QueryGlobalMinGasPriceResponse{} } +func (m *QueryGlobalMinGasPriceResponse) String() string { return proto.CompactTextString(m) } +func (*QueryGlobalMinGasPriceResponse) ProtoMessage() {} +func (*QueryGlobalMinGasPriceResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_03991b98eceb9743, []int{27} +} +func (m *QueryGlobalMinGasPriceResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *QueryGlobalMinGasPriceResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_QueryGlobalMinGasPriceResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *QueryGlobalMinGasPriceResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryGlobalMinGasPriceResponse.Merge(m, src) +} +func (m *QueryGlobalMinGasPriceResponse) XXX_Size() int { + return m.Size() +} +func (m *QueryGlobalMinGasPriceResponse) XXX_DiscardUnknown() { + xxx_messageInfo_QueryGlobalMinGasPriceResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryGlobalMinGasPriceResponse proto.InternalMessageInfo + func init() { + proto.RegisterType((*QueryConfigRequest)(nil), "os.evm.v1.QueryConfigRequest") + proto.RegisterType((*QueryConfigResponse)(nil), "os.evm.v1.QueryConfigResponse") proto.RegisterType((*QueryAccountRequest)(nil), "os.evm.v1.QueryAccountRequest") proto.RegisterType((*QueryAccountResponse)(nil), "os.evm.v1.QueryAccountResponse") proto.RegisterType((*QueryCosmosAccountRequest)(nil), "os.evm.v1.QueryCosmosAccountRequest") @@ -1329,104 +1510,115 @@ func init() { proto.RegisterType((*QueryTraceBlockResponse)(nil), "os.evm.v1.QueryTraceBlockResponse") proto.RegisterType((*QueryBaseFeeRequest)(nil), "os.evm.v1.QueryBaseFeeRequest") proto.RegisterType((*QueryBaseFeeResponse)(nil), "os.evm.v1.QueryBaseFeeResponse") + proto.RegisterType((*QueryGlobalMinGasPriceRequest)(nil), "os.evm.v1.QueryGlobalMinGasPriceRequest") + proto.RegisterType((*QueryGlobalMinGasPriceResponse)(nil), "os.evm.v1.QueryGlobalMinGasPriceResponse") } func init() { proto.RegisterFile("os/evm/v1/query.proto", fileDescriptor_03991b98eceb9743) } var fileDescriptor_03991b98eceb9743 = []byte{ - // 1461 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0xcd, 0x6f, 0x1b, 0x45, - 0x14, 0xcf, 0xc6, 0x4e, 0xec, 0x3c, 0x27, 0x6d, 0x3a, 0x4d, 0x53, 0xc7, 0x4d, 0xec, 0x64, 0x45, - 0x6a, 0x2b, 0xa2, 0xbb, 0x4d, 0x40, 0x95, 0x8a, 0x90, 0x50, 0x1d, 0xf5, 0x8b, 0xb6, 0xa8, 0x98, - 0x88, 0x03, 0x12, 0xb2, 0xc6, 0xeb, 0xc9, 0xda, 0xc4, 0xbb, 0xe3, 0xee, 0x8c, 0x2d, 0x87, 0xaa, - 0x97, 0x1e, 0x10, 0x12, 0x1c, 0x2a, 0xf5, 0x8c, 0xd4, 0x23, 0xdc, 0xb8, 0xf1, 0x2f, 0xf4, 0x58, - 0x89, 0x0b, 0xe2, 0x50, 0x50, 0x8b, 0x04, 0x7f, 0x00, 0x27, 0x4e, 0x68, 0x3e, 0xd6, 0xde, 0xf5, - 0x47, 0x42, 0xf9, 0xb8, 0x71, 0xb1, 0x77, 0xde, 0xbc, 0x79, 0xbf, 0xdf, 0x9b, 0xf7, 0xe6, 0xbd, - 0x07, 0x67, 0x28, 0xb3, 0x49, 0xd7, 0xb3, 0xbb, 0xdb, 0xf6, 0xbd, 0x0e, 0x09, 0x0e, 0xad, 0x76, - 0x40, 0x39, 0x45, 0x73, 0x94, 0x59, 0xa4, 0xeb, 0x59, 0xdd, 0xed, 0xdc, 0x29, 0xec, 0x35, 0x7d, - 0x6a, 0xcb, 0x5f, 0xb5, 0x9b, 0xdb, 0x72, 0x28, 0xf3, 0x28, 0xb3, 0x6b, 0x98, 0x11, 0x75, 0xcc, - 0xee, 0x6e, 0xd7, 0x08, 0xc7, 0xdb, 0x76, 0x1b, 0xbb, 0x4d, 0x1f, 0xf3, 0x26, 0xf5, 0xb5, 0xee, - 0x92, 0x4b, 0x5d, 0x2a, 0x3f, 0x6d, 0xf1, 0xa5, 0xa5, 0xab, 0x2e, 0xa5, 0x6e, 0x8b, 0xd8, 0xb8, - 0xdd, 0xb4, 0xb1, 0xef, 0x53, 0x2e, 0x8f, 0x30, 0xbd, 0x5b, 0xd0, 0xbb, 0x72, 0x55, 0xeb, 0xec, - 0xdb, 0xbc, 0xe9, 0x11, 0xc6, 0xb1, 0xd7, 0xd6, 0x0a, 0xa7, 0x07, 0xac, 0x05, 0x4b, 0x25, 0x44, - 0x03, 0x21, 0xef, 0x29, 0x99, 0x79, 0x19, 0x4e, 0xbf, 0x2f, 0xf8, 0x5d, 0x71, 0x1c, 0xda, 0xf1, - 0x79, 0x85, 0xdc, 0xeb, 0x10, 0xc6, 0x51, 0x16, 0x52, 0xb8, 0x5e, 0x0f, 0x08, 0x63, 0x59, 0x63, - 0xdd, 0x28, 0xcd, 0x55, 0xc2, 0xe5, 0x5b, 0xe9, 0xcf, 0x9f, 0x14, 0xa6, 0x7e, 0x7b, 0x52, 0x98, - 0x32, 0x1d, 0x58, 0x8a, 0x1f, 0x65, 0x6d, 0xea, 0x33, 0x22, 0xce, 0xd6, 0x70, 0x0b, 0xfb, 0x0e, - 0x09, 0xcf, 0xea, 0x25, 0x3a, 0x07, 0x73, 0x0e, 0xad, 0x93, 0x6a, 0x03, 0xb3, 0x46, 0x76, 0x5a, - 0xee, 0xa5, 0x85, 0xe0, 0x06, 0x66, 0x0d, 0xb4, 0x04, 0x33, 0x3e, 0x15, 0x87, 0x12, 0xeb, 0x46, - 0x29, 0x59, 0x51, 0x0b, 0xf3, 0x1d, 0x58, 0x91, 0x20, 0xbb, 0xf2, 0x42, 0xff, 0x06, 0xcb, 0xcf, - 0x0c, 0xc8, 0x8d, 0xb3, 0xa0, 0xc9, 0x6e, 0xc2, 0x09, 0x15, 0xab, 0x6a, 0xdc, 0xd2, 0x82, 0x92, - 0x5e, 0x51, 0x42, 0x94, 0x83, 0x34, 0x13, 0xa0, 0x82, 0xdf, 0xb4, 0xe4, 0xd7, 0x5f, 0x0b, 0x13, - 0x58, 0x59, 0xad, 0xfa, 0x1d, 0xaf, 0x46, 0x02, 0xed, 0xc1, 0x82, 0x96, 0xbe, 0x27, 0x85, 0xe6, - 0x2d, 0x58, 0x95, 0x3c, 0x3e, 0xc4, 0xad, 0x66, 0x1d, 0x73, 0x1a, 0x0c, 0x39, 0xb3, 0x01, 0xf3, - 0x0e, 0xf5, 0x87, 0x79, 0x64, 0x84, 0xec, 0xca, 0x88, 0x57, 0x5f, 0x18, 0xb0, 0x36, 0xc1, 0x9a, - 0x76, 0xac, 0x08, 0x27, 0x43, 0x56, 0x71, 0x8b, 0x21, 0xd9, 0x7f, 0xd1, 0xb5, 0x30, 0x89, 0xca, - 0x2a, 0xce, 0xaf, 0x12, 0x9e, 0x8b, 0x3a, 0x89, 0xfa, 0x47, 0x8f, 0x4b, 0x22, 0xf3, 0x96, 0x06, - 0xfb, 0x80, 0xd3, 0x00, 0xbb, 0xc7, 0x83, 0xa1, 0x45, 0x48, 0x1c, 0x90, 0x43, 0x9d, 0x6f, 0xe2, - 0x33, 0x02, 0xff, 0xba, 0x86, 0xef, 0x1b, 0xd3, 0xf0, 0x4b, 0x30, 0xd3, 0xc5, 0xad, 0x4e, 0x08, - 0xae, 0x16, 0xe6, 0x25, 0x58, 0xd4, 0xa9, 0x54, 0x7f, 0x25, 0x27, 0x8b, 0x70, 0x2a, 0x72, 0x4e, - 0x43, 0x20, 0x48, 0x8a, 0xdc, 0x97, 0xa7, 0xe6, 0x2b, 0xf2, 0xdb, 0xfc, 0x14, 0x90, 0x54, 0xdc, - 0xeb, 0xdd, 0xa6, 0x2e, 0x0b, 0x21, 0x10, 0x24, 0xe5, 0x8b, 0x51, 0xf6, 0xe5, 0x37, 0xba, 0x06, - 0x30, 0xa8, 0x24, 0xd2, 0xb7, 0xcc, 0xce, 0x79, 0x4b, 0x25, 0xad, 0x25, 0xca, 0x8e, 0xa5, 0xaa, - 0x95, 0x2e, 0x3b, 0xd6, 0xdd, 0xc1, 0x55, 0x55, 0x22, 0x27, 0x23, 0x24, 0x1f, 0x1a, 0xfa, 0x62, - 0x43, 0x70, 0xcd, 0xd3, 0x84, 0x64, 0x8b, 0xba, 0xc2, 0xbb, 0x44, 0x29, 0xb3, 0x73, 0xc2, 0xea, - 0x17, 0x3e, 0xeb, 0x36, 0x75, 0x2b, 0x72, 0x0f, 0x5d, 0x1f, 0xc3, 0xa6, 0x78, 0x2c, 0x1b, 0x05, - 0x10, 0xa5, 0x63, 0x2e, 0xe9, 0x0b, 0xb8, 0x8b, 0x03, 0xec, 0x85, 0x17, 0xd0, 0x0f, 0x79, 0x28, - 0xd5, 0xcc, 0xde, 0x84, 0xd9, 0xb6, 0x94, 0xc8, 0x9b, 0xc9, 0xec, 0x9c, 0x8a, 0x70, 0x53, 0xaa, - 0xe5, 0xb9, 0xa7, 0xcf, 0x0b, 0x53, 0x5f, 0xff, 0xfa, 0xed, 0x96, 0x51, 0xd1, 0xba, 0xe6, 0x77, - 0x06, 0x9c, 0xb8, 0xca, 0x1b, 0xbb, 0xb8, 0xd5, 0x8a, 0x5c, 0x30, 0x0e, 0x5c, 0x16, 0x86, 0x42, - 0x7c, 0xa3, 0xb3, 0x90, 0x72, 0x31, 0xab, 0x3a, 0xb8, 0xad, 0x5f, 0xc5, 0xac, 0x8b, 0xd9, 0x2e, - 0x6e, 0xa3, 0x8f, 0x61, 0xb1, 0x1d, 0xd0, 0x36, 0x65, 0x24, 0xe8, 0xbf, 0x2c, 0xf1, 0x2a, 0xe6, - 0xcb, 0x3b, 0x7f, 0x3c, 0x2f, 0x58, 0x6e, 0x93, 0x37, 0x3a, 0x35, 0xcb, 0xa1, 0x9e, 0xad, 0x9b, - 0x80, 0xfa, 0xbb, 0xc0, 0xea, 0x07, 0x36, 0x3f, 0x6c, 0x13, 0x66, 0xed, 0x0e, 0x9e, 0x74, 0xe5, - 0x64, 0x68, 0x2b, 0x7c, 0x8e, 0x2b, 0x90, 0x76, 0x1a, 0xb8, 0xe9, 0x57, 0x9b, 0xf5, 0x6c, 0x72, - 0xdd, 0x28, 0x25, 0x2a, 0x29, 0xb9, 0xbe, 0x59, 0x37, 0x8b, 0x70, 0xfa, 0x2a, 0xe3, 0x4d, 0x0f, - 0x73, 0x72, 0x1d, 0x0f, 0xae, 0x61, 0x11, 0x12, 0x2e, 0x56, 0xe4, 0x93, 0x15, 0xf1, 0x69, 0xfe, - 0x9e, 0x08, 0x43, 0x19, 0x60, 0x87, 0xec, 0xf5, 0x42, 0x3f, 0xb7, 0x20, 0xe1, 0x31, 0x57, 0xdf, - 0x56, 0x36, 0x72, 0x5b, 0x77, 0x98, 0x7b, 0x95, 0x37, 0x48, 0x40, 0x3a, 0xde, 0x5e, 0xaf, 0x22, - 0x94, 0xd0, 0x65, 0x98, 0xe7, 0xe2, 0x74, 0xd5, 0xa1, 0xfe, 0x7e, 0xd3, 0x95, 0x2e, 0x66, 0x76, - 0x96, 0x23, 0x87, 0xa4, 0xf1, 0x5d, 0xb9, 0x5b, 0xc9, 0xf0, 0xc1, 0x02, 0xbd, 0x0d, 0xf3, 0xed, - 0x80, 0xd4, 0x89, 0x43, 0x18, 0xa3, 0x01, 0xcb, 0x26, 0x65, 0xe6, 0x4c, 0xc6, 0x8b, 0x69, 0x8b, - 0x3a, 0x58, 0x6b, 0x51, 0xe7, 0x20, 0xac, 0x38, 0x33, 0xf2, 0x12, 0x32, 0x52, 0xa6, 0xea, 0x0d, - 0x5a, 0x03, 0x50, 0x2a, 0xf2, 0x59, 0xcc, 0xca, 0x67, 0x31, 0x27, 0x25, 0xb2, 0x93, 0xdc, 0x08, - 0xb7, 0x45, 0x57, 0xcc, 0xa6, 0x24, 0xf1, 0x9c, 0xa5, 0x5a, 0xa6, 0x15, 0xb6, 0x4c, 0x6b, 0x2f, - 0x6c, 0x99, 0xe5, 0x05, 0x91, 0x24, 0x8f, 0x7e, 0x2a, 0x18, 0x2a, 0x51, 0x94, 0x25, 0xb1, 0x3d, - 0x36, 0xd6, 0xe9, 0xff, 0x26, 0xd6, 0x73, 0xb1, 0x58, 0x23, 0x13, 0x16, 0x94, 0x0f, 0x1e, 0xee, - 0x55, 0x45, 0x78, 0x21, 0x72, 0x0d, 0x77, 0x70, 0xef, 0x3a, 0x66, 0xef, 0x26, 0xd3, 0xd3, 0x8b, - 0x89, 0x4a, 0x9a, 0xf7, 0xaa, 0x4d, 0xbf, 0x4e, 0x7a, 0xe6, 0x96, 0x2e, 0x66, 0xfd, 0xa8, 0x0f, - 0x2a, 0x4d, 0x1d, 0x73, 0x1c, 0xa6, 0xb7, 0xf8, 0x36, 0xbf, 0x49, 0xc0, 0xf2, 0x40, 0xb9, 0x2c, - 0xac, 0x46, 0xb2, 0x84, 0xf7, 0xc2, 0xf7, 0x7e, 0x44, 0x96, 0xf0, 0x1e, 0xfb, 0x27, 0x59, 0xf2, - 0x7f, 0x9c, 0xff, 0x62, 0x9c, 0xcd, 0x0b, 0x70, 0x76, 0x24, 0x54, 0x47, 0x84, 0xf6, 0x4c, 0xbf, - 0x1b, 0x33, 0x72, 0x8d, 0x84, 0x55, 0xdf, 0xbc, 0xdd, 0xef, 0xb4, 0x5a, 0xdc, 0xaf, 0xa2, 0x69, - 0x51, 0xa1, 0xab, 0xfb, 0x44, 0x77, 0xbb, 0xf2, 0xca, 0x8f, 0xcf, 0x0b, 0x67, 0x94, 0x87, 0xac, - 0x7e, 0x60, 0x35, 0xa9, 0xed, 0x61, 0xde, 0xb0, 0x6e, 0xfa, 0x5c, 0x74, 0x61, 0x79, 0x7a, 0xe7, - 0x71, 0x06, 0x66, 0xa4, 0x39, 0xc4, 0x20, 0xa5, 0x67, 0x0f, 0x94, 0x8f, 0xc4, 0x7d, 0xcc, 0x54, - 0x99, 0x2b, 0x4c, 0xdc, 0x57, 0x5c, 0xcc, 0xe2, 0xc3, 0xef, 0x7f, 0x79, 0x3c, 0xbd, 0x81, 0x0a, - 0x62, 0x4e, 0x1d, 0x4c, 0xab, 0x7a, 0xda, 0xb0, 0xef, 0xeb, 0xd8, 0x3c, 0x40, 0x5f, 0x1a, 0xb0, - 0x10, 0x1b, 0xe8, 0xd0, 0x6b, 0xc3, 0xb6, 0xc7, 0x4d, 0x8c, 0xb9, 0xcd, 0x63, 0xb4, 0x34, 0x0f, - 0x4b, 0xf2, 0x28, 0xa1, 0xf3, 0x71, 0x1e, 0xe1, 0xa4, 0x38, 0x42, 0xe7, 0x2b, 0x03, 0x16, 0x87, - 0x27, 0x31, 0x54, 0x1c, 0xc6, 0x9a, 0x30, 0xf9, 0xe5, 0x4a, 0xc7, 0x2b, 0x6a, 0x5e, 0x97, 0x24, - 0xaf, 0x8b, 0xc8, 0x8a, 0xf3, 0xea, 0x86, 0xfa, 0x03, 0x6a, 0xd1, 0x51, 0xf2, 0x01, 0xe2, 0x90, - 0xd2, 0x03, 0xd6, 0x68, 0x8c, 0xe2, 0x43, 0xdb, 0x68, 0x8c, 0x86, 0x26, 0x33, 0xb3, 0x24, 0x39, - 0x98, 0x68, 0x3d, 0xce, 0x41, 0x8f, 0x67, 0x2c, 0x72, 0x2b, 0x87, 0x90, 0xd2, 0x73, 0xd5, 0x28, - 0x6a, 0x7c, 0x7a, 0x1b, 0x45, 0x1d, 0x1a, 0xc8, 0xcc, 0x0b, 0x12, 0xb5, 0x88, 0x36, 0xe3, 0xa8, - 0x4c, 0xa9, 0x0d, 0x40, 0xed, 0xfb, 0x07, 0xe4, 0xf0, 0x01, 0x6a, 0x40, 0x52, 0x0c, 0x5b, 0xe8, - 0xdc, 0x68, 0xbc, 0xfb, 0xa3, 0x5b, 0x6e, 0x75, 0xfc, 0xa6, 0x46, 0xdc, 0x94, 0x88, 0x05, 0xb4, - 0x36, 0x9c, 0x03, 0xf5, 0x98, 0x93, 0x04, 0x66, 0xd5, 0xac, 0x81, 0xd6, 0x86, 0xcd, 0xc5, 0x86, - 0x98, 0x5c, 0x7e, 0xd2, 0xb6, 0xc6, 0x5b, 0x95, 0x78, 0xcb, 0x68, 0x29, 0x8e, 0xa7, 0xa6, 0x16, - 0xb4, 0x0f, 0x29, 0x3d, 0xb4, 0xa0, 0x95, 0x88, 0xa1, 0xf8, 0x20, 0x93, 0x5b, 0x9f, 0x58, 0xad, - 0x43, 0x94, 0xbc, 0x44, 0xc9, 0xa2, 0xe5, 0x38, 0x0a, 0xe1, 0x8d, 0xaa, 0x23, 0x8c, 0xb7, 0x20, - 0x13, 0x99, 0x31, 0x8e, 0xc2, 0x8a, 0xfa, 0x33, 0x66, 0x2c, 0x31, 0x4d, 0x89, 0xb4, 0x8a, 0x72, - 0x43, 0x48, 0x5a, 0x55, 0x14, 0x3b, 0xf4, 0x09, 0xa4, 0x74, 0xb3, 0x1a, 0xcd, 0x90, 0xf8, 0xec, - 0x32, 0x9a, 0x21, 0x43, 0x5d, 0x6e, 0x92, 0x67, 0xaa, 0x3d, 0xf1, 0x1e, 0xea, 0x02, 0x0c, 0x0a, - 0x28, 0xda, 0x18, 0x6b, 0x2e, 0xda, 0x07, 0x73, 0xe6, 0x51, 0x2a, 0x1a, 0x74, 0x43, 0x82, 0x9e, - 0x43, 0x2b, 0xe3, 0x40, 0x65, 0x0d, 0x17, 0x3e, 0xea, 0x92, 0x3b, 0xee, 0xed, 0x45, 0x4b, 0xf4, - 0xb8, 0xb7, 0x17, 0xab, 0xd5, 0x93, 0x7c, 0x0c, 0xeb, 0x77, 0xf9, 0xf2, 0xd3, 0x17, 0x79, 0xe3, - 0xd9, 0x8b, 0xbc, 0xf1, 0xf3, 0x8b, 0xbc, 0xf1, 0xe8, 0x65, 0x7e, 0xea, 0xd9, 0xcb, 0xfc, 0xd4, - 0x0f, 0x2f, 0xf3, 0x53, 0x1f, 0x15, 0x22, 0x3d, 0x4c, 0x9d, 0xa5, 0xcc, 0xee, 0x49, 0x03, 0xb2, - 0x81, 0xd5, 0x66, 0x65, 0xc3, 0x7c, 0xe3, 0xcf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x54, 0xb4, 0xfd, - 0x17, 0xf0, 0x10, 0x00, 0x00, + // 1614 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x58, 0xcf, 0x6f, 0x1b, 0xc5, + 0x17, 0xcf, 0xc6, 0x4e, 0xec, 0x3c, 0x27, 0x6d, 0x32, 0x4d, 0x53, 0xc7, 0x49, 0xec, 0x64, 0xbf, + 0xdf, 0x34, 0xf9, 0x46, 0xdf, 0xee, 0x36, 0x01, 0x55, 0x2a, 0x42, 0x42, 0x49, 0x94, 0xa6, 0xa5, + 0x2d, 0x2a, 0x26, 0xe2, 0x80, 0x84, 0xac, 0xf1, 0x7a, 0xb2, 0x5e, 0xe2, 0xdd, 0x71, 0x77, 0xd6, + 0x96, 0x43, 0xd5, 0x4b, 0x0f, 0x08, 0xf1, 0x43, 0xaa, 0xc4, 0x19, 0xa9, 0x47, 0xb8, 0x71, 0xe3, + 0x5f, 0xe8, 0xb1, 0x12, 0x17, 0xc4, 0xa1, 0xa0, 0x16, 0x09, 0xfe, 0x00, 0x4e, 0x9c, 0xd0, 0xfc, + 0x58, 0x7b, 0xd7, 0x6b, 0x27, 0x2d, 0x3f, 0x6e, 0x5c, 0x92, 0x9d, 0x99, 0x37, 0xef, 0xf3, 0x79, + 0x33, 0x6f, 0xde, 0xfb, 0xc8, 0x70, 0x9e, 0x32, 0x93, 0xb4, 0x5d, 0xb3, 0xbd, 0x69, 0xde, 0x6d, + 0x11, 0xff, 0xd8, 0x68, 0xfa, 0x34, 0xa0, 0x68, 0x82, 0x32, 0x83, 0xb4, 0x5d, 0xa3, 0xbd, 0x59, + 0x98, 0xc1, 0xae, 0xe3, 0x51, 0x53, 0xfc, 0x95, 0xab, 0x85, 0x0d, 0x8b, 0x32, 0x97, 0x32, 0xb3, + 0x8a, 0x19, 0x91, 0xdb, 0xcc, 0xf6, 0x66, 0x95, 0x04, 0x78, 0xd3, 0x6c, 0x62, 0xdb, 0xf1, 0x70, + 0xe0, 0x50, 0x4f, 0xd9, 0xce, 0xda, 0xd4, 0xa6, 0xe2, 0xd3, 0xe4, 0x5f, 0x6a, 0x76, 0xd1, 0xa6, + 0xd4, 0x6e, 0x10, 0x13, 0x37, 0x1d, 0x13, 0x7b, 0x1e, 0x0d, 0xc4, 0x16, 0xa6, 0x56, 0x4b, 0x6a, + 0x55, 0x8c, 0xaa, 0xad, 0x43, 0x33, 0x70, 0x5c, 0xc2, 0x02, 0xec, 0x36, 0x95, 0xc1, 0xb9, 0x1e, + 0x6b, 0xce, 0x52, 0x4e, 0xa2, 0xde, 0x64, 0xd0, 0x91, 0x73, 0xfa, 0x2c, 0xa0, 0xb7, 0x39, 0xbf, + 0x5d, 0xea, 0x1d, 0x3a, 0x76, 0x99, 0xdc, 0x6d, 0x11, 0x16, 0xe8, 0x7b, 0x70, 0x2e, 0x36, 0xcb, + 0x9a, 0xd4, 0x63, 0x04, 0x19, 0x30, 0x6e, 0x89, 0x99, 0xbc, 0xb6, 0xac, 0xad, 0xe7, 0xb6, 0xe6, + 0x8c, 0xee, 0x29, 0x18, 0xbb, 0x75, 0xec, 0x78, 0xca, 0x5e, 0x59, 0xe9, 0x57, 0x95, 0x9b, 0x6d, + 0xcb, 0xa2, 0x2d, 0x2f, 0x50, 0xde, 0x51, 0x1e, 0x32, 0xb8, 0x56, 0xf3, 0x09, 0x63, 0xc2, 0xcf, + 0x44, 0x39, 0x1c, 0xbe, 0x96, 0xfd, 0xf8, 0x51, 0x69, 0xe4, 0xd7, 0x47, 0xa5, 0x11, 0xdd, 0x82, + 0xd9, 0xf8, 0x56, 0x45, 0x21, 0x0f, 0x99, 0x2a, 0x6e, 0x60, 0xcf, 0x22, 0xe1, 0x5e, 0x35, 0x44, + 0x0b, 0x30, 0x61, 0xd1, 0x1a, 0xa9, 0xd4, 0x31, 0xab, 0xe7, 0x47, 0xc5, 0x5a, 0x96, 0x4f, 0x5c, + 0xc7, 0xac, 0x8e, 0x66, 0x61, 0xcc, 0xa3, 0x7c, 0x53, 0x6a, 0x59, 0x5b, 0x4f, 0x97, 0xe5, 0x40, + 0x7f, 0x03, 0xe6, 0x55, 0x98, 0xfc, 0xb6, 0xfe, 0x04, 0xcb, 0x8f, 0x34, 0x28, 0x0c, 0xf2, 0xa0, + 0xc8, 0xae, 0xc2, 0x19, 0x99, 0x08, 0x95, 0xb8, 0xa7, 0x29, 0x39, 0xbb, 0x2d, 0x27, 0x51, 0x01, + 0xb2, 0x8c, 0x83, 0x72, 0x7e, 0xa3, 0x82, 0x5f, 0x77, 0xcc, 0x5d, 0x60, 0xe9, 0xb5, 0xe2, 0xb5, + 0xdc, 0x2a, 0xf1, 0x55, 0x04, 0x53, 0x6a, 0xf6, 0x2d, 0x31, 0xa9, 0xdf, 0x84, 0x45, 0xc1, 0xe3, + 0x5d, 0xdc, 0x70, 0x6a, 0x38, 0xa0, 0x7e, 0x5f, 0x30, 0x2b, 0x30, 0x69, 0x51, 0xaf, 0x9f, 0x47, + 0x8e, 0xcf, 0x6d, 0x27, 0xa2, 0xfa, 0x54, 0x83, 0xa5, 0x21, 0xde, 0x54, 0x60, 0x6b, 0x70, 0x36, + 0x64, 0x15, 0xf7, 0x18, 0x92, 0xfd, 0x1b, 0x43, 0x0b, 0x93, 0x68, 0x47, 0xde, 0xf3, 0xcb, 0x5c, + 0xcf, 0x65, 0x95, 0x44, 0xdd, 0xad, 0xa7, 0x25, 0x91, 0x7e, 0x53, 0x81, 0xbd, 0x13, 0x50, 0x1f, + 0xdb, 0xa7, 0x83, 0xa1, 0x69, 0x48, 0x1d, 0x91, 0x63, 0x95, 0x6f, 0xfc, 0x33, 0x02, 0xff, 0x7f, + 0x05, 0xdf, 0x75, 0xa6, 0xe0, 0x67, 0x61, 0xac, 0x8d, 0x1b, 0xad, 0x10, 0x5c, 0x0e, 0xf4, 0x2b, + 0x30, 0xad, 0x52, 0xa9, 0xf6, 0x52, 0x41, 0xae, 0xc1, 0x4c, 0x64, 0x9f, 0x82, 0x40, 0x90, 0xe6, + 0xb9, 0x2f, 0x76, 0x4d, 0x96, 0xc5, 0xb7, 0xfe, 0xa1, 0x7a, 0xea, 0x07, 0x9d, 0x5b, 0xd4, 0x66, + 0x21, 0x04, 0x82, 0xb4, 0x78, 0x31, 0xd2, 0xbf, 0xf8, 0x46, 0xd7, 0x00, 0x7a, 0x65, 0x4a, 0xc4, + 0x96, 0xdb, 0xba, 0x68, 0xc8, 0xa4, 0x35, 0x78, 0x4d, 0x33, 0x64, 0x29, 0x54, 0x35, 0xcd, 0xb8, + 0xd3, 0x3b, 0xaa, 0x72, 0x64, 0x67, 0x84, 0xe4, 0x03, 0x4d, 0x1d, 0x6c, 0x08, 0xae, 0x78, 0xea, + 0x90, 0x6e, 0x50, 0x9b, 0x47, 0x97, 0x5a, 0xcf, 0x6d, 0x9d, 0x89, 0xd4, 0x93, 0x5b, 0xd4, 0x2e, + 0x8b, 0x35, 0xb4, 0x3f, 0x80, 0xcd, 0xda, 0xa9, 0x6c, 0x24, 0x40, 0x94, 0x4e, 0xb7, 0xd6, 0xdd, + 0xc1, 0x3e, 0x76, 0xc3, 0x03, 0xe8, 0x5e, 0x79, 0x38, 0xab, 0x98, 0xbd, 0x0a, 0xe3, 0x4d, 0x31, + 0xa3, 0x6a, 0xdd, 0x4c, 0x84, 0x9b, 0x34, 0xdd, 0x99, 0x78, 0xfc, 0xb4, 0x34, 0xf2, 0xd5, 0x2f, + 0xdf, 0x6c, 0x68, 0x65, 0x65, 0xab, 0x7f, 0xab, 0xc1, 0x99, 0xbd, 0xa0, 0xbe, 0x8b, 0x1b, 0x8d, + 0xc8, 0x01, 0x63, 0xdf, 0x66, 0xe1, 0x55, 0xf0, 0x6f, 0x74, 0x01, 0x32, 0x36, 0x66, 0x15, 0x0b, + 0x37, 0xd5, 0xab, 0x18, 0xb7, 0x31, 0xdb, 0xc5, 0x4d, 0xf4, 0x3e, 0x4c, 0x37, 0x7d, 0xda, 0xa4, + 0x8c, 0xf8, 0xdd, 0x97, 0xc5, 0x5f, 0xc5, 0xe4, 0xce, 0xd6, 0xef, 0x4f, 0x4b, 0x86, 0xed, 0x04, + 0xf5, 0x56, 0xd5, 0xb0, 0xa8, 0x6b, 0xaa, 0x0e, 0x23, 0xff, 0x5d, 0x62, 0xb5, 0x23, 0x33, 0x38, + 0x6e, 0x12, 0x66, 0xec, 0xf6, 0x9e, 0x74, 0xf9, 0x6c, 0xe8, 0x2b, 0x7c, 0x8e, 0xf3, 0x90, 0xb5, + 0x78, 0x9d, 0xae, 0x38, 0xb5, 0x7c, 0x7a, 0x59, 0x5b, 0x4f, 0x95, 0x33, 0x62, 0x7c, 0xa3, 0xa6, + 0x1f, 0xc0, 0xb9, 0x3d, 0x16, 0x38, 0x2e, 0x0e, 0xc8, 0x3e, 0xee, 0x1d, 0xc3, 0x34, 0xa4, 0x6c, + 0x2c, 0xc9, 0xa7, 0xcb, 0xfc, 0x93, 0xcf, 0xf8, 0x24, 0x10, 0xbc, 0x27, 0xcb, 0xfc, 0x93, 0x7b, + 0x6d, 0xbb, 0x15, 0xe2, 0xfb, 0x54, 0x3e, 0xe1, 0x89, 0x72, 0xa6, 0xed, 0xee, 0xf1, 0xa1, 0xfe, + 0x5b, 0x2a, 0xbc, 0x77, 0x1f, 0x5b, 0xe4, 0xa0, 0x13, 0x1e, 0xca, 0x06, 0xa4, 0x5c, 0x16, 0xb6, + 0x91, 0x7c, 0xe4, 0x68, 0x6f, 0x33, 0x7b, 0x2f, 0xa8, 0x13, 0x9f, 0xb4, 0xdc, 0x83, 0x4e, 0x99, + 0x1b, 0xa1, 0xab, 0x30, 0x19, 0xf0, 0xdd, 0x15, 0xd5, 0x7b, 0x52, 0x89, 0xde, 0x23, 0x9c, 0xab, + 0xde, 0x93, 0x0b, 0x7a, 0x03, 0xf4, 0x3a, 0x4c, 0x36, 0x7d, 0x52, 0x23, 0x16, 0x61, 0x8c, 0xfa, + 0x2c, 0x9f, 0x16, 0x69, 0x36, 0x1c, 0x2f, 0x66, 0xcd, 0x8b, 0x66, 0xb5, 0x41, 0xad, 0xa3, 0xb0, + 0x3c, 0x8d, 0x89, 0x13, 0xcb, 0x89, 0x39, 0x59, 0x9c, 0xd0, 0x12, 0x80, 0x34, 0x11, 0x6f, 0x68, + 0x5c, 0x04, 0x3f, 0x21, 0x66, 0x44, 0xdb, 0xb9, 0x1e, 0x2e, 0xf3, 0xfe, 0x9c, 0xcf, 0x08, 0xe2, + 0x05, 0x43, 0x36, 0x6f, 0x23, 0x6c, 0xde, 0xc6, 0x41, 0xd8, 0xbc, 0x77, 0xa6, 0x78, 0x46, 0x3d, + 0xfc, 0xb1, 0xa4, 0xc9, 0xac, 0x92, 0x9e, 0xf8, 0xf2, 0xc0, 0xc4, 0xc8, 0xfe, 0x33, 0x89, 0x31, + 0x11, 0x4b, 0x0c, 0xa4, 0xc3, 0x94, 0x8c, 0xc1, 0xc5, 0x9d, 0x0a, 0xcf, 0x05, 0x88, 0x1c, 0xc3, + 0x6d, 0xdc, 0xd9, 0xc7, 0xec, 0xcd, 0x74, 0x76, 0x74, 0x3a, 0x55, 0xce, 0x06, 0x9d, 0x8a, 0xe3, + 0xd5, 0x48, 0x47, 0xdf, 0x50, 0x95, 0xaf, 0x7b, 0xeb, 0xbd, 0xb2, 0x54, 0xc3, 0x01, 0x0e, 0xdf, + 0x02, 0xff, 0xd6, 0xbf, 0x4e, 0xc1, 0x5c, 0xcf, 0x78, 0x87, 0x7b, 0x8d, 0x64, 0x49, 0xd0, 0x09, + 0x8b, 0xc3, 0x09, 0x59, 0x12, 0x74, 0xd8, 0x5f, 0xc9, 0x92, 0x7f, 0xef, 0xf9, 0x05, 0xef, 0x59, + 0xbf, 0x04, 0x17, 0x12, 0x57, 0x75, 0xc2, 0xd5, 0x9e, 0xef, 0xb6, 0x6e, 0x46, 0xae, 0x91, 0xb0, + 0x45, 0xe8, 0xb7, 0xba, 0x6d, 0x59, 0x4d, 0x77, 0x4b, 0x6e, 0x96, 0x97, 0xf3, 0xca, 0x21, 0x51, + 0xad, 0x71, 0x67, 0xfe, 0x87, 0xa7, 0xa5, 0xf3, 0x32, 0x42, 0x56, 0x3b, 0x32, 0x1c, 0x6a, 0xba, + 0x38, 0xa8, 0x1b, 0x37, 0xbc, 0x80, 0xb7, 0x6c, 0xb1, 0x5b, 0x2f, 0x29, 0xb1, 0xb2, 0xdf, 0xa0, + 0x55, 0xdc, 0xb8, 0xed, 0x78, 0xfb, 0x98, 0xdd, 0xf1, 0x9d, 0xae, 0x52, 0xd0, 0x2d, 0x28, 0x0e, + 0x33, 0x50, 0xc0, 0xdb, 0x30, 0xe5, 0x3a, 0x1e, 0x0f, 0xba, 0xd2, 0xe4, 0x0b, 0x0a, 0x7d, 0x89, + 0xdf, 0xd2, 0x70, 0x06, 0x39, 0xb7, 0xe7, 0x6a, 0xeb, 0x93, 0x29, 0x18, 0x13, 0x28, 0x88, 0x41, + 0x46, 0xc9, 0x25, 0x54, 0x8c, 0x64, 0xdf, 0x00, 0x21, 0x5c, 0x28, 0x0d, 0x5d, 0x97, 0xc4, 0xf4, + 0xb5, 0x07, 0xdf, 0xfd, 0xfc, 0xc5, 0xe8, 0x0a, 0x2a, 0x71, 0xdd, 0xde, 0x53, 0xef, 0x4a, 0x20, + 0x99, 0xf7, 0x54, 0x86, 0xdc, 0x47, 0x9f, 0x69, 0x30, 0x15, 0xd3, 0xa0, 0xe8, 0xbf, 0xfd, 0xbe, + 0x07, 0x89, 0xdc, 0xc2, 0xea, 0x29, 0x56, 0x8a, 0x87, 0x21, 0x78, 0xac, 0xa3, 0x8b, 0x71, 0x1e, + 0xa1, 0xb8, 0x4d, 0xd0, 0xf9, 0x52, 0x83, 0xe9, 0x7e, 0xf1, 0x88, 0xd6, 0xfa, 0xb1, 0x86, 0x88, + 0xd5, 0xc2, 0xfa, 0xe9, 0x86, 0x8a, 0xd7, 0x15, 0xc1, 0xeb, 0x32, 0x32, 0xe2, 0xbc, 0xda, 0xa1, + 0x7d, 0x8f, 0x5a, 0x54, 0xfd, 0xde, 0x47, 0x01, 0x64, 0x94, 0x26, 0x4c, 0xde, 0x51, 0x5c, 0x67, + 0x26, 0xef, 0xa8, 0x4f, 0x4c, 0xea, 0xeb, 0x82, 0x83, 0x8e, 0x96, 0xe3, 0x1c, 0x94, 0xa2, 0x64, + 0x91, 0x53, 0x39, 0x86, 0x8c, 0x92, 0x82, 0x49, 0xd4, 0xb8, 0xe0, 0x4c, 0xa2, 0xf6, 0x69, 0x48, + 0xfd, 0x92, 0x40, 0x5d, 0x43, 0xab, 0x71, 0x54, 0x26, 0xcd, 0x7a, 0xa0, 0xe6, 0xbd, 0x23, 0x72, + 0x7c, 0x1f, 0xd5, 0x21, 0xcd, 0xf5, 0x21, 0x5a, 0x48, 0xde, 0x77, 0x57, 0x6d, 0x16, 0x16, 0x07, + 0x2f, 0x2a, 0xc4, 0x55, 0x81, 0x58, 0x42, 0x4b, 0xfd, 0x39, 0x50, 0x8b, 0x05, 0x49, 0x60, 0x5c, + 0xca, 0x23, 0xb4, 0xd4, 0xef, 0x2e, 0xa6, 0xbb, 0x0a, 0xc5, 0x61, 0xcb, 0x0a, 0x6f, 0x51, 0xe0, + 0xcd, 0xa1, 0xd9, 0x38, 0x9e, 0x14, 0x5a, 0xe8, 0x10, 0x32, 0x4a, 0x67, 0xa1, 0xf9, 0x88, 0xa3, + 0xb8, 0xf6, 0x2a, 0x2c, 0x0f, 0xed, 0x19, 0x21, 0x4a, 0x51, 0xa0, 0xe4, 0xd1, 0x5c, 0x1c, 0x85, + 0x04, 0xf5, 0x8a, 0xc5, 0x9d, 0x37, 0x20, 0x17, 0x91, 0x45, 0x27, 0x61, 0x45, 0xe3, 0x19, 0xa0, + 0xa4, 0x74, 0x5d, 0x20, 0x2d, 0xa2, 0x42, 0x1f, 0x92, 0x32, 0xe5, 0xd5, 0x07, 0x7d, 0x00, 0x19, + 0xd5, 0x32, 0x93, 0x19, 0x12, 0x57, 0x50, 0xc9, 0x0c, 0xe9, 0xeb, 0xb5, 0xc3, 0x22, 0x93, 0x4d, + 0x32, 0xe8, 0xa0, 0x36, 0x40, 0xaf, 0x8c, 0xa3, 0x95, 0x81, 0xee, 0xa2, 0xdd, 0xb8, 0xa0, 0x9f, + 0x64, 0xa2, 0x40, 0x57, 0x04, 0xe8, 0x02, 0x9a, 0x1f, 0x04, 0x2a, 0x3a, 0x09, 0x8f, 0x51, 0x15, + 0xfe, 0x41, 0x6f, 0x2f, 0xda, 0x28, 0x06, 0xbd, 0xbd, 0x58, 0xc7, 0x18, 0x16, 0x63, 0xd8, 0x45, + 0x78, 0x32, 0xaa, 0x1e, 0xbf, 0x94, 0xcc, 0xed, 0xc8, 0x0f, 0x1e, 0xc9, 0x64, 0x8c, 0xff, 0xf2, + 0x31, 0x2c, 0x19, 0xa5, 0xd6, 0x40, 0x9f, 0x6b, 0x30, 0x93, 0xe8, 0x2e, 0x28, 0x51, 0xc6, 0x86, + 0x75, 0xa8, 0xc2, 0xff, 0x5e, 0xc0, 0x52, 0x11, 0xf9, 0x8f, 0x20, 0xb2, 0x84, 0x16, 0xe2, 0x44, + 0x62, 0xed, 0x6b, 0xe7, 0xea, 0xe3, 0x67, 0x45, 0xed, 0xc9, 0xb3, 0xa2, 0xf6, 0xd3, 0xb3, 0xa2, + 0xf6, 0xf0, 0x79, 0x71, 0xe4, 0xc9, 0xf3, 0xe2, 0xc8, 0xf7, 0xcf, 0x8b, 0x23, 0xef, 0x95, 0x22, + 0x02, 0x42, 0x3a, 0xa0, 0xcc, 0xec, 0x08, 0x2f, 0x42, 0x3d, 0x54, 0xc7, 0x85, 0x5a, 0x79, 0xe5, + 0x8f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x36, 0x77, 0x41, 0xe1, 0xf7, 0x12, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1470,6 +1662,13 @@ type QueryClient interface { // it's similar to feemarket module's method, but also checks london hardfork // status. BaseFee(ctx context.Context, in *QueryBaseFeeRequest, opts ...grpc.CallOption) (*QueryBaseFeeResponse, error) + // Config queries the EVM configuration + Config(ctx context.Context, in *QueryConfigRequest, opts ...grpc.CallOption) (*QueryConfigResponse, error) + // GlobalMinGasPrice queries the MinGasPrice + // it's similar to feemarket module's method, + // but makes the conversion to 18 decimals + // when the evm denom is represented with a different precision. + GlobalMinGasPrice(ctx context.Context, in *QueryGlobalMinGasPriceRequest, opts ...grpc.CallOption) (*QueryGlobalMinGasPriceResponse, error) } type queryClient struct { @@ -1588,6 +1787,24 @@ func (c *queryClient) BaseFee(ctx context.Context, in *QueryBaseFeeRequest, opts return out, nil } +func (c *queryClient) Config(ctx context.Context, in *QueryConfigRequest, opts ...grpc.CallOption) (*QueryConfigResponse, error) { + out := new(QueryConfigResponse) + err := c.cc.Invoke(ctx, "/os.evm.v1.Query/Config", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) GlobalMinGasPrice(ctx context.Context, in *QueryGlobalMinGasPriceRequest, opts ...grpc.CallOption) (*QueryGlobalMinGasPriceResponse, error) { + out := new(QueryGlobalMinGasPriceResponse) + err := c.cc.Invoke(ctx, "/os.evm.v1.Query/GlobalMinGasPrice", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // QueryServer is the server API for Query service. type QueryServer interface { // Account queries an Ethereum account. @@ -1619,6 +1836,13 @@ type QueryServer interface { // it's similar to feemarket module's method, but also checks london hardfork // status. BaseFee(context.Context, *QueryBaseFeeRequest) (*QueryBaseFeeResponse, error) + // Config queries the EVM configuration + Config(context.Context, *QueryConfigRequest) (*QueryConfigResponse, error) + // GlobalMinGasPrice queries the MinGasPrice + // it's similar to feemarket module's method, + // but makes the conversion to 18 decimals + // when the evm denom is represented with a different precision. + GlobalMinGasPrice(context.Context, *QueryGlobalMinGasPriceRequest) (*QueryGlobalMinGasPriceResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. @@ -1661,6 +1885,12 @@ func (*UnimplementedQueryServer) TraceBlock(ctx context.Context, req *QueryTrace func (*UnimplementedQueryServer) BaseFee(ctx context.Context, req *QueryBaseFeeRequest) (*QueryBaseFeeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method BaseFee not implemented") } +func (*UnimplementedQueryServer) Config(ctx context.Context, req *QueryConfigRequest) (*QueryConfigResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Config not implemented") +} +func (*UnimplementedQueryServer) GlobalMinGasPrice(ctx context.Context, req *QueryGlobalMinGasPriceRequest) (*QueryGlobalMinGasPriceResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GlobalMinGasPrice not implemented") +} func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) @@ -1882,6 +2112,42 @@ func _Query_BaseFee_Handler(srv interface{}, ctx context.Context, dec func(inter return interceptor(ctx, in, info, handler) } +func _Query_Config_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryConfigRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Config(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/os.evm.v1.Query/Config", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Config(ctx, req.(*QueryConfigRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_GlobalMinGasPrice_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryGlobalMinGasPriceRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).GlobalMinGasPrice(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/os.evm.v1.Query/GlobalMinGasPrice", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).GlobalMinGasPrice(ctx, req.(*QueryGlobalMinGasPriceRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "os.evm.v1.Query", HandlerType: (*QueryServer)(nil), @@ -1934,11 +2200,77 @@ var _Query_serviceDesc = grpc.ServiceDesc{ MethodName: "BaseFee", Handler: _Query_BaseFee_Handler, }, + { + MethodName: "Config", + Handler: _Query_Config_Handler, + }, + { + MethodName: "GlobalMinGasPrice", + Handler: _Query_GlobalMinGasPrice_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "os/evm/v1/query.proto", } +func (m *QueryConfigRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *QueryConfigRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *QueryConfigRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *QueryConfigResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *QueryConfigResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *QueryConfigResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Config != nil { + { + size, err := m.Config.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintQuery(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *QueryAccountRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -2552,6 +2884,20 @@ func (m *EstimateGasResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + if len(m.VmError) > 0 { + i -= len(m.VmError) + copy(dAtA[i:], m.VmError) + i = encodeVarintQuery(dAtA, i, uint64(len(m.VmError))) + i-- + dAtA[i] = 0x1a + } + if len(m.Ret) > 0 { + i -= len(m.Ret) + copy(dAtA[i:], m.Ret) + i = encodeVarintQuery(dAtA, i, uint64(len(m.Ret))) + i-- + dAtA[i] = 0x12 + } if m.Gas != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Gas)) i-- @@ -2597,12 +2943,12 @@ func (m *QueryTraceTxRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i-- dAtA[i] = 0x42 } - n4, err4 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.BlockTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.BlockTime):]) - if err4 != nil { - return 0, err4 + n5, err5 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.BlockTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.BlockTime):]) + if err5 != nil { + return 0, err5 } - i -= n4 - i = encodeVarintQuery(dAtA, i, uint64(n4)) + i -= n5 + i = encodeVarintQuery(dAtA, i, uint64(n5)) i-- dAtA[i] = 0x3a if len(m.BlockHash) > 0 { @@ -2725,12 +3071,12 @@ func (m *QueryTraceBlockRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) i-- dAtA[i] = 0x42 } - n7, err7 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.BlockTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.BlockTime):]) - if err7 != nil { - return 0, err7 + n8, err8 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.BlockTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.BlockTime):]) + if err8 != nil { + return 0, err8 } - i -= n7 - i = encodeVarintQuery(dAtA, i, uint64(n7)) + i -= n8 + i = encodeVarintQuery(dAtA, i, uint64(n8)) i-- dAtA[i] = 0x3a if len(m.BlockHash) > 0 { @@ -2862,17 +3208,95 @@ func (m *QueryBaseFeeResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { - offset -= sovQuery(v) - base := offset - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - dAtA[offset] = uint8(v) +func (m *QueryGlobalMinGasPriceRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *QueryGlobalMinGasPriceRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *QueryGlobalMinGasPriceRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *QueryGlobalMinGasPriceResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *QueryGlobalMinGasPriceResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *QueryGlobalMinGasPriceResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size := m.MinGasPrice.Size() + i -= size + if _, err := m.MinGasPrice.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintQuery(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { + offset -= sovQuery(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) return base } +func (m *QueryConfigRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *QueryConfigResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Config != nil { + l = m.Config.Size() + n += 1 + l + sovQuery(uint64(l)) + } + return n +} + func (m *QueryAccountRequest) Size() (n int) { if m == nil { return 0 @@ -3140,6 +3564,14 @@ func (m *EstimateGasResponse) Size() (n int) { if m.Gas != 0 { n += 1 + sovQuery(uint64(m.Gas)) } + l = len(m.Ret) + if l > 0 { + n += 1 + l + sovQuery(uint64(l)) + } + l = len(m.VmError) + if l > 0 { + n += 1 + l + sovQuery(uint64(l)) + } return n } @@ -3271,12 +3703,168 @@ func (m *QueryBaseFeeResponse) Size() (n int) { return n } +func (m *QueryGlobalMinGasPriceRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *QueryGlobalMinGasPriceResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.MinGasPrice.Size() + n += 1 + l + sovQuery(uint64(l)) + return n +} + func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } +func (m *QueryConfigRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: QueryConfigRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: QueryConfigRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *QueryConfigResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: QueryConfigResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: QueryConfigResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Config == nil { + m.Config = &ChainConfig{} + } + if err := m.Config.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *QueryAccountRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -4997,6 +5585,72 @@ func (m *EstimateGasResponse) Unmarshal(dAtA []byte) error { break } } + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Ret", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Ret = append(m.Ret[:0], dAtA[iNdEx:postIndex]...) + if m.Ret == nil { + m.Ret = []byte{} + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VmError", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.VmError = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) @@ -5910,6 +6564,140 @@ func (m *QueryBaseFeeResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *QueryGlobalMinGasPriceRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: QueryGlobalMinGasPriceRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: QueryGlobalMinGasPriceRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *QueryGlobalMinGasPriceResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: QueryGlobalMinGasPriceResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: QueryGlobalMinGasPriceResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MinGasPrice", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.MinGasPrice.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 diff --git a/x/evm/types/query.pb.gw.go b/x/evm/types/query.pb.gw.go index 71f00259..ab3c72c1 100644 --- a/x/evm/types/query.pb.gw.go +++ b/x/evm/types/query.pb.gw.go @@ -559,6 +559,42 @@ func local_request_Query_BaseFee_0(ctx context.Context, marshaler runtime.Marsha } +func request_Query_Config_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq QueryConfigRequest + var metadata runtime.ServerMetadata + + msg, err := client.Config(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Query_Config_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq QueryConfigRequest + var metadata runtime.ServerMetadata + + msg, err := server.Config(ctx, &protoReq) + return msg, metadata, err + +} + +func request_Query_GlobalMinGasPrice_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq QueryGlobalMinGasPriceRequest + var metadata runtime.ServerMetadata + + msg, err := client.GlobalMinGasPrice(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Query_GlobalMinGasPrice_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq QueryGlobalMinGasPriceRequest + var metadata runtime.ServerMetadata + + msg, err := server.GlobalMinGasPrice(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -841,6 +877,52 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv }) + mux.Handle("GET", pattern_Query_Config_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Query_Config_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Query_Config_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_Query_GlobalMinGasPrice_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Query_GlobalMinGasPrice_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Query_GlobalMinGasPrice_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -1122,6 +1204,46 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie }) + mux.Handle("GET", pattern_Query_Config_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Query_Config_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Query_Config_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_Query_GlobalMinGasPrice_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Query_GlobalMinGasPrice_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Query_GlobalMinGasPrice_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -1149,6 +1271,10 @@ var ( pattern_Query_TraceBlock_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"evmos", "evm", "v1", "trace_block"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_BaseFee_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"evmos", "evm", "v1", "base_fee"}, "", runtime.AssumeColonVerbOpt(false))) + + pattern_Query_Config_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"evmos", "evm", "v1", "config"}, "", runtime.AssumeColonVerbOpt(false))) + + pattern_Query_GlobalMinGasPrice_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"evmos", "evm", "v1", "min_gas_price"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( @@ -1175,4 +1301,8 @@ var ( forward_Query_TraceBlock_0 = runtime.ForwardResponseMessage forward_Query_BaseFee_0 = runtime.ForwardResponseMessage + + forward_Query_Config_0 = runtime.ForwardResponseMessage + + forward_Query_GlobalMinGasPrice_0 = runtime.ForwardResponseMessage ) diff --git a/x/evm/types/scaling.go b/x/evm/types/scaling.go new file mode 100644 index 00000000..b9bc3bdd --- /dev/null +++ b/x/evm/types/scaling.go @@ -0,0 +1,104 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package types + +import ( + "fmt" + "math/big" + + sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" +) + +// MustConvertEvmCoinTo18Decimals converts the coin's Amount from its original +// representation into a 18 decimals. The function panics if coin denom is +// not the evm denom or in case of overflow. +func MustConvertEvmCoinTo18Decimals(coin sdk.Coin) sdk.Coin { + if coin.Denom != GetEVMCoinDenom() { + panic(fmt.Sprintf("expected evm denom %s, received %s", GetEVMCoinDenom(), coin.Denom)) + } + + evmCoinDecimal := GetEVMCoinDecimals() + newAmount := coin.Amount.Mul(evmCoinDecimal.ConversionFactor()) + + return sdk.Coin{Denom: coin.Denom, Amount: newAmount} +} + +// ConvertAmountToLegacy18Decimals convert the given amount into a 18 decimals +// representation. +func ConvertAmountTo18DecimalsLegacy(amt sdkmath.LegacyDec) sdkmath.LegacyDec { + evmCoinDecimal := GetEVMCoinDecimals() + + return amt.MulInt(evmCoinDecimal.ConversionFactor()) +} + +// ConvertAmountTo18DecimalsBigInt convert the given amount into a 18 decimals +// representation. +func ConvertAmountTo18DecimalsBigInt(amt *big.Int) *big.Int { + evmCoinDecimal := GetEVMCoinDecimals() + + return new(big.Int).Mul(amt, evmCoinDecimal.ConversionFactor().BigInt()) +} + +// ConvertAmountFrom18DecimalsBigInt convert the given amount into a 18 decimals +// representation. +func ConvertAmountFrom18DecimalsBigInt(amt *big.Int) *big.Int { + evmCoinDecimal := GetEVMCoinDecimals() + + return new(big.Int).Quo(amt, evmCoinDecimal.ConversionFactor().BigInt()) +} + +// ConvertBigIntFrom18DecimalsToLegacyDec converts the given amount into a LegacyDec +// with the corresponding decimals of the EVM denom. +func ConvertBigIntFrom18DecimalsToLegacyDec(amt *big.Int) sdkmath.LegacyDec { + evmCoinDecimal := GetEVMCoinDecimals() + decAmt := sdkmath.LegacyNewDecFromBigInt(amt) + return decAmt.QuoInt(evmCoinDecimal.ConversionFactor()) +} + +// ConvertEvmCoinFrom18Decimals converts the coin's Amount from 18 decimals to its +// original representation. Return an error if the coin denom is not the EVM. +func ConvertEvmCoinFrom18Decimals(coin sdk.Coin) (sdk.Coin, error) { + if coin.Denom != GetEVMCoinDenom() { + return sdk.Coin{}, fmt.Errorf("expected coin denom %s, received %s", GetEVMCoinDenom(), coin.Denom) + } + + evmCoinDecimal := GetEVMCoinDecimals() + newAmount := coin.Amount.Quo(evmCoinDecimal.ConversionFactor()) + + return sdk.Coin{Denom: coin.Denom, Amount: newAmount}, nil +} + +// ConvertCoinsFrom18Decimals returns the given coins with the Amount of the evm +// coin converted from the 18 decimals representation to the original one. +func ConvertCoinsFrom18Decimals(coins sdk.Coins) sdk.Coins { + evmDenom := GetEVMCoinDenom() + + convertedCoins := make(sdk.Coins, len(coins)) + for i, coin := range coins { + if coin.Denom == evmDenom { + evmCoinDecimals := GetEVMCoinDecimals() + + newAmount := coin.Amount.Quo(evmCoinDecimals.ConversionFactor()) + + coin = sdk.Coin{Denom: coin.Denom, Amount: newAmount} + } + convertedCoins[i] = coin + } + return convertedCoins +} + +// AdjustExtraDecimalsBigInt replaces all extra decimals by zero of an amount with 18 decimals in big.Int when having a decimal configuration different than 18 decimals +func AdjustExtraDecimalsBigInt(amt *big.Int) *big.Int { + if amt.Sign() == 0 { + return amt + } + dec := GetEVMCoinDecimals() + if dec == EighteenDecimals { + return amt + } + scaleFactor := dec.ConversionFactor() + scaledDown := new(big.Int).Quo(amt, scaleFactor.BigInt()) + return new(big.Int).Mul(scaledDown, scaleFactor.BigInt()) +} diff --git a/x/evm/types/scaling_test.go b/x/evm/types/scaling_test.go new file mode 100644 index 00000000..71b14586 --- /dev/null +++ b/x/evm/types/scaling_test.go @@ -0,0 +1,327 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package types_test + +import ( + "fmt" + "math/big" + "testing" + + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" + testconstants "github.com/evmos/os/testutil/constants" + evmtypes "github.com/evmos/os/x/evm/types" + "github.com/stretchr/testify/require" +) + +const exampleDenom = testconstants.ExampleAttoDenom + +func TestMustConvertEvmCoinTo18Decimals(t *testing.T) { + baseCoinZero := sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(0)} + + testCases := []struct { + name string + evmCoinInfo evmtypes.EvmCoinInfo + coin sdk.Coin + expCoin sdk.Coin + expPanic bool + }{ + { + name: "pass - zero amount 18 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.EighteenDecimals}, + coin: baseCoinZero, + expPanic: false, + expCoin: baseCoinZero, + }, + { + name: "pass - zero amount 6 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coin: baseCoinZero, + expPanic: false, + expCoin: baseCoinZero, + }, + { + name: "pass - no conversion with 18 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.EighteenDecimals}, + coin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(10)}, + expPanic: false, + expCoin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(10)}, + }, + { + name: "pass - conversion with 6 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(1)}, + expPanic: false, + expCoin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(1e12)}, + }, + { + name: "panic - not evm denom", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coin: sdk.Coin{Denom: "evmos", Amount: math.NewInt(1)}, + expPanic: true, + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + defer func() { + if r := recover(); r != nil { + if tc.expPanic { + require.NotNil(t, r, "expected test to panic") + } else { + t.Errorf("unexpected panic: %v", r) + } + } else if tc.expPanic { + t.Errorf("expected panic but did not occur") + } + }() + + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + require.NoError(t, configurator.WithEVMCoinInfo(tc.evmCoinInfo.Denom, uint8(tc.evmCoinInfo.Decimals)).Configure()) + + coinConverted := evmtypes.MustConvertEvmCoinTo18Decimals(tc.coin) + + if !tc.expPanic { + require.Equal(t, tc.expCoin, coinConverted, "expected a different coin") + } + }) + } +} + +func TestConvertEvmCoinFrom18Decimals(t *testing.T) { + baseCoinZero := sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(0)} + + testCases := []struct { + name string + evmCoinInfo evmtypes.EvmCoinInfo + coin sdk.Coin + expCoin sdk.Coin + expErr bool + }{ + { + name: "pass - zero amount 18 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.EighteenDecimals}, + coin: baseCoinZero, + expErr: false, + expCoin: baseCoinZero, + }, + { + name: "pass - zero amount 6 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coin: baseCoinZero, + expErr: false, + expCoin: baseCoinZero, + }, + { + name: "pass - no conversion with 18 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.EighteenDecimals}, + coin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(10)}, + expErr: false, + expCoin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(10)}, + }, + { + name: "pass - conversion with 6 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(1e12)}, + expErr: false, + expCoin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(1)}, + }, + { + name: "pass - conversion with amount less than conversion factor", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coin: sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(1e11)}, + expErr: false, + expCoin: baseCoinZero, + }, + { + name: "fail - not evm denom", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coin: sdk.Coin{Denom: "evmos", Amount: math.NewInt(1)}, + expErr: true, + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + require.NoError(t, configurator.WithEVMCoinInfo(tc.evmCoinInfo.Denom, uint8(tc.evmCoinInfo.Decimals)).Configure()) + + coinConverted, err := evmtypes.ConvertEvmCoinFrom18Decimals(tc.coin) + + if !tc.expErr { + require.NoError(t, err) + require.Equal(t, tc.expCoin, coinConverted, "expected a different coin") + } else { + require.Error(t, err) + } + }) + } +} + +func TestConvertCoinsFrom18Decimals(t *testing.T) { + nonBaseCoin := sdk.Coin{Denom: "btc", Amount: math.NewInt(10)} + baseCoin := sdk.Coin{Denom: exampleDenom, Amount: math.NewInt(10)} + + testCases := []struct { + name string + evmCoinInfo evmtypes.EvmCoinInfo + coins sdk.Coins + expCoins sdk.Coins + }{ + { + name: "pass - no evm denom", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coins: sdk.Coins{nonBaseCoin}, + expCoins: sdk.Coins{nonBaseCoin}, + }, + { + name: "pass - only base denom 18 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.EighteenDecimals}, + coins: sdk.Coins{baseCoin}, + expCoins: sdk.Coins{baseCoin}, + }, + { + name: "pass - only base denom 6 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coins: sdk.Coins{baseCoin}, + expCoins: sdk.Coins{sdk.Coin{Denom: exampleDenom, Amount: baseCoin.Amount.QuoRaw(1e12)}}, + }, + { + name: "pass - multiple coins and base denom 18 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.EighteenDecimals}, + coins: sdk.Coins{nonBaseCoin, baseCoin}, + expCoins: sdk.Coins{nonBaseCoin, baseCoin}, + }, + { + name: "pass - multiple coins and base denom 6 decimals", + evmCoinInfo: evmtypes.EvmCoinInfo{Denom: exampleDenom, Decimals: evmtypes.SixDecimals}, + coins: sdk.Coins{nonBaseCoin, baseCoin}, + expCoins: sdk.Coins{nonBaseCoin, sdk.Coin{Denom: exampleDenom, Amount: baseCoin.Amount.QuoRaw(1e12)}}, + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + require.NoError(t, configurator.WithEVMCoinInfo(tc.evmCoinInfo.Denom, uint8(tc.evmCoinInfo.Decimals)).Configure()) + + coinConverted := evmtypes.ConvertCoinsFrom18Decimals(tc.coins) + require.Equal(t, tc.expCoins, coinConverted, "expected a different coin") + }) + } +} + +func TestZeroExtraDecimalsBigInt(t *testing.T) { + testCases := []struct { + name string + amt *big.Int + exp *big.Int + }{ + { + name: "almost 1: 0.99999...", + amt: big.NewInt(999999999999), + exp: big.NewInt(0), + }, + { + name: "decimal < 5: 1.4", + amt: big.NewInt(14e11), + exp: big.NewInt(1e12), + }, + { + name: "decimal < 5: 1.499999999999", + amt: big.NewInt(1499999999999), + exp: big.NewInt(1e12), + }, + { + name: "decimal == 5: 1.5", + amt: big.NewInt(15e11), + exp: big.NewInt(1e12), + }, + { + name: "decimal > 5: 1.9", + amt: big.NewInt(19e11), + exp: big.NewInt(1e12), + }, + { + name: "1 wei", + amt: big.NewInt(1), + exp: big.NewInt(0), + }, + } + + for _, cfg := range []evmtypes.EvmCoinInfo{ + {Denom: testconstants.ExampleAttoDenom, Decimals: evmtypes.SixDecimals}, + {Denom: testconstants.ExampleAttoDenom, Decimals: evmtypes.EighteenDecimals}, + } { + for _, tc := range testCases { + t.Run(fmt.Sprintf("%d dec - %s", cfg.Decimals, tc.name), func(t *testing.T) { + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + require.NoError(t, configurator.WithEVMCoinInfo(cfg.Denom, uint8(cfg.Decimals)).Configure()) + + res := evmtypes.AdjustExtraDecimalsBigInt(tc.amt) + if cfg.Decimals == evmtypes.EighteenDecimals { + tc.exp = tc.amt + } + require.Equal(t, tc.exp, res) + }) + } + } +} + +func TestConvertBigIntFrom18DecimalsToLegacyDec(t *testing.T) { + testCases := []struct { + name string + amt *big.Int + exp6dec math.LegacyDec + }{ + { + name: "smallest amount", + amt: big.NewInt(1), + exp6dec: math.LegacyMustNewDecFromStr("0.000000000001"), + }, + { + name: "almost 1: 0.99999...", + amt: big.NewInt(999999999999), + exp6dec: math.LegacyMustNewDecFromStr("0.999999999999"), + }, + { + name: "half of the minimum uint", + amt: big.NewInt(5e11), + exp6dec: math.LegacyMustNewDecFromStr("0.5"), + }, + { + name: "one int", + amt: big.NewInt(1e12), + exp6dec: math.LegacyOneDec(), + }, + { + name: "one 'ether'", + amt: big.NewInt(1e18), + exp6dec: math.LegacyNewDec(1e6), + }, + } + + for _, cfg := range []evmtypes.EvmCoinInfo{ + {Denom: testconstants.ExampleMicroDenom, Decimals: evmtypes.SixDecimals}, + {Denom: testconstants.ExampleAttoDenom, Decimals: evmtypes.EighteenDecimals}, + } { + for _, tc := range testCases { + t.Run(fmt.Sprintf("%d dec - %s", cfg.Decimals, tc.name), func(t *testing.T) { + configurator := evmtypes.NewEVMConfigurator() + configurator.ResetTestConfig() + require.NoError(t, configurator.WithEVMCoinInfo(cfg.Denom, uint8(cfg.Decimals)).Configure()) + res := evmtypes.ConvertBigIntFrom18DecimalsToLegacyDec(tc.amt) + exp := math.LegacyNewDecFromBigInt(tc.amt) + if cfg.Decimals == evmtypes.SixDecimals { + exp = tc.exp6dec + } + require.Equal(t, exp, res) + }) + } + } +} diff --git a/x/evm/types/storage_test.go b/x/evm/types/storage_test.go index 515f2a83..8e0e7253 100644 --- a/x/evm/types/storage_test.go +++ b/x/evm/types/storage_test.go @@ -38,7 +38,6 @@ func TestStorageValidate(t *testing.T) { } for _, tc := range testCases { - tc := tc err := tc.storage.Validate() if tc.expPass { require.NoError(t, err, tc.name) @@ -72,7 +71,6 @@ func TestStorageCopy(t *testing.T) { } for _, tc := range testCases { - tc := tc require.Equal(t, tc.storage, tc.storage.Copy(), tc.name) } } diff --git a/x/evm/types/tx_data.go b/x/evm/types/tx_data.go index 05c7622b..3fa743c3 100644 --- a/x/evm/types/tx_data.go +++ b/x/evm/types/tx_data.go @@ -40,12 +40,17 @@ type TxData interface { AsEthereumData() ethtypes.TxData Validate() error - // static fee + // Fee returns the maximum fee a sender of a message is willing to pay. Fee() *big.Int + // Cost returns the total cost of a transaction before executing any smart + // contract call. This means it should return the fee the user has to pay + // plus the amount of tokens they want to transfer. Cost() *big.Int - // effective gasPrice/fee/cost according to current base fee + // EffectiveGasPrice returns the price for the gas used in a transaction + // based on the transaction type. EffectiveGasPrice(baseFee *big.Int) *big.Int + // EffectiveFee returns the fees a user is willing to pay for a transaction. EffectiveFee(baseFee *big.Int) *big.Int EffectiveCost(baseFee *big.Int) *big.Int } @@ -70,11 +75,16 @@ func NewTxDataFromTx(tx *ethtypes.Transaction) (TxData, error) { return txData, nil } +// fee returns the fee for a transaction given by the gas price time the gas. func fee(gasPrice *big.Int, gas uint64) *big.Int { gasLimit := new(big.Int).SetUint64(gas) return new(big.Int).Mul(gasPrice, gasLimit) } +// cost returns the sum of the fee and value. If value is nil it returns only +// the fee. This function is made to be used in the ante handler to compute the +// total cost of a transaction given by the fee the user has to pay and the +// amount they want to transfer. func cost(fee, value *big.Int) *big.Int { if value != nil { return new(big.Int).Add(fee, value) diff --git a/x/evm/types/utils.go b/x/evm/types/utils.go index bd01d73e..aa530224 100644 --- a/x/evm/types/utils.go +++ b/x/evm/types/utils.go @@ -91,22 +91,20 @@ func UnwrapEthereumMsg(tx *sdk.Tx, ethHash common.Hash) (*MsgEthereumTx, error) func UnpackEthMsg(msg sdk.Msg) ( ethMsg *MsgEthereumTx, txData TxData, - from sdk.AccAddress, err error, ) { msgEthTx, ok := msg.(*MsgEthereumTx) if !ok { - return nil, nil, nil, errorsmod.Wrapf(errortypes.ErrUnknownRequest, "invalid message type %T, expected %T", msg, (*MsgEthereumTx)(nil)) + return nil, nil, errorsmod.Wrapf(errortypes.ErrUnknownRequest, "invalid message type %T, expected %T", msg, (*MsgEthereumTx)(nil)) } txData, err = UnpackTxData(msgEthTx.Data) if err != nil { - return nil, nil, nil, errorsmod.Wrap(err, "failed to unpack tx data any for tx") + return nil, nil, errorsmod.Wrap(err, "failed to unpack tx data any for tx") } // sender address should be in the tx cache from the previous AnteHandle call - from = msgEthTx.GetFrom() - return msgEthTx, txData, from, nil + return msgEthTx, txData, nil } // BinSearch executes the binary search and hone in on an executable gas limit diff --git a/x/evm/wrappers/README.md b/x/evm/wrappers/README.md new file mode 100644 index 00000000..8c5f38da --- /dev/null +++ b/x/evm/wrappers/README.md @@ -0,0 +1,33 @@ +# Wrappers + +The wrapper package defines wrappers around Cosmos SDK modules required to +handle coins with different representation of the decimals inside the x/evm module. + +All wrapper implementations should be used only for transaction executions that +involves the EVM. When a keeper is required as a dependency for another Cosmos +SDK module, it should be used the original Keeper. + +## BankWrapper + +This package contains the `BankWrapper`, a wrapper around the Cosmos SDK bank keeper that is designed +to manage the EVM denomination with a custom decimal representation. The primary purpose of the +`BankWrapper` is to handle conversions between Cosmos SDK's default decimal system and the 18-decimal +representation commonly used in EVM-based systems. + +## Features + +- **Balance Conversion:** Automatically converts balances to 18 decimals, the standard for EVM coins. +- **Send and Receive Coins:** Handles sending coins between accounts and modules, ensuring proper conversion + to and from the 18-decimal system. +- **Mint and Burn Coins:** Provides methods for minting and burning coins, with conversions applied + as necessary. + +## Conversion Logic + +The wrapper uses helper functions to convert between Cosmos SDK's bank module decimal representation +and EVM's 18-decimal standard: + +- `mustConvertEvmCoinTo18Decimals`: Converts a coin to 18 decimals. +- `convertCoinsFrom18Decimals`: Converts coins from 18 decimals to their original representation. + +Both methods convert only the evm denom amount. diff --git a/x/evm/wrappers/bank.go b/x/evm/wrappers/bank.go new file mode 100644 index 00000000..7f2c3d19 --- /dev/null +++ b/x/evm/wrappers/bank.go @@ -0,0 +1,114 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package wrappers + +import ( + "context" + "math/big" + + "cosmossdk.io/errors" + sdkmath "cosmossdk.io/math" + + sdk "github.com/cosmos/cosmos-sdk/types" + + "github.com/evmos/os/x/evm/types" +) + +var _ types.BankWrapper = BankWrapper{} + +// BankWrapper is a wrapper around the Cosmos SDK bank keeper +// that is used to manage an evm denom with a custom decimal representation. +type BankWrapper struct { + types.BankKeeper +} + +// NewBankWrapper creates a new BankWrapper instance. +func NewBankWrapper( + bk types.BankKeeper, +) *BankWrapper { + return &BankWrapper{ + bk, + } +} + +// ------------------------------------------------------------------------------------------ +// Bank wrapper own methods +// ------------------------------------------------------------------------------------------ + +// MintAmountToAccount converts the given amount into the evm coin scaling +// the amount to the original decimals, then mints that amount to the provided account. +func (w BankWrapper) MintAmountToAccount(ctx context.Context, recipientAddr sdk.AccAddress, amt *big.Int) error { + coin := sdk.Coin{Denom: types.GetEVMCoinDenom(), Amount: sdkmath.NewIntFromBigInt(amt)} + + convertedCoin, err := types.ConvertEvmCoinFrom18Decimals(coin) + if err != nil { + return errors.Wrap(err, "failed to mint coin to account in bank wrapper") + } + + coinsToMint := sdk.Coins{convertedCoin} + if err := w.BankKeeper.MintCoins(ctx, types.ModuleName, coinsToMint); err != nil { + return errors.Wrap(err, "failed to mint coins to account in bank wrapper") + } + + return w.BankKeeper.SendCoinsFromModuleToAccount(ctx, types.ModuleName, recipientAddr, coinsToMint) +} + +// BurnAmountFromAccount converts the given amount into the evm coin scaling +// the amount to the original decimals, then burns that quantity from the provided account. +func (w BankWrapper) BurnAmountFromAccount(ctx context.Context, account sdk.AccAddress, amt *big.Int) error { + coin := sdk.Coin{Denom: types.GetEVMCoinDenom(), Amount: sdkmath.NewIntFromBigInt(amt)} + + convertedCoin, err := types.ConvertEvmCoinFrom18Decimals(coin) + if err != nil { + return errors.Wrap(err, "failed to burn coins from account in bank wrapper") + } + + coinsToBurn := sdk.Coins{convertedCoin} + if err := w.BankKeeper.SendCoinsFromAccountToModule(ctx, account, types.ModuleName, coinsToBurn); err != nil { + return errors.Wrap(err, "failed to burn coins from account in bank wrapper") + } + return w.BankKeeper.BurnCoins(ctx, types.ModuleName, coinsToBurn) +} + +// ------------------------------------------------------------------------------------------ +// Bank keeper shadowed methods +// ------------------------------------------------------------------------------------------ + +// GetBalance returns the balance of the given account converted to 18 decimals. +func (w BankWrapper) GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin { + // Get the balance from the BankModule. The balance returned is in the bank + // decimals representation, which could be different than the 18 decimals + // representation used in the evm. + coin := w.BankKeeper.GetBalance(ctx, addr, denom) + + return types.MustConvertEvmCoinTo18Decimals(coin) +} + +// SendCoinsFromAccountToModule wraps around the Cosmos SDK x/bank module's +// SendCoinsFromAccountToModule method to convert the evm coin, if present in +// the input, to its original representation. +func (w BankWrapper) SendCoinsFromAccountToModule(ctx context.Context, senderAddr sdk.AccAddress, recipientModule string, coins sdk.Coins) error { + convertedCoins := types.ConvertCoinsFrom18Decimals(coins) + if convertedCoins.IsZero() { + // if after scaling the coins the amt is zero + // then is a no-op. + // Also this avoids getting a validation error on the + // SendCoinsFromAccountToModule function of the bank keeper + return nil + } + + return w.BankKeeper.SendCoinsFromAccountToModule(ctx, senderAddr, recipientModule, convertedCoins) +} + +// SendCoinsFromModuleToAccount wraps around the Cosmos SDK x/bank module's +// SendCoinsFromModuleToAccount method to convert the evm coin, if present in +// the input, to its original representation. +func (w BankWrapper) SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, coins sdk.Coins) error { + convertedCoins := types.ConvertCoinsFrom18Decimals(coins) + if convertedCoins.IsZero() { + return nil + } + + return w.BankKeeper.SendCoinsFromModuleToAccount(ctx, senderModule, recipientAddr, convertedCoins) +} diff --git a/x/evm/wrappers/feemarket.go b/x/evm/wrappers/feemarket.go new file mode 100644 index 00000000..b46a0e89 --- /dev/null +++ b/x/evm/wrappers/feemarket.go @@ -0,0 +1,58 @@ +// Copyright Tharsis Labs Ltd.(Evmos) +// SPDX-License-Identifier:ENCL-1.0(https://github.com/evmos/evmos/blob/main/LICENSE) + +package wrappers + +import ( + "math/big" + + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/evmos/os/x/evm/types" + feemarkettypes "github.com/evmos/os/x/feemarket/types" +) + +// FeeMarketWrapper is a wrapper around the feemarket keeper +// that is used to manage an evm denom with 6 or 18 decimals. +// The wrapper makes the corresponding conversions to achieve: +// - With the EVM, the wrapper works always with 18 decimals. +// - With the feemarket module, the wrapper works always +// with the bank module decimals (either 6 or 18). +type FeeMarketWrapper struct { + types.FeeMarketKeeper +} + +// NewFeeMarketWrapper creates a new feemarket Keeper wrapper instance. +// The BankWrapper is used to manage an evm denom with 6 or 18 decimals. +func NewFeeMarketWrapper( + fk types.FeeMarketKeeper, +) *FeeMarketWrapper { + return &FeeMarketWrapper{ + fk, + } +} + +// GetBaseFee returns the base fee converted to 18 decimals. +func (w FeeMarketWrapper) GetBaseFee(ctx sdk.Context) *big.Int { + baseFee := w.FeeMarketKeeper.GetBaseFee(ctx) + if baseFee.IsNil() { + return nil + } + return types.ConvertAmountTo18DecimalsLegacy(baseFee).TruncateInt().BigInt() +} + +// CalculateBaseFee returns the calculated base fee converted to 18 decimals. +func (w FeeMarketWrapper) CalculateBaseFee(ctx sdk.Context) *big.Int { + baseFee := w.FeeMarketKeeper.CalculateBaseFee(ctx) + if baseFee.IsNil() { + return nil + } + return types.ConvertAmountTo18DecimalsLegacy(baseFee).TruncateInt().BigInt() +} + +// GetParams returns the params with associated fees values converted to 18 decimals. +func (w FeeMarketWrapper) GetParams(ctx sdk.Context) feemarkettypes.Params { + params := w.FeeMarketKeeper.GetParams(ctx) + params.BaseFee = types.ConvertAmountTo18DecimalsLegacy(params.BaseFee) + params.MinGasPrice = types.ConvertAmountTo18DecimalsLegacy(params.MinGasPrice) + return params +} diff --git a/x/feemarket/keeper/abci.go b/x/feemarket/keeper/abci.go index cbf1537c..7b4b14fd 100644 --- a/x/feemarket/keeper/abci.go +++ b/x/feemarket/keeper/abci.go @@ -18,14 +18,20 @@ func (k *Keeper) BeginBlock(ctx sdk.Context) error { baseFee := k.CalculateBaseFee(ctx) // return immediately if base fee is nil - if baseFee == nil { + if baseFee.IsNil() { return nil } k.SetBaseFee(ctx, baseFee) defer func() { - telemetry.SetGauge(float32(baseFee.Int64()), "feemarket", "base_fee") + floatBaseFee, err := baseFee.Float64() + if err != nil { + ctx.Logger().Error("error converting base fee to float64", "error", err.Error()) + return + } + // there'll be no panic if fails to convert to float32. Will only loose precision + telemetry.SetGauge(float32(floatBaseFee), "feemarket", "base_fee") }() // Store current base fee in event diff --git a/x/feemarket/keeper/eip1559.go b/x/feemarket/keeper/eip1559.go index b2f67c45..2035f549 100644 --- a/x/feemarket/keeper/eip1559.go +++ b/x/feemarket/keeper/eip1559.go @@ -3,11 +3,9 @@ package keeper import ( - "math/big" - + sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/math" ) @@ -15,12 +13,12 @@ import ( // block during BeginBlock. If the NoBaseFee parameter is enabled or below activation height, this function returns nil. // NOTE: This code is inspired from the go-ethereum EIP1559 implementation and adapted to Cosmos SDK-based // chains. For the canonical code refer to: https://github.com/ethereum/go-ethereum/blob/master/consensus/misc/eip1559.go -func (k Keeper) CalculateBaseFee(ctx sdk.Context) *big.Int { +func (k Keeper) CalculateBaseFee(ctx sdk.Context) sdkmath.LegacyDec { params := k.GetParams(ctx) // Ignore the calculation if not enabled if !params.IsBaseFeeEnabled(ctx.BlockHeight()) { - return nil + return sdkmath.LegacyDec{} } consParams := ctx.ConsensusParams() @@ -29,66 +27,69 @@ func (k Keeper) CalculateBaseFee(ctx sdk.Context) *big.Int { // defined in the parameters (DefaultBaseFee if it hasn't been changed by // governance). if ctx.BlockHeight() == params.EnableHeight { - return params.BaseFee.BigInt() + return params.BaseFee } // get the block gas used and the base fee values for the parent block. // NOTE: this is not the parent's base fee but the current block's base fee, // as it is retrieved from the transient store, which is committed to the // persistent KVStore after EndBlock (ABCI Commit). - parentBaseFee := params.BaseFee.BigInt() - if parentBaseFee == nil { - return nil + parentBaseFee := params.BaseFee + if parentBaseFee.IsNil() { + return sdkmath.LegacyDec{} } parentGasUsed := k.GetBlockGasWanted(ctx) - gasLimit := new(big.Int).SetUint64(math.MaxUint64) + gasLimit := sdkmath.NewIntFromUint64(math.MaxUint64) // NOTE: a MaxGas equal to -1 means that block gas is unlimited if consParams.Block != nil && consParams.Block.MaxGas > -1 { - gasLimit = big.NewInt(consParams.Block.MaxGas) + gasLimit = sdkmath.NewInt(consParams.Block.MaxGas) } // CONTRACT: ElasticityMultiplier cannot be 0 as it's checked in the params // validation - parentGasTargetBig := new(big.Int).Div(gasLimit, new(big.Int).SetUint64(uint64(params.ElasticityMultiplier))) - if !parentGasTargetBig.IsUint64() { - return nil + parentGasTargetInt := gasLimit.Quo(sdkmath.NewIntFromUint64(uint64(params.ElasticityMultiplier))) + if !parentGasTargetInt.IsUint64() { + return sdkmath.LegacyDec{} } - parentGasTarget := parentGasTargetBig.Uint64() - baseFeeChangeDenominator := new(big.Int).SetUint64(uint64(params.BaseFeeChangeDenominator)) + parentGasTarget := parentGasTargetInt.Uint64() + baseFeeChangeDenominator := sdkmath.NewIntFromUint64(uint64(params.BaseFeeChangeDenominator)) // If the parent gasUsed is the same as the target, the baseFee remains // unchanged. if parentGasUsed == parentGasTarget { - return new(big.Int).Set(parentBaseFee) + return parentBaseFee + } + + if parentGasTargetInt.IsZero() { + return sdkmath.LegacyZeroDec() } if parentGasUsed > parentGasTarget { // If the parent block used more gas than its target, the baseFee should // increase. - gasUsedDelta := new(big.Int).SetUint64(parentGasUsed - parentGasTarget) - x := new(big.Int).Mul(parentBaseFee, gasUsedDelta) - y := x.Div(x, parentGasTargetBig) - baseFeeDelta := math.BigMax( - x.Div(y, baseFeeChangeDenominator), - common.Big1, + gasUsedDelta := sdkmath.NewIntFromUint64(parentGasUsed - parentGasTarget) + x := parentBaseFee.MulInt(gasUsedDelta) + y := x.QuoInt(parentGasTargetInt) + baseFeeDelta := sdkmath.LegacyMaxDec( + y.QuoInt(baseFeeChangeDenominator), + sdkmath.LegacyOneDec(), ) - return x.Add(parentBaseFee, baseFeeDelta) + return parentBaseFee.Add(baseFeeDelta) } // Otherwise if the parent block used less gas than its target, the baseFee // should decrease. - gasUsedDelta := new(big.Int).SetUint64(parentGasTarget - parentGasUsed) - x := new(big.Int).Mul(parentBaseFee, gasUsedDelta) - y := x.Div(x, parentGasTargetBig) - baseFeeDelta := x.Div(y, baseFeeChangeDenominator) + gasUsedDelta := sdkmath.NewIntFromUint64(parentGasTarget - parentGasUsed) + x := parentBaseFee.MulInt(gasUsedDelta) + y := x.QuoInt(parentGasTargetInt) + baseFeeDelta := y.QuoInt(baseFeeChangeDenominator) // Set global min gas price as lower bound of the base fee, transactions below // the min gas price don't even reach the mempool. - minGasPrice := params.MinGasPrice.TruncateInt().BigInt() - return math.BigMax(x.Sub(parentBaseFee, baseFeeDelta), minGasPrice) + return sdkmath.LegacyMaxDec(parentBaseFee.Sub(baseFeeDelta), params.MinGasPrice) } diff --git a/x/feemarket/keeper/eip1559_test.go b/x/feemarket/keeper/eip1559_test.go index 002a23e4..4fbaaff6 100644 --- a/x/feemarket/keeper/eip1559_test.go +++ b/x/feemarket/keeper/eip1559_test.go @@ -1,7 +1,6 @@ package keeper_test import ( - "math/big" "testing" "cosmossdk.io/math" @@ -15,7 +14,7 @@ func TestCalculateBaseFee(t *testing.T) { var ( nw *network.UnitTestNetwork ctx sdk.Context - initialBaseFee math.Int + initialBaseFee math.LegacyDec ) testCases := []struct { @@ -24,7 +23,7 @@ func TestCalculateBaseFee(t *testing.T) { blockHeight int64 parentBlockGasWanted uint64 minGasPrice math.LegacyDec - expFee func() *big.Int + expFee func() math.LegacyDec }{ { "without BaseFee", @@ -40,7 +39,7 @@ func TestCalculateBaseFee(t *testing.T) { 0, 0, math.LegacyZeroDec(), - func() *big.Int { return nw.App.FeeMarketKeeper.GetParams(ctx).BaseFee.BigInt() }, + func() math.LegacyDec { return nw.App.FeeMarketKeeper.GetParams(ctx).BaseFee }, }, { "with BaseFee - parent block wanted the same gas as its target (ElasticityMultiplier = 2)", @@ -48,7 +47,7 @@ func TestCalculateBaseFee(t *testing.T) { 1, 50, math.LegacyZeroDec(), - func() *big.Int { return nw.App.FeeMarketKeeper.GetParams(ctx).BaseFee.BigInt() }, + func() math.LegacyDec { return nw.App.FeeMarketKeeper.GetParams(ctx).BaseFee }, }, { "with BaseFee - parent block wanted the same gas as its target, with higher min gas price (ElasticityMultiplier = 2)", @@ -56,7 +55,7 @@ func TestCalculateBaseFee(t *testing.T) { 1, 50, math.LegacyNewDec(1500000000), - func() *big.Int { return nw.App.FeeMarketKeeper.GetParams(ctx).BaseFee.BigInt() }, + func() math.LegacyDec { return nw.App.FeeMarketKeeper.GetParams(ctx).BaseFee }, }, { "with BaseFee - parent block wanted more gas than its target (ElasticityMultiplier = 2)", @@ -64,7 +63,7 @@ func TestCalculateBaseFee(t *testing.T) { 1, 100, math.LegacyZeroDec(), - func() *big.Int { return initialBaseFee.Add(math.NewInt(109375000)).BigInt() }, + func() math.LegacyDec { return initialBaseFee.Add(math.LegacyNewDec(109375000)) }, }, { "with BaseFee - parent block wanted more gas than its target, with higher min gas price (ElasticityMultiplier = 2)", @@ -72,7 +71,7 @@ func TestCalculateBaseFee(t *testing.T) { 1, 100, math.LegacyNewDec(1500000000), - func() *big.Int { return initialBaseFee.Add(math.NewInt(109375000)).BigInt() }, + func() math.LegacyDec { return initialBaseFee.Add(math.LegacyNewDec(109375000)) }, }, { "with BaseFee - Parent gas wanted smaller than parent gas target (ElasticityMultiplier = 2)", @@ -80,7 +79,7 @@ func TestCalculateBaseFee(t *testing.T) { 1, 25, math.LegacyZeroDec(), - func() *big.Int { return initialBaseFee.Sub(math.NewInt(54687500)).BigInt() }, + func() math.LegacyDec { return initialBaseFee.Sub(math.LegacyNewDec(54687500)) }, }, { "with BaseFee - Parent gas wanted smaller than parent gas target, with higher min gas price (ElasticityMultiplier = 2)", @@ -88,7 +87,7 @@ func TestCalculateBaseFee(t *testing.T) { 1, 25, math.LegacyNewDec(1500000000), - func() *big.Int { return big.NewInt(1500000000) }, + func() math.LegacyDec { return math.LegacyNewDec(1500000000) }, }, } for _, tc := range testCases { @@ -121,7 +120,7 @@ func TestCalculateBaseFee(t *testing.T) { fee := nw.App.FeeMarketKeeper.CalculateBaseFee(ctx) if tc.NoBaseFee { - require.Nil(t, fee, tc.name) + require.True(t, fee.IsNil(), tc.name) } else { require.Equal(t, tc.expFee(), fee, tc.name) } diff --git a/x/feemarket/keeper/grpc_query.go b/x/feemarket/keeper/grpc_query.go index bc2f869b..6381b842 100644 --- a/x/feemarket/keeper/grpc_query.go +++ b/x/feemarket/keeper/grpc_query.go @@ -30,11 +30,7 @@ func (k Keeper) BaseFee(c context.Context, _ *types.QueryBaseFeeRequest) (*types res := &types.QueryBaseFeeResponse{} baseFee := k.GetBaseFee(ctx) - - if baseFee != nil { - aux := sdkmath.NewIntFromBigInt(baseFee) - res.BaseFee = &aux - } + res.BaseFee = &baseFee return res, nil } diff --git a/x/feemarket/keeper/grpc_query_test.go b/x/feemarket/keeper/grpc_query_test.go index 45b17d06..664ab8b6 100644 --- a/x/feemarket/keeper/grpc_query_test.go +++ b/x/feemarket/keeper/grpc_query_test.go @@ -48,11 +48,10 @@ func TestQueryParams(t *testing.T) { func TestQueryBaseFee(t *testing.T) { var ( - aux sdkmath.Int expRes *types.QueryBaseFeeResponse nw *network.UnitTestNetwork ctx sdk.Context - initialBaseFee sdkmath.Int + initialBaseFee sdkmath.LegacyDec ) testCases := []struct { @@ -70,11 +69,10 @@ func TestQueryBaseFee(t *testing.T) { { "pass - non-nil Base Fee", func() { - baseFee := sdkmath.OneInt().BigInt() + baseFee := sdkmath.LegacyNewDec(1) nw.App.FeeMarketKeeper.SetBaseFee(ctx, baseFee) - aux = sdkmath.NewIntFromBigInt(baseFee) - expRes = &types.QueryBaseFeeResponse{BaseFee: &aux} + expRes = &types.QueryBaseFeeResponse{BaseFee: &baseFee} }, true, }, @@ -85,7 +83,7 @@ func TestQueryBaseFee(t *testing.T) { nw = network.NewUnitTestNetwork() ctx = nw.GetContext() qc := nw.GetFeeMarketClient() - initialBaseFee = sdkmath.NewIntFromBigInt(nw.App.FeeMarketKeeper.GetBaseFee(ctx)) + initialBaseFee = nw.App.FeeMarketKeeper.GetBaseFee(ctx) tc.malleate() diff --git a/x/feemarket/keeper/integration_test.go b/x/feemarket/keeper/integration_test.go index 1740c0f2..c288f2c2 100644 --- a/x/feemarket/keeper/integration_test.go +++ b/x/feemarket/keeper/integration_test.go @@ -77,7 +77,7 @@ var _ = Describe("Feemarket", func() { // local min-gas-prices is 10aevmos params := fmkttypes.DefaultParams() params.MinGasPrice = math.LegacyNewDec(minGasPrices) - params.BaseFee = math.ZeroInt() + params.BaseFee = math.LegacyNewDec(0) err := testutils.UpdateFeeMarketParams( testutils.UpdateParamsInput{ Tf: s.factory, @@ -145,7 +145,7 @@ var _ = Describe("Feemarket", func() { // local min-gas-prices is 10aevmos params := fmkttypes.DefaultParams() params.MinGasPrice = math.LegacyNewDec(minGasPrices) - params.BaseFee = math.ZeroInt() + params.BaseFee = math.LegacyNewDec(0) err := testutils.UpdateFeeMarketParams( testutils.UpdateParamsInput{ @@ -210,7 +210,7 @@ var _ = Describe("Feemarket", func() { Context("with MinGasPrices (feemarket param) < min-gas-prices (local)", func() { // minGasPrices is the feemarket MinGasPrices const minGasPrices int64 = 7 - baseFee := math.NewInt(15) + baseFee := math.LegacyNewDec(15) BeforeEach(func() { // local min-gas-prices is 10aevmos @@ -259,7 +259,7 @@ var _ = Describe("Feemarket", func() { }) It("should accept transactions with gasPrice >= baseFee", func() { - gasPrice := baseFee + gasPrice := baseFee.TruncateInt() txArgs.GasPrice = &gasPrice tx, err := s.factory.BuildCosmosTx(privKey, txArgs) Expect(err).To(BeNil()) @@ -291,7 +291,7 @@ var _ = Describe("Feemarket", func() { Expect(res.Log).To(ContainSubstring("insufficient fee")) }) It("should accept transactions with gasPrice >= baseFee", func() { - gasPrice := baseFee + gasPrice := baseFee.TruncateInt() txArgs.GasPrice = &gasPrice res, err := s.factory.ExecuteCosmosTx(privKey, txArgs) Expect(err).To(BeNil()) @@ -329,7 +329,7 @@ var _ = Describe("Feemarket", func() { params := fmkttypes.DefaultParams() params.MinGasPrice = math.LegacyNewDec(minGasPrices) - params.BaseFee = math.NewInt(baseFee) + params.BaseFee = math.LegacyNewDec(baseFee) // Note that the tests run the same transactions with `gasLimit = // 200_000`. With the fee calculation `Fee = (baseFee + tip) * gasLimit`, @@ -523,7 +523,7 @@ var _ = Describe("Feemarket", func() { // local min-gas-prices is 10aevmos params := fmkttypes.DefaultParams() params.MinGasPrice = math.LegacyNewDec(minGasPrices) - params.BaseFee = math.NewInt(baseFee) + params.BaseFee = math.LegacyNewDec(baseFee) // Note that the tests run the same transactions with `gasLimit = // 200_000`. With the fee calculation `Fee = (baseFee + tip) * gasLimit`, @@ -617,7 +617,7 @@ var _ = Describe("Feemarket", func() { // local min-gas-prices is 10aevmos params := fmkttypes.DefaultParams() params.MinGasPrice = math.LegacyNewDec(minGasPrices) - params.BaseFee = math.NewInt(baseFee) + params.BaseFee = math.LegacyNewDec(baseFee) err := testutils.UpdateFeeMarketParams( testutils.UpdateParamsInput{ diff --git a/x/feemarket/keeper/keeper.go b/x/feemarket/keeper/keeper.go index 8777e60c..6a63b250 100644 --- a/x/feemarket/keeper/keeper.go +++ b/x/feemarket/keeper/keeper.go @@ -69,22 +69,13 @@ func (k Keeper) SetBlockGasWanted(ctx sdk.Context, gas uint64) { // GetBlockGasWanted returns the last block gas wanted value from the store. func (k Keeper) GetBlockGasWanted(ctx sdk.Context) uint64 { store := ctx.KVStore(k.storeKey) - bz := store.Get(types.KeyPrefixBlockGasWanted) - if len(bz) == 0 { - return 0 - } - - return sdk.BigEndianToUint64(bz) + return sdk.BigEndianToUint64(store.Get(types.KeyPrefixBlockGasWanted)) } // GetTransientGasWanted returns the gas wanted in the current block from transient store. func (k Keeper) GetTransientGasWanted(ctx sdk.Context) uint64 { store := ctx.TransientStore(k.transientKey) - bz := store.Get(types.KeyPrefixTransientBlockGasWanted) - if len(bz) == 0 { - return 0 - } - return sdk.BigEndianToUint64(bz) + return sdk.BigEndianToUint64(store.Get(types.KeyPrefixTransientBlockGasWanted)) } // SetTransientBlockGasWanted sets the block gas wanted to the transient store. diff --git a/x/feemarket/keeper/keeper_test.go b/x/feemarket/keeper/keeper_test.go index 926c05a9..53dfda7b 100644 --- a/x/feemarket/keeper/keeper_test.go +++ b/x/feemarket/keeper/keeper_test.go @@ -1,7 +1,6 @@ package keeper_test import ( - "math/big" "testing" "cosmossdk.io/math" @@ -50,14 +49,14 @@ func TestSetGetGasFee(t *testing.T) { testCases := []struct { name string malleate func() - expFee *big.Int + expFee math.LegacyDec }{ { "with last block given", func() { - nw.App.FeeMarketKeeper.SetBaseFee(ctx, math.LegacyOneDec().BigInt()) + nw.App.FeeMarketKeeper.SetBaseFee(ctx, math.LegacyOneDec()) }, - math.LegacyOneDec().BigInt(), + math.LegacyOneDec(), }, } diff --git a/x/feemarket/keeper/params.go b/x/feemarket/keeper/params.go index d70a8a09..321330e0 100644 --- a/x/feemarket/keeper/params.go +++ b/x/feemarket/keeper/params.go @@ -3,8 +3,6 @@ package keeper import ( - "math/big" - "cosmossdk.io/math" "github.com/evmos/os/x/feemarket/types" @@ -58,24 +56,28 @@ func (k Keeper) GetBaseFeeEnabled(ctx sdk.Context) bool { } // GetBaseFee gets the base fee from the store -func (k Keeper) GetBaseFee(ctx sdk.Context) *big.Int { +func (k Keeper) GetBaseFee(ctx sdk.Context) math.LegacyDec { params := k.GetParams(ctx) if params.NoBaseFee { - return nil + return math.LegacyDec{} } - baseFee := params.BaseFee.BigInt() - if baseFee == nil || baseFee.Sign() == 0 { + baseFee := params.BaseFee + if baseFee.IsNil() || baseFee.IsZero() { + bfV1 := k.GetBaseFeeV1(ctx) + if bfV1 == nil { + return math.LegacyDec{} + } // try v1 format - return k.GetBaseFeeV1(ctx) + return math.LegacyNewDecFromBigInt(bfV1) } return baseFee } // SetBaseFee set's the base fee in the store -func (k Keeper) SetBaseFee(ctx sdk.Context, baseFee *big.Int) { +func (k Keeper) SetBaseFee(ctx sdk.Context, baseFee math.LegacyDec) { params := k.GetParams(ctx) - params.BaseFee = math.NewIntFromBigInt(baseFee) + params.BaseFee = baseFee err := k.SetParams(ctx, params) if err != nil { return diff --git a/x/feemarket/module.go b/x/feemarket/module.go index 0545f67b..77fd4f9a 100644 --- a/x/feemarket/module.go +++ b/x/feemarket/module.go @@ -25,7 +25,7 @@ import ( ) // consensusVersion defines the current x/feemarket module consensus version. -const consensusVersion = 4 +const consensusVersion = 5 var ( _ module.AppModule = AppModule{} diff --git a/x/feemarket/types/feemarket.pb.go b/x/feemarket/types/feemarket.pb.go index 9a636db7..500c1421 100644 --- a/x/feemarket/types/feemarket.pb.go +++ b/x/feemarket/types/feemarket.pb.go @@ -39,7 +39,7 @@ type Params struct { // enabled. EnableHeight int64 `protobuf:"varint,5,opt,name=enable_height,json=enableHeight,proto3" json:"enable_height,omitempty"` // base_fee for EIP-1559 blocks. - BaseFee cosmossdk_io_math.Int `protobuf:"bytes,6,opt,name=base_fee,json=baseFee,proto3,customtype=cosmossdk.io/math.Int" json:"base_fee"` + BaseFee cosmossdk_io_math.LegacyDec `protobuf:"bytes,6,opt,name=base_fee,json=baseFee,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"base_fee"` // min_gas_price defines the minimum gas price value for cosmos and eth // transactions MinGasPrice cosmossdk_io_math.LegacyDec `protobuf:"bytes,7,opt,name=min_gas_price,json=minGasPrice,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"min_gas_price"` @@ -116,34 +116,34 @@ func init() { func init() { proto.RegisterFile("os/feemarket/v1/feemarket.proto", fileDescriptor_1824628138b64297) } var fileDescriptor_1824628138b64297 = []byte{ - // 428 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x92, 0xcf, 0x6a, 0xdb, 0x40, - 0x10, 0xc6, 0xbd, 0x75, 0xe2, 0x38, 0x9b, 0x9a, 0xba, 0x4b, 0x0c, 0xc2, 0x01, 0xd9, 0xa4, 0x14, - 0x44, 0x0e, 0x5a, 0x42, 0x6e, 0x85, 0x50, 0x70, 0x43, 0xff, 0x91, 0x42, 0xd0, 0xa1, 0x87, 0x5e, - 0x96, 0x95, 0x32, 0x91, 0x96, 0x68, 0x77, 0x84, 0x76, 0x63, 0xea, 0x57, 0xe8, 0xa9, 0x8f, 0xd1, - 0x63, 0x1e, 0x23, 0xc7, 0x1c, 0x4b, 0x0e, 0xa1, 0xd8, 0x87, 0xbc, 0x46, 0x89, 0x94, 0x58, 0xa6, - 0x3d, 0xe5, 0xb2, 0xcc, 0x7e, 0xdf, 0xcc, 0x8f, 0xd9, 0x9d, 0xa1, 0x23, 0xb4, 0xfc, 0x0c, 0x40, - 0xcb, 0xf2, 0x1c, 0x1c, 0x9f, 0xee, 0x37, 0x97, 0xb0, 0x28, 0xd1, 0x21, 0x7b, 0x81, 0x36, 0x6c, - 0xb4, 0xe9, 0xfe, 0xf0, 0xa5, 0xd4, 0xca, 0x20, 0xaf, 0xce, 0x3a, 0x67, 0xb8, 0x9d, 0x62, 0x8a, - 0x55, 0xc8, 0xef, 0xa3, 0x5a, 0xdd, 0xbd, 0x69, 0xd3, 0xce, 0x89, 0x2c, 0xa5, 0xb6, 0xcc, 0xa7, - 0x5b, 0x06, 0x45, 0x2c, 0x2d, 0x88, 0x33, 0x00, 0x8f, 0x8c, 0x49, 0xd0, 0x8d, 0x36, 0x0d, 0x4e, - 0xa4, 0x85, 0xf7, 0x00, 0xec, 0x90, 0xee, 0x3c, 0x9a, 0x22, 0xc9, 0xa4, 0x49, 0x41, 0x9c, 0x82, - 0x41, 0xad, 0x8c, 0x74, 0x58, 0x7a, 0xcf, 0xc6, 0x24, 0xe8, 0x45, 0x5e, 0x5c, 0x67, 0xbf, 0xab, - 0x12, 0x8e, 0x1a, 0x9f, 0x1d, 0xd0, 0x01, 0xe4, 0xd2, 0x3a, 0x95, 0x28, 0x37, 0x13, 0xfa, 0x22, - 0x77, 0xaa, 0xc8, 0x15, 0x94, 0x5e, 0xbb, 0x2a, 0xdc, 0x6e, 0xcc, 0x2f, 0x4b, 0x8f, 0xbd, 0xa2, - 0x3d, 0x30, 0x32, 0xce, 0x41, 0x64, 0xa0, 0xd2, 0xcc, 0x79, 0xeb, 0x63, 0x12, 0xb4, 0xa3, 0xe7, - 0xb5, 0xf8, 0xb1, 0xd2, 0xd8, 0x21, 0xed, 0x2e, 0xbb, 0xee, 0x8c, 0x49, 0xb0, 0x39, 0xd9, 0xbd, - 0xba, 0x1d, 0xb5, 0x6e, 0x6e, 0x47, 0x83, 0x04, 0xad, 0x46, 0x6b, 0x4f, 0xcf, 0x43, 0x85, 0x5c, - 0x4b, 0x97, 0x85, 0x9f, 0x8c, 0xfb, 0x75, 0x77, 0xb9, 0x47, 0xa2, 0x8d, 0x87, 0x4e, 0xd9, 0x31, - 0xed, 0x69, 0x65, 0x44, 0x2a, 0xad, 0x28, 0x4a, 0x95, 0x80, 0xb7, 0x51, 0x31, 0x82, 0x07, 0xc6, - 0xce, 0xff, 0x8c, 0x63, 0x48, 0x65, 0x32, 0x3b, 0x82, 0xa4, 0x26, 0x6d, 0x69, 0x65, 0x3e, 0x48, - 0x7b, 0x72, 0x5f, 0xcc, 0xbe, 0x52, 0xf6, 0x48, 0x5b, 0x79, 0x63, 0xf7, 0x89, 0xc8, 0x7e, 0x8d, - 0x6c, 0x7e, 0xe2, 0xcd, 0xf0, 0xc7, 0xdd, 0xe5, 0xde, 0x00, 0x2d, 0xff, 0xbe, 0xb2, 0x0a, 0xf5, - 0xe4, 0x3e, 0xaf, 0x75, 0xd7, 0xfa, 0xeb, 0x51, 0x5f, 0x19, 0xe5, 0x94, 0xcc, 0x97, 0x23, 0x9c, - 0xbc, 0xbd, 0x9a, 0xfb, 0xe4, 0x7a, 0xee, 0x93, 0x3f, 0x73, 0x9f, 0xfc, 0x5c, 0xf8, 0xad, 0xeb, - 0x85, 0xdf, 0xfa, 0xbd, 0xf0, 0x5b, 0xdf, 0x5e, 0xa7, 0xca, 0x65, 0x17, 0x71, 0x98, 0xa0, 0xe6, - 0x30, 0xd5, 0x68, 0xf9, 0x3f, 0x64, 0x37, 0x2b, 0xc0, 0xc6, 0x9d, 0x6a, 0x49, 0x0e, 0xfe, 0x06, - 0x00, 0x00, 0xff, 0xff, 0x50, 0x16, 0x20, 0x30, 0x81, 0x02, 0x00, 0x00, + // 418 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x92, 0xc1, 0x6a, 0xdc, 0x30, + 0x10, 0x86, 0x57, 0xdd, 0x64, 0xe3, 0x28, 0x5d, 0xba, 0x15, 0x09, 0x98, 0x0d, 0x78, 0x4d, 0x4b, + 0xc1, 0xe4, 0x60, 0x11, 0x72, 0x2b, 0x94, 0xc2, 0x26, 0xb4, 0xa5, 0xa4, 0x10, 0x7c, 0xe8, 0xa1, + 0x17, 0x21, 0x3b, 0x13, 0x5b, 0xc4, 0xd2, 0x18, 0x4b, 0x59, 0xba, 0xaf, 0xd0, 0x53, 0x1f, 0xa3, + 0xc7, 0x3c, 0x46, 0x8e, 0x39, 0x96, 0x1e, 0x42, 0xd8, 0x3d, 0xe4, 0x35, 0x4a, 0xec, 0x66, 0x1d, + 0x7a, 0xcb, 0x45, 0x8c, 0xfe, 0x7f, 0xe6, 0x63, 0xa4, 0x19, 0x3a, 0x41, 0xcb, 0xcf, 0x00, 0xb4, + 0xac, 0xcf, 0xc1, 0xf1, 0xd9, 0x7e, 0x77, 0x89, 0xab, 0x1a, 0x1d, 0xb2, 0x17, 0x68, 0xe3, 0x4e, + 0x9b, 0xed, 0x8f, 0x5f, 0x4a, 0xad, 0x0c, 0xf2, 0xe6, 0x6c, 0x73, 0xc6, 0xdb, 0x39, 0xe6, 0xd8, + 0x84, 0xfc, 0x3e, 0x6a, 0xd5, 0x57, 0xb7, 0x7d, 0x3a, 0x38, 0x91, 0xb5, 0xd4, 0x96, 0x05, 0x74, + 0xcb, 0xa0, 0x48, 0xa5, 0x05, 0x71, 0x06, 0xe0, 0x93, 0x90, 0x44, 0x5e, 0xb2, 0x69, 0x70, 0x2a, + 0x2d, 0x7c, 0x00, 0x60, 0xef, 0xe8, 0xee, 0x83, 0x29, 0xb2, 0x42, 0x9a, 0x1c, 0xc4, 0x29, 0x18, + 0xd4, 0xca, 0x48, 0x87, 0xb5, 0xff, 0x2c, 0x24, 0xd1, 0x30, 0xf1, 0xd3, 0x36, 0xfb, 0xb0, 0x49, + 0x38, 0xea, 0x7c, 0x76, 0x40, 0x77, 0xa0, 0x94, 0xd6, 0xa9, 0x4c, 0xb9, 0xb9, 0xd0, 0x17, 0xa5, + 0x53, 0x55, 0xa9, 0xa0, 0xf6, 0xfb, 0x4d, 0xe1, 0x76, 0x67, 0x7e, 0x59, 0x79, 0xec, 0x35, 0x1d, + 0x82, 0x91, 0x69, 0x09, 0xa2, 0x00, 0x95, 0x17, 0xce, 0x5f, 0x0f, 0x49, 0xd4, 0x4f, 0x9e, 0xb7, + 0xe2, 0xa7, 0x46, 0x63, 0x87, 0xd4, 0x5b, 0x75, 0x3d, 0x08, 0x49, 0xb4, 0x39, 0x8d, 0xae, 0x6e, + 0x26, 0xbd, 0x3f, 0x37, 0x93, 0xdd, 0x0c, 0xad, 0x46, 0x6b, 0x4f, 0xcf, 0x63, 0x85, 0x5c, 0x4b, + 0x57, 0xc4, 0xc7, 0x90, 0xcb, 0x6c, 0x7e, 0x04, 0xd9, 0xaf, 0xbb, 0xcb, 0x3d, 0x92, 0x6c, 0xfc, + 0xeb, 0x97, 0x1d, 0xd3, 0xa1, 0x56, 0x46, 0xe4, 0xd2, 0x8a, 0xaa, 0x56, 0x19, 0xf8, 0x1b, 0x4f, + 0x24, 0x6d, 0x69, 0x65, 0x3e, 0x4a, 0x7b, 0x72, 0x5f, 0xcc, 0xbe, 0x52, 0xf6, 0x40, 0x7b, 0xf4, + 0x52, 0xef, 0x89, 0xc8, 0x51, 0x8b, 0xec, 0xfe, 0xe3, 0xed, 0xf8, 0xc7, 0xdd, 0xe5, 0xde, 0x0e, + 0x5a, 0xfe, 0xfd, 0xd1, 0x42, 0xb4, 0xf3, 0xfb, 0xbc, 0xe6, 0xad, 0x8d, 0xd6, 0x93, 0x91, 0x32, + 0xca, 0x29, 0x59, 0xae, 0x06, 0x39, 0x7d, 0x7f, 0xb5, 0x08, 0xc8, 0xf5, 0x22, 0x20, 0xb7, 0x8b, + 0x80, 0xfc, 0x5c, 0x06, 0xbd, 0xeb, 0x65, 0xd0, 0xfb, 0xbd, 0x0c, 0x7a, 0xdf, 0xde, 0xe4, 0xca, + 0x15, 0x17, 0x69, 0x9c, 0xa1, 0xe6, 0x30, 0xd3, 0x68, 0xf9, 0x7f, 0x64, 0x37, 0xaf, 0xc0, 0xa6, + 0x83, 0x66, 0x55, 0x0e, 0xfe, 0x06, 0x00, 0x00, 0xff, 0xff, 0x58, 0xc4, 0x49, 0x3d, 0x87, 0x02, + 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/feemarket/types/genesis_test.go b/x/feemarket/types/genesis_test.go index 843f70fc..e1ec275f 100644 --- a/x/feemarket/types/genesis_test.go +++ b/x/feemarket/types/genesis_test.go @@ -52,7 +52,6 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { } for _, tc := range testCases { - tc := tc err := tc.genState.Validate() if tc.expPass { suite.Require().NoError(err, tc.name) diff --git a/x/feemarket/types/params.go b/x/feemarket/types/params.go index 115c3b3e..a1475598 100644 --- a/x/feemarket/types/params.go +++ b/x/feemarket/types/params.go @@ -11,6 +11,8 @@ import ( ) var ( + // DefaultBaseFee for the Evmos chain + DefaultBaseFee = math.LegacyNewDec(1_000_000_000) // DefaultMinGasMultiplier is 0.5 or 50% DefaultMinGasMultiplier = math.LegacyNewDecWithPrec(50, 2) // DefaultMinGasPrice is 0 (i.e disabled) @@ -56,7 +58,7 @@ func NewParams( noBaseFee bool, baseFeeChangeDenom, elasticityMultiplier uint32, - baseFee uint64, + baseFee math.LegacyDec, enableHeight int64, minGasPrice math.LegacyDec, minGasPriceMultiplier math.LegacyDec, @@ -65,7 +67,7 @@ func NewParams( NoBaseFee: noBaseFee, BaseFeeChangeDenominator: baseFeeChangeDenom, ElasticityMultiplier: elasticityMultiplier, - BaseFee: math.NewIntFromUint64(baseFee), + BaseFee: baseFee, EnableHeight: enableHeight, MinGasPrice: minGasPrice, MinGasMultiplier: minGasPriceMultiplier, @@ -78,7 +80,7 @@ func DefaultParams() Params { NoBaseFee: DefaultNoBaseFee, BaseFeeChangeDenominator: params.BaseFeeChangeDenominator, ElasticityMultiplier: params.ElasticityMultiplier, - BaseFee: math.NewIntFromUint64(params.InitialBaseFee), + BaseFee: DefaultBaseFee, EnableHeight: DefaultEnableHeight, MinGasPrice: DefaultMinGasPrice, MinGasMultiplier: DefaultMinGasMultiplier, diff --git a/x/feemarket/types/params_test.go b/x/feemarket/types/params_test.go index a47241de..00534c9c 100644 --- a/x/feemarket/types/params_test.go +++ b/x/feemarket/types/params_test.go @@ -3,7 +3,7 @@ package types import ( "testing" - sdkmath "cosmossdk.io/math" + "cosmossdk.io/math" "github.com/stretchr/testify/suite" ) @@ -24,7 +24,7 @@ func (suite *ParamsTestSuite) TestParamsValidate() { {"default", DefaultParams(), false}, { "valid", - NewParams(true, 7, 3, 2000000000, int64(544435345345435345), sdkmath.LegacyNewDecWithPrec(20, 4), DefaultMinGasMultiplier), + NewParams(true, 7, 3, math.LegacyNewDec(2000000000), int64(544435345345435345), math.LegacyNewDecWithPrec(20, 4), DefaultMinGasMultiplier), false, }, { @@ -34,27 +34,27 @@ func (suite *ParamsTestSuite) TestParamsValidate() { }, { "base fee change denominator is 0 ", - NewParams(true, 0, 3, 2000000000, int64(544435345345435345), sdkmath.LegacyNewDecWithPrec(20, 4), DefaultMinGasMultiplier), + NewParams(true, 0, 3, math.LegacyNewDec(2000000000), int64(544435345345435345), math.LegacyNewDecWithPrec(20, 4), DefaultMinGasMultiplier), true, }, { "invalid: min gas price negative", - NewParams(true, 7, 3, 2000000000, int64(544435345345435345), sdkmath.LegacyNewDecFromInt(sdkmath.NewInt(-1)), DefaultMinGasMultiplier), + NewParams(true, 7, 3, math.LegacyNewDec(2000000000), int64(544435345345435345), math.LegacyNewDecFromInt(math.NewInt(-1)), DefaultMinGasMultiplier), true, }, { "valid: min gas multiplier zero", - NewParams(true, 7, 3, 2000000000, int64(544435345345435345), DefaultMinGasPrice, sdkmath.LegacyZeroDec()), + NewParams(true, 7, 3, math.LegacyNewDec(2000000000), int64(544435345345435345), DefaultMinGasPrice, math.LegacyZeroDec()), false, }, { "invalid: min gas multiplier is negative", - NewParams(true, 7, 3, 2000000000, int64(544435345345435345), DefaultMinGasPrice, sdkmath.LegacyNewDecWithPrec(-5, 1)), + NewParams(true, 7, 3, math.LegacyNewDec(2000000000), int64(544435345345435345), DefaultMinGasPrice, math.LegacyNewDecWithPrec(-5, 1)), true, }, { "invalid: min gas multiplier bigger than 1", - NewParams(true, 7, 3, 2000000000, int64(544435345345435345), sdkmath.LegacyNewDecWithPrec(20, 4), sdkmath.LegacyNewDec(2)), + NewParams(true, 7, 3, math.LegacyNewDec(2000000000), int64(544435345345435345), math.LegacyNewDecWithPrec(20, 4), math.LegacyNewDec(2)), true, }, } @@ -80,14 +80,14 @@ func (suite *ParamsTestSuite) TestParamsValidatePriv() { suite.Require().NoError(validateElasticityMultiplier(uint32(2))) suite.Require().Error(validateBaseFee("")) suite.Require().Error(validateBaseFee(int64(2000000000))) - suite.Require().Error(validateBaseFee(sdkmath.NewInt(-2000000000))) - suite.Require().NoError(validateBaseFee(sdkmath.NewInt(2000000000))) + suite.Require().Error(validateBaseFee(math.NewInt(-2000000000))) + suite.Require().NoError(validateBaseFee(math.NewInt(2000000000))) suite.Require().Error(validateEnableHeight("")) suite.Require().Error(validateEnableHeight(int64(-544435345345435345))) suite.Require().NoError(validateEnableHeight(int64(544435345345435345))) - suite.Require().Error(validateMinGasPrice(sdkmath.LegacyDec{})) - suite.Require().Error(validateMinGasMultiplier(sdkmath.LegacyNewDec(-5))) - suite.Require().Error(validateMinGasMultiplier(sdkmath.LegacyDec{})) + suite.Require().Error(validateMinGasPrice(math.LegacyDec{})) + suite.Require().Error(validateMinGasMultiplier(math.LegacyNewDec(-5))) + suite.Require().Error(validateMinGasMultiplier(math.LegacyDec{})) suite.Require().Error(validateMinGasMultiplier("")) } @@ -98,11 +98,11 @@ func (suite *ParamsTestSuite) TestParamsValidateMinGasPrice() { expError bool }{ {"default", DefaultParams().MinGasPrice, false}, - {"valid", sdkmath.LegacyNewDecFromInt(sdkmath.NewInt(1)), false}, - {"valid", sdkmath.LegacyNewDecFromInt(sdkmath.NewInt(1)), false}, + {"valid", math.LegacyNewDecFromInt(math.NewInt(1)), false}, + {"valid", math.LegacyNewDecFromInt(math.NewInt(1)), false}, {"invalid - wrong type - bool", false, true}, {"invalid - is nil", nil, true}, - {"invalid - is negative", sdkmath.LegacyNewDecFromInt(sdkmath.NewInt(-1)), true}, + {"invalid - is negative", math.LegacyNewDecFromInt(math.NewInt(-1)), true}, } for _, tc := range testCases { diff --git a/x/feemarket/types/query.pb.go b/x/feemarket/types/query.pb.go index 034d698b..8c9303bb 100644 --- a/x/feemarket/types/query.pb.go +++ b/x/feemarket/types/query.pb.go @@ -155,7 +155,7 @@ var xxx_messageInfo_QueryBaseFeeRequest proto.InternalMessageInfo // QueryBaseFeeResponse returns the EIP1559 base fee. type QueryBaseFeeResponse struct { // base_fee is the EIP1559 base fee - BaseFee *cosmossdk_io_math.Int `protobuf:"bytes,1,opt,name=base_fee,json=baseFee,proto3,customtype=cosmossdk.io/math.Int" json:"base_fee,omitempty"` + BaseFee *cosmossdk_io_math.LegacyDec `protobuf:"bytes,1,opt,name=base_fee,json=baseFee,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"base_fee,omitempty"` } func (m *QueryBaseFeeResponse) Reset() { *m = QueryBaseFeeResponse{} } @@ -287,35 +287,35 @@ func init() { func init() { proto.RegisterFile("os/feemarket/v1/query.proto", fileDescriptor_133bffc3ae615960) } var fileDescriptor_133bffc3ae615960 = []byte{ - // 446 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x92, 0xb1, 0x6e, 0xd4, 0x40, - 0x10, 0x86, 0xed, 0x44, 0x5c, 0x92, 0xa5, 0x00, 0x96, 0x3b, 0xc2, 0x39, 0x91, 0x0d, 0x86, 0x20, - 0xa0, 0xd8, 0x55, 0x02, 0x15, 0x0d, 0x92, 0x0b, 0x10, 0x12, 0x05, 0x71, 0x49, 0x13, 0xad, 0x8f, - 0x89, 0x63, 0x5d, 0xec, 0x71, 0xbc, 0x7b, 0x27, 0xae, 0xa0, 0xe1, 0x09, 0x90, 0x78, 0x09, 0x4a, - 0x1e, 0x23, 0x65, 0x24, 0x1a, 0x44, 0x11, 0xa1, 0x3b, 0x24, 0x1e, 0x81, 0x16, 0x79, 0xbd, 0x0e, - 0xd8, 0x56, 0x92, 0xc6, 0x1a, 0xcd, 0xfe, 0xf3, 0x7f, 0x3b, 0xbf, 0x97, 0x6c, 0xa0, 0xe4, 0xfb, - 0x00, 0xa9, 0x28, 0xc6, 0xa0, 0xf8, 0x74, 0x9b, 0x1f, 0x4d, 0xa0, 0x98, 0xb1, 0xbc, 0x40, 0x85, - 0xf4, 0x1a, 0x4a, 0x76, 0x76, 0xc8, 0xa6, 0xdb, 0xce, 0x0d, 0x91, 0x26, 0x19, 0x72, 0xfd, 0xad, - 0x34, 0x4e, 0x3f, 0xc6, 0x18, 0x75, 0xc9, 0xcb, 0xca, 0x74, 0x37, 0x63, 0xc4, 0xf8, 0x10, 0xb8, - 0xc8, 0x13, 0x2e, 0xb2, 0x0c, 0x95, 0x50, 0x09, 0x66, 0xd2, 0x9c, 0x7a, 0x6d, 0xe8, 0x3f, 0x88, - 0x16, 0xf8, 0x7d, 0x42, 0x77, 0xcb, 0x7b, 0xbc, 0x11, 0x85, 0x48, 0x65, 0x08, 0x47, 0x13, 0x90, - 0xca, 0xdf, 0x25, 0x37, 0x1b, 0x5d, 0x99, 0x63, 0x26, 0x81, 0x3e, 0x23, 0xbd, 0x5c, 0x77, 0x6e, - 0xdb, 0x77, 0xec, 0x87, 0x57, 0x77, 0xd6, 0x59, 0xeb, 0xda, 0xac, 0x1a, 0x08, 0xd6, 0x8e, 0x4f, - 0x3d, 0xeb, 0xcb, 0xef, 0xaf, 0x8f, 0xed, 0xd0, 0x4c, 0xf8, 0x03, 0x63, 0x19, 0x08, 0x09, 0x2f, - 0x00, 0x6a, 0xd2, 0x6b, 0xd2, 0x6f, 0xb6, 0x0d, 0xea, 0x29, 0x59, 0x8d, 0x84, 0x84, 0xbd, 0x7d, - 0x00, 0x0d, 0x5b, 0x0b, 0x86, 0x3f, 0x4e, 0xbd, 0xc1, 0x08, 0x65, 0x8a, 0x52, 0xbe, 0x1b, 0xb3, - 0x04, 0x79, 0x2a, 0xd4, 0x01, 0x7b, 0x95, 0xa9, 0x70, 0x25, 0xaa, 0xa6, 0xfd, 0x5b, 0xb5, 0xdb, - 0x21, 0x8e, 0xc6, 0x2f, 0xc5, 0xd9, 0x3e, 0x8f, 0xc8, 0xa0, 0xd5, 0x37, 0x98, 0xeb, 0x64, 0x39, - 0x16, 0xd5, 0x3a, 0xcb, 0x61, 0x59, 0xee, 0xfc, 0x59, 0x22, 0x57, 0xb4, 0x96, 0x2a, 0xd2, 0xab, - 0xd6, 0xa1, 0xf7, 0x3a, 0x7b, 0x76, 0x33, 0x73, 0xee, 0x5f, 0x2c, 0xaa, 0x80, 0xbe, 0xf7, 0xf1, - 0xdb, 0xaf, 0xcf, 0x4b, 0x43, 0xba, 0xce, 0xdb, 0x7f, 0xa6, 0xca, 0x89, 0xce, 0xc8, 0x8a, 0xc9, - 0x82, 0x9e, 0xe3, 0xd8, 0x4c, 0xd0, 0xd9, 0xba, 0x44, 0x65, 0xc0, 0x77, 0x35, 0x78, 0x83, 0x0e, - 0x3b, 0xe0, 0x3a, 0x67, 0xfa, 0x81, 0xac, 0xd6, 0x01, 0xd1, 0xf3, 0x5c, 0x9b, 0xc1, 0x3a, 0x0f, - 0x2e, 0x93, 0x19, 0xba, 0xaf, 0xe9, 0x9b, 0xd4, 0xe9, 0xd2, 0x4b, 0xe9, 0x5e, 0x2c, 0x64, 0xf0, - 0xfc, 0x78, 0xee, 0xda, 0x27, 0x73, 0xd7, 0xfe, 0x39, 0x77, 0xed, 0x4f, 0x0b, 0xd7, 0x3a, 0x59, - 0xb8, 0xd6, 0xf7, 0x85, 0x6b, 0xbd, 0xdd, 0x8a, 0x13, 0x75, 0x30, 0x89, 0xd8, 0x08, 0x53, 0x0e, - 0xd3, 0x14, 0x65, 0xe9, 0xf2, 0xfe, 0x3f, 0x1f, 0x35, 0xcb, 0x41, 0x46, 0x3d, 0xfd, 0xa4, 0x9f, - 0xfc, 0x0d, 0x00, 0x00, 0xff, 0xff, 0x09, 0xd3, 0xe9, 0x6f, 0x6a, 0x03, 0x00, 0x00, + // 448 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x92, 0x31, 0x6f, 0xd3, 0x40, + 0x18, 0x86, 0xe3, 0x56, 0xa4, 0xed, 0x31, 0x00, 0x47, 0x4a, 0xa9, 0x53, 0xd9, 0x60, 0x28, 0x02, + 0x86, 0x3b, 0xb5, 0x6c, 0x2c, 0x48, 0x11, 0x82, 0x85, 0x81, 0x7a, 0x64, 0xa9, 0x2e, 0xe6, 0xeb, + 0xd5, 0x4a, 0xed, 0xcf, 0xcd, 0x5d, 0x22, 0x3c, 0xb0, 0xf0, 0x0b, 0x90, 0xf8, 0x13, 0x8c, 0xfc, + 0x8c, 0x8e, 0x95, 0x58, 0x10, 0x43, 0x85, 0x12, 0x24, 0x7e, 0x02, 0x2b, 0xf2, 0xf9, 0x1c, 0xb0, + 0xad, 0x92, 0x25, 0xfa, 0xf4, 0xde, 0x7b, 0xef, 0x73, 0xdf, 0x1b, 0x93, 0x3e, 0x2a, 0x7e, 0x04, + 0x90, 0x88, 0xf1, 0x08, 0x34, 0x9f, 0xee, 0xf1, 0xd3, 0x09, 0x8c, 0x73, 0x96, 0x8d, 0x51, 0x23, + 0xbd, 0x86, 0x8a, 0x2d, 0x0e, 0xd9, 0x74, 0xcf, 0xbd, 0x21, 0x92, 0x38, 0x45, 0x6e, 0x7e, 0x4b, + 0x8f, 0xdb, 0x93, 0x28, 0xd1, 0x8c, 0xbc, 0x98, 0xac, 0xba, 0x23, 0x11, 0xe5, 0x09, 0x70, 0x91, + 0xc5, 0x5c, 0xa4, 0x29, 0x6a, 0xa1, 0x63, 0x4c, 0x95, 0x3d, 0xf5, 0x9b, 0xd0, 0xbf, 0x10, 0x63, + 0x08, 0x7a, 0x84, 0x1e, 0x14, 0xef, 0x78, 0x2d, 0xc6, 0x22, 0x51, 0x21, 0x9c, 0x4e, 0x40, 0xe9, + 0xe0, 0x80, 0xdc, 0xac, 0xa9, 0x2a, 0xc3, 0x54, 0x01, 0x7d, 0x4a, 0xba, 0x99, 0x51, 0x6e, 0x3b, + 0x77, 0x9c, 0x87, 0x57, 0xf7, 0xb7, 0x58, 0xe3, 0xd9, 0xac, 0xbc, 0x30, 0xd8, 0x38, 0xbb, 0xf0, + 0x3b, 0x9f, 0x7f, 0x7d, 0x79, 0xec, 0x84, 0xf6, 0x46, 0xb0, 0x69, 0x23, 0x07, 0x42, 0xc1, 0x0b, + 0x80, 0x8a, 0x14, 0x92, 0x5e, 0x5d, 0x5e, 0xa0, 0xd6, 0x87, 0x42, 0xc1, 0xe1, 0x11, 0x80, 0x81, + 0x6d, 0x0c, 0xfc, 0xef, 0x17, 0x7e, 0x3f, 0x42, 0x95, 0xa0, 0x52, 0x6f, 0x47, 0x2c, 0x46, 0x9e, + 0x08, 0x7d, 0xcc, 0x5e, 0x81, 0x14, 0x51, 0xfe, 0x1c, 0xa2, 0x70, 0x6d, 0x58, 0x66, 0x04, 0xb7, + 0xaa, 0xcc, 0x13, 0x8c, 0x46, 0x2f, 0xc5, 0x62, 0xab, 0x47, 0x64, 0xb3, 0xa1, 0x5b, 0xd8, 0x75, + 0xb2, 0x2a, 0x45, 0xb9, 0xd4, 0x6a, 0x58, 0x8c, 0xfb, 0xbf, 0x57, 0xc8, 0x15, 0xe3, 0xa5, 0x9a, + 0x74, 0xcb, 0xa5, 0xe8, 0xbd, 0xd6, 0xb6, 0xed, 0xe6, 0xdc, 0xfb, 0xff, 0x37, 0x95, 0xc0, 0xc0, + 0xff, 0xf0, 0xf5, 0xe7, 0xa7, 0x95, 0x6d, 0xba, 0xc5, 0x9b, 0xff, 0x4f, 0xd9, 0x16, 0xcd, 0xc9, + 0x9a, 0x6d, 0x84, 0x5e, 0x92, 0x58, 0xef, 0xd1, 0xdd, 0x5d, 0xe2, 0xb2, 0xe0, 0xbb, 0x06, 0xdc, + 0xa7, 0xdb, 0x2d, 0x70, 0xd5, 0x36, 0x7d, 0x4f, 0xd6, 0xab, 0x82, 0xe8, 0x65, 0xa9, 0xf5, 0x62, + 0xdd, 0x07, 0xcb, 0x6c, 0x96, 0x1e, 0x18, 0xfa, 0x0e, 0x75, 0xdb, 0xf4, 0xc2, 0x7a, 0x28, 0x85, + 0x1a, 0x3c, 0x3b, 0x9b, 0x79, 0xce, 0xf9, 0xcc, 0x73, 0x7e, 0xcc, 0x3c, 0xe7, 0xe3, 0xdc, 0xeb, + 0x9c, 0xcf, 0xbd, 0xce, 0xb7, 0xb9, 0xd7, 0x79, 0xb3, 0x2b, 0x63, 0x7d, 0x3c, 0x19, 0xb2, 0x08, + 0x13, 0x0e, 0xd3, 0x04, 0x55, 0x91, 0xf2, 0xee, 0x9f, 0x1c, 0x9d, 0x67, 0xa0, 0x86, 0x5d, 0xf3, + 0x61, 0x3f, 0xf9, 0x13, 0x00, 0x00, 0xff, 0xff, 0x85, 0x30, 0x7a, 0x34, 0x70, 0x03, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -963,7 +963,7 @@ func (m *QueryBaseFeeResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - var v cosmossdk_io_math.Int + var v cosmossdk_io_math.LegacyDec m.BaseFee = &v if err := m.BaseFee.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err diff --git a/x/ibc/transfer/keeper/msg_server_test.go b/x/ibc/transfer/keeper/msg_server_test.go index 39cbbfdc..edf80b16 100644 --- a/x/ibc/transfer/keeper/msg_server_test.go +++ b/x/ibc/transfer/keeper/msg_server_test.go @@ -13,6 +13,7 @@ import ( channeltypes "github.com/cosmos/ibc-go/v8/modules/core/04-channel/types" "github.com/evmos/os/testutil/integration/os/keyring" testutils "github.com/evmos/os/testutil/integration/os/utils" + evmtypes "github.com/evmos/os/x/evm/types" "github.com/evmos/os/x/ibc/transfer/keeper" "github.com/stretchr/testify/mock" ) @@ -37,7 +38,7 @@ func (suite *KeeperTestSuite) TestTransfer() { { "pass - no token pair", func() *types.MsgTransfer { - transferMsg := types.NewMsgTransfer("transfer", "channel-0", sdk.NewCoin("aevmos", math.NewInt(10)), sender.AccAddr.String(), "", timeoutHeight, 0, "") + transferMsg := types.NewMsgTransfer("transfer", "channel-0", sdk.NewCoin(evmtypes.GetEVMCoinDenom(), math.NewInt(10)), sender.AccAddr.String(), "", timeoutHeight, 0, "") return transferMsg }, true,