From b86301f2a98debd05c130f7dfd0a6ccf401bb05c Mon Sep 17 00:00:00 2001 From: crypto-facs <84574577+crypto-facs@users.noreply.github.com> Date: Fri, 8 Jul 2022 06:58:04 -0400 Subject: [PATCH 01/19] imp(deps): Geth upgrade v1.10.19 (#1159) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * upgrade geth and fix build * add support for * update EIPs * fix keeper tests * update traceTx function with latest geth changes * remove unnecessary comments * fix tests * update proto * add migrations * update module version * fix grpc test * fix lint * fix lint * update changelog * fix typo * remove unnecessary format logs * Update proto/ethermint/evm/v1/evm.proto Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com> * remove debug true on default * update comments * fixing ante tests * fixed cycle imports on migrate_test * fix wrong naming * update comment Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com> --- CHANGELOG.md | 6 + app/ante/utils_test.go | 3 +- docs/api/proto-docs.md | 3 +- go.mod | 30 +- go.sum | 93 +- proto/ethermint/evm/v1/evm.proto | 15 +- rpc/types/block.go | 11 +- x/evm/keeper/grpc_query.go | 111 +- x/evm/keeper/grpc_query_test.go | 16 +- x/evm/keeper/keeper_test.go | 3 +- x/evm/keeper/migrations.go | 16 + x/evm/keeper/state_transition.go | 2 +- x/evm/migrations/v2/types/chain_config.go | 165 + x/evm/migrations/v3/migrate.go | 25 + x/evm/migrations/v3/migrate_test.go | 57 + x/evm/migrations/v3/types/chain_config.go | 164 + x/evm/migrations/v3/types/evm.pb.go | 3812 +++++++++++++++++++++ x/evm/migrations/v3/types/params.go | 150 + x/evm/module.go | 12 +- x/evm/types/chain_config.go | 16 +- x/evm/types/evm.pb.go | 272 +- x/evm/types/tracer.go | 84 +- x/evm/types/tracer_test.go | 75 - 23 files changed, 4706 insertions(+), 435 deletions(-) create mode 100644 x/evm/migrations/v2/types/chain_config.go create mode 100644 x/evm/migrations/v3/migrate.go create mode 100644 x/evm/migrations/v3/migrate_test.go create mode 100644 x/evm/migrations/v3/types/chain_config.go create mode 100644 x/evm/migrations/v3/types/evm.pb.go create mode 100644 x/evm/migrations/v3/types/params.go diff --git a/CHANGELOG.md b/CHANGELOG.md index 2a58d75fb8..db227b3039 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -36,6 +36,12 @@ Ref: https://keepachangelog.com/en/1.0.0/ # Changelog +## Unreleased + +### State Machine Breaking +* (deps) [\#1159](https://github.com/evmos/ethermint/pull/1159) Bump Geth version to `v1.10.19`. + + ## [v0.16.0] - 2022-06-06 ### State Machine Breaking diff --git a/app/ante/utils_test.go b/app/ante/utils_test.go index 47618efa23..5b8ccd4b86 100644 --- a/app/ante/utils_test.go +++ b/app/ante/utils_test.go @@ -80,7 +80,8 @@ func (suite *AnteTestSuite) SetupTest() { maxInt := sdk.NewInt(math.MaxInt64) evmGenesis.Params.ChainConfig.LondonBlock = &maxInt evmGenesis.Params.ChainConfig.ArrowGlacierBlock = &maxInt - evmGenesis.Params.ChainConfig.MergeForkBlock = &maxInt + evmGenesis.Params.ChainConfig.GrayGlacierBlock = &maxInt + evmGenesis.Params.ChainConfig.MergeNetsplitBlock = &maxInt } if suite.evmParamsOption != nil { suite.evmParamsOption(&evmGenesis.Params) diff --git a/docs/api/proto-docs.md b/docs/api/proto-docs.md index c509465827..4960412813 100644 --- a/docs/api/proto-docs.md +++ b/docs/api/proto-docs.md @@ -182,7 +182,8 @@ instead of *big.Int. | `berlin_block` | [string](#string) | | Berlin switch block (nil = no fork, 0 = already on berlin) | | `london_block` | [string](#string) | | London switch block (nil = no fork, 0 = already on london) | | `arrow_glacier_block` | [string](#string) | | Eip-4345 (bomb delay) switch block (nil = no fork, 0 = already activated) | -| `merge_fork_block` | [string](#string) | | EIP-3675 (TheMerge) switch block (nil = no fork, 0 = already in merge proceedings) | +| `gray_glacier_block` | [string](#string) | | EIP-5133 (bomb delay) switch block (nil = no fork, 0 = already activated) | +| `merge_netsplit_block` | [string](#string) | | Virtual fork after The Merge to use as a network splitter | diff --git a/go.mod b/go.mod index c0413b1f66..5d8af3479c 100644 --- a/go.mod +++ b/go.mod @@ -10,13 +10,12 @@ require ( github.com/cosmos/go-bip39 v1.0.0 github.com/cosmos/ibc-go/v3 v3.0.0 github.com/davecgh/go-spew v1.1.1 - github.com/ethereum/go-ethereum v1.10.16 + github.com/ethereum/go-ethereum v1.10.19 github.com/gogo/protobuf v1.3.3 github.com/golang/protobuf v1.5.2 github.com/gorilla/mux v1.8.0 github.com/gorilla/websocket v1.5.0 github.com/grpc-ecosystem/grpc-gateway v1.16.0 - github.com/holiman/uint256 v1.2.0 github.com/improbable-eng/grpc-web v0.15.0 github.com/miguelmota/go-ethereum-hdwallet v0.1.1 github.com/onsi/ginkgo/v2 v2.1.4 @@ -34,10 +33,9 @@ require ( github.com/tendermint/tendermint v0.34.19 github.com/tendermint/tm-db v0.6.7 github.com/tyler-smith/go-bip39 v1.1.0 - go.etcd.io/bbolt v1.3.6 // indirect - golang.org/x/crypto v0.0.0-20220518034528-6f7dac969898 // indirect - google.golang.org/genproto v0.0.0-20220519153652-3a47de7e79bd - google.golang.org/grpc v1.46.2 + golang.org/x/text v0.3.7 + google.golang.org/genproto v0.0.0-20220628213854-d9e0b6570c03 + google.golang.org/grpc v1.47.0 google.golang.org/protobuf v1.28.0 gopkg.in/yaml.v2 v2.4.0 ) @@ -55,6 +53,7 @@ require ( github.com/benbjohnson/clock v1.3.0 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bgentry/speakeasy v0.1.0 // indirect + github.com/btcsuite/btcd/btcec/v2 v2.2.0 // indirect github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 // indirect github.com/celestiaorg/go-cnc v0.1.0 // indirect github.com/cenkalti/backoff/v4 v4.1.1 // indirect @@ -73,12 +72,14 @@ require ( github.com/danieljoos/wincred v1.0.2 // indirect github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c // indirect github.com/deckarep/golang-set v1.8.0 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect github.com/dgraph-io/badger/v2 v2.2007.2 // indirect github.com/dgraph-io/badger/v3 v3.2103.2 // indirect github.com/dgraph-io/ristretto v0.1.0 // indirect github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect - github.com/docker/go-units v0.4.0 // indirect + github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91 // indirect + github.com/dop251/goja v0.0.0-20220405120441-9037c2b61cbf // indirect github.com/dustin/go-humanize v1.0.0 // indirect github.com/dvsekhvalnov/jose2go v0.0.0-20200901110807-248326c1351b // indirect github.com/edsrzf/mmap-go v1.0.0 // indirect @@ -91,8 +92,9 @@ require ( github.com/go-kit/kit v0.12.0 // indirect github.com/go-kit/log v0.2.0 // indirect github.com/go-logfmt/logfmt v0.5.1 // indirect - github.com/go-ole/go-ole v1.2.5 // indirect - github.com/go-resty/resty/v2 v2.7.0 // indirect + github.com/go-ole/go-ole v1.2.1 // indirect + github.com/go-playground/validator/v10 v10.4.1 // indirect + github.com/go-sourcemap/sourcemap v2.1.3+incompatible // indirect github.com/go-stack/stack v1.8.0 // indirect github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect @@ -119,6 +121,7 @@ require ( github.com/hashicorp/hcl v1.0.0 // indirect github.com/hdevalence/ed25519consensus v0.0.0-20210204194344-59a8610d2b87 // indirect github.com/holiman/bloomfilter/v2 v2.0.3 // indirect + github.com/holiman/uint256 v1.2.0 // indirect github.com/huin/goupnp v1.0.3 // indirect github.com/inconshreveable/mousetrap v1.0.0 // indirect github.com/ipfs/go-cid v0.2.0 // indirect @@ -238,11 +241,8 @@ require ( github.com/whyrusleeping/multiaddr-filter v0.0.0-20160516205228-e903e4adabd7 // indirect github.com/whyrusleeping/timecache v0.0.0-20160911033111-cfcb2f1abfee // indirect github.com/zondax/hid v0.9.0 // indirect - go.opencensus.io v0.23.0 // indirect - go.uber.org/atomic v1.9.0 // indirect - go.uber.org/multierr v1.8.0 // indirect - go.uber.org/zap v1.21.0 // indirect - golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3 // indirect + go.etcd.io/bbolt v1.3.6 // indirect + golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d // indirect golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2 // indirect golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a // indirect @@ -252,8 +252,6 @@ require ( golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df // indirect gopkg.in/ini.v1 v1.66.4 // indirect gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect - gopkg.in/olebedev/go-duktape.v3 v3.0.0-20200619000410-60c24ae608a6 // indirect - gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect lukechampine.com/blake3 v1.1.7 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/go.sum b/go.sum index 0fabea9475..b886d935a1 100644 --- a/go.sum +++ b/go.sum @@ -193,6 +193,8 @@ github.com/btcsuite/btcd v0.21.0-beta/go.mod h1:ZSWyehm27aAuS9bvkATT+Xte3hjHZ+MR github.com/btcsuite/btcd v0.22.0-beta/go.mod h1:9n5ntfhhHQBIhUvlhDvD3Qg6fRUj4jkN0VB8L8svzOA= github.com/btcsuite/btcd v0.22.1 h1:CnwP9LM/M9xuRrGSCGeMVs9iv09uMqwsVX7EeIpgV2c= github.com/btcsuite/btcd v0.22.1/go.mod h1:wqgTSL29+50LRkmOVknEdmt8ZojIzhuWvgu/iptuN7Y= +github.com/btcsuite/btcd/btcec/v2 v2.2.0 h1:fzn1qaOt32TuLjFlkzYSsBC35Q3KUjT1SwPxiMSCF5k= +github.com/btcsuite/btcd/btcec/v2 v2.2.0/go.mod h1:U7MHm051Al6XmscBQ0BoNydpOTsFAn707034b5nY8zU= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= github.com/btcsuite/btclog v0.0.0-20170628155309-84c8d2346e9f/go.mod h1:TdznJufoqS23FtqVCzL0ZqgP5MqXbb4fg/WgDys70nA= @@ -306,7 +308,6 @@ github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsr github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/cyberdelia/templates v0.0.0-20141128023046-ca7fffd4298c/go.mod h1:GyV+0YP4qX0UQ7r2MoYZ+AvYDp12OF5yg4q8rGnyNh4= github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= github.com/danieljoos/wincred v1.0.2 h1:zf4bhty2iLuwgjgpraD2E9UbvO+fe54XXGJbOwe23fU= github.com/danieljoos/wincred v1.0.2/go.mod h1:SnuYRW9lp1oJrZX/dXJqr0cPK5gYXqx3EJbmjhLdK9U= @@ -321,9 +322,11 @@ github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c/go.mod h1:6Uh github.com/deckarep/golang-set v0.0.0-20180603214616-504e848d77ea/go.mod h1:93vsz/8Wt4joVM7c2AVqh+YRMiUSc14yDtF28KmMOgQ= github.com/deckarep/golang-set v1.8.0 h1:sk9/l/KqpunDwP7pSjUg0keiOOLEnOBHzykLrsPppp4= github.com/deckarep/golang-set v1.8.0/go.mod h1:5nI87KwE7wgsBU1F4GKAw2Qod7p5kyS383rP6+o6qqo= +github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= +github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 h1:YLtO71vCjJRCBcrPMtQ9nqBsqpA1m5sE92cU+pd5Mcc= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= -github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= -github.com/deepmap/oapi-codegen v1.8.2/go.mod h1:YLgSKSDv/bZQB7N4ws6luhozi3cEdRktEqrX88CvjIw= github.com/denisenkom/go-mssqldb v0.12.0/go.mod h1:iiK0YP1ZeepvmBQk/QpLEhhTNJgfzrpArPY/aFvc9yU= 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= @@ -346,6 +349,7 @@ github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WA github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= github.com/dlclark/regexp2 v1.2.0/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc= +github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91 h1:Izz0+t1Z5nI16/II7vuEo/nHjodOg0p7+OiDpjX5t1E= github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc= github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= github.com/docker/docker v1.4.2-0.20180625184442-8e610b2b55bf/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= @@ -354,7 +358,8 @@ github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5Xh github.com/docker/go-units v0.4.0 h1:3uh0PgVws3nIA0Q+MwDC8yjEPf9zjRfZZWXZYDct3Tw= github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/dop251/goja v0.0.0-20200721192441-a695b0cdd498/go.mod h1:Mw6PkjjMXWbTj+nnj4s3QPXq1jaT0s5pC0iFD4+BOAA= -github.com/dop251/goja v0.0.0-20211011172007-d99e4b8cbf48/go.mod h1:R9ET47fwRVRPZnOGvHxxhuZcbrMCuiqOz3Rlrh4KSnk= +github.com/dop251/goja v0.0.0-20220405120441-9037c2b61cbf h1:Yt+4K30SdjOkRoRRm3vYNQgR+/ZIy0RmeUDZo7Y8zeQ= +github.com/dop251/goja v0.0.0-20220405120441-9037c2b61cbf/go.mod h1:R9ET47fwRVRPZnOGvHxxhuZcbrMCuiqOz3Rlrh4KSnk= github.com/dop251/goja_nodejs v0.0.0-20210225215109-d91c329300e7/go.mod h1:hn7BA7c8pLvoGndExHudxTDKZ84Pyvv+90pbBjbTz0Y= github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo= @@ -378,8 +383,8 @@ github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7 github.com/envoyproxy/protoc-gen-validate v0.6.2/go.mod h1:2t7qjJNvHPx8IjnBOzl9E9/baC+qXE/TeeyBRzgJDws= github.com/ethereum/go-ethereum v1.9.25/go.mod h1:vMkFiYLHI4tgPw4k2j4MHKoovchFE8plZ0M9VMk4/oM= github.com/ethereum/go-ethereum v1.10.4/go.mod h1:nEE0TP5MtxGzOMd7egIrbPJMQBnhVU3ELNxhBglIzhg= -github.com/ethereum/go-ethereum v1.10.16 h1:3oPrumn0bCW/idjcxMn5YYVCdK7VzJYIvwGZUGLEaoc= -github.com/ethereum/go-ethereum v1.10.16/go.mod h1:Anj6cxczl+AHy63o4X9O8yWNHuN5wMpfb8MAnHkWn7Y= +github.com/ethereum/go-ethereum v1.10.19 h1:EOR5JbL4MD5yeOqv8W2iC1s4NximrTjqFccUz8lyBRA= +github.com/ethereum/go-ethereum v1.10.19/go.mod h1:IJBNMtzKcNHPtllYihy6BL2IgK1u+32JriaTbdt4v+w= github.com/facebookgo/ensure v0.0.0-20160127193407-b4ab57deab51/go.mod h1:Yg+htXGokKKdzcwhuNDwVvN+uBxDGXJ7G/VN1d8fa64= github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c h1:8ISkoahWXwZR41ois5lSJBSVw4D0OV19Ht/JSTzvSv0= github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 h1:JWuenKqqX8nojtoVVWjGfOF9635RETekkoH6Cc9SX0A= @@ -418,8 +423,6 @@ github.com/fsnotify/fsnotify v1.5.4 h1:jRbGcIw6P2Meqdwuo0H1p6JVLbL5DHKAKlYndzMwV github.com/fsnotify/fsnotify v1.5.4/go.mod h1:OVB6XrOHzAwXMpEM7uPOzcehqUV2UqJxmVXmkdnm1bU= github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff h1:tY80oXqGNY4FhTFhk+o9oFHGINQ/+vhlm8HFzi6znCI= github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff/go.mod h1:x7DCsMOv1taUwEWCzT4cmDeAkigA5/QCwUodaVOe8Ww= -github.com/getkin/kin-openapi v0.53.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= -github.com/getkin/kin-openapi v0.61.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/gin-contrib/sse v0.1.0 h1:Y/yl/+YNO8GZSjAhjMsSuLt29uWRFHdHYUb5lYOV9qE= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= @@ -428,9 +431,6 @@ github.com/gin-gonic/gin v1.7.0 h1:jGB9xAJQ12AIGNB4HguylppmDK1Am9ppF7XnGXXJuoU= github.com/gliderlabs/ssh v0.1.1/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= github.com/glycerine/go-unsnap-stream v0.0.0-20180323001048-9f0cb55181dd/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE= github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24= -github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= -github.com/go-chi/chi/v5 v5.0.0/go.mod h1:BBug9lr0cqtdAhsu6R4AAdvufI0/XBzAQSsUqJpoZOs= -github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -451,10 +451,6 @@ github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbV github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-ole/go-ole v1.2.1/go.mod h1:7FAglXiTm7HKlQRDeOQ6ZNUHidzCWXuZWq/1dTyBNF8= -github.com/go-ole/go-ole v1.2.5 h1:t4MGB5xEDZvXI+0rMjjsfBsD7yAgp/s9ZDkL1JndXwY= -github.com/go-ole/go-ole v1.2.5/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= -github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.13.0 h1:HyWk6mgj5qFqCT5fjGBuRArbVDfE4hi8+e8ceBS/t7Q= github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= @@ -465,6 +461,7 @@ github.com/go-playground/validator/v10 v10.2.0/go.mod h1:uOYAAleCW8F/7oMFd6aG0GO github.com/go-resty/resty/v2 v2.7.0 h1:me+K9p3uhSmXtrBZ4k9jcEAfJmuC8IivWHwaLZwPrFY= github.com/go-resty/resty/v2 v2.7.0/go.mod h1:9PWDzw47qPphMRFfhsyk0NnSgvluHcljSMVIq3w7q0I= github.com/go-sourcemap/sourcemap v2.1.2+incompatible/go.mod h1:F8jJfvm2KbVjc5NqelyYJmf/v5J0dwNLS2mL4sNA1Jg= +github.com/go-sourcemap/sourcemap v2.1.3+incompatible h1:W1iEw64niKVGogNgBN3ePyLFfuisuzeidWPMPWmECqU= github.com/go-sourcemap/sourcemap v2.1.3+incompatible/go.mod h1:F8jJfvm2KbVjc5NqelyYJmf/v5J0dwNLS2mL4sNA1Jg= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-sql-driver/mysql v1.4.1/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= @@ -490,6 +487,7 @@ github.com/gofrs/uuid v3.3.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRx github.com/gogo/gateway v1.1.0 h1:u0SuhL9+Il+UbjM9VIE3ntfRujKbvVpFvNB4HbjeVQ0= github.com/gogo/gateway v1.1.0/go.mod h1:S7rR8FRQyG3QFESeSv4l2WnsyzlCLG0CzBbUUo/mbic= github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= +github.com/golang-jwt/jwt/v4 v4.3.0 h1:kHL1vqdqWNfATmA0FNMdmZNMyZI1U6O31X4rlIPoBog= github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0= github.com/golang-sql/sqlexp v0.0.0-20170517235910-f1bb20e5a188/go.mod h1:vXjM/+wXQnTPR4KqTKDgJukSZ6amVRtWMPEjE6sQoK8= github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= @@ -537,7 +535,6 @@ github.com/golang/snappy v0.0.3-0.20201103224600-674baa8c7fc3/go.mod h1:/XxbfmMg github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/golangci/lint-1 v0.0.0-20181222135242-d2cdd8c08219/go.mod h1:/X8TswGSh1pIozq4ZwCfxS0WA5JGXguxk94ar/4c87Y= 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.0.1 h1:gK4Kx5IaGY9CD5sPJ36FHiBJ6ZXl0kilRiiCj+jdYp4= @@ -624,8 +621,6 @@ github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/ad github.com/gotestyourself/gotestyourself v2.2.0+incompatible/go.mod h1:zZKM6oeNM8k+FRljX1mnzVYeS8wiGgQyvST1/GafPbY= github.com/graph-gophers/graphql-go v0.0.0-20191115155744-f33e81362277/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= github.com/graph-gophers/graphql-go v0.0.0-20201113091052-beb923fada29/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= -github.com/graph-gophers/graphql-go v1.3.0/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= -github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.2.2/go.mod h1:EaizFBKfUKtMIF5iaDEhniwNedqGo9FuLFzppDr3uwI= @@ -658,7 +653,6 @@ github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brv 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-bexpr v0.1.10 h1:9kuI5PFotCboP3dkDYFr/wi0gg0QVbSNz5oFRpxn4uE= -github.com/hashicorp/go-bexpr v0.1.10/go.mod h1:oxlubA2vC/gFVfX1A6JGp7ls7uCDlfJn732ehYYg+g0= github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= @@ -712,7 +706,6 @@ github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmK github.com/hudl/fargo v1.4.0/go.mod h1:9Ai6uvFy5fQNq6VPKtg+Ceq1+eTY4nKUlR2JElEOcDo= github.com/huin/goupnp v1.0.0/go.mod h1:n9v9KO1tAxYH82qOn+UTIFQDmx5n1Zxd/ClZDMX7Bnc= github.com/huin/goupnp v1.0.1-0.20210310174557-0ca763054c88/go.mod h1:nNs7wvRfN1eKaMknBydLNQU6146XQim8t4h+q90biWo= -github.com/huin/goupnp v1.0.2/go.mod h1:0dxJBVBHqTMjIUMkESDTNgOOx/Mw5wYIfyFmdzSamkM= github.com/huin/goupnp v1.0.3 h1:N8No57ls+MnjlB+JPiCVSOyy/ot7MJTqlo7rn+NYSqQ= github.com/huin/goupnp v1.0.3/go.mod h1:ZxNlw5WqJj6wSsRK5+YfflQGXYfccj5VgQsMNixHM7Y= github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150/go.mod h1:PpLOETDnJ0o3iZrZfqZzyLl6l7F3c6L1oWn7OICBi6o= @@ -726,13 +719,10 @@ github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANyt github.com/influxdata/flux v0.65.1/go.mod h1:J754/zds0vvpfwuq7Gc2wRdVwEodfpCFM7mYlOw2LqY= github.com/influxdata/influxdb v1.2.3-0.20180221223340-01288bdb0883/go.mod h1:qZna6X/4elxqT3yI9iZYdZrWWdeFOOprn86kgg4+IzY= github.com/influxdata/influxdb v1.8.3/go.mod h1:JugdFhsvvI8gadxOI6noqNeeBHvWNTbfYGtiAn+2jhI= -github.com/influxdata/influxdb-client-go/v2 v2.4.0/go.mod h1:vLNHdxTJkIf2mSLvGrpj8TCcISApPoXkaxP8g9uRlW8= github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= github.com/influxdata/influxdb1-client v0.0.0-20200827194710-b269163b24ab/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= github.com/influxdata/influxql v1.1.1-0.20200828144457-65d3ef77d385/go.mod h1:gHp9y86a/pxhjJ+zMjNXiQAA197Xk9wLxaz+fGG+kWk= github.com/influxdata/line-protocol v0.0.0-20180522152040-32c6aa80de5e/go.mod h1:4kt73NQhadE3daL3WhR5EJ/J2ocX0PZzwxQ0gXJ7oFE= -github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= -github.com/influxdata/line-protocol v0.0.0-20210311194329-9aa0e372d097/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= github.com/influxdata/promql/v2 v2.12.0/go.mod h1:fxOPu+DY0bqCTCECchSRtWfc+0X19ybifQhZoQNF5D8= github.com/influxdata/roaring v0.4.13-0.20180809181101-fc520f41fab6/go.mod h1:bSgUQ7q5ZLSO+bKBGqJiCBGAl+9DxyW63zLTujjUlOE= github.com/influxdata/tdigest v0.0.0-20181121200506-bf2b5ad3c0a9/go.mod h1:Js0mqiSBE6Ffsg94weZZ2c+v/ciT8QRHFOap7EKDrR0= @@ -826,7 +816,6 @@ github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E github.com/jwilder/encoding v0.0.0-20170811194829-b4e1701a28ef/go.mod h1:Ct9fl0F6iIOGgxJ5npU/IUOhOhqlVrGjyIZc8/MagT0= github.com/kami-zh/go-capturer v0.0.0-20171211120116-e492ea43421d/go.mod h1:P2viExyCEfeWGU259JnaQ34Inuec4R38JCyBx2edgD0= github.com/karalabe/usb v0.0.0-20190919080040-51dc0efba356/go.mod h1:Od972xHfMJowv7NGVDiWVxk2zxnWgjLlJzE+F4F7AGU= -github.com/karalabe/usb v0.0.2/go.mod h1:Od972xHfMJowv7NGVDiWVxk2zxnWgjLlJzE+F4F7AGU= github.com/keybase/go-keychain v0.0.0-20190712205309-48d3d31d256d h1:Z+RDyXzjKE0i2sTjZ/b1uxiGtPhFy34Ou/Tk0qwN0kM= github.com/keybase/go-keychain v0.0.0-20190712205309-48d3d31d256d/go.mod h1:JJNrCn9otv/2QP4D7SMJBgaleKpOf66PnW6F5WGNRIc= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= @@ -865,8 +854,6 @@ 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/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= -github.com/labstack/echo/v4 v4.2.1/go.mod h1:AA49e0DZ8kk5jTOOCKNuPR6oTnBS0dYiM4FW1e6jwpg= -github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= github.com/leodido/go-urn v1.2.0 h1:hpXL4XnriNwQ/ABnpepYM/1vCLWNDfUNts8dX3xTG6Y= github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= @@ -1043,31 +1030,10 @@ github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czP github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= github.com/magiconair/properties v1.8.6 h1:5ibWZ6iY0NctNGWo87LalDlEZ6R41TqbbDamhfG/Qzo= github.com/magiconair/properties v1.8.6/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= -github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/marten-seemann/qpack v0.2.1/go.mod h1:F7Gl5L1jIgN1D11ucXefiuJS9UMVP2opoCp2jDKb7wc= -github.com/marten-seemann/qtls-go1-15 v0.1.4/go.mod h1:GyFwywLKkRt+6mfU99csTEY1joMZz5vmB1WNZH3P81I= -github.com/marten-seemann/qtls-go1-16 v0.1.4/go.mod h1:gNpI2Ol+lRS3WwSOtIUUtRwZEQMXjYK+dQSBFbethAk= -github.com/marten-seemann/qtls-go1-16 v0.1.5 h1:o9JrYPPco/Nukd/HpOHMHZoBDXQqoNtUCmny98/1uqQ= -github.com/marten-seemann/qtls-go1-16 v0.1.5/go.mod h1:gNpI2Ol+lRS3WwSOtIUUtRwZEQMXjYK+dQSBFbethAk= -github.com/marten-seemann/qtls-go1-17 v0.1.0/go.mod h1:fz4HIxByo+LlWcreM4CZOYNuz3taBQ8rN2X6FqvaWo8= -github.com/marten-seemann/qtls-go1-17 v0.1.1 h1:DQjHPq+aOzUeh9/lixAGunn6rIOQyWChPSI4+hgW7jc= -github.com/marten-seemann/qtls-go1-17 v0.1.1/go.mod h1:C2ekUKcDdz9SDWxec1N/MvcXBpaX9l3Nx67XaR84L5s= -github.com/marten-seemann/qtls-go1-18 v0.1.0-beta.1/go.mod h1:PUhIQk19LoFt2174H4+an8TYvWOGjb/hHwphBeaDHwI= -github.com/marten-seemann/qtls-go1-18 v0.1.1 h1:qp7p7XXUFL7fpBvSS1sWD+uSqPvzNQK43DH+/qEkj0Y= -github.com/marten-seemann/qtls-go1-18 v0.1.1/go.mod h1:mJttiymBAByA49mhlNZZGrH5u1uXYZJ+RW28Py7f4m4= -github.com/marten-seemann/tcp v0.0.0-20210406111302-dfbc87cc63fd h1:br0buuQ854V8u83wA0rVZ8ttrq5CpaPZdvrK0LP2lOk= -github.com/marten-seemann/tcp v0.0.0-20210406111302-dfbc87cc63fd/go.mod h1:QuCEs1Nt24+FYQEqAAncTDPJIuGs+LxK1MCiFL25pMU= -github.com/matryer/moq v0.0.0-20190312154309-6cfb0558e1bd/go.mod h1:9ELz6aaclSIGnZBoaSLZ3NAl1VTufbOrXBPvtcy6WiQ= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.0/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= -github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= -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.7/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.12 h1:jF+Du6AlPIjs2BiUiQlKOX0rt3SujHxPnksPKZbaA40= @@ -1079,7 +1045,6 @@ github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNx github.com/mattn/go-isatty v0.0.5-0.20180830101745-3fb116b82035/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.5/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2yME+cCiQ= github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84= github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= @@ -1136,13 +1101,11 @@ github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0Qu github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.3.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.4.2/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/pointerstructure v1.2.0 h1:O+i9nHnXS3l/9Wu7r4NrEdwA2VFTicjUEN1uBnDo34A= -github.com/mitchellh/pointerstructure v1.2.0/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8ohIXc3tViBH44KcwB2g4= github.com/moby/sys/mountinfo v0.4.1/go.mod h1:rEr8tzG/lsIZHBtN/JjGG+LMYx9eXgW2JI+6q0qou+A= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= @@ -1593,11 +1556,6 @@ github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijb github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli v1.22.2/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli/v2 v2.3.0/go.mod h1:LJmUH05zAU44vOAcrfzZQKsZbVcdbOG8rtL3/XcUArI= -github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -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/viant/assertly v0.4.8/go.mod h1:aGifi++jvCrUaklKEKT0BU95igDNaqkvz+49uaYMPRU= -github.com/viant/toolbox v0.24.0/go.mod h1:OxMCG57V0PXuIP2HNQrtJf2CjqdmbrOx5EkMILuUhzM= github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE= github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df/go.mod h1:JP3t17pCcGlemwknint6hfoeCVQrEMVwxRLRjXpq+BU= github.com/vmihailenco/msgpack/v5 v5.1.4/go.mod h1:C5gboKD0TJPqWDTVTtrQNfRbiBwHZGo8UTqP/9/XvLI= @@ -1719,8 +1677,6 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201117144127-c1f2f97bffc9/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= -golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= -golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= golang.org/x/crypto v0.0.0-20210314154223-e6e6c4f2bb5b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= 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= @@ -1730,8 +1686,9 @@ golang.org/x/crypto v0.0.0-20210813211128-0a44fdfbc16e/go.mod h1:GvvjBRRGRdwPK5y golang.org/x/crypto v0.0.0-20210817164053-32db794688a5/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210915214749-c084706c2272/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20220518034528-6f7dac969898 h1:SLP7Q4Di66FONjDJbCYrCRrh97focO6sLogHO7/g8F0= -golang.org/x/crypto v0.0.0-20220518034528-6f7dac969898/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.0.0-20220411220226-7b82a4e95df4/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d h1:sK3txAijHtOK88l68nt020reeT1ZdKLIYetKl95FzVY= +golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -1913,7 +1870,6 @@ golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190712062909-fae7ac547cb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1954,7 +1910,6 @@ golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200824131525-c12d262b63d8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200826173525-f9321e4c35a6/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200909081042-eff7692f9009/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1994,7 +1949,6 @@ golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210903071746-97244b99971b/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -2030,7 +1984,6 @@ golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxb golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20200416051211-89c76fbcd5d1/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20201208040808-7e3f01d25324/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac h1:7zkz7BUtwNFFqcowJ+RIgu2MaV/MapERkDIy+mwPyjs= golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= @@ -2237,8 +2190,17 @@ google.golang.org/genproto v0.0.0-20211028162531-8db9c33dc351/go.mod h1:5CzLGKJ6 google.golang.org/genproto v0.0.0-20211118181313-81c1377c94b1/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20211206160659-862468c7d6e0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= -google.golang.org/genproto v0.0.0-20220519153652-3a47de7e79bd h1:e0TwkXOdbnH/1x5rc5MZ/VYyiZ4v+RdVfrGMqEwT68I= -google.golang.org/genproto v0.0.0-20220519153652-3a47de7e79bd/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20211221195035-429b39de9b1c/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220126215142-9970aeb2e350/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220207164111-0872dc986b00/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220218161850-94dd64e39d7c/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220222213610-43724f9ea8cf/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220304144024-325a89244dc8/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220310185008-1973136f34c6/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220324131243-acbaeb5b85eb/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= +google.golang.org/genproto v0.0.0-20220407144326-9054f6ed7bac/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220628213854-d9e0b6570c03 h1:W70HjnmXFJm+8RNjOpIDYW2nKsSi/af0VvIZUtYkwuU= +google.golang.org/genproto v0.0.0-20220628213854-d9e0b6570c03/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= google.golang.org/grpc v1.33.2 h1:EQyQC3sa8M+p6Ulc8yy9SWSS2GVwyRc83gAbG8lrl4o= google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= @@ -2276,7 +2238,6 @@ gopkg.in/ini.v1 v1.66.4 h1:SsAcf+mM7mRZo2nJNGt8mZCjG8ZRaNGMURJw7BsIST4= gopkg.in/ini.v1 v1.66.4/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce h1:+JknDZhAj8YMt7GC73Ei8pv4MzjDUNPHgQWJdtMAaDU= gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce/go.mod h1:5AcXVHNjg+BDxry382+8OKon8SEWiKktQR07RKPsv1c= -gopkg.in/olebedev/go-duktape.v3 v3.0.0-20200619000410-60c24ae608a6 h1:a6cXbcDDUkSBlpnkWV1bJ+vv3mOgQEltEJ2rPxroVu0= gopkg.in/olebedev/go-duktape.v3 v3.0.0-20200619000410-60c24ae608a6/go.mod h1:uAJfkITjFhyEEuUfm7bsmCZRbW5WRq8s9EY8HZ6hCns= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= gopkg.in/src-d/go-cli.v0 v0.0.0-20181105080154-d492247bbc0d/go.mod h1:z+K8VcOYVYcSwSjGebuDL6176A1XskgbtNl64NSg+n8= diff --git a/proto/ethermint/evm/v1/evm.proto b/proto/ethermint/evm/v1/evm.proto index 406276a290..fe9c450e02 100644 --- a/proto/ethermint/evm/v1/evm.proto +++ b/proto/ethermint/evm/v1/evm.proto @@ -112,11 +112,20 @@ message ChainConfig { (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.moretags) = "yaml:\"arrow_glacier_block\"" ]; - // EIP-3675 (TheMerge) switch block (nil = no fork, 0 = already in merge proceedings) - string merge_fork_block = 19 [ + // DEPRECATED: merge fork block was deprecated: https://github.com/ethereum/go-ethereum/pull/24904 + reserved 19; + reserved "merge_fork_block"; + // EIP-5133 (bomb delay) switch block (nil = no fork, 0 = already activated) + string gray_glacier_block = 20 [ (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"merge_fork_block\"" + (gogoproto.moretags) = "yaml:\"gray_glacier_block\"" ]; + // Virtual fork after The Merge to use as a network splitter + string merge_netsplit_block = 21 [ + (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", + (gogoproto.moretags) = "yaml:\"merge_netsplit_block\"" + ]; + } // State represents a single Storage key value pair item. diff --git a/rpc/types/block.go b/rpc/types/block.go index 0f407f9086..24d2876d67 100644 --- a/rpc/types/block.go +++ b/rpc/types/block.go @@ -30,9 +30,10 @@ const ( ) const ( - BlockParamEarliest = "earliest" - BlockParamLatest = "latest" - BlockParamPending = "pending" + BlockParamEarliest = "earliest" + BlockParamLatest = "latest" + BlockParamFinalized = "finalized" + BlockParamPending = "pending" ) // NewBlockNumber creates a new BlockNumber instance. @@ -57,7 +58,7 @@ func ContextWithHeight(height int64) context.Context { } // UnmarshalJSON parses the given JSON fragment into a BlockNumber. It supports: -// - "latest", "earliest" or "pending" as string arguments +// - "latest", "finalized", "earliest" or "pending" as string arguments // - the block number // Returned errors: // - an invalid block number error when the given argument isn't a known strings @@ -72,7 +73,7 @@ func (bn *BlockNumber) UnmarshalJSON(data []byte) error { case BlockParamEarliest: *bn = EthEarliestBlockNumber return nil - case BlockParamLatest: + case BlockParamLatest, BlockParamFinalized: *bn = EthLatestBlockNumber return nil case BlockParamPending: diff --git a/x/evm/keeper/grpc_query.go b/x/evm/keeper/grpc_query.go index 04ee1d357d..1303f18025 100644 --- a/x/evm/keeper/grpc_query.go +++ b/x/evm/keeper/grpc_query.go @@ -485,100 +485,75 @@ func (k *Keeper) traceTx( ) (*interface{}, uint, error) { // Assemble the structured logger or the JavaScript tracer var ( - tracer vm.EVMLogger + tracer tracers.Tracer overrides *ethparams.ChainConfig err error + timeout = defaultTraceTimeout ) - msg, err := tx.AsMessage(signer, cfg.BaseFee) if err != nil { return nil, 0, status.Error(codes.Internal, err.Error()) } - if traceConfig != nil && traceConfig.Overrides != nil { + if traceConfig == nil { + traceConfig = &types.TraceConfig{} + } + + if traceConfig.Overrides != nil { overrides = traceConfig.Overrides.EthereumConfig(cfg.ChainConfig.ChainID) } - switch { - case traceConfig != nil && traceConfig.Tracer != "": - timeout := defaultTraceTimeout - // TODO: change timeout to time.duration - // Used string to comply with go ethereum - if traceConfig.Timeout != "" { - timeout, err = time.ParseDuration(traceConfig.Timeout) - if err != nil { - return nil, 0, status.Errorf(codes.InvalidArgument, "timeout value: %s", err.Error()) - } - } + logConfig := logger.Config{ + EnableMemory: traceConfig.EnableMemory, + DisableStorage: traceConfig.DisableStorage, + DisableStack: traceConfig.DisableStack, + EnableReturnData: traceConfig.EnableReturnData, + Debug: traceConfig.Debug, + Limit: int(traceConfig.Limit), + Overrides: overrides, + } - tCtx := &tracers.Context{ - BlockHash: txConfig.BlockHash, - TxIndex: int(txConfig.TxIndex), - TxHash: txConfig.TxHash, - } + tracer = logger.NewStructLogger(&logConfig) - // Construct the JavaScript tracer to execute with + tCtx := &tracers.Context{ + BlockHash: txConfig.BlockHash, + TxIndex: int(txConfig.TxIndex), + TxHash: txConfig.TxHash, + } + + if traceConfig.Tracer != "" { if tracer, err = tracers.New(traceConfig.Tracer, tCtx); err != nil { return nil, 0, status.Error(codes.Internal, err.Error()) } + } - // Handle timeouts and RPC cancellations - deadlineCtx, cancel := context.WithTimeout(ctx.Context(), timeout) - defer cancel() - - go func() { - <-deadlineCtx.Done() - if errors.Is(deadlineCtx.Err(), context.DeadlineExceeded) { - tracer.(tracers.Tracer).Stop(errors.New("execution timeout")) - } - }() - - case traceConfig != nil: - logConfig := logger.Config{ - EnableMemory: traceConfig.EnableMemory, - DisableStorage: traceConfig.DisableStorage, - DisableStack: traceConfig.DisableStack, - EnableReturnData: traceConfig.EnableReturnData, - Debug: traceConfig.Debug, - Limit: int(traceConfig.Limit), - Overrides: overrides, + // Define a meaningful timeout of a single transaction trace + if traceConfig.Timeout != "" { + if timeout, err = time.ParseDuration(traceConfig.Timeout); err != nil { + return nil, 0, status.Errorf(codes.InvalidArgument, "timeout value: %s", err.Error()) } - tracer = logger.NewStructLogger(&logConfig) - default: - tracer = types.NewTracer(types.TracerStruct, msg, cfg.ChainConfig, ctx.BlockHeight()) } + // Handle timeouts and RPC cancellations + deadlineCtx, cancel := context.WithTimeout(ctx.Context(), timeout) + defer cancel() + + go func() { + <-deadlineCtx.Done() + if errors.Is(deadlineCtx.Err(), context.DeadlineExceeded) { + tracer.Stop(errors.New("execution timeout")) + } + }() + res, err := k.ApplyMessageWithConfig(ctx, msg, tracer, commitMessage, cfg, txConfig) if err != nil { return nil, 0, status.Error(codes.Internal, err.Error()) } var result interface{} - - // Depending on the tracer type, format and return the trace result data. - switch tracer := tracer.(type) { - case *logger.StructLogger: - returnVal := "" - revert := res.Revert() - if len(revert) > 0 { - returnVal = fmt.Sprintf("%x", revert) - } else { - returnVal = fmt.Sprintf("%x", res.Return()) - } - result = types.ExecutionResult{ - Gas: res.GasUsed, - Failed: res.Failed(), - ReturnValue: returnVal, - StructLogs: types.FormatLogs(tracer.StructLogs()), - } - case tracers.Tracer: - result, err = tracer.GetResult() - if err != nil { - return nil, 0, status.Error(codes.Internal, err.Error()) - } - - default: - return nil, 0, status.Errorf(codes.InvalidArgument, "invalid tracer type %T", tracer) + result, err = tracer.GetResult() + if err != nil { + return nil, 0, status.Error(codes.Internal, err.Error()) } return &result, txConfig.LogIndex + uint(len(res.Logs)), nil diff --git a/x/evm/keeper/grpc_query_test.go b/x/evm/keeper/grpc_query_test.go index 47e9c49619..19e317a859 100644 --- a/x/evm/keeper/grpc_query_test.go +++ b/x/evm/keeper/grpc_query_test.go @@ -623,7 +623,7 @@ func (suite *KeeperTestSuite) TestTraceTx() { predecessors = []*types.MsgEthereumTx{} }, expPass: true, - traceResponse: []byte{0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x34, 0x38, 0x32, 0x38, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22, 0x2c, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a}, + traceResponse: []byte{0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22, 0x2c, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x30, 0x32, 0x39}, }, { msg: "default trace with filtered response", @@ -636,7 +636,7 @@ func (suite *KeeperTestSuite) TestTraceTx() { predecessors = []*types.MsgEthereumTx{} }, expPass: true, - traceResponse: []byte{0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x34, 0x38, 0x32, 0x38, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22, 0x2c, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a}, + traceResponse: []byte{0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22, 0x2c, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x30, 0x32, 0x39}, enableFeemarket: false, }, { @@ -661,7 +661,7 @@ func (suite *KeeperTestSuite) TestTraceTx() { predecessors = []*types.MsgEthereumTx{} }, expPass: true, - traceResponse: []byte{0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x34, 0x38, 0x32, 0x38, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22, 0x2c, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a}, + traceResponse: []byte{0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22, 0x2c, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x30, 0x32, 0x39}, enableFeemarket: true, }, { @@ -696,7 +696,7 @@ func (suite *KeeperTestSuite) TestTraceTx() { predecessors = append(predecessors, firstTx) }, expPass: true, - traceResponse: []byte{0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x34, 0x38, 0x32, 0x38, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22, 0x2c, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a}, + traceResponse: []byte{0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22, 0x2c, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x31, 0x33, 0x31, 0x39}, enableFeemarket: false, }, } @@ -757,7 +757,7 @@ func (suite *KeeperTestSuite) TestTraceBlock() { traceConfig = nil }, expPass: true, - traceResponse: []byte{0x5b, 0x7b, 0x22, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x34, 0x38, 0x32, 0x38, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55}, + traceResponse: []byte{0x5b, 0x7b, 0x22, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22}, }, { msg: "filtered trace", @@ -769,7 +769,7 @@ func (suite *KeeperTestSuite) TestTraceBlock() { } }, expPass: true, - traceResponse: []byte{0x5b, 0x7b, 0x22, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x34, 0x38, 0x32, 0x38, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55}, + traceResponse: []byte{0x5b, 0x7b, 0x22, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22}, }, { msg: "javascript tracer", @@ -791,7 +791,7 @@ func (suite *KeeperTestSuite) TestTraceBlock() { } }, expPass: true, - traceResponse: []byte{0x5b, 0x7b, 0x22, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x34, 0x38, 0x32, 0x38, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55}, + traceResponse: []byte{0x5b, 0x7b, 0x22, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22}, enableFeemarket: true, }, { @@ -825,7 +825,7 @@ func (suite *KeeperTestSuite) TestTraceBlock() { txs = append([]*types.MsgEthereumTx{}, firstTx, secondTx) }, expPass: true, - traceResponse: []byte{0x5b, 0x7b, 0x22, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x33, 0x34, 0x38, 0x32, 0x38, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55}, + traceResponse: []byte{0x5b, 0x7b, 0x22, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x7b, 0x22, 0x67, 0x61, 0x73, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x3a, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3a, 0x22, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x31, 0x22, 0x2c, 0x22, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x4c, 0x6f, 0x67, 0x73, 0x22, 0x3a, 0x5b, 0x7b, 0x22, 0x70, 0x63, 0x22, 0x3a, 0x30, 0x2c, 0x22, 0x6f, 0x70, 0x22, 0x3a, 0x22, 0x50, 0x55, 0x53, 0x48, 0x31, 0x22}, enableFeemarket: false, }, } diff --git a/x/evm/keeper/keeper_test.go b/x/evm/keeper/keeper_test.go index 1c0deea5e3..5340b71dc8 100644 --- a/x/evm/keeper/keeper_test.go +++ b/x/evm/keeper/keeper_test.go @@ -100,7 +100,8 @@ func (suite *KeeperTestSuite) DoSetupTest(t require.TestingT) { maxInt := sdk.NewInt(math.MaxInt64) evmGenesis.Params.ChainConfig.LondonBlock = &maxInt evmGenesis.Params.ChainConfig.ArrowGlacierBlock = &maxInt - evmGenesis.Params.ChainConfig.MergeForkBlock = &maxInt + evmGenesis.Params.ChainConfig.GrayGlacierBlock = &maxInt + evmGenesis.Params.ChainConfig.MergeNetsplitBlock = &maxInt genesis[types.ModuleName] = app.AppCodec().MustMarshalJSON(evmGenesis) } return genesis diff --git a/x/evm/keeper/migrations.go b/x/evm/keeper/migrations.go index 3be1ada66f..acc0cf6629 100644 --- a/x/evm/keeper/migrations.go +++ b/x/evm/keeper/migrations.go @@ -1,5 +1,11 @@ package keeper +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + v2 "github.com/evmos/ethermint/x/evm/migrations/v2" + v3 "github.com/evmos/ethermint/x/evm/migrations/v3" +) + // Migrator is a struct for handling in-place store migrations. type Migrator struct { keeper Keeper @@ -11,3 +17,13 @@ func NewMigrator(keeper Keeper) Migrator { keeper: keeper, } } + +// Migrate1to2 migrates the store from consensus version v1 to v2 +func (m Migrator) Migrate1to2(ctx sdk.Context) error { + return v2.MigrateStore(ctx, &m.keeper.paramSpace) +} + +// Migrate2to3 migrates the store from consensus version v2 to v3 +func (m Migrator) Migrate2to3(ctx sdk.Context) error { + return v3.MigrateStore(ctx, &m.keeper.paramSpace) +} diff --git a/x/evm/keeper/state_transition.go b/x/evm/keeper/state_transition.go index fbc56538fa..431b634ceb 100644 --- a/x/evm/keeper/state_transition.go +++ b/x/evm/keeper/state_transition.go @@ -372,7 +372,7 @@ func (k *Keeper) ApplyMessageWithConfig(ctx sdk.Context, msg core.Message, trace // 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.MergeForkBlock != nil); rules.IsBerlin { + if rules := cfg.ChainConfig.Rules(big.NewInt(ctx.BlockHeight()), cfg.ChainConfig.MergeNetsplitBlock != nil); rules.IsBerlin { stateDB.PrepareAccessList(msg.From(), msg.To(), vm.ActivePrecompiles(rules), msg.AccessList()) } diff --git a/x/evm/migrations/v2/types/chain_config.go b/x/evm/migrations/v2/types/chain_config.go new file mode 100644 index 0000000000..a596580f4f --- /dev/null +++ b/x/evm/migrations/v2/types/chain_config.go @@ -0,0 +1,165 @@ +package types + +import ( + "math/big" + "strings" + + sdk "github.com/cosmos/cosmos-sdk/types" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/params" + + "github.com/evmos/ethermint/x/evm/types" +) + +// 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, + HomesteadBlock: getBlockValue(cc.HomesteadBlock), + DAOForkBlock: getBlockValue(cc.DAOForkBlock), + DAOForkSupport: cc.DAOForkSupport, + EIP150Block: getBlockValue(cc.EIP150Block), + EIP150Hash: common.HexToHash(cc.EIP150Hash), + EIP155Block: getBlockValue(cc.EIP155Block), + EIP158Block: getBlockValue(cc.EIP158Block), + ByzantiumBlock: getBlockValue(cc.ByzantiumBlock), + ConstantinopleBlock: getBlockValue(cc.ConstantinopleBlock), + PetersburgBlock: getBlockValue(cc.PetersburgBlock), + IstanbulBlock: getBlockValue(cc.IstanbulBlock), + MuirGlacierBlock: getBlockValue(cc.MuirGlacierBlock), + BerlinBlock: getBlockValue(cc.BerlinBlock), + LondonBlock: getBlockValue(cc.LondonBlock), + ArrowGlacierBlock: getBlockValue(cc.ArrowGlacierBlock), + MergeNetsplitBlock: getBlockValue(cc.MergeForkBlock), + TerminalTotalDifficulty: nil, + Ethash: nil, + Clique: nil, + } +} + +// DefaultChainConfig returns default evm parameters. +func DefaultChainConfig() ChainConfig { + homesteadBlock := sdk.ZeroInt() + daoForkBlock := sdk.ZeroInt() + eip150Block := sdk.ZeroInt() + eip155Block := sdk.ZeroInt() + eip158Block := sdk.ZeroInt() + byzantiumBlock := sdk.ZeroInt() + constantinopleBlock := sdk.ZeroInt() + petersburgBlock := sdk.ZeroInt() + istanbulBlock := sdk.ZeroInt() + muirGlacierBlock := sdk.ZeroInt() + berlinBlock := sdk.ZeroInt() + londonBlock := sdk.ZeroInt() + arrowGlacierBlock := sdk.ZeroInt() + mergeForkBlock := sdk.ZeroInt() + + return ChainConfig{ + HomesteadBlock: &homesteadBlock, + DAOForkBlock: &daoForkBlock, + DAOForkSupport: true, + EIP150Block: &eip150Block, + EIP150Hash: common.Hash{}.String(), + EIP155Block: &eip155Block, + EIP158Block: &eip158Block, + ByzantiumBlock: &byzantiumBlock, + ConstantinopleBlock: &constantinopleBlock, + PetersburgBlock: &petersburgBlock, + IstanbulBlock: &istanbulBlock, + MuirGlacierBlock: &muirGlacierBlock, + BerlinBlock: &berlinBlock, + LondonBlock: &londonBlock, + ArrowGlacierBlock: &arrowGlacierBlock, + MergeForkBlock: &mergeForkBlock, + } +} + +func getBlockValue(block *sdk.Int) *big.Int { + if block == nil || block.IsNegative() { + return nil + } + + return block.BigInt() +} + +// Validate performs a basic validation of the ChainConfig params. The function will return an error +// if any of the block values is uninitialized (i.e nil) or if the EIP150Hash is an invalid hash. +func (cc ChainConfig) Validate() error { + if err := validateBlock(cc.HomesteadBlock); err != nil { + return sdkerrors.Wrap(err, "homesteadBlock") + } + if err := validateBlock(cc.DAOForkBlock); err != nil { + return sdkerrors.Wrap(err, "daoForkBlock") + } + if err := validateBlock(cc.EIP150Block); err != nil { + return sdkerrors.Wrap(err, "eip150Block") + } + if err := validateHash(cc.EIP150Hash); err != nil { + return err + } + if err := validateBlock(cc.EIP155Block); err != nil { + return sdkerrors.Wrap(err, "eip155Block") + } + if err := validateBlock(cc.EIP158Block); err != nil { + return sdkerrors.Wrap(err, "eip158Block") + } + if err := validateBlock(cc.ByzantiumBlock); err != nil { + return sdkerrors.Wrap(err, "byzantiumBlock") + } + if err := validateBlock(cc.ConstantinopleBlock); err != nil { + return sdkerrors.Wrap(err, "constantinopleBlock") + } + if err := validateBlock(cc.PetersburgBlock); err != nil { + return sdkerrors.Wrap(err, "petersburgBlock") + } + if err := validateBlock(cc.IstanbulBlock); err != nil { + return sdkerrors.Wrap(err, "istanbulBlock") + } + if err := validateBlock(cc.MuirGlacierBlock); err != nil { + return sdkerrors.Wrap(err, "muirGlacierBlock") + } + if err := validateBlock(cc.BerlinBlock); err != nil { + return sdkerrors.Wrap(err, "berlinBlock") + } + if err := validateBlock(cc.LondonBlock); err != nil { + return sdkerrors.Wrap(err, "londonBlock") + } + if err := validateBlock(cc.ArrowGlacierBlock); err != nil { + return sdkerrors.Wrap(err, "arrowGlacierBlock") + } + if err := validateBlock(cc.MergeForkBlock); err != nil { + return sdkerrors.Wrap(err, "mergeForkBlock") + } + + // NOTE: chain ID is not needed to check config order + if err := cc.EthereumConfig(nil).CheckConfigForkOrder(); err != nil { + return sdkerrors.Wrap(err, "invalid config fork order") + } + return nil +} + +func validateHash(hex string) error { + if hex != "" && strings.TrimSpace(hex) == "" { + return sdkerrors.Wrap(types.ErrInvalidChainConfig, "hash cannot be blank") + } + + return nil +} + +func validateBlock(block *sdk.Int) error { + // nil value means that the fork has not yet been applied + if block == nil { + return nil + } + + if block.IsNegative() { + return sdkerrors.Wrapf( + types.ErrInvalidChainConfig, "block value cannot be negative: %s", block, + ) + } + + return nil +} diff --git a/x/evm/migrations/v3/migrate.go b/x/evm/migrations/v3/migrate.go new file mode 100644 index 0000000000..22ce74e86b --- /dev/null +++ b/x/evm/migrations/v3/migrate.go @@ -0,0 +1,25 @@ +package v3 + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + "github.com/evmos/ethermint/x/evm/types" +) + +// MigrateStore sets the default for GrayGlacierBlock and MergeNetsplitBlock in ChainConfig parameter. +func MigrateStore(ctx sdk.Context, paramstore *paramtypes.Subspace) error { + if !paramstore.HasKeyTable() { + ps := paramstore.WithKeyTable(types.ParamKeyTable()) + paramstore = &ps + } + prevConfig := &types.ChainConfig{} + paramstore.GetIfExists(ctx, types.ParamStoreKeyChainConfig, prevConfig) + + defaultConfig := types.DefaultChainConfig() + + prevConfig.GrayGlacierBlock = defaultConfig.GrayGlacierBlock + prevConfig.MergeNetsplitBlock = defaultConfig.MergeNetsplitBlock + + paramstore.Set(ctx, types.ParamStoreKeyChainConfig, prevConfig) + return nil +} diff --git a/x/evm/migrations/v3/migrate_test.go b/x/evm/migrations/v3/migrate_test.go new file mode 100644 index 0000000000..3d77ea0dca --- /dev/null +++ b/x/evm/migrations/v3/migrate_test.go @@ -0,0 +1,57 @@ +package v3_test + +import ( + "fmt" + v3 "github.com/evmos/ethermint/x/evm/migrations/v3" + "testing" + + "github.com/stretchr/testify/require" + + "github.com/cosmos/cosmos-sdk/testutil" + sdk "github.com/cosmos/cosmos-sdk/types" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + + "github.com/evmos/ethermint/encoding" + + "github.com/evmos/ethermint/app" + v3types "github.com/evmos/ethermint/x/evm/migrations/v3/types" + "github.com/evmos/ethermint/x/evm/types" +) + +func TestMigrateStore(t *testing.T) { + encCfg := encoding.MakeConfig(app.ModuleBasics) + evmKey := sdk.NewKVStoreKey(types.StoreKey) + tEvmKey := sdk.NewTransientStoreKey(fmt.Sprintf("%s_test", types.StoreKey)) + ctx := testutil.DefaultContext(evmKey, tEvmKey) + paramstore := paramtypes.NewSubspace( + encCfg.Marshaler, encCfg.Amino, evmKey, tEvmKey, "evm", + ).WithKeyTable(v3types.ParamKeyTable()) + + params := v3types.DefaultParams() + paramstore.SetParamSet(ctx, ¶ms) + + require.Panics(t, func() { + var preMigrationConfig types.ChainConfig + paramstore.Get(ctx, types.ParamStoreKeyChainConfig, &preMigrationConfig) + }) + var preMigrationConfig v3types.ChainConfig + paramstore.Get(ctx, types.ParamStoreKeyChainConfig, &preMigrationConfig) + require.NotNil(t, preMigrationConfig.MergeForkBlock) + + paramstore = paramtypes.NewSubspace( + encCfg.Marshaler, encCfg.Amino, evmKey, tEvmKey, "evm", + ).WithKeyTable(types.ParamKeyTable()) + err := v3.MigrateStore(ctx, ¶mstore) + require.NoError(t, err) + + updatedDefaultConfig := types.DefaultChainConfig() + + var postMigrationConfig types.ChainConfig + paramstore.Get(ctx, types.ParamStoreKeyChainConfig, &postMigrationConfig) + require.Equal(t, postMigrationConfig.GrayGlacierBlock, updatedDefaultConfig.GrayGlacierBlock) + require.Equal(t, postMigrationConfig.MergeNetsplitBlock, updatedDefaultConfig.MergeNetsplitBlock) + require.Panics(t, func() { + var preMigrationConfig v3types.ChainConfig + paramstore.Get(ctx, types.ParamStoreKeyChainConfig, &preMigrationConfig) + }) +} diff --git a/x/evm/migrations/v3/types/chain_config.go b/x/evm/migrations/v3/types/chain_config.go new file mode 100644 index 0000000000..d939cd6b6d --- /dev/null +++ b/x/evm/migrations/v3/types/chain_config.go @@ -0,0 +1,164 @@ +package types + +import ( + "math/big" + "strings" + + "github.com/evmos/ethermint/x/evm/types" + + sdk "github.com/cosmos/cosmos-sdk/types" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/params" +) + +// 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, + HomesteadBlock: getBlockValue(cc.HomesteadBlock), + DAOForkBlock: getBlockValue(cc.DAOForkBlock), + DAOForkSupport: cc.DAOForkSupport, + EIP150Block: getBlockValue(cc.EIP150Block), + EIP150Hash: common.HexToHash(cc.EIP150Hash), + EIP155Block: getBlockValue(cc.EIP155Block), + EIP158Block: getBlockValue(cc.EIP158Block), + ByzantiumBlock: getBlockValue(cc.ByzantiumBlock), + ConstantinopleBlock: getBlockValue(cc.ConstantinopleBlock), + PetersburgBlock: getBlockValue(cc.PetersburgBlock), + IstanbulBlock: getBlockValue(cc.IstanbulBlock), + MuirGlacierBlock: getBlockValue(cc.MuirGlacierBlock), + BerlinBlock: getBlockValue(cc.BerlinBlock), + LondonBlock: getBlockValue(cc.LondonBlock), + ArrowGlacierBlock: getBlockValue(cc.ArrowGlacierBlock), + TerminalTotalDifficulty: nil, + Ethash: nil, + Clique: nil, + } +} + +// DefaultChainConfig returns default evm parameters. +func DefaultChainConfig() ChainConfig { + homesteadBlock := sdk.ZeroInt() + daoForkBlock := sdk.ZeroInt() + eip150Block := sdk.ZeroInt() + eip155Block := sdk.ZeroInt() + eip158Block := sdk.ZeroInt() + byzantiumBlock := sdk.ZeroInt() + constantinopleBlock := sdk.ZeroInt() + petersburgBlock := sdk.ZeroInt() + istanbulBlock := sdk.ZeroInt() + muirGlacierBlock := sdk.ZeroInt() + berlinBlock := sdk.ZeroInt() + londonBlock := sdk.ZeroInt() + arrowGlacierBlock := sdk.ZeroInt() + mergeForkBlock := sdk.ZeroInt() + + return ChainConfig{ + HomesteadBlock: &homesteadBlock, + DAOForkBlock: &daoForkBlock, + DAOForkSupport: true, + EIP150Block: &eip150Block, + EIP150Hash: common.Hash{}.String(), + EIP155Block: &eip155Block, + EIP158Block: &eip158Block, + ByzantiumBlock: &byzantiumBlock, + ConstantinopleBlock: &constantinopleBlock, + PetersburgBlock: &petersburgBlock, + IstanbulBlock: &istanbulBlock, + MuirGlacierBlock: &muirGlacierBlock, + BerlinBlock: &berlinBlock, + LondonBlock: &londonBlock, + ArrowGlacierBlock: &arrowGlacierBlock, + MergeForkBlock: &mergeForkBlock, + } +} + +func getBlockValue(block *sdk.Int) *big.Int { + if block == nil || block.IsNegative() { + return nil + } + + return block.BigInt() +} + +// Validate performs a basic validation of the ChainConfig params. The function will return an error +// if any of the block values is uninitialized (i.e nil) or if the EIP150Hash is an invalid hash. +func (cc ChainConfig) Validate() error { + if err := validateBlock(cc.HomesteadBlock); err != nil { + return sdkerrors.Wrap(err, "homesteadBlock") + } + if err := validateBlock(cc.DAOForkBlock); err != nil { + return sdkerrors.Wrap(err, "daoForkBlock") + } + if err := validateBlock(cc.EIP150Block); err != nil { + return sdkerrors.Wrap(err, "eip150Block") + } + if err := validateHash(cc.EIP150Hash); err != nil { + return err + } + if err := validateBlock(cc.EIP155Block); err != nil { + return sdkerrors.Wrap(err, "eip155Block") + } + if err := validateBlock(cc.EIP158Block); err != nil { + return sdkerrors.Wrap(err, "eip158Block") + } + if err := validateBlock(cc.ByzantiumBlock); err != nil { + return sdkerrors.Wrap(err, "byzantiumBlock") + } + if err := validateBlock(cc.ConstantinopleBlock); err != nil { + return sdkerrors.Wrap(err, "constantinopleBlock") + } + if err := validateBlock(cc.PetersburgBlock); err != nil { + return sdkerrors.Wrap(err, "petersburgBlock") + } + if err := validateBlock(cc.IstanbulBlock); err != nil { + return sdkerrors.Wrap(err, "istanbulBlock") + } + if err := validateBlock(cc.MuirGlacierBlock); err != nil { + return sdkerrors.Wrap(err, "muirGlacierBlock") + } + if err := validateBlock(cc.BerlinBlock); err != nil { + return sdkerrors.Wrap(err, "berlinBlock") + } + if err := validateBlock(cc.LondonBlock); err != nil { + return sdkerrors.Wrap(err, "londonBlock") + } + if err := validateBlock(cc.ArrowGlacierBlock); err != nil { + return sdkerrors.Wrap(err, "arrowGlacierBlock") + } + if err := validateBlock(cc.MergeForkBlock); err != nil { + return sdkerrors.Wrap(err, "mergeForkBlock") + } + + // NOTE: chain ID is not needed to check config order + if err := cc.EthereumConfig(nil).CheckConfigForkOrder(); err != nil { + return sdkerrors.Wrap(err, "invalid config fork order") + } + return nil +} + +func validateHash(hex string) error { + if hex != "" && strings.TrimSpace(hex) == "" { + return sdkerrors.Wrap(types.ErrInvalidChainConfig, "hash cannot be blank") + } + + return nil +} + +func validateBlock(block *sdk.Int) error { + // nil value means that the fork has not yet been applied + if block == nil { + return nil + } + + if block.IsNegative() { + return sdkerrors.Wrapf( + types.ErrInvalidChainConfig, "block value cannot be negative: %s", block, + ) + } + + return nil +} diff --git a/x/evm/migrations/v3/types/evm.pb.go b/x/evm/migrations/v3/types/evm.pb.go new file mode 100644 index 0000000000..7d20b3ec5b --- /dev/null +++ b/x/evm/migrations/v3/types/evm.pb.go @@ -0,0 +1,3812 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: ethermint/evm/v1/evm.proto + +package types + +import ( + fmt "fmt" + github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" + _ "github.com/gogo/protobuf/gogoproto" + proto "github.com/gogo/protobuf/proto" + io "io" + math "math" + math_bits "math/bits" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +// Params defines the EVM module parameters +type Params struct { + // evm denom represents the token denomination used to run the EVM state + // transitions. + EvmDenom string `protobuf:"bytes,1,opt,name=evm_denom,json=evmDenom,proto3" json:"evm_denom,omitempty" yaml:"evm_denom"` + // enable create toggles state transitions that use the vm.Create function + EnableCreate bool `protobuf:"varint,2,opt,name=enable_create,json=enableCreate,proto3" json:"enable_create,omitempty" yaml:"enable_create"` + // enable call toggles state transitions that use the vm.Call function + EnableCall bool `protobuf:"varint,3,opt,name=enable_call,json=enableCall,proto3" json:"enable_call,omitempty" yaml:"enable_call"` + // extra eips defines the additional EIPs for the vm.Config + ExtraEIPs []int64 `protobuf:"varint,4,rep,packed,name=extra_eips,json=extraEips,proto3" json:"extra_eips,omitempty" yaml:"extra_eips"` + // chain config defines the EVM chain configuration parameters + ChainConfig ChainConfig `protobuf:"bytes,5,opt,name=chain_config,json=chainConfig,proto3" json:"chain_config" yaml:"chain_config"` + // Allow unprotected transactions defines if replay-protected (i.e non EIP155 + // signed) transactions can be executed on the state machine. + AllowUnprotectedTxs bool `protobuf:"varint,6,opt,name=allow_unprotected_txs,json=allowUnprotectedTxs,proto3" json:"allow_unprotected_txs,omitempty"` +} + +func (m *Params) Reset() { *m = Params{} } +func (m *Params) String() string { return proto.CompactTextString(m) } +func (*Params) ProtoMessage() {} +func (*Params) Descriptor() ([]byte, []int) { + return fileDescriptor_d21ecc92c8c8583e, []int{0} +} +func (m *Params) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_Params.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 *Params) XXX_Merge(src proto.Message) { + xxx_messageInfo_Params.Merge(m, src) +} +func (m *Params) XXX_Size() int { + return m.Size() +} +func (m *Params) XXX_DiscardUnknown() { + xxx_messageInfo_Params.DiscardUnknown(m) +} + +var xxx_messageInfo_Params proto.InternalMessageInfo + +func (m *Params) GetEvmDenom() string { + if m != nil { + return m.EvmDenom + } + return "" +} + +func (m *Params) GetEnableCreate() bool { + if m != nil { + return m.EnableCreate + } + return false +} + +func (m *Params) GetEnableCall() bool { + if m != nil { + return m.EnableCall + } + return false +} + +func (m *Params) GetExtraEIPs() []int64 { + if m != nil { + return m.ExtraEIPs + } + return nil +} + +func (m *Params) GetChainConfig() ChainConfig { + if m != nil { + return m.ChainConfig + } + return ChainConfig{} +} + +func (m *Params) GetAllowUnprotectedTxs() bool { + if m != nil { + return m.AllowUnprotectedTxs + } + return false +} + +// ChainConfig defines the Ethereum ChainConfig parameters using *sdk.Int values +// instead of *big.Int. +type ChainConfig struct { + // Homestead switch block (nil no fork, 0 = already homestead) + HomesteadBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,1,opt,name=homestead_block,json=homesteadBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"homestead_block,omitempty" yaml:"homestead_block"` + // TheDAO hard-fork switch block (nil no fork) + DAOForkBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,2,opt,name=dao_fork_block,json=daoForkBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"dao_fork_block,omitempty" yaml:"dao_fork_block"` + // Whether the nodes supports or opposes the DAO hard-fork + DAOForkSupport bool `protobuf:"varint,3,opt,name=dao_fork_support,json=daoForkSupport,proto3" json:"dao_fork_support,omitempty" yaml:"dao_fork_support"` + // EIP150 implements the Gas price changes + // (https://github.com/ethereum/EIPs/issues/150) EIP150 HF block (nil no fork) + EIP150Block *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,4,opt,name=eip150_block,json=eip150Block,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"eip150_block,omitempty" yaml:"eip150_block"` + // EIP150 HF hash (needed for header only clients as only gas pricing changed) + EIP150Hash string `protobuf:"bytes,5,opt,name=eip150_hash,json=eip150Hash,proto3" json:"eip150_hash,omitempty" yaml:"byzantium_block"` + // EIP155Block HF block + EIP155Block *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,6,opt,name=eip155_block,json=eip155Block,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"eip155_block,omitempty" yaml:"eip155_block"` + // EIP158 HF block + EIP158Block *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,7,opt,name=eip158_block,json=eip158Block,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"eip158_block,omitempty" yaml:"eip158_block"` + // Byzantium switch block (nil no fork, 0 = already on byzantium) + ByzantiumBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,8,opt,name=byzantium_block,json=byzantiumBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"byzantium_block,omitempty" yaml:"byzantium_block"` + // Constantinople switch block (nil no fork, 0 = already activated) + ConstantinopleBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,9,opt,name=constantinople_block,json=constantinopleBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"constantinople_block,omitempty" yaml:"constantinople_block"` + // Petersburg switch block (nil same as Constantinople) + PetersburgBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,10,opt,name=petersburg_block,json=petersburgBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"petersburg_block,omitempty" yaml:"petersburg_block"` + // Istanbul switch block (nil no fork, 0 = already on istanbul) + IstanbulBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,11,opt,name=istanbul_block,json=istanbulBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"istanbul_block,omitempty" yaml:"istanbul_block"` + // Eip-2384 (bomb delay) switch block (nil no fork, 0 = already activated) + MuirGlacierBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,12,opt,name=muir_glacier_block,json=muirGlacierBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"muir_glacier_block,omitempty" yaml:"muir_glacier_block"` + // Berlin switch block (nil = no fork, 0 = already on berlin) + BerlinBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,13,opt,name=berlin_block,json=berlinBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"berlin_block,omitempty" yaml:"berlin_block"` + // London switch block (nil = no fork, 0 = already on london) + LondonBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,17,opt,name=london_block,json=londonBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"london_block,omitempty" yaml:"london_block"` + // Eip-4345 (bomb delay) switch block (nil = no fork, 0 = already activated) + ArrowGlacierBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,18,opt,name=arrow_glacier_block,json=arrowGlacierBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"arrow_glacier_block,omitempty" yaml:"arrow_glacier_block"` + // EIP-3675 (TheMerge) switch block (nil = no fork, 0 = already in merge proceedings) + MergeForkBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,19,opt,name=merge_fork_block,json=mergeForkBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"merge_fork_block,omitempty" yaml:"merge_fork_block"` +} + +func (m *ChainConfig) Reset() { *m = ChainConfig{} } +func (m *ChainConfig) String() string { return proto.CompactTextString(m) } +func (*ChainConfig) ProtoMessage() {} +func (*ChainConfig) Descriptor() ([]byte, []int) { + return fileDescriptor_d21ecc92c8c8583e, []int{1} +} +func (m *ChainConfig) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *ChainConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_ChainConfig.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 *ChainConfig) XXX_Merge(src proto.Message) { + xxx_messageInfo_ChainConfig.Merge(m, src) +} +func (m *ChainConfig) XXX_Size() int { + return m.Size() +} +func (m *ChainConfig) XXX_DiscardUnknown() { + xxx_messageInfo_ChainConfig.DiscardUnknown(m) +} + +var xxx_messageInfo_ChainConfig proto.InternalMessageInfo + +func (m *ChainConfig) GetDAOForkSupport() bool { + if m != nil { + return m.DAOForkSupport + } + return false +} + +func (m *ChainConfig) GetEIP150Hash() string { + if m != nil { + return m.EIP150Hash + } + return "" +} + +// State represents a single Storage key value pair item. +type State struct { + Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` + Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` +} + +func (m *State) Reset() { *m = State{} } +func (m *State) String() string { return proto.CompactTextString(m) } +func (*State) ProtoMessage() {} +func (*State) Descriptor() ([]byte, []int) { + return fileDescriptor_d21ecc92c8c8583e, []int{2} +} +func (m *State) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *State) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_State.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 *State) XXX_Merge(src proto.Message) { + xxx_messageInfo_State.Merge(m, src) +} +func (m *State) XXX_Size() int { + return m.Size() +} +func (m *State) XXX_DiscardUnknown() { + xxx_messageInfo_State.DiscardUnknown(m) +} + +var xxx_messageInfo_State proto.InternalMessageInfo + +func (m *State) GetKey() string { + if m != nil { + return m.Key + } + return "" +} + +func (m *State) GetValue() string { + if m != nil { + return m.Value + } + return "" +} + +// TransactionLogs define the logs generated from a transaction execution +// with a given hash. It it used for import/export data as transactions are not +// persisted on blockchain state after an upgrade. +type TransactionLogs struct { + Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"` + Logs []*Log `protobuf:"bytes,2,rep,name=logs,proto3" json:"logs,omitempty"` +} + +func (m *TransactionLogs) Reset() { *m = TransactionLogs{} } +func (m *TransactionLogs) String() string { return proto.CompactTextString(m) } +func (*TransactionLogs) ProtoMessage() {} +func (*TransactionLogs) Descriptor() ([]byte, []int) { + return fileDescriptor_d21ecc92c8c8583e, []int{3} +} +func (m *TransactionLogs) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *TransactionLogs) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_TransactionLogs.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 *TransactionLogs) XXX_Merge(src proto.Message) { + xxx_messageInfo_TransactionLogs.Merge(m, src) +} +func (m *TransactionLogs) XXX_Size() int { + return m.Size() +} +func (m *TransactionLogs) XXX_DiscardUnknown() { + xxx_messageInfo_TransactionLogs.DiscardUnknown(m) +} + +var xxx_messageInfo_TransactionLogs proto.InternalMessageInfo + +func (m *TransactionLogs) GetHash() string { + if m != nil { + return m.Hash + } + return "" +} + +func (m *TransactionLogs) GetLogs() []*Log { + if m != nil { + return m.Logs + } + return nil +} + +// Log represents an protobuf compatible Ethereum Log that defines a contract +// log event. These events are generated by the LOG opcode and stored/indexed by +// the node. +type Log struct { + // address of the contract that generated the event + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + // list of topics provided by the contract. + Topics []string `protobuf:"bytes,2,rep,name=topics,proto3" json:"topics,omitempty"` + // supplied by the contract, usually ABI-encoded + Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` + // block in which the transaction was included + BlockNumber uint64 `protobuf:"varint,4,opt,name=block_number,json=blockNumber,proto3" json:"blockNumber"` + // hash of the transaction + TxHash string `protobuf:"bytes,5,opt,name=tx_hash,json=txHash,proto3" json:"transactionHash"` + // index of the transaction in the block + TxIndex uint64 `protobuf:"varint,6,opt,name=tx_index,json=txIndex,proto3" json:"transactionIndex"` + // hash of the block in which the transaction was included + BlockHash string `protobuf:"bytes,7,opt,name=block_hash,json=blockHash,proto3" json:"blockHash"` + // index of the log in the block + Index uint64 `protobuf:"varint,8,opt,name=index,proto3" json:"logIndex"` + // The Removed field is true if this log was reverted due to a chain + // reorganisation. You must pay attention to this field if you receive logs + // through a filter query. + Removed bool `protobuf:"varint,9,opt,name=removed,proto3" json:"removed,omitempty"` +} + +func (m *Log) Reset() { *m = Log{} } +func (m *Log) String() string { return proto.CompactTextString(m) } +func (*Log) ProtoMessage() {} +func (*Log) Descriptor() ([]byte, []int) { + return fileDescriptor_d21ecc92c8c8583e, []int{4} +} +func (m *Log) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *Log) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_Log.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 *Log) XXX_Merge(src proto.Message) { + xxx_messageInfo_Log.Merge(m, src) +} +func (m *Log) XXX_Size() int { + return m.Size() +} +func (m *Log) XXX_DiscardUnknown() { + xxx_messageInfo_Log.DiscardUnknown(m) +} + +var xxx_messageInfo_Log proto.InternalMessageInfo + +func (m *Log) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + +func (m *Log) GetTopics() []string { + if m != nil { + return m.Topics + } + return nil +} + +func (m *Log) GetData() []byte { + if m != nil { + return m.Data + } + return nil +} + +func (m *Log) GetBlockNumber() uint64 { + if m != nil { + return m.BlockNumber + } + return 0 +} + +func (m *Log) GetTxHash() string { + if m != nil { + return m.TxHash + } + return "" +} + +func (m *Log) GetTxIndex() uint64 { + if m != nil { + return m.TxIndex + } + return 0 +} + +func (m *Log) GetBlockHash() string { + if m != nil { + return m.BlockHash + } + return "" +} + +func (m *Log) GetIndex() uint64 { + if m != nil { + return m.Index + } + return 0 +} + +func (m *Log) GetRemoved() bool { + if m != nil { + return m.Removed + } + return false +} + +// TxResult stores results of Tx execution. +type TxResult struct { + // contract_address contains the ethereum address of the created contract (if + // any). If the state transition is an evm.Call, the contract address will be + // empty. + ContractAddress string `protobuf:"bytes,1,opt,name=contract_address,json=contractAddress,proto3" json:"contract_address,omitempty" yaml:"contract_address"` + // bloom represents the bloom filter bytes + Bloom []byte `protobuf:"bytes,2,opt,name=bloom,proto3" json:"bloom,omitempty"` + // tx_logs contains the transaction hash and the proto-compatible ethereum + // logs. + TxLogs TransactionLogs `protobuf:"bytes,3,opt,name=tx_logs,json=txLogs,proto3" json:"tx_logs" yaml:"tx_logs"` + // ret defines the bytes from the execution. + Ret []byte `protobuf:"bytes,4,opt,name=ret,proto3" json:"ret,omitempty"` + // reverted flag is set to true when the call has been reverted + Reverted bool `protobuf:"varint,5,opt,name=reverted,proto3" json:"reverted,omitempty"` + // gas_used notes the amount of gas consumed while execution + GasUsed uint64 `protobuf:"varint,6,opt,name=gas_used,json=gasUsed,proto3" json:"gas_used,omitempty"` +} + +func (m *TxResult) Reset() { *m = TxResult{} } +func (m *TxResult) String() string { return proto.CompactTextString(m) } +func (*TxResult) ProtoMessage() {} +func (*TxResult) Descriptor() ([]byte, []int) { + return fileDescriptor_d21ecc92c8c8583e, []int{5} +} +func (m *TxResult) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *TxResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_TxResult.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 *TxResult) XXX_Merge(src proto.Message) { + xxx_messageInfo_TxResult.Merge(m, src) +} +func (m *TxResult) XXX_Size() int { + return m.Size() +} +func (m *TxResult) XXX_DiscardUnknown() { + xxx_messageInfo_TxResult.DiscardUnknown(m) +} + +var xxx_messageInfo_TxResult proto.InternalMessageInfo + +// AccessTuple is the element type of an access list. +type AccessTuple struct { + // hex formatted ethereum address + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + // hex formatted hashes of the storage keys + StorageKeys []string `protobuf:"bytes,2,rep,name=storage_keys,json=storageKeys,proto3" json:"storageKeys"` +} + +func (m *AccessTuple) Reset() { *m = AccessTuple{} } +func (m *AccessTuple) String() string { return proto.CompactTextString(m) } +func (*AccessTuple) ProtoMessage() {} +func (*AccessTuple) Descriptor() ([]byte, []int) { + return fileDescriptor_d21ecc92c8c8583e, []int{6} +} +func (m *AccessTuple) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *AccessTuple) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_AccessTuple.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 *AccessTuple) XXX_Merge(src proto.Message) { + xxx_messageInfo_AccessTuple.Merge(m, src) +} +func (m *AccessTuple) XXX_Size() int { + return m.Size() +} +func (m *AccessTuple) XXX_DiscardUnknown() { + xxx_messageInfo_AccessTuple.DiscardUnknown(m) +} + +var xxx_messageInfo_AccessTuple proto.InternalMessageInfo + +// TraceConfig holds extra parameters to trace functions. +type TraceConfig struct { + // custom javascript tracer + Tracer string `protobuf:"bytes,1,opt,name=tracer,proto3" json:"tracer,omitempty"` + // overrides the default timeout of 5 seconds for JavaScript-based tracing + // calls + Timeout string `protobuf:"bytes,2,opt,name=timeout,proto3" json:"timeout,omitempty"` + // number of blocks the tracer is willing to go back + Reexec uint64 `protobuf:"varint,3,opt,name=reexec,proto3" json:"reexec,omitempty"` + // disable stack capture + DisableStack bool `protobuf:"varint,5,opt,name=disable_stack,json=disableStack,proto3" json:"disableStack"` + // disable storage capture + DisableStorage bool `protobuf:"varint,6,opt,name=disable_storage,json=disableStorage,proto3" json:"disableStorage"` + // print output during capture end + Debug bool `protobuf:"varint,8,opt,name=debug,proto3" json:"debug,omitempty"` + // maximum length of output, but zero means unlimited + Limit int32 `protobuf:"varint,9,opt,name=limit,proto3" json:"limit,omitempty"` + // Chain overrides, can be used to execute a trace using future fork rules + Overrides *ChainConfig `protobuf:"bytes,10,opt,name=overrides,proto3" json:"overrides,omitempty"` + // enable memory capture + EnableMemory bool `protobuf:"varint,11,opt,name=enable_memory,json=enableMemory,proto3" json:"enableMemory"` + // enable return data capture + EnableReturnData bool `protobuf:"varint,12,opt,name=enable_return_data,json=enableReturnData,proto3" json:"enableReturnData"` +} + +func (m *TraceConfig) Reset() { *m = TraceConfig{} } +func (m *TraceConfig) String() string { return proto.CompactTextString(m) } +func (*TraceConfig) ProtoMessage() {} +func (*TraceConfig) Descriptor() ([]byte, []int) { + return fileDescriptor_d21ecc92c8c8583e, []int{7} +} +func (m *TraceConfig) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *TraceConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_TraceConfig.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 *TraceConfig) XXX_Merge(src proto.Message) { + xxx_messageInfo_TraceConfig.Merge(m, src) +} +func (m *TraceConfig) XXX_Size() int { + return m.Size() +} +func (m *TraceConfig) XXX_DiscardUnknown() { + xxx_messageInfo_TraceConfig.DiscardUnknown(m) +} + +var xxx_messageInfo_TraceConfig proto.InternalMessageInfo + +func (m *TraceConfig) GetTracer() string { + if m != nil { + return m.Tracer + } + return "" +} + +func (m *TraceConfig) GetTimeout() string { + if m != nil { + return m.Timeout + } + return "" +} + +func (m *TraceConfig) GetReexec() uint64 { + if m != nil { + return m.Reexec + } + return 0 +} + +func (m *TraceConfig) GetDisableStack() bool { + if m != nil { + return m.DisableStack + } + return false +} + +func (m *TraceConfig) GetDisableStorage() bool { + if m != nil { + return m.DisableStorage + } + return false +} + +func (m *TraceConfig) GetDebug() bool { + if m != nil { + return m.Debug + } + return false +} + +func (m *TraceConfig) GetLimit() int32 { + if m != nil { + return m.Limit + } + return 0 +} + +func (m *TraceConfig) GetOverrides() *ChainConfig { + if m != nil { + return m.Overrides + } + return nil +} + +func (m *TraceConfig) GetEnableMemory() bool { + if m != nil { + return m.EnableMemory + } + return false +} + +func (m *TraceConfig) GetEnableReturnData() bool { + if m != nil { + return m.EnableReturnData + } + return false +} + +var fileDescriptor_d21ecc92c8c8583e = []byte{ + // 1503 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x57, 0x5d, 0x4f, 0x1b, 0xc7, + 0x1a, 0x06, 0x6c, 0x60, 0x3d, 0x36, 0xf6, 0x32, 0x10, 0x8e, 0x43, 0x74, 0x58, 0xce, 0x5e, 0x1c, + 0x71, 0xa4, 0x04, 0x02, 0x11, 0x3a, 0x51, 0xa2, 0x23, 0x1d, 0x0c, 0x24, 0x81, 0x93, 0xd3, 0xa2, + 0x81, 0xa8, 0x52, 0xa5, 0x6a, 0x35, 0xde, 0x9d, 0x2c, 0x5b, 0x76, 0x77, 0xac, 0x99, 0x59, 0xc7, + 0xae, 0xfa, 0x03, 0x5a, 0xf5, 0xa6, 0x3f, 0xa1, 0x7f, 0xa1, 0xff, 0x22, 0xea, 0x55, 0x2e, 0xab, + 0x5e, 0xac, 0x22, 0x72, 0xc7, 0xa5, 0x7f, 0x41, 0x35, 0x1f, 0xfe, 0x04, 0xb5, 0x85, 0x2b, 0xcf, + 0xf3, 0x7e, 0x3c, 0xcf, 0xcc, 0x3b, 0xef, 0xce, 0x8c, 0xc1, 0x2a, 0x11, 0xe7, 0x84, 0x25, 0x51, + 0x2a, 0xb6, 0x48, 0x3b, 0xd9, 0x6a, 0x6f, 0xcb, 0x9f, 0xcd, 0x16, 0xa3, 0x82, 0x42, 0x7b, 0xe0, + 0xdb, 0x94, 0xc6, 0xf6, 0xf6, 0xea, 0x72, 0x48, 0x43, 0xaa, 0x9c, 0x5b, 0x72, 0xa4, 0xe3, 0xdc, + 0xef, 0x0b, 0x60, 0xee, 0x04, 0x33, 0x9c, 0x70, 0xb8, 0x0d, 0x4a, 0xa4, 0x9d, 0x78, 0x01, 0x49, + 0x69, 0x52, 0x9f, 0x5e, 0x9f, 0xde, 0x28, 0x35, 0x96, 0x7b, 0xb9, 0x63, 0x77, 0x71, 0x12, 0x3f, + 0x73, 0x07, 0x2e, 0x17, 0x59, 0xa4, 0x9d, 0x1c, 0xc8, 0x21, 0xfc, 0x0f, 0x58, 0x20, 0x29, 0x6e, + 0xc6, 0xc4, 0xf3, 0x19, 0xc1, 0x82, 0xd4, 0x67, 0xd6, 0xa7, 0x37, 0xac, 0x46, 0xbd, 0x97, 0x3b, + 0xcb, 0x26, 0x6d, 0xd4, 0xed, 0xa2, 0x8a, 0xc6, 0xfb, 0x0a, 0xc2, 0x7f, 0x83, 0x72, 0xdf, 0x8f, + 0xe3, 0xb8, 0x5e, 0x50, 0xc9, 0x2b, 0xbd, 0xdc, 0x81, 0xe3, 0xc9, 0x38, 0x8e, 0x5d, 0x04, 0x4c, + 0x2a, 0x8e, 0x63, 0xb8, 0x07, 0x00, 0xe9, 0x08, 0x86, 0x3d, 0x12, 0xb5, 0x78, 0xbd, 0xb8, 0x5e, + 0xd8, 0x28, 0x34, 0xdc, 0xcb, 0xdc, 0x29, 0x1d, 0x4a, 0xeb, 0xe1, 0xd1, 0x09, 0xef, 0xe5, 0xce, + 0xa2, 0x21, 0x19, 0x04, 0xba, 0xa8, 0xa4, 0xc0, 0x61, 0xd4, 0xe2, 0xf0, 0x2b, 0x50, 0xf1, 0xcf, + 0x71, 0x94, 0x7a, 0x3e, 0x4d, 0xdf, 0x46, 0x61, 0x7d, 0x76, 0x7d, 0x7a, 0xa3, 0xbc, 0xf3, 0xf7, + 0xcd, 0xc9, 0xba, 0x6d, 0xee, 0xcb, 0xa8, 0x7d, 0x15, 0xd4, 0x78, 0xf0, 0x3e, 0x77, 0xa6, 0x7a, + 0xb9, 0xb3, 0xa4, 0xa9, 0x47, 0x09, 0x5c, 0x54, 0xf6, 0x87, 0x91, 0x70, 0x07, 0xdc, 0xc3, 0x71, + 0x4c, 0xdf, 0x79, 0x59, 0x2a, 0x0b, 0x4d, 0x7c, 0x41, 0x02, 0x4f, 0x74, 0x78, 0x7d, 0x4e, 0x2e, + 0x12, 0x2d, 0x29, 0xe7, 0x9b, 0xa1, 0xef, 0xac, 0xc3, 0xdd, 0x9f, 0xab, 0xa0, 0x3c, 0xa2, 0x06, + 0x13, 0x50, 0x3b, 0xa7, 0x09, 0xe1, 0x82, 0xe0, 0xc0, 0x6b, 0xc6, 0xd4, 0xbf, 0x30, 0xdb, 0x72, + 0xf0, 0x5b, 0xee, 0xfc, 0x33, 0x8c, 0xc4, 0x79, 0xd6, 0xdc, 0xf4, 0x69, 0xb2, 0xe5, 0x53, 0x9e, + 0x50, 0x6e, 0x7e, 0x1e, 0xf1, 0xe0, 0x62, 0x4b, 0x74, 0x5b, 0x84, 0x6f, 0x1e, 0xa5, 0xa2, 0x97, + 0x3b, 0x2b, 0x7a, 0xb2, 0x13, 0x54, 0x2e, 0xaa, 0x0e, 0x2c, 0x0d, 0x69, 0x80, 0x5d, 0x50, 0x0d, + 0x30, 0xf5, 0xde, 0x52, 0x76, 0x61, 0xd4, 0x66, 0x94, 0xda, 0xe9, 0x5f, 0x57, 0xbb, 0xcc, 0x9d, + 0xca, 0xc1, 0xde, 0xe7, 0x2f, 0x28, 0xbb, 0x50, 0x9c, 0xbd, 0xdc, 0xb9, 0xa7, 0xd5, 0xc7, 0x99, + 0x5d, 0x54, 0x09, 0x30, 0x1d, 0x84, 0xc1, 0x2f, 0x80, 0x3d, 0x08, 0xe0, 0x59, 0xab, 0x45, 0x99, + 0x30, 0xdd, 0xf0, 0xe8, 0x32, 0x77, 0xaa, 0x86, 0xf2, 0x54, 0x7b, 0x7a, 0xb9, 0xf3, 0xb7, 0x09, + 0x52, 0x93, 0xe3, 0xa2, 0xaa, 0xa1, 0x35, 0xa1, 0x90, 0x83, 0x0a, 0x89, 0x5a, 0xdb, 0xbb, 0x8f, + 0xcd, 0x8a, 0x8a, 0x6a, 0x45, 0x27, 0xb7, 0x5a, 0x51, 0xf9, 0xf0, 0xe8, 0x64, 0x7b, 0xf7, 0x71, + 0x7f, 0x41, 0x66, 0xef, 0x47, 0x69, 0x5d, 0x54, 0xd6, 0x50, 0xaf, 0xe6, 0x08, 0x18, 0xe8, 0x9d, + 0x63, 0x7e, 0xae, 0x3a, 0xab, 0xd4, 0xd8, 0xb8, 0xcc, 0x1d, 0xa0, 0x99, 0x5e, 0x61, 0x7e, 0x3e, + 0xdc, 0x97, 0x66, 0xf7, 0x1b, 0x9c, 0x8a, 0x28, 0x4b, 0xfa, 0x5c, 0x40, 0x27, 0xcb, 0xa8, 0xc1, + 0xfc, 0x77, 0xcd, 0xfc, 0xe7, 0xee, 0x3c, 0xff, 0xdd, 0x9b, 0xe6, 0xbf, 0x3b, 0x3e, 0x7f, 0x1d, + 0x33, 0x10, 0x7d, 0x6a, 0x44, 0xe7, 0xef, 0x2c, 0xfa, 0xf4, 0x26, 0xd1, 0xa7, 0xe3, 0xa2, 0x3a, + 0x46, 0x36, 0xfb, 0x44, 0x25, 0xea, 0xd6, 0xdd, 0x9b, 0xfd, 0x5a, 0x51, 0xab, 0x03, 0x8b, 0x96, + 0xfb, 0x16, 0x2c, 0xfb, 0x34, 0xe5, 0x42, 0xda, 0x52, 0xda, 0x8a, 0x89, 0xd1, 0x2c, 0x29, 0xcd, + 0xa3, 0x5b, 0x69, 0x3e, 0x30, 0xa7, 0xc1, 0x0d, 0x7c, 0x2e, 0x5a, 0x1a, 0x37, 0x6b, 0xf5, 0x16, + 0xb0, 0x5b, 0x44, 0x10, 0xc6, 0x9b, 0x19, 0x0b, 0x8d, 0x32, 0x50, 0xca, 0x87, 0xb7, 0x52, 0x36, + 0xdf, 0xc1, 0x24, 0x97, 0x8b, 0x6a, 0x43, 0x93, 0x56, 0xfc, 0x1a, 0x54, 0x23, 0x39, 0x8d, 0x66, + 0x16, 0x1b, 0xbd, 0xb2, 0xd2, 0xdb, 0xbf, 0x95, 0x9e, 0xf9, 0x98, 0xc7, 0x99, 0x5c, 0xb4, 0xd0, + 0x37, 0x68, 0xad, 0x0c, 0xc0, 0x24, 0x8b, 0x98, 0x17, 0xc6, 0xd8, 0x8f, 0x08, 0x33, 0x7a, 0x15, + 0xa5, 0xf7, 0xf2, 0x56, 0x7a, 0xf7, 0xb5, 0xde, 0x75, 0x36, 0x17, 0xd9, 0xd2, 0xf8, 0x52, 0xdb, + 0xb4, 0x6c, 0x00, 0x2a, 0x4d, 0xc2, 0xe2, 0x28, 0x35, 0x82, 0x0b, 0x4a, 0x70, 0xef, 0x56, 0x82, + 0xa6, 0x4f, 0x47, 0x79, 0x5c, 0x54, 0xd6, 0x70, 0xa0, 0x12, 0xd3, 0x34, 0xa0, 0x7d, 0x95, 0xc5, + 0xbb, 0xab, 0x8c, 0xf2, 0xb8, 0xa8, 0xac, 0xa1, 0x56, 0xe9, 0x80, 0x25, 0xcc, 0x18, 0x7d, 0x37, + 0x51, 0x43, 0xa8, 0xc4, 0x5e, 0xdd, 0x4a, 0x6c, 0x55, 0x8b, 0xdd, 0x40, 0xe7, 0xa2, 0x45, 0x65, + 0x1d, 0xab, 0x22, 0x05, 0x76, 0x42, 0x58, 0x48, 0x46, 0xef, 0x81, 0xa5, 0xbb, 0xb7, 0xe6, 0x24, + 0x97, 0x8b, 0xaa, 0xca, 0x34, 0x38, 0xfb, 0x8f, 0x8b, 0x56, 0xd5, 0xae, 0x1d, 0x17, 0xad, 0x9a, + 0x6d, 0x1f, 0x17, 0x2d, 0xdb, 0x5e, 0x44, 0x0b, 0x5d, 0x1a, 0x53, 0xaf, 0xfd, 0x44, 0x67, 0xa0, + 0x32, 0x79, 0x87, 0xb9, 0xf9, 0x90, 0x51, 0xd5, 0xc7, 0x02, 0xc7, 0x5d, 0x2e, 0x0c, 0xdd, 0x16, + 0x98, 0x3d, 0x15, 0xf2, 0x2d, 0x61, 0x83, 0xc2, 0x05, 0xe9, 0xea, 0x0b, 0x12, 0xc9, 0x21, 0x5c, + 0x06, 0xb3, 0x6d, 0x1c, 0x67, 0xfa, 0x51, 0x52, 0x42, 0x1a, 0xb8, 0x27, 0xa0, 0x76, 0xc6, 0x70, + 0xca, 0xb1, 0x2f, 0x22, 0x9a, 0xbe, 0xa6, 0x21, 0x87, 0x10, 0x14, 0xd5, 0x41, 0xad, 0x73, 0xd5, + 0x18, 0xfe, 0x0b, 0x14, 0x63, 0x1a, 0xf2, 0xfa, 0xcc, 0x7a, 0x61, 0xa3, 0xbc, 0x73, 0xef, 0xfa, + 0xb3, 0xe0, 0x35, 0x0d, 0x91, 0x0a, 0x71, 0x7f, 0x99, 0x01, 0x85, 0xd7, 0x34, 0x84, 0x75, 0x30, + 0x8f, 0x83, 0x80, 0x11, 0xce, 0x0d, 0x53, 0x1f, 0xc2, 0x15, 0x30, 0x27, 0x68, 0x2b, 0xf2, 0x35, + 0x5d, 0x09, 0x19, 0x24, 0x85, 0x03, 0x2c, 0xb0, 0xba, 0xea, 0x2a, 0x48, 0x8d, 0xe1, 0x0e, 0xa8, + 0xa8, 0x95, 0x79, 0x69, 0x96, 0x34, 0x09, 0x53, 0x37, 0x56, 0xb1, 0x51, 0xbb, 0xca, 0x9d, 0xb2, + 0xb2, 0x7f, 0xa6, 0xcc, 0x68, 0x14, 0xc0, 0x87, 0x60, 0x5e, 0x74, 0x46, 0x2f, 0x9b, 0xa5, 0xab, + 0xdc, 0xa9, 0x89, 0xe1, 0x32, 0xe5, 0x5d, 0x82, 0xe6, 0x44, 0x47, 0xdd, 0x29, 0x5b, 0xc0, 0x12, + 0x1d, 0x2f, 0x4a, 0x03, 0xd2, 0x51, 0xf7, 0x49, 0xb1, 0xb1, 0x7c, 0x95, 0x3b, 0xf6, 0x48, 0xf8, + 0x91, 0xf4, 0xa1, 0x79, 0xd1, 0x51, 0x03, 0xf8, 0x10, 0x00, 0x3d, 0x25, 0xa5, 0xa0, 0x6f, 0x83, + 0x85, 0xab, 0xdc, 0x29, 0x29, 0xab, 0xe2, 0x1e, 0x0e, 0xa1, 0x0b, 0x66, 0x35, 0xb7, 0xa5, 0xb8, + 0x2b, 0x57, 0xb9, 0x63, 0xc5, 0x34, 0xd4, 0x9c, 0xda, 0x25, 0x4b, 0xc5, 0x48, 0x42, 0xdb, 0x24, + 0x50, 0x07, 0xae, 0x85, 0xfa, 0xd0, 0xfd, 0x61, 0x06, 0x58, 0x67, 0x1d, 0x44, 0x78, 0x16, 0x0b, + 0xf8, 0x02, 0xd8, 0x3e, 0x4d, 0x05, 0xc3, 0xbe, 0xf0, 0xc6, 0x4a, 0xdb, 0x78, 0x30, 0xec, 0xb0, + 0xc9, 0x08, 0x17, 0xd5, 0xfa, 0xa6, 0x3d, 0x53, 0xff, 0x65, 0x30, 0xdb, 0x8c, 0x29, 0x4d, 0x54, + 0x27, 0x54, 0x90, 0x06, 0x10, 0xa9, 0xaa, 0xa9, 0x5d, 0x2e, 0xa8, 0xc7, 0xdf, 0x3f, 0xae, 0xef, + 0xf2, 0x44, 0xab, 0x34, 0x56, 0xcc, 0x03, 0xb0, 0xaa, 0xb5, 0x4d, 0xbe, 0x2b, 0x6b, 0xab, 0x5a, + 0xc9, 0x06, 0x05, 0x46, 0x84, 0xda, 0xb4, 0x0a, 0x92, 0x43, 0xb8, 0x0a, 0x2c, 0x46, 0xda, 0x84, + 0x09, 0x12, 0xa8, 0xcd, 0xb1, 0xd0, 0x00, 0xc3, 0xfb, 0xc0, 0x0a, 0x31, 0xf7, 0x32, 0x4e, 0x02, + 0xbd, 0x13, 0x68, 0x3e, 0xc4, 0xfc, 0x0d, 0x27, 0xc1, 0xb3, 0xe2, 0x77, 0x3f, 0x39, 0x53, 0x2e, + 0x06, 0xe5, 0x3d, 0xdf, 0x27, 0x9c, 0x9f, 0x65, 0xad, 0x98, 0xfc, 0x41, 0x87, 0xed, 0x80, 0x0a, + 0x17, 0x94, 0xe1, 0x90, 0x78, 0x17, 0xa4, 0x6b, 0xfa, 0x4c, 0x77, 0x8d, 0xb1, 0xff, 0x8f, 0x74, + 0x39, 0x1a, 0x05, 0x46, 0xe2, 0x63, 0x01, 0x94, 0xcf, 0x18, 0xf6, 0x89, 0x79, 0x74, 0xca, 0x5e, + 0x95, 0x90, 0x19, 0x09, 0x83, 0xa4, 0xb6, 0x88, 0x12, 0x42, 0x33, 0x61, 0xbe, 0xa7, 0x3e, 0x94, + 0x19, 0x8c, 0x90, 0x0e, 0xf1, 0x55, 0x19, 0x8b, 0xc8, 0x20, 0xb8, 0x0b, 0x16, 0x82, 0x88, 0xab, + 0x17, 0x3c, 0x17, 0xd8, 0xbf, 0xd0, 0xcb, 0x6f, 0xd8, 0x57, 0xb9, 0x53, 0x31, 0x8e, 0x53, 0x69, + 0x47, 0x63, 0x08, 0x3e, 0x07, 0xb5, 0x61, 0x9a, 0x9a, 0xad, 0x7e, 0x33, 0x37, 0xe0, 0x55, 0xee, + 0x54, 0x07, 0xa1, 0xca, 0x83, 0x26, 0xb0, 0xdc, 0xe9, 0x80, 0x34, 0xb3, 0x50, 0x35, 0x9f, 0x85, + 0x34, 0x90, 0xd6, 0x38, 0x4a, 0x22, 0xa1, 0x9a, 0x6d, 0x16, 0x69, 0x00, 0x9f, 0x83, 0x12, 0x6d, + 0x13, 0xc6, 0xa2, 0x80, 0x70, 0x75, 0xfb, 0xfe, 0xd9, 0xf3, 0x1f, 0x0d, 0xe3, 0xe5, 0xe2, 0xcc, + 0xbf, 0x93, 0x84, 0x24, 0x94, 0x75, 0xd5, 0x75, 0x6a, 0x16, 0xa7, 0x1d, 0xff, 0x57, 0x76, 0x34, + 0x86, 0x60, 0x03, 0x40, 0x93, 0xc6, 0x88, 0xc8, 0x58, 0xea, 0xa9, 0xef, 0xbf, 0xa2, 0x72, 0xd5, + 0x57, 0xa8, 0xbd, 0x48, 0x39, 0x0f, 0xb0, 0xc0, 0xe8, 0x9a, 0xe5, 0xb8, 0x68, 0x15, 0xed, 0xd9, + 0xe3, 0xa2, 0x35, 0x6f, 0x5b, 0x83, 0xf5, 0x9b, 0x59, 0xa0, 0xa5, 0x3e, 0x1e, 0xa1, 0x6f, 0xfc, + 0xf7, 0xfd, 0xe5, 0xda, 0xf4, 0x87, 0xcb, 0xb5, 0xe9, 0x8f, 0x97, 0x6b, 0xd3, 0x3f, 0x7e, 0x5a, + 0x9b, 0xfa, 0xf0, 0x69, 0x6d, 0xea, 0xd7, 0x4f, 0x6b, 0x53, 0x5f, 0x8e, 0x1e, 0xe7, 0xa4, 0x2d, + 0x4f, 0xf3, 0xe1, 0x5f, 0xca, 0x8e, 0xfa, 0x53, 0xa9, 0x8e, 0xf4, 0xe6, 0x9c, 0xfa, 0xb3, 0xf8, + 0xe4, 0xf7, 0x00, 0x00, 0x00, 0xff, 0xff, 0x33, 0x43, 0xe0, 0x76, 0x72, 0x0e, 0x00, 0x00, +} + +func (m *Params) 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 *Params) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.AllowUnprotectedTxs { + i-- + if m.AllowUnprotectedTxs { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x30 + } + { + size, err := m.ChainConfig.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x2a + if len(m.ExtraEIPs) > 0 { + dAtA3 := make([]byte, len(m.ExtraEIPs)*10) + var j2 int + for _, num1 := range m.ExtraEIPs { + num := uint64(num1) + for num >= 1<<7 { + dAtA3[j2] = uint8(uint64(num)&0x7f | 0x80) + num >>= 7 + j2++ + } + dAtA3[j2] = uint8(num) + j2++ + } + i -= j2 + copy(dAtA[i:], dAtA3[:j2]) + i = encodeVarintEvm(dAtA, i, uint64(j2)) + i-- + dAtA[i] = 0x22 + } + if m.EnableCall { + i-- + if m.EnableCall { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x18 + } + if m.EnableCreate { + i-- + if m.EnableCreate { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x10 + } + if len(m.EvmDenom) > 0 { + i -= len(m.EvmDenom) + copy(dAtA[i:], m.EvmDenom) + i = encodeVarintEvm(dAtA, i, uint64(len(m.EvmDenom))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *ChainConfig) 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 *ChainConfig) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *ChainConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.MergeForkBlock != nil { + { + size := m.MergeForkBlock.Size() + i -= size + if _, err := m.MergeForkBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0x9a + } + if m.ArrowGlacierBlock != nil { + { + size := m.ArrowGlacierBlock.Size() + i -= size + if _, err := m.ArrowGlacierBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0x92 + } + if m.LondonBlock != nil { + { + size := m.LondonBlock.Size() + i -= size + if _, err := m.LondonBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0x8a + } + if m.BerlinBlock != nil { + { + size := m.BerlinBlock.Size() + i -= size + if _, err := m.BerlinBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x6a + } + if m.MuirGlacierBlock != nil { + { + size := m.MuirGlacierBlock.Size() + i -= size + if _, err := m.MuirGlacierBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x62 + } + if m.IstanbulBlock != nil { + { + size := m.IstanbulBlock.Size() + i -= size + if _, err := m.IstanbulBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x5a + } + if m.PetersburgBlock != nil { + { + size := m.PetersburgBlock.Size() + i -= size + if _, err := m.PetersburgBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x52 + } + if m.ConstantinopleBlock != nil { + { + size := m.ConstantinopleBlock.Size() + i -= size + if _, err := m.ConstantinopleBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x4a + } + if m.ByzantiumBlock != nil { + { + size := m.ByzantiumBlock.Size() + i -= size + if _, err := m.ByzantiumBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x42 + } + if m.EIP158Block != nil { + { + size := m.EIP158Block.Size() + i -= size + if _, err := m.EIP158Block.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x3a + } + if m.EIP155Block != nil { + { + size := m.EIP155Block.Size() + i -= size + if _, err := m.EIP155Block.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x32 + } + if len(m.EIP150Hash) > 0 { + i -= len(m.EIP150Hash) + copy(dAtA[i:], m.EIP150Hash) + i = encodeVarintEvm(dAtA, i, uint64(len(m.EIP150Hash))) + i-- + dAtA[i] = 0x2a + } + if m.EIP150Block != nil { + { + size := m.EIP150Block.Size() + i -= size + if _, err := m.EIP150Block.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 + } + if m.DAOForkSupport { + i-- + if m.DAOForkSupport { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x18 + } + if m.DAOForkBlock != nil { + { + size := m.DAOForkBlock.Size() + i -= size + if _, err := m.DAOForkBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if m.HomesteadBlock != nil { + { + size := m.HomesteadBlock.Size() + i -= size + if _, err := m.HomesteadBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *State) 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 *State) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *State) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Value) > 0 { + i -= len(m.Value) + copy(dAtA[i:], m.Value) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Value))) + i-- + dAtA[i] = 0x12 + } + if len(m.Key) > 0 { + i -= len(m.Key) + copy(dAtA[i:], m.Key) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Key))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *TransactionLogs) 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 *TransactionLogs) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *TransactionLogs) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Logs) > 0 { + for iNdEx := len(m.Logs) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Logs[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + } + if len(m.Hash) > 0 { + i -= len(m.Hash) + copy(dAtA[i:], m.Hash) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Hash))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *Log) 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 *Log) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *Log) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Removed { + i-- + if m.Removed { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x48 + } + if m.Index != 0 { + i = encodeVarintEvm(dAtA, i, uint64(m.Index)) + i-- + dAtA[i] = 0x40 + } + if len(m.BlockHash) > 0 { + i -= len(m.BlockHash) + copy(dAtA[i:], m.BlockHash) + i = encodeVarintEvm(dAtA, i, uint64(len(m.BlockHash))) + i-- + dAtA[i] = 0x3a + } + if m.TxIndex != 0 { + i = encodeVarintEvm(dAtA, i, uint64(m.TxIndex)) + i-- + dAtA[i] = 0x30 + } + if len(m.TxHash) > 0 { + i -= len(m.TxHash) + copy(dAtA[i:], m.TxHash) + i = encodeVarintEvm(dAtA, i, uint64(len(m.TxHash))) + i-- + dAtA[i] = 0x2a + } + if m.BlockNumber != 0 { + i = encodeVarintEvm(dAtA, i, uint64(m.BlockNumber)) + i-- + dAtA[i] = 0x20 + } + if len(m.Data) > 0 { + i -= len(m.Data) + copy(dAtA[i:], m.Data) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Data))) + i-- + dAtA[i] = 0x1a + } + if len(m.Topics) > 0 { + for iNdEx := len(m.Topics) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Topics[iNdEx]) + copy(dAtA[i:], m.Topics[iNdEx]) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Topics[iNdEx]))) + i-- + dAtA[i] = 0x12 + } + } + if len(m.Address) > 0 { + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *TxResult) 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 *TxResult) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *TxResult) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.GasUsed != 0 { + i = encodeVarintEvm(dAtA, i, uint64(m.GasUsed)) + i-- + dAtA[i] = 0x30 + } + if m.Reverted { + i-- + if m.Reverted { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x28 + } + if len(m.Ret) > 0 { + i -= len(m.Ret) + copy(dAtA[i:], m.Ret) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Ret))) + i-- + dAtA[i] = 0x22 + } + { + size, err := m.TxLogs.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + if len(m.Bloom) > 0 { + i -= len(m.Bloom) + copy(dAtA[i:], m.Bloom) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Bloom))) + i-- + dAtA[i] = 0x12 + } + if len(m.ContractAddress) > 0 { + i -= len(m.ContractAddress) + copy(dAtA[i:], m.ContractAddress) + i = encodeVarintEvm(dAtA, i, uint64(len(m.ContractAddress))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *AccessTuple) 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 *AccessTuple) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *AccessTuple) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.StorageKeys) > 0 { + for iNdEx := len(m.StorageKeys) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.StorageKeys[iNdEx]) + copy(dAtA[i:], m.StorageKeys[iNdEx]) + i = encodeVarintEvm(dAtA, i, uint64(len(m.StorageKeys[iNdEx]))) + i-- + dAtA[i] = 0x12 + } + } + if len(m.Address) > 0 { + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *TraceConfig) 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 *TraceConfig) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *TraceConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.EnableReturnData { + i-- + if m.EnableReturnData { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x60 + } + if m.EnableMemory { + i-- + if m.EnableMemory { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x58 + } + if m.Overrides != nil { + { + size, err := m.Overrides.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x52 + } + if m.Limit != 0 { + i = encodeVarintEvm(dAtA, i, uint64(m.Limit)) + i-- + dAtA[i] = 0x48 + } + if m.Debug { + i-- + if m.Debug { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x40 + } + if m.DisableStorage { + i-- + if m.DisableStorage { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x30 + } + if m.DisableStack { + i-- + if m.DisableStack { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x28 + } + if m.Reexec != 0 { + i = encodeVarintEvm(dAtA, i, uint64(m.Reexec)) + i-- + dAtA[i] = 0x18 + } + if len(m.Timeout) > 0 { + i -= len(m.Timeout) + copy(dAtA[i:], m.Timeout) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Timeout))) + i-- + dAtA[i] = 0x12 + } + if len(m.Tracer) > 0 { + i -= len(m.Tracer) + copy(dAtA[i:], m.Tracer) + i = encodeVarintEvm(dAtA, i, uint64(len(m.Tracer))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func encodeVarintEvm(dAtA []byte, offset int, v uint64) int { + offset -= sovEvm(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *Params) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.EvmDenom) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if m.EnableCreate { + n += 2 + } + if m.EnableCall { + n += 2 + } + if len(m.ExtraEIPs) > 0 { + l = 0 + for _, e := range m.ExtraEIPs { + l += sovEvm(uint64(e)) + } + n += 1 + sovEvm(uint64(l)) + l + } + l = m.ChainConfig.Size() + n += 1 + l + sovEvm(uint64(l)) + if m.AllowUnprotectedTxs { + n += 2 + } + return n +} + +func (m *ChainConfig) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.HomesteadBlock != nil { + l = m.HomesteadBlock.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.DAOForkBlock != nil { + l = m.DAOForkBlock.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.DAOForkSupport { + n += 2 + } + if m.EIP150Block != nil { + l = m.EIP150Block.Size() + n += 1 + l + sovEvm(uint64(l)) + } + l = len(m.EIP150Hash) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if m.EIP155Block != nil { + l = m.EIP155Block.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.EIP158Block != nil { + l = m.EIP158Block.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.ByzantiumBlock != nil { + l = m.ByzantiumBlock.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.ConstantinopleBlock != nil { + l = m.ConstantinopleBlock.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.PetersburgBlock != nil { + l = m.PetersburgBlock.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.IstanbulBlock != nil { + l = m.IstanbulBlock.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.MuirGlacierBlock != nil { + l = m.MuirGlacierBlock.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.BerlinBlock != nil { + l = m.BerlinBlock.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.LondonBlock != nil { + l = m.LondonBlock.Size() + n += 2 + l + sovEvm(uint64(l)) + } + if m.ArrowGlacierBlock != nil { + l = m.ArrowGlacierBlock.Size() + n += 2 + l + sovEvm(uint64(l)) + } + if m.MergeForkBlock != nil { + l = m.MergeForkBlock.Size() + n += 2 + l + sovEvm(uint64(l)) + } + return n +} + +func (m *State) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Key) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + l = len(m.Value) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + return n +} + +func (m *TransactionLogs) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Hash) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if len(m.Logs) > 0 { + for _, e := range m.Logs { + l = e.Size() + n += 1 + l + sovEvm(uint64(l)) + } + } + return n +} + +func (m *Log) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Address) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if len(m.Topics) > 0 { + for _, s := range m.Topics { + l = len(s) + n += 1 + l + sovEvm(uint64(l)) + } + } + l = len(m.Data) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if m.BlockNumber != 0 { + n += 1 + sovEvm(uint64(m.BlockNumber)) + } + l = len(m.TxHash) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if m.TxIndex != 0 { + n += 1 + sovEvm(uint64(m.TxIndex)) + } + l = len(m.BlockHash) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if m.Index != 0 { + n += 1 + sovEvm(uint64(m.Index)) + } + if m.Removed { + n += 2 + } + return n +} + +func (m *TxResult) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.ContractAddress) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + l = len(m.Bloom) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + l = m.TxLogs.Size() + n += 1 + l + sovEvm(uint64(l)) + l = len(m.Ret) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if m.Reverted { + n += 2 + } + if m.GasUsed != 0 { + n += 1 + sovEvm(uint64(m.GasUsed)) + } + return n +} + +func (m *AccessTuple) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Address) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if len(m.StorageKeys) > 0 { + for _, s := range m.StorageKeys { + l = len(s) + n += 1 + l + sovEvm(uint64(l)) + } + } + return n +} + +func (m *TraceConfig) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Tracer) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + l = len(m.Timeout) + if l > 0 { + n += 1 + l + sovEvm(uint64(l)) + } + if m.Reexec != 0 { + n += 1 + sovEvm(uint64(m.Reexec)) + } + if m.DisableStack { + n += 2 + } + if m.DisableStorage { + n += 2 + } + if m.Debug { + n += 2 + } + if m.Limit != 0 { + n += 1 + sovEvm(uint64(m.Limit)) + } + if m.Overrides != nil { + l = m.Overrides.Size() + n += 1 + l + sovEvm(uint64(l)) + } + if m.EnableMemory { + n += 2 + } + if m.EnableReturnData { + n += 2 + } + return n +} + +func sovEvm(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozEvm(x uint64) (n int) { + return sovEvm(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *Params) 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 ErrIntOverflowEvm + } + 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: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EvmDenom", 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.EvmDenom = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field EnableCreate", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.EnableCreate = bool(v != 0) + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field EnableCall", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.EnableCall = bool(v != 0) + case 4: + if wireType == 0 { + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.ExtraEIPs = append(m.ExtraEIPs, v) + } else if wireType == 2 { + var packedLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + packedLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if packedLen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + packedLen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + var elementCount int + var count int + for _, integer := range dAtA[iNdEx:postIndex] { + if integer < 128 { + count++ + } + } + elementCount = count + if elementCount != 0 && len(m.ExtraEIPs) == 0 { + m.ExtraEIPs = make([]int64, 0, elementCount) + } + for iNdEx < postIndex { + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.ExtraEIPs = append(m.ExtraEIPs, v) + } + } else { + return fmt.Errorf("proto: wrong wireType = %d for field ExtraEIPs", wireType) + } + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ChainConfig", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ChainConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field AllowUnprotectedTxs", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.AllowUnprotectedTxs = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipEvm(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthEvm + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ChainConfig) 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 ErrIntOverflowEvm + } + 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: ChainConfig: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ChainConfig: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field HomesteadBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.HomesteadBlock = &v + if err := m.HomesteadBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DAOForkBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.DAOForkBlock = &v + if err := m.DAOForkBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DAOForkSupport", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.DAOForkSupport = bool(v != 0) + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EIP150Block", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.EIP150Block = &v + if err := m.EIP150Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EIP150Hash", 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.EIP150Hash = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EIP155Block", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.EIP155Block = &v + if err := m.EIP155Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EIP158Block", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.EIP158Block = &v + if err := m.EIP158Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ByzantiumBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.ByzantiumBlock = &v + if err := m.ByzantiumBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 9: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ConstantinopleBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.ConstantinopleBlock = &v + if err := m.ConstantinopleBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 10: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PetersburgBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.PetersburgBlock = &v + if err := m.PetersburgBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 11: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field IstanbulBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.IstanbulBlock = &v + if err := m.IstanbulBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 12: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MuirGlacierBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.MuirGlacierBlock = &v + if err := m.MuirGlacierBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 13: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field BerlinBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.BerlinBlock = &v + if err := m.BerlinBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 17: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LondonBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.LondonBlock = &v + if err := m.LondonBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 18: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ArrowGlacierBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.ArrowGlacierBlock = &v + if err := m.ArrowGlacierBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 19: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MergeForkBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.MergeForkBlock = &v + if err := m.MergeForkBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipEvm(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthEvm + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *State) 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 ErrIntOverflowEvm + } + 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: State: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: State: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Key", 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.Key = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Value", 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.Value = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipEvm(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthEvm + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TransactionLogs) 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 ErrIntOverflowEvm + } + 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: TransactionLogs: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TransactionLogs: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Hash", 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.Hash = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Logs", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Logs = append(m.Logs, &Log{}) + if err := m.Logs[len(m.Logs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipEvm(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthEvm + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Log) 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 ErrIntOverflowEvm + } + 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: Log: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Log: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Address", 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.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Topics", 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.Topics = append(m.Topics, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...) + if m.Data == nil { + m.Data = []byte{} + } + iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field BlockNumber", wireType) + } + m.BlockNumber = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.BlockNumber |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TxHash", 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.TxHash = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TxIndex", wireType) + } + m.TxIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.TxIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field BlockHash", 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.BlockHash = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 8: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType) + } + m.Index = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Index |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 9: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Removed", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.Removed = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipEvm(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthEvm + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TxResult) 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 ErrIntOverflowEvm + } + 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: TxResult: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TxResult: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ContractAddress", 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.ContractAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Bloom", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Bloom = append(m.Bloom[:0], dAtA[iNdEx:postIndex]...) + if m.Bloom == nil { + m.Bloom = []byte{} + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TxLogs", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.TxLogs.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + 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 ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + 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 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Reverted", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.Reverted = bool(v != 0) + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field GasUsed", wireType) + } + m.GasUsed = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.GasUsed |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipEvm(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthEvm + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *AccessTuple) 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 ErrIntOverflowEvm + } + 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: AccessTuple: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: AccessTuple: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Address", 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.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field StorageKeys", 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.StorageKeys = append(m.StorageKeys, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipEvm(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthEvm + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TraceConfig) 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 ErrIntOverflowEvm + } + 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: TraceConfig: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TraceConfig: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Tracer", 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.Tracer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Timeout", 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.Timeout = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Reexec", wireType) + } + m.Reexec = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Reexec |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DisableStack", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.DisableStack = bool(v != 0) + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DisableStorage", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.DisableStorage = bool(v != 0) + case 8: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Debug", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.Debug = bool(v != 0) + case 9: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType) + } + m.Limit = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Limit |= int32(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 10: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Overrides", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthEvm + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthEvm + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Overrides == nil { + m.Overrides = &ChainConfig{} + } + if err := m.Overrides.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 11: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field EnableMemory", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.EnableMemory = bool(v != 0) + case 12: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field EnableReturnData", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvm + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.EnableReturnData = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipEvm(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthEvm + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipEvm(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + depth := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowEvm + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowEvm + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + case 1: + iNdEx += 8 + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowEvm + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if length < 0 { + return 0, ErrInvalidLengthEvm + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupEvm + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthEvm + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthEvm = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowEvm = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupEvm = fmt.Errorf("proto: unexpected end of group") +) diff --git a/x/evm/migrations/v3/types/params.go b/x/evm/migrations/v3/types/params.go new file mode 100644 index 0000000000..91f9b32914 --- /dev/null +++ b/x/evm/migrations/v3/types/params.go @@ -0,0 +1,150 @@ +package types + +import ( + "fmt" + "math/big" + + "github.com/ethereum/go-ethereum/params" + + sdk "github.com/cosmos/cosmos-sdk/types" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + "github.com/ethereum/go-ethereum/core/vm" + "github.com/evmos/ethermint/types" +) + +var _ paramtypes.ParamSet = &Params{} + +var ( + // DefaultEVMDenom defines the default EVM denomination on Ethermint + DefaultEVMDenom = types.AttoPhoton + // DefaultMinGasMultiplier is 0.5 or 50% + DefaultMinGasMultiplier = sdk.NewDecWithPrec(50, 2) + // DefaultAllowUnprotectedTxs rejects all unprotected txs (i.e false) + DefaultAllowUnprotectedTxs = false +) + +// Parameter keys +var ( + ParamStoreKeyEVMDenom = []byte("EVMDenom") + ParamStoreKeyEnableCreate = []byte("EnableCreate") + ParamStoreKeyEnableCall = []byte("EnableCall") + ParamStoreKeyExtraEIPs = []byte("EnableExtraEIPs") + ParamStoreKeyChainConfig = []byte("ChainConfig") + ParamStoreKeyAllowUnprotectedTxs = []byte("AllowUnprotectedTxs") + + // AvailableExtraEIPs define the list of all EIPs that can be enabled by the + // EVM interpreter. These EIPs are applied in order and can override the + // instruction sets from the latest hard fork enabled by the ChainConfig. For + // more info check: + // https://github.com/ethereum/go-ethereum/blob/master/core/vm/interpreter.go#L97 + AvailableExtraEIPs = []int64{1344, 1884, 2200, 2929, 3198, 3529} +) + +// ParamKeyTable returns the parameter key table. +func ParamKeyTable() paramtypes.KeyTable { + return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) +} + +// NewParams creates a new Params instance +func NewParams(evmDenom string, enableCreate, enableCall bool, config ChainConfig, extraEIPs ...int64) Params { + return Params{ + EvmDenom: evmDenom, + EnableCreate: enableCreate, + EnableCall: enableCall, + ExtraEIPs: extraEIPs, + ChainConfig: config, + } +} + +// DefaultParams returns default evm parameters +// ExtraEIPs is empty to prevent overriding the latest hard fork instruction set +func DefaultParams() Params { + return Params{ + EvmDenom: DefaultEVMDenom, + EnableCreate: true, + EnableCall: true, + ChainConfig: DefaultChainConfig(), + ExtraEIPs: nil, + AllowUnprotectedTxs: DefaultAllowUnprotectedTxs, + } +} + +// ParamSetPairs returns the parameter set pairs. +func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { + return paramtypes.ParamSetPairs{ + paramtypes.NewParamSetPair(ParamStoreKeyEVMDenom, &p.EvmDenom, validateEVMDenom), + paramtypes.NewParamSetPair(ParamStoreKeyEnableCreate, &p.EnableCreate, validateBool), + paramtypes.NewParamSetPair(ParamStoreKeyEnableCall, &p.EnableCall, validateBool), + paramtypes.NewParamSetPair(ParamStoreKeyExtraEIPs, &p.ExtraEIPs, validateEIPs), + paramtypes.NewParamSetPair(ParamStoreKeyChainConfig, &p.ChainConfig, validateChainConfig), + paramtypes.NewParamSetPair(ParamStoreKeyAllowUnprotectedTxs, &p.AllowUnprotectedTxs, validateBool), + } +} + +// Validate performs basic validation on evm parameters. +func (p Params) Validate() error { + if err := sdk.ValidateDenom(p.EvmDenom); err != nil { + return err + } + + if err := validateEIPs(p.ExtraEIPs); err != nil { + return err + } + + return p.ChainConfig.Validate() +} + +// EIPs returns the ExtraEips as a int slice +func (p Params) EIPs() []int { + eips := make([]int, len(p.ExtraEIPs)) + for i, eip := range p.ExtraEIPs { + eips[i] = int(eip) + } + return eips +} + +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 { + return fmt.Errorf("invalid parameter type: %T", i) + } + return nil +} + +func validateEIPs(i interface{}) error { + eips, ok := i.([]int64) + if !ok { + return fmt.Errorf("invalid EIP slice type: %T", i) + } + + for _, eip := range eips { + if !vm.ValidEip(int(eip)) { + return fmt.Errorf("EIP %d is not activateable, valid EIPS are: %s", eip, vm.ActivateableEips()) + } + } + + 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() +} + +// IsLondon returns if london hardfork is enabled. +func IsLondon(ethConfig *params.ChainConfig, height int64) bool { + return ethConfig.IsLondon(big.NewInt(height)) +} diff --git a/x/evm/module.go b/x/evm/module.go index c7b837a57b..73c245afbc 100644 --- a/x/evm/module.go +++ b/x/evm/module.go @@ -44,7 +44,7 @@ func (AppModuleBasic) RegisterLegacyAminoCodec(_ *codec.LegacyAmino) { // ConsensusVersion returns the consensus state-breaking version for the module. func (AppModuleBasic) ConsensusVersion() uint64 { - return 1 + return 3 } // DefaultGenesis returns default genesis state as raw bytes for the evm @@ -123,7 +123,15 @@ func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), am.keeper) types.RegisterQueryServer(cfg.QueryServer(), am.keeper) - _ = keeper.NewMigrator(*am.keeper) + m := keeper.NewMigrator(*am.keeper) + err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2) + if err != nil { + panic(err) + } + err = cfg.RegisterMigration(types.ModuleName, 2, m.Migrate2to3) + if err != nil { + panic(err) + } } // Route returns the message routing key for the evm module. diff --git a/x/evm/types/chain_config.go b/x/evm/types/chain_config.go index fbc0288ff5..8a040101c7 100644 --- a/x/evm/types/chain_config.go +++ b/x/evm/types/chain_config.go @@ -31,7 +31,8 @@ func (cc ChainConfig) EthereumConfig(chainID *big.Int) *params.ChainConfig { BerlinBlock: getBlockValue(cc.BerlinBlock), LondonBlock: getBlockValue(cc.LondonBlock), ArrowGlacierBlock: getBlockValue(cc.ArrowGlacierBlock), - MergeForkBlock: getBlockValue(cc.MergeForkBlock), + GrayGlacierBlock: getBlockValue(cc.GrayGlacierBlock), + MergeNetsplitBlock: getBlockValue(cc.MergeNetsplitBlock), TerminalTotalDifficulty: nil, Ethash: nil, Clique: nil, @@ -53,7 +54,8 @@ func DefaultChainConfig() ChainConfig { berlinBlock := sdk.ZeroInt() londonBlock := sdk.ZeroInt() arrowGlacierBlock := sdk.ZeroInt() - mergeForkBlock := sdk.ZeroInt() + grayGlacierBlock := sdk.ZeroInt() + mergeNetsplitBlock := sdk.ZeroInt() return ChainConfig{ HomesteadBlock: &homesteadBlock, @@ -71,7 +73,8 @@ func DefaultChainConfig() ChainConfig { BerlinBlock: &berlinBlock, LondonBlock: &londonBlock, ArrowGlacierBlock: &arrowGlacierBlock, - MergeForkBlock: &mergeForkBlock, + GrayGlacierBlock: &grayGlacierBlock, + MergeNetsplitBlock: &mergeNetsplitBlock, } } @@ -128,8 +131,11 @@ func (cc ChainConfig) Validate() error { if err := validateBlock(cc.ArrowGlacierBlock); err != nil { return sdkerrors.Wrap(err, "arrowGlacierBlock") } - if err := validateBlock(cc.MergeForkBlock); err != nil { - return sdkerrors.Wrap(err, "mergeForkBlock") + if err := validateBlock(cc.GrayGlacierBlock); err != nil { + return sdkerrors.Wrap(err, "GrayGlacierBlock") + } + if err := validateBlock(cc.MergeNetsplitBlock); err != nil { + return sdkerrors.Wrap(err, "MergeNetsplitBlock") } // NOTE: chain ID is not needed to check config order diff --git a/x/evm/types/evm.pb.go b/x/evm/types/evm.pb.go index 78977f2b5f..7420f7a4d3 100644 --- a/x/evm/types/evm.pb.go +++ b/x/evm/types/evm.pb.go @@ -141,8 +141,10 @@ type ChainConfig struct { LondonBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,17,opt,name=london_block,json=londonBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"london_block,omitempty" yaml:"london_block"` // Eip-4345 (bomb delay) switch block (nil = no fork, 0 = already activated) ArrowGlacierBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,18,opt,name=arrow_glacier_block,json=arrowGlacierBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"arrow_glacier_block,omitempty" yaml:"arrow_glacier_block"` - // EIP-3675 (TheMerge) switch block (nil = no fork, 0 = already in merge proceedings) - MergeForkBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,19,opt,name=merge_fork_block,json=mergeForkBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"merge_fork_block,omitempty" yaml:"merge_fork_block"` + // EIP-5133 (bomb delay) switch block (nil = no fork, 0 = already activated) + GrayGlacierBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,20,opt,name=gray_glacier_block,json=grayGlacierBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"gray_glacier_block,omitempty" yaml:"gray_glacier_block"` + // Virtual fork after The Merge to use as a network splitter + MergeNetsplitBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,21,opt,name=merge_netsplit_block,json=mergeNetsplitBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"merge_netsplit_block,omitempty" yaml:"merge_netsplit_block"` } func (m *ChainConfig) Reset() { *m = ChainConfig{} } @@ -657,100 +659,104 @@ func init() { func init() { proto.RegisterFile("ethermint/evm/v1/evm.proto", fileDescriptor_d21ecc92c8c8583e) } var fileDescriptor_d21ecc92c8c8583e = []byte{ - // 1475 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x57, 0xdf, 0x6e, 0xdb, 0xb6, - 0x1a, 0x4f, 0x62, 0x27, 0x91, 0x69, 0xc7, 0x56, 0x98, 0x34, 0xc7, 0x4d, 0x71, 0xa2, 0x1c, 0x5d, - 0x1c, 0xe4, 0x00, 0x6d, 0xdc, 0xa4, 0x08, 0x4e, 0xd1, 0x62, 0x17, 0x51, 0x92, 0xb6, 0xc9, 0xba, - 0x2d, 0x60, 0x32, 0x0c, 0x18, 0x30, 0x08, 0xb4, 0xc4, 0xca, 0x5a, 0x24, 0xd1, 0x20, 0x29, 0xd7, - 0x1e, 0xf6, 0x00, 0x03, 0x76, 0xb3, 0x47, 0xd8, 0x2b, 0xec, 0x2d, 0x8a, 0x5d, 0xf5, 0x66, 0xc0, - 0xb0, 0x0b, 0xa1, 0x48, 0xef, 0x72, 0xe9, 0x27, 0x18, 0x44, 0xd2, 0x7f, 0x13, 0x6c, 0x4b, 0xae, - 0xcc, 0xdf, 0xf7, 0xe7, 0xf7, 0x23, 0x3f, 0x7e, 0x14, 0x69, 0xb0, 0x4e, 0x44, 0x8b, 0xb0, 0x38, - 0x4c, 0x44, 0x83, 0x74, 0xe2, 0x46, 0x67, 0x27, 0xff, 0xd9, 0x6e, 0x33, 0x2a, 0x28, 0x34, 0x87, - 0xbe, 0xed, 0xdc, 0xd8, 0xd9, 0x59, 0x5f, 0x0d, 0x68, 0x40, 0xa5, 0xb3, 0x91, 0x8f, 0x54, 0x9c, - 0xfd, 0xdb, 0x1c, 0x58, 0x38, 0xc5, 0x0c, 0xc7, 0x1c, 0xee, 0x80, 0x12, 0xe9, 0xc4, 0xae, 0x4f, - 0x12, 0x1a, 0xd7, 0x67, 0x37, 0x67, 0xb7, 0x4a, 0xce, 0x6a, 0x3f, 0xb3, 0xcc, 0x1e, 0x8e, 0xa3, - 0x67, 0xf6, 0xd0, 0x65, 0x23, 0x83, 0x74, 0xe2, 0xc3, 0x7c, 0x08, 0x3f, 0x01, 0x4b, 0x24, 0xc1, - 0xcd, 0x88, 0xb8, 0x1e, 0x23, 0x58, 0x90, 0xfa, 0xdc, 0xe6, 0xec, 0x96, 0xe1, 0xd4, 0xfb, 0x99, - 0xb5, 0xaa, 0xd3, 0xc6, 0xdd, 0x36, 0xaa, 0x28, 0x7c, 0x20, 0x21, 0xfc, 0x3f, 0x28, 0x0f, 0xfc, - 0x38, 0x8a, 0xea, 0x05, 0x99, 0xbc, 0xd6, 0xcf, 0x2c, 0x38, 0x99, 0x8c, 0xa3, 0xc8, 0x46, 0x40, - 0xa7, 0xe2, 0x28, 0x82, 0xfb, 0x00, 0x90, 0xae, 0x60, 0xd8, 0x25, 0x61, 0x9b, 0xd7, 0x8b, 0x9b, - 0x85, 0xad, 0x82, 0x63, 0x5f, 0x66, 0x56, 0xe9, 0x28, 0xb7, 0x1e, 0x1d, 0x9f, 0xf2, 0x7e, 0x66, - 0x2d, 0x6b, 0x92, 0x61, 0xa0, 0x8d, 0x4a, 0x12, 0x1c, 0x85, 0x6d, 0x0e, 0xbf, 0x01, 0x15, 0xaf, - 0x85, 0xc3, 0xc4, 0xf5, 0x68, 0xf2, 0x26, 0x0c, 0xea, 0xf3, 0x9b, 0xb3, 0x5b, 0xe5, 0xdd, 0x7f, - 0x6f, 0x4f, 0xd7, 0x6d, 0xfb, 0x20, 0x8f, 0x3a, 0x90, 0x41, 0xce, 0x83, 0x77, 0x99, 0x35, 0xd3, - 0xcf, 0xac, 0x15, 0x45, 0x3d, 0x4e, 0x60, 0xa3, 0xb2, 0x37, 0x8a, 0xb4, 0x7f, 0xa9, 0x82, 0xf2, - 0x58, 0x26, 0x8c, 0x41, 0xad, 0x45, 0x63, 0xc2, 0x05, 0xc1, 0xbe, 0xdb, 0x8c, 0xa8, 0x77, 0xa1, - 0x4b, 0x7c, 0xf8, 0x47, 0x66, 0xfd, 0x37, 0x08, 0x45, 0x2b, 0x6d, 0x6e, 0x7b, 0x34, 0x6e, 0x78, - 0x94, 0xc7, 0x94, 0xeb, 0x9f, 0x47, 0xdc, 0xbf, 0x68, 0x88, 0x5e, 0x9b, 0xf0, 0xed, 0xe3, 0x44, - 0xf4, 0x33, 0x6b, 0x4d, 0x09, 0x4f, 0x51, 0xd9, 0xa8, 0x3a, 0xb4, 0x38, 0xb9, 0x01, 0xf6, 0x40, - 0xd5, 0xc7, 0xd4, 0x7d, 0x43, 0xd9, 0x85, 0x56, 0x9b, 0x93, 0x6a, 0x67, 0xff, 0x5c, 0xed, 0x32, - 0xb3, 0x2a, 0x87, 0xfb, 0x5f, 0xbc, 0xa0, 0xec, 0x42, 0x72, 0xf6, 0x33, 0xeb, 0x9e, 0x52, 0x9f, - 0x64, 0xb6, 0x51, 0xc5, 0xc7, 0x74, 0x18, 0x06, 0xbf, 0x02, 0xe6, 0x30, 0x80, 0xa7, 0xed, 0x36, - 0x65, 0x42, 0xef, 0xec, 0xa3, 0xcb, 0xcc, 0xaa, 0x6a, 0xca, 0x33, 0xe5, 0xe9, 0x67, 0xd6, 0xbf, - 0xa6, 0x48, 0x75, 0x8e, 0x8d, 0xaa, 0x9a, 0x56, 0x87, 0x42, 0x0e, 0x2a, 0x24, 0x6c, 0xef, 0xec, - 0x3d, 0xd6, 0x2b, 0x2a, 0xca, 0x15, 0x9d, 0xde, 0x6a, 0x45, 0xe5, 0xa3, 0xe3, 0xd3, 0x9d, 0xbd, - 0xc7, 0x83, 0x05, 0xe9, 0x7d, 0x1c, 0xa7, 0xb5, 0x51, 0x59, 0x41, 0xb5, 0x9a, 0x63, 0xa0, 0xa1, - 0xdb, 0xc2, 0xbc, 0x25, 0xbb, 0xa4, 0xe4, 0x6c, 0x5d, 0x66, 0x16, 0x50, 0x4c, 0xaf, 0x30, 0x6f, - 0x8d, 0xf6, 0xa5, 0xd9, 0xfb, 0x0e, 0x27, 0x22, 0x4c, 0xe3, 0x01, 0x17, 0x50, 0xc9, 0x79, 0xd4, - 0x70, 0xfe, 0x7b, 0x7a, 0xfe, 0x0b, 0x77, 0x9e, 0xff, 0xde, 0x4d, 0xf3, 0xdf, 0x9b, 0x9c, 0xbf, - 0x8a, 0x19, 0x8a, 0x3e, 0xd5, 0xa2, 0x8b, 0x77, 0x16, 0x7d, 0x7a, 0x93, 0xe8, 0xd3, 0x49, 0x51, - 0x15, 0x93, 0x37, 0xfb, 0x54, 0x25, 0xea, 0xc6, 0xdd, 0x9b, 0xfd, 0x5a, 0x51, 0xab, 0x43, 0x8b, - 0x92, 0xfb, 0x1e, 0xac, 0x7a, 0x34, 0xe1, 0x22, 0xb7, 0x25, 0xb4, 0x1d, 0x11, 0xad, 0x59, 0x92, - 0x9a, 0xc7, 0xb7, 0xd2, 0x7c, 0xa0, 0x4f, 0xf6, 0x0d, 0x7c, 0x36, 0x5a, 0x99, 0x34, 0x2b, 0xf5, - 0x36, 0x30, 0xdb, 0x44, 0x10, 0xc6, 0x9b, 0x29, 0x0b, 0xb4, 0x32, 0x90, 0xca, 0x47, 0xb7, 0x52, - 0xd6, 0xe7, 0x60, 0x9a, 0xcb, 0x46, 0xb5, 0x91, 0x49, 0x29, 0x7e, 0x0b, 0xaa, 0x61, 0x3e, 0x8d, - 0x66, 0x1a, 0x69, 0xbd, 0xb2, 0xd4, 0x3b, 0xb8, 0x95, 0x9e, 0x3e, 0xcc, 0x93, 0x4c, 0x36, 0x5a, - 0x1a, 0x18, 0x94, 0x56, 0x0a, 0x60, 0x9c, 0x86, 0xcc, 0x0d, 0x22, 0xec, 0x85, 0x84, 0x69, 0xbd, - 0x8a, 0xd4, 0x7b, 0x79, 0x2b, 0xbd, 0xfb, 0x4a, 0xef, 0x3a, 0x9b, 0x8d, 0xcc, 0xdc, 0xf8, 0x52, - 0xd9, 0x94, 0xac, 0x0f, 0x2a, 0x4d, 0xc2, 0xa2, 0x30, 0xd1, 0x82, 0x4b, 0x52, 0x70, 0xff, 0x56, - 0x82, 0xba, 0x4f, 0xc7, 0x79, 0x6c, 0x54, 0x56, 0x70, 0xa8, 0x12, 0xd1, 0xc4, 0xa7, 0x03, 0x95, - 0xe5, 0xbb, 0xab, 0x8c, 0xf3, 0xd8, 0xa8, 0xac, 0xa0, 0x52, 0xe9, 0x82, 0x15, 0xcc, 0x18, 0x7d, - 0x3b, 0x55, 0x43, 0x28, 0xc5, 0x5e, 0xdd, 0x4a, 0x6c, 0x5d, 0x89, 0xdd, 0x40, 0x67, 0xa3, 0x65, - 0x69, 0x9d, 0xa8, 0x22, 0x05, 0x66, 0x4c, 0x58, 0x40, 0xc6, 0xef, 0x81, 0x95, 0xbb, 0xb7, 0xe6, - 0x34, 0x97, 0x8d, 0xaa, 0xd2, 0x34, 0xfc, 0xf6, 0x9f, 0x14, 0x8d, 0xaa, 0x59, 0x3b, 0x29, 0x1a, - 0x35, 0xd3, 0x3c, 0x29, 0x1a, 0xa6, 0xb9, 0x8c, 0x96, 0x7a, 0x34, 0xa2, 0x6e, 0xe7, 0x89, 0xca, - 0x40, 0x65, 0xf2, 0x16, 0x73, 0x7d, 0x90, 0x51, 0xd5, 0xc3, 0x02, 0x47, 0x3d, 0x2e, 0x34, 0x5d, - 0x03, 0xcc, 0x9f, 0x89, 0xfc, 0x5d, 0x60, 0x82, 0xc2, 0x05, 0xe9, 0xa9, 0x0b, 0x12, 0xe5, 0x43, - 0xb8, 0x0a, 0xe6, 0x3b, 0x38, 0x4a, 0xd5, 0x03, 0xa3, 0x84, 0x14, 0xb0, 0x4f, 0x41, 0xed, 0x9c, - 0xe1, 0x84, 0x63, 0x4f, 0x84, 0x34, 0x79, 0x4d, 0x03, 0x0e, 0x21, 0x28, 0xca, 0x0f, 0xb5, 0xca, - 0x95, 0x63, 0xf8, 0x3f, 0x50, 0x8c, 0x68, 0xc0, 0xeb, 0x73, 0x9b, 0x85, 0xad, 0xf2, 0xee, 0xbd, - 0xeb, 0x57, 0xfc, 0x6b, 0x1a, 0x20, 0x19, 0x62, 0xff, 0x3a, 0x07, 0x0a, 0xaf, 0x69, 0x00, 0xeb, - 0x60, 0x11, 0xfb, 0x3e, 0x23, 0x9c, 0x6b, 0xa6, 0x01, 0x84, 0x6b, 0x60, 0x41, 0xd0, 0x76, 0xe8, - 0x29, 0xba, 0x12, 0xd2, 0x28, 0x17, 0xf6, 0xb1, 0xc0, 0xf2, 0xaa, 0xab, 0x20, 0x39, 0x86, 0xbb, - 0xa0, 0x22, 0x57, 0xe6, 0x26, 0x69, 0xdc, 0x24, 0x4c, 0xde, 0x58, 0x45, 0xa7, 0x76, 0x95, 0x59, - 0x65, 0x69, 0xff, 0x5c, 0x9a, 0xd1, 0x38, 0x80, 0x0f, 0xc1, 0xa2, 0xe8, 0x8e, 0x5f, 0x36, 0x2b, - 0x57, 0x99, 0x55, 0x13, 0xa3, 0x65, 0xe6, 0x77, 0x09, 0x5a, 0x10, 0x5d, 0x79, 0xa7, 0x34, 0x80, - 0x21, 0xba, 0x6e, 0x98, 0xf8, 0xa4, 0x2b, 0xef, 0x93, 0xa2, 0xb3, 0x7a, 0x95, 0x59, 0xe6, 0x58, - 0xf8, 0x71, 0xee, 0x43, 0x8b, 0xa2, 0x2b, 0x07, 0xf0, 0x21, 0x00, 0x6a, 0x4a, 0x52, 0x41, 0xdd, - 0x06, 0x4b, 0x57, 0x99, 0x55, 0x92, 0x56, 0xc9, 0x3d, 0x1a, 0x42, 0x1b, 0xcc, 0x2b, 0x6e, 0x43, - 0x72, 0x57, 0xae, 0x32, 0xcb, 0x88, 0x68, 0xa0, 0x38, 0x95, 0x2b, 0x2f, 0x15, 0x23, 0x31, 0xed, - 0x10, 0x5f, 0x7e, 0x70, 0x0d, 0x34, 0x80, 0xf6, 0x8f, 0x73, 0xc0, 0x38, 0xef, 0x22, 0xc2, 0xd3, - 0x48, 0xc0, 0x17, 0xc0, 0xf4, 0x68, 0x22, 0x18, 0xf6, 0x84, 0x3b, 0x51, 0x5a, 0xe7, 0xc1, 0xa8, - 0xc3, 0xa6, 0x23, 0x6c, 0x54, 0x1b, 0x98, 0xf6, 0x75, 0xfd, 0x57, 0xc1, 0x7c, 0x33, 0xa2, 0x34, - 0x96, 0x9d, 0x50, 0x41, 0x0a, 0x40, 0x24, 0xab, 0x26, 0x77, 0xb9, 0x20, 0x1f, 0x72, 0xff, 0xb9, - 0xbe, 0xcb, 0x53, 0xad, 0xe2, 0xac, 0xe9, 0xc7, 0x5c, 0x55, 0x69, 0xeb, 0x7c, 0x3b, 0xaf, 0xad, - 0x6c, 0x25, 0x13, 0x14, 0x18, 0x11, 0x72, 0xd3, 0x2a, 0x28, 0x1f, 0xc2, 0x75, 0x60, 0x30, 0xd2, - 0x21, 0x4c, 0x10, 0x5f, 0x6e, 0x8e, 0x81, 0x86, 0x18, 0xde, 0x07, 0x46, 0x80, 0xb9, 0x9b, 0x72, - 0xe2, 0xab, 0x9d, 0x40, 0x8b, 0x01, 0xe6, 0x5f, 0x72, 0xe2, 0x3f, 0x2b, 0xfe, 0xf0, 0xb3, 0x35, - 0x63, 0x63, 0x50, 0xde, 0xf7, 0x3c, 0xc2, 0xf9, 0x79, 0xda, 0x8e, 0xc8, 0x5f, 0x74, 0xd8, 0x2e, - 0xa8, 0x70, 0x41, 0x19, 0x0e, 0x88, 0x7b, 0x41, 0x7a, 0xba, 0xcf, 0x54, 0xd7, 0x68, 0xfb, 0xa7, - 0xa4, 0xc7, 0xd1, 0x38, 0xd0, 0x12, 0x1f, 0x0a, 0xa0, 0x7c, 0xce, 0xb0, 0x47, 0xf4, 0xa3, 0x33, - 0xef, 0xd5, 0x1c, 0x32, 0x2d, 0xa1, 0x51, 0xae, 0x2d, 0xc2, 0x98, 0xd0, 0x54, 0xe8, 0xf3, 0x34, - 0x80, 0x79, 0x06, 0x23, 0xa4, 0x4b, 0x3c, 0x59, 0xc6, 0x22, 0xd2, 0x08, 0xee, 0x81, 0x25, 0x3f, - 0xe4, 0xf2, 0x35, 0xce, 0x05, 0xf6, 0x2e, 0xd4, 0xf2, 0x1d, 0xf3, 0x2a, 0xb3, 0x2a, 0xda, 0x71, - 0x96, 0xdb, 0xd1, 0x04, 0x82, 0xcf, 0x41, 0x6d, 0x94, 0x26, 0x67, 0x2b, 0x6b, 0x63, 0x38, 0xf0, - 0x2a, 0xb3, 0xaa, 0xc3, 0x50, 0xe9, 0x41, 0x53, 0x38, 0xdf, 0x69, 0x9f, 0x34, 0xd3, 0x40, 0x36, - 0x9f, 0x81, 0x14, 0xc8, 0xad, 0x51, 0x18, 0x87, 0x42, 0x36, 0xdb, 0x3c, 0x52, 0x00, 0x3e, 0x07, - 0x25, 0xda, 0x21, 0x8c, 0x85, 0x3e, 0xe1, 0xf2, 0xf6, 0xfd, 0xbb, 0xa7, 0x3c, 0x1a, 0xc5, 0xe7, - 0x8b, 0xd3, 0xff, 0x34, 0x62, 0x12, 0x53, 0xd6, 0x93, 0xd7, 0xa9, 0x5e, 0x9c, 0x72, 0x7c, 0x26, - 0xed, 0x68, 0x02, 0x41, 0x07, 0x40, 0x9d, 0xc6, 0x88, 0x48, 0x59, 0xe2, 0xca, 0xf3, 0x5f, 0x91, - 0xb9, 0xf2, 0x14, 0x2a, 0x2f, 0x92, 0xce, 0x43, 0x2c, 0x30, 0xba, 0x66, 0x39, 0x29, 0x1a, 0x45, - 0x73, 0xfe, 0xa4, 0x68, 0x2c, 0x9a, 0xc6, 0x70, 0xfd, 0x7a, 0x16, 0x68, 0x65, 0x80, 0xc7, 0xe8, - 0x1d, 0xe7, 0xdd, 0xe5, 0xc6, 0xec, 0xfb, 0xcb, 0x8d, 0xd9, 0x0f, 0x97, 0x1b, 0xb3, 0x3f, 0x7d, - 0xdc, 0x98, 0x79, 0xff, 0x71, 0x63, 0xe6, 0xf7, 0x8f, 0x1b, 0x33, 0x5f, 0x6f, 0x8d, 0x7d, 0xce, - 0x45, 0x0b, 0x33, 0x1e, 0xf2, 0xc6, 0xe8, 0x0f, 0x62, 0x57, 0xfe, 0x45, 0x94, 0x1f, 0xf5, 0xe6, - 0x82, 0xfc, 0xeb, 0xf7, 0xe4, 0xcf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x69, 0xef, 0x82, 0x39, 0x40, - 0x0e, 0x00, 0x00, + // 1538 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x57, 0x5d, 0x4f, 0xdc, 0xca, + 0x19, 0x06, 0x76, 0x01, 0xef, 0xec, 0xb2, 0x6b, 0x86, 0x85, 0x6e, 0x88, 0x8a, 0xa9, 0x2f, 0x2a, + 0x2a, 0x25, 0x10, 0x88, 0x50, 0xa3, 0x44, 0x95, 0xca, 0x02, 0x49, 0xa0, 0x69, 0x8a, 0x06, 0xa2, + 0x4a, 0x95, 0x2a, 0x6b, 0xd6, 0x9e, 0x18, 0x17, 0xdb, 0xb3, 0x9a, 0x19, 0x6f, 0x76, 0xdb, 0xfe, + 0x80, 0x56, 0xbd, 0xe9, 0x4f, 0xe8, 0xcf, 0x89, 0xaa, 0x5e, 0xe4, 0xb2, 0x3a, 0x17, 0x56, 0x44, + 0xee, 0xb8, 0xdc, 0x5f, 0x70, 0x34, 0x1f, 0xfb, 0x09, 0x3a, 0xe7, 0xc0, 0x95, 0xe7, 0x79, 0x3f, + 0x9e, 0x67, 0x3e, 0x5e, 0xfb, 0x1d, 0x83, 0x75, 0x22, 0x2e, 0x09, 0x4b, 0xa2, 0x54, 0xec, 0x90, + 0x4e, 0xb2, 0xd3, 0xd9, 0x95, 0x8f, 0xed, 0x36, 0xa3, 0x82, 0x42, 0x7b, 0xe8, 0xdb, 0x96, 0xc6, + 0xce, 0xee, 0x7a, 0x3d, 0xa4, 0x21, 0x55, 0xce, 0x1d, 0x39, 0xd2, 0x71, 0xee, 0x3f, 0x0b, 0x60, + 0xe1, 0x0c, 0x33, 0x9c, 0x70, 0xb8, 0x0b, 0x4a, 0xa4, 0x93, 0x78, 0x01, 0x49, 0x69, 0xd2, 0x98, + 0xdd, 0x9c, 0xdd, 0x2a, 0x35, 0xeb, 0xfd, 0xdc, 0xb1, 0x7b, 0x38, 0x89, 0x5f, 0xba, 0x43, 0x97, + 0x8b, 0x2c, 0xd2, 0x49, 0x8e, 0xe4, 0x10, 0xfe, 0x06, 0x2c, 0x91, 0x14, 0xb7, 0x62, 0xe2, 0xf9, + 0x8c, 0x60, 0x41, 0x1a, 0x73, 0x9b, 0xb3, 0x5b, 0x56, 0xb3, 0xd1, 0xcf, 0x9d, 0xba, 0x49, 0x1b, + 0x77, 0xbb, 0xa8, 0xa2, 0xf1, 0xa1, 0x82, 0xf0, 0xd7, 0xa0, 0x3c, 0xf0, 0xe3, 0x38, 0x6e, 0x14, + 0x54, 0xf2, 0x5a, 0x3f, 0x77, 0xe0, 0x64, 0x32, 0x8e, 0x63, 0x17, 0x01, 0x93, 0x8a, 0xe3, 0x18, + 0x1e, 0x00, 0x40, 0xba, 0x82, 0x61, 0x8f, 0x44, 0x6d, 0xde, 0x28, 0x6e, 0x16, 0xb6, 0x0a, 0x4d, + 0xf7, 0x3a, 0x77, 0x4a, 0xc7, 0xd2, 0x7a, 0x7c, 0x72, 0xc6, 0xfb, 0xb9, 0xb3, 0x6c, 0x48, 0x86, + 0x81, 0x2e, 0x2a, 0x29, 0x70, 0x1c, 0xb5, 0x39, 0xfc, 0x33, 0xa8, 0xf8, 0x97, 0x38, 0x4a, 0x3d, + 0x9f, 0xa6, 0x1f, 0xa3, 0xb0, 0x31, 0xbf, 0x39, 0xbb, 0x55, 0xde, 0xfb, 0xf9, 0xf6, 0xf4, 0xbe, + 0x6d, 0x1f, 0xca, 0xa8, 0x43, 0x15, 0xd4, 0x7c, 0xfc, 0x39, 0x77, 0x66, 0xfa, 0xb9, 0xb3, 0xa2, + 0xa9, 0xc7, 0x09, 0x5c, 0x54, 0xf6, 0x47, 0x91, 0x70, 0x0f, 0xac, 0xe2, 0x38, 0xa6, 0x9f, 0xbc, + 0x2c, 0x95, 0x1b, 0x4d, 0x7c, 0x41, 0x02, 0x4f, 0x74, 0x79, 0x63, 0x41, 0x2e, 0x12, 0xad, 0x28, + 0xe7, 0x87, 0x91, 0xef, 0xa2, 0xcb, 0xdd, 0xff, 0xd5, 0x40, 0x79, 0x4c, 0x0d, 0x26, 0xa0, 0x76, + 0x49, 0x13, 0xc2, 0x05, 0xc1, 0x81, 0xd7, 0x8a, 0xa9, 0x7f, 0x65, 0x8e, 0xe5, 0xe8, 0xbb, 0xdc, + 0xf9, 0x65, 0x18, 0x89, 0xcb, 0xac, 0xb5, 0xed, 0xd3, 0x64, 0xc7, 0xa7, 0x3c, 0xa1, 0xdc, 0x3c, + 0x9e, 0xf2, 0xe0, 0x6a, 0x47, 0xf4, 0xda, 0x84, 0x6f, 0x9f, 0xa4, 0xa2, 0x9f, 0x3b, 0x6b, 0x7a, + 0xb2, 0x53, 0x54, 0x2e, 0xaa, 0x0e, 0x2d, 0x4d, 0x69, 0x80, 0x3d, 0x50, 0x0d, 0x30, 0xf5, 0x3e, + 0x52, 0x76, 0x65, 0xd4, 0xe6, 0x94, 0xda, 0xf9, 0x4f, 0x57, 0xbb, 0xce, 0x9d, 0xca, 0xd1, 0xc1, + 0x1f, 0x5e, 0x53, 0x76, 0xa5, 0x38, 0xfb, 0xb9, 0xb3, 0xaa, 0xd5, 0x27, 0x99, 0x5d, 0x54, 0x09, + 0x30, 0x1d, 0x86, 0xc1, 0x3f, 0x02, 0x7b, 0x18, 0xc0, 0xb3, 0x76, 0x9b, 0x32, 0x61, 0xaa, 0xe1, + 0xe9, 0x75, 0xee, 0x54, 0x0d, 0xe5, 0xb9, 0xf6, 0xf4, 0x73, 0xe7, 0x67, 0x53, 0xa4, 0x26, 0xc7, + 0x45, 0x55, 0x43, 0x6b, 0x42, 0x21, 0x07, 0x15, 0x12, 0xb5, 0x77, 0xf7, 0x9f, 0x99, 0x15, 0x15, + 0xd5, 0x8a, 0xce, 0xee, 0xb5, 0xa2, 0xf2, 0xf1, 0xc9, 0xd9, 0xee, 0xfe, 0xb3, 0xc1, 0x82, 0xcc, + 0xd9, 0x8f, 0xd3, 0xba, 0xa8, 0xac, 0xa1, 0x5e, 0xcd, 0x09, 0x30, 0xd0, 0xbb, 0xc4, 0xfc, 0x52, + 0x55, 0x56, 0xa9, 0xb9, 0x75, 0x9d, 0x3b, 0x40, 0x33, 0xbd, 0xc5, 0xfc, 0x72, 0x74, 0x2e, 0xad, + 0xde, 0x5f, 0x71, 0x2a, 0xa2, 0x2c, 0x19, 0x70, 0x01, 0x9d, 0x2c, 0xa3, 0x86, 0xf3, 0xdf, 0x37, + 0xf3, 0x5f, 0x78, 0xf0, 0xfc, 0xf7, 0xef, 0x9a, 0xff, 0xfe, 0xe4, 0xfc, 0x75, 0xcc, 0x50, 0xf4, + 0x85, 0x11, 0x5d, 0x7c, 0xb0, 0xe8, 0x8b, 0xbb, 0x44, 0x5f, 0x4c, 0x8a, 0xea, 0x18, 0x59, 0xec, + 0x53, 0x3b, 0xd1, 0xb0, 0x1e, 0x5e, 0xec, 0xb7, 0x36, 0xb5, 0x3a, 0xb4, 0x68, 0xb9, 0xbf, 0x83, + 0xba, 0x4f, 0x53, 0x2e, 0xa4, 0x2d, 0xa5, 0xed, 0x98, 0x18, 0xcd, 0x92, 0xd2, 0x3c, 0xb9, 0x97, + 0xe6, 0x63, 0xf3, 0x35, 0xb8, 0x83, 0xcf, 0x45, 0x2b, 0x93, 0x66, 0xad, 0xde, 0x06, 0x76, 0x9b, + 0x08, 0xc2, 0x78, 0x2b, 0x63, 0xa1, 0x51, 0x06, 0x4a, 0xf9, 0xf8, 0x5e, 0xca, 0xe6, 0x3d, 0x98, + 0xe6, 0x72, 0x51, 0x6d, 0x64, 0xd2, 0x8a, 0x7f, 0x01, 0xd5, 0x48, 0x4e, 0xa3, 0x95, 0xc5, 0x46, + 0xaf, 0xac, 0xf4, 0x0e, 0xef, 0xa5, 0x67, 0x5e, 0xe6, 0x49, 0x26, 0x17, 0x2d, 0x0d, 0x0c, 0x5a, + 0x2b, 0x03, 0x30, 0xc9, 0x22, 0xe6, 0x85, 0x31, 0xf6, 0x23, 0xc2, 0x8c, 0x5e, 0x45, 0xe9, 0xbd, + 0xb9, 0x97, 0xde, 0x23, 0xad, 0x77, 0x9b, 0xcd, 0x45, 0xb6, 0x34, 0xbe, 0xd1, 0x36, 0x2d, 0x1b, + 0x80, 0x4a, 0x8b, 0xb0, 0x38, 0x4a, 0x8d, 0xe0, 0x92, 0x12, 0x3c, 0xb8, 0x97, 0xa0, 0xa9, 0xd3, + 0x71, 0x1e, 0x17, 0x95, 0x35, 0x1c, 0xaa, 0xc4, 0x34, 0x0d, 0xe8, 0x40, 0x65, 0xf9, 0xe1, 0x2a, + 0xe3, 0x3c, 0x2e, 0x2a, 0x6b, 0xa8, 0x55, 0xba, 0x60, 0x05, 0x33, 0x46, 0x3f, 0x4d, 0xed, 0x21, + 0x54, 0x62, 0x6f, 0xef, 0x25, 0xb6, 0xae, 0xc5, 0xee, 0xa0, 0x73, 0xd1, 0xb2, 0xb2, 0x4e, 0xec, + 0x62, 0x06, 0x60, 0xc8, 0x70, 0x6f, 0x4a, 0xb8, 0xfe, 0xf0, 0xc3, 0xbb, 0xcd, 0xe6, 0x22, 0x5b, + 0x1a, 0x27, 0x64, 0xff, 0x06, 0xea, 0x09, 0x61, 0x21, 0xf1, 0x52, 0x22, 0x78, 0x3b, 0x8e, 0x84, + 0x11, 0x5e, 0x7d, 0xf8, 0xfb, 0x78, 0x17, 0x9f, 0x8b, 0xa0, 0x32, 0xbf, 0x37, 0x56, 0x25, 0x7e, + 0x5a, 0xb4, 0xaa, 0x76, 0xed, 0xb4, 0x68, 0xd5, 0x6c, 0xfb, 0xb4, 0x68, 0xd9, 0xf6, 0xf2, 0x69, + 0xd1, 0x5a, 0xb1, 0xeb, 0x68, 0xa9, 0x47, 0x63, 0xea, 0x75, 0x9e, 0xeb, 0x5c, 0x54, 0x26, 0x9f, + 0x30, 0x37, 0x5f, 0x14, 0x54, 0xf5, 0xb1, 0xc0, 0x71, 0x8f, 0x1b, 0x62, 0x64, 0x6b, 0xb9, 0xb1, + 0x1e, 0xb7, 0x03, 0xe6, 0xcf, 0x85, 0xbc, 0xe6, 0xd8, 0xa0, 0x70, 0x45, 0x7a, 0xba, 0x77, 0x23, + 0x39, 0x84, 0x75, 0x30, 0xdf, 0xc1, 0x71, 0xa6, 0xef, 0x4b, 0x25, 0xa4, 0x81, 0x7b, 0x06, 0x6a, + 0x17, 0x0c, 0xa7, 0x1c, 0xfb, 0x22, 0xa2, 0xe9, 0x3b, 0x1a, 0x72, 0x08, 0x41, 0x51, 0xf5, 0x10, + 0x9d, 0xab, 0xc6, 0xf0, 0x57, 0xa0, 0x18, 0xd3, 0x90, 0x37, 0xe6, 0x36, 0x0b, 0x5b, 0xe5, 0xbd, + 0xd5, 0xdb, 0x37, 0x96, 0x77, 0x34, 0x44, 0x2a, 0xc4, 0xfd, 0xef, 0x1c, 0x28, 0xbc, 0xa3, 0x21, + 0x6c, 0x80, 0x45, 0x1c, 0x04, 0x8c, 0x70, 0x6e, 0x98, 0x06, 0x10, 0xae, 0x81, 0x05, 0x41, 0xdb, + 0x91, 0xaf, 0xe9, 0x4a, 0xc8, 0x20, 0x29, 0x1c, 0x60, 0x81, 0x55, 0x17, 0xae, 0x20, 0x35, 0x86, + 0x7b, 0xa0, 0xa2, 0x56, 0xe6, 0xa5, 0x59, 0xd2, 0x22, 0x4c, 0x35, 0xd3, 0x62, 0xb3, 0x76, 0x93, + 0x3b, 0x65, 0x65, 0x7f, 0xaf, 0xcc, 0x68, 0x1c, 0xc0, 0x27, 0x60, 0x51, 0x74, 0xc7, 0xfb, 0xe0, + 0xca, 0x4d, 0xee, 0xd4, 0xc4, 0x68, 0x99, 0xb2, 0xcd, 0xa1, 0x05, 0xd1, 0x55, 0xed, 0x6e, 0x07, + 0x58, 0xa2, 0xeb, 0x45, 0x69, 0x40, 0xba, 0xaa, 0xd5, 0x15, 0x9b, 0xf5, 0x9b, 0xdc, 0xb1, 0xc7, + 0xc2, 0x4f, 0xa4, 0x0f, 0x2d, 0x8a, 0xae, 0x1a, 0xc0, 0x27, 0x00, 0xe8, 0x29, 0x29, 0x05, 0xdd, + 0xa8, 0x96, 0x6e, 0x72, 0xa7, 0xa4, 0xac, 0x8a, 0x7b, 0x34, 0x84, 0x2e, 0x98, 0xd7, 0xdc, 0x96, + 0xe2, 0xae, 0xdc, 0xe4, 0x8e, 0x15, 0xd3, 0x50, 0x73, 0x6a, 0x97, 0xdc, 0x2a, 0x46, 0x12, 0xda, + 0x21, 0x81, 0xea, 0x05, 0x16, 0x1a, 0x40, 0xf7, 0x5f, 0x73, 0xc0, 0xba, 0xe8, 0x22, 0xc2, 0xb3, + 0x58, 0xc0, 0xd7, 0xc0, 0xf6, 0x69, 0x2a, 0x18, 0xf6, 0x85, 0x37, 0xb1, 0xb5, 0xcd, 0xc7, 0xa3, + 0xef, 0xf2, 0x74, 0x84, 0x8b, 0x6a, 0x03, 0xd3, 0x81, 0xd9, 0xff, 0x3a, 0x98, 0x6f, 0xc5, 0x94, + 0x26, 0xaa, 0x12, 0x2a, 0x48, 0x03, 0x88, 0xd4, 0xae, 0xa9, 0x53, 0x2e, 0xa8, 0x7b, 0xe9, 0x2f, + 0x6e, 0x9f, 0xf2, 0x54, 0xa9, 0x34, 0xd7, 0xcc, 0xdd, 0xb4, 0xaa, 0xb5, 0x4d, 0xbe, 0x2b, 0xf7, + 0x56, 0x95, 0x92, 0x0d, 0x0a, 0x8c, 0x08, 0x75, 0x68, 0x15, 0x24, 0x87, 0x70, 0x1d, 0x58, 0x8c, + 0x74, 0x08, 0x13, 0x24, 0x50, 0x87, 0x63, 0xa1, 0x21, 0x86, 0x8f, 0x80, 0x15, 0x62, 0xee, 0x65, + 0x9c, 0x04, 0xfa, 0x24, 0xd0, 0x62, 0x88, 0xf9, 0x07, 0x4e, 0x82, 0x97, 0xc5, 0x7f, 0xfc, 0xc7, + 0x99, 0x71, 0x31, 0x28, 0x1f, 0xf8, 0x3e, 0xe1, 0xfc, 0x22, 0x6b, 0xc7, 0xe4, 0x07, 0x2a, 0x6c, + 0x0f, 0x54, 0xb8, 0xa0, 0x0c, 0x87, 0xc4, 0xbb, 0x22, 0x3d, 0x53, 0x67, 0xba, 0x6a, 0x8c, 0xfd, + 0x77, 0xa4, 0xc7, 0xd1, 0x38, 0x30, 0x12, 0x5f, 0x0b, 0xa0, 0x7c, 0xc1, 0xb0, 0x4f, 0xcc, 0x7d, + 0x58, 0xd6, 0xaa, 0x84, 0xcc, 0x48, 0x18, 0x24, 0xb5, 0x45, 0x94, 0x10, 0x9a, 0x09, 0xf3, 0x3e, + 0x0d, 0xa0, 0xcc, 0x60, 0x84, 0x74, 0x89, 0xaf, 0xb6, 0xb1, 0x88, 0x0c, 0x82, 0xfb, 0x60, 0x29, + 0x88, 0xb8, 0xfa, 0xb9, 0xe0, 0x02, 0xfb, 0x57, 0x7a, 0xf9, 0x4d, 0xfb, 0x26, 0x77, 0x2a, 0xc6, + 0x71, 0x2e, 0xed, 0x68, 0x02, 0xc1, 0x57, 0xa0, 0x36, 0x4a, 0x53, 0xb3, 0xd5, 0xd7, 0xf9, 0x26, + 0xbc, 0xc9, 0x9d, 0xea, 0x30, 0x54, 0x79, 0xd0, 0x14, 0x96, 0x27, 0x1d, 0x90, 0x56, 0x16, 0xaa, + 0xe2, 0xb3, 0x90, 0x06, 0xd2, 0x1a, 0x47, 0x49, 0x24, 0x54, 0xb1, 0xcd, 0x23, 0x0d, 0xe0, 0x2b, + 0x50, 0xa2, 0x1d, 0xc2, 0x58, 0x14, 0x10, 0xae, 0x2e, 0x06, 0x3f, 0xf6, 0x67, 0x82, 0x46, 0xf1, + 0x72, 0x71, 0xe6, 0xc7, 0x29, 0x21, 0x09, 0x65, 0x3d, 0xd5, 0xe9, 0xcd, 0xe2, 0xb4, 0xe3, 0xf7, + 0xca, 0x8e, 0x26, 0x10, 0x6c, 0x02, 0x68, 0xd2, 0x18, 0x11, 0x19, 0x4b, 0x3d, 0xf5, 0xfe, 0x57, + 0x54, 0xae, 0x7a, 0x0b, 0xb5, 0x17, 0x29, 0xe7, 0x11, 0x16, 0x18, 0xdd, 0xb2, 0x9c, 0x16, 0xad, + 0xa2, 0x3d, 0x7f, 0x5a, 0xb4, 0x16, 0x6d, 0x6b, 0xb8, 0x7e, 0x33, 0x0b, 0xb4, 0x32, 0xc0, 0x63, + 0xf4, 0xcd, 0xdf, 0x7e, 0xbe, 0xde, 0x98, 0xfd, 0x72, 0xbd, 0x31, 0xfb, 0xf5, 0x7a, 0x63, 0xf6, + 0xdf, 0xdf, 0x36, 0x66, 0xbe, 0x7c, 0xdb, 0x98, 0xf9, 0xff, 0xb7, 0x8d, 0x99, 0x3f, 0x8d, 0x7f, + 0xee, 0x49, 0x47, 0x7e, 0xed, 0x47, 0x7f, 0xbb, 0x5d, 0xf5, 0xbf, 0xab, 0x3e, 0xf9, 0xad, 0x05, + 0xf5, 0x1f, 0xfb, 0xfc, 0xfb, 0x00, 0x00, 0x00, 0xff, 0xff, 0xfb, 0x44, 0xf1, 0x35, 0x0d, 0x0f, + 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { @@ -852,11 +858,11 @@ func (m *ChainConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l - if m.MergeForkBlock != nil { + if m.MergeNetsplitBlock != nil { { - size := m.MergeForkBlock.Size() + size := m.MergeNetsplitBlock.Size() i -= size - if _, err := m.MergeForkBlock.MarshalTo(dAtA[i:]); err != nil { + if _, err := m.MergeNetsplitBlock.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintEvm(dAtA, i, uint64(size)) @@ -864,7 +870,21 @@ func (m *ChainConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { i-- dAtA[i] = 0x1 i-- - dAtA[i] = 0x9a + dAtA[i] = 0xaa + } + if m.GrayGlacierBlock != nil { + { + size := m.GrayGlacierBlock.Size() + i -= size + if _, err := m.GrayGlacierBlock.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintEvm(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0xa2 } if m.ArrowGlacierBlock != nil { { @@ -1533,8 +1553,12 @@ func (m *ChainConfig) Size() (n int) { l = m.ArrowGlacierBlock.Size() n += 2 + l + sovEvm(uint64(l)) } - if m.MergeForkBlock != nil { - l = m.MergeForkBlock.Size() + if m.GrayGlacierBlock != nil { + l = m.GrayGlacierBlock.Size() + n += 2 + l + sovEvm(uint64(l)) + } + if m.MergeNetsplitBlock != nil { + l = m.MergeNetsplitBlock.Size() n += 2 + l + sovEvm(uint64(l)) } return n @@ -2495,9 +2519,45 @@ func (m *ChainConfig) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex - case 19: + case 20: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field GrayGlacierBlock", 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 + } + var v github_com_cosmos_cosmos_sdk_types.Int + m.GrayGlacierBlock = &v + if err := m.GrayGlacierBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 21: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MergeForkBlock", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field MergeNetsplitBlock", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -2526,8 +2586,8 @@ func (m *ChainConfig) Unmarshal(dAtA []byte) error { return io.ErrUnexpectedEOF } var v github_com_cosmos_cosmos_sdk_types.Int - m.MergeForkBlock = &v - if err := m.MergeForkBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.MergeNetsplitBlock = &v + if err := m.MergeNetsplitBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex diff --git a/x/evm/types/tracer.go b/x/evm/types/tracer.go index 7e59662389..d3827c70fa 100644 --- a/x/evm/types/tracer.go +++ b/x/evm/types/tracer.go @@ -1,7 +1,6 @@ package types import ( - "fmt" "math/big" "os" "time" @@ -31,7 +30,7 @@ func NewTracer(tracer string, msg core.Message, cfg *params.ChainConfig, height switch tracer { case TracerAccessList: - preCompiles := vm.ActivePrecompiles(cfg.Rules(big.NewInt(height), cfg.MergeForkBlock != nil)) + preCompiles := vm.ActivePrecompiles(cfg.Rules(big.NewInt(height), cfg.MergeNetsplitBlock != nil)) return logger.NewAccessListTracer(msg.AccessList(), msg.From(), *msg.To(), preCompiles) case TracerJSON: return logger.NewJSONLogger(logCfg, os.Stderr) @@ -44,87 +43,12 @@ func NewTracer(tracer string, msg core.Message, cfg *params.ChainConfig, height } } -// TxTraceTask represents a single transaction trace task when an entire block -// is being traced. -type TxTraceTask struct { - Index int // Transaction offset in the block -} - // TxTraceResult is the result of a single transaction trace during a block trace. type TxTraceResult struct { Result interface{} `json:"result,omitempty"` // Trace results produced by the tracer Error string `json:"error,omitempty"` // Trace failure produced by the tracer } -// ExecutionResult groups all structured logs emitted by the EVM -// while replaying a transaction in debug mode as well as transaction -// execution status, the amount of gas used and the return value -type ExecutionResult struct { - Gas uint64 `json:"gas"` - Failed bool `json:"failed"` - ReturnValue string `json:"returnValue"` - StructLogs []StructLogRes `json:"structLogs"` -} - -// StructLogRes stores a structured log emitted by the EVM while replaying a -// transaction in debug mode. Taken from go-ethereum -type StructLogRes struct { - Pc uint64 `json:"pc"` - Op string `json:"op"` - Gas uint64 `json:"gas"` - GasCost uint64 `json:"gasCost"` - Depth int `json:"depth"` - Error string `json:"error,omitempty"` - Stack *[]string `json:"stack,omitempty"` - Memory *[]string `json:"memory,omitempty"` - Storage *map[string]string `json:"storage,omitempty"` -} - -// FormatLogs formats EVM returned structured logs for json output -func FormatLogs(logs []logger.StructLog) []StructLogRes { - formatted := make([]StructLogRes, len(logs)) - for index, trace := range logs { - formatted[index] = StructLogRes{ - Pc: trace.Pc, - Op: trace.Op.String(), - Gas: trace.Gas, - GasCost: trace.GasCost, - Depth: trace.Depth, - Error: trace.ErrorString(), - } - - if trace.Stack != nil { - stack := make([]string, len(trace.Stack)) - for i, stackValue := range trace.Stack { - stack[i] = fmt.Sprintf("%x", stackValue) - } - formatted[index].Stack = &stack - } - - if trace.Memory != nil { - memory := make([]string, 0, (len(trace.Memory)+31)/32) - for i, n := 0, len(trace.Memory); i < n; { - end := i + 32 - if end >= n { - end = n - } - memory = append(memory, fmt.Sprintf("%x", trace.Memory[i:end])) - i = end - } - formatted[index].Memory = &memory - } - - if trace.Storage != nil { - storage := make(map[string]string) - for i, storageValue := range trace.Storage { - storage[fmt.Sprintf("%x", i)] = fmt.Sprintf("%x", storageValue) - } - formatted[index].Storage = &storage - } - } - return formatted -} - var _ vm.EVMLogger = &NoOpTracer{} // NoOpTracer is an empty implementation of vm.Tracer interface @@ -156,3 +80,9 @@ func (dt NoOpTracer) CaptureEnter(typ vm.OpCode, from common.Address, to common. // CaptureExit implements vm.Tracer interface func (dt NoOpTracer) CaptureExit(output []byte, gasUsed uint64, err error) {} + +// CaptureTxStart implements vm.Tracer interface +func (dt NoOpTracer) CaptureTxStart(gasLimit uint64) {} + +// CaptureTxEnd implements vm.Tracer interface +func (dt NoOpTracer) CaptureTxEnd(restGas uint64) {} diff --git a/x/evm/types/tracer_test.go b/x/evm/types/tracer_test.go index dff68bcf04..6e21f93a63 100644 --- a/x/evm/types/tracer_test.go +++ b/x/evm/types/tracer_test.go @@ -1,86 +1,11 @@ package types import ( - "fmt" "testing" - "github.com/ethereum/go-ethereum/eth/tracers/logger" - - "github.com/ethereum/go-ethereum/common" - "github.com/holiman/uint256" "github.com/stretchr/testify/require" ) -func TestFormatLogs(t *testing.T) { - zeroUint256 := []uint256.Int{*uint256.NewInt(0)} - zeroByte := []byte{5} - zeroStorage := make(map[string]string) - - testCases := []struct { - name string - logs []logger.StructLog - exp []StructLogRes - }{ - { - "empty logs", - []logger.StructLog{}, - []StructLogRes{}, - }, - { - "non-empty stack", - []logger.StructLog{ - { - Stack: zeroUint256, - }, - }, - []StructLogRes{ - { - Pc: uint64(0), - Op: "STOP", - Stack: &[]string{fmt.Sprintf("%x", zeroUint256[0])}, - }, - }, - }, - { - "non-empty memory", - []logger.StructLog{ - { - Memory: zeroByte, - }, - }, - []StructLogRes{ - { - Pc: uint64(0), - Op: "STOP", - Memory: &[]string{"05"}, - }, - }, - }, - { - "non-empty storage", - []logger.StructLog{ - { - Storage: make(map[common.Hash]common.Hash), - }, - }, - []StructLogRes{ - { - Pc: uint64(0), - Op: "STOP", - Storage: &zeroStorage, - }, - }, - }, - } - for _, tc := range testCases { - t.Run(tc.name, func(t *testing.T) { - actual := FormatLogs(tc.logs) - - require.Equal(t, tc.exp, actual) - }) - } -} - func TestNewNoOpTracer(t *testing.T) { require.Equal(t, &NoOpTracer{}, NewNoOpTracer()) } From cf85f6aaabfae8f0ca07d07ef8798e8c5d2d72d6 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Sun, 31 Jul 2022 14:15:25 -0600 Subject: [PATCH 02/19] cherry pick upgrade to geth v0.1.19 and remove migrations --- CHANGELOG.md | 390 +- CONTRIBUTING.md | 16 +- Dockerfile | 4 +- Makefile | 8 +- README.md | 2 +- app/ante/ante.go | 2 +- app/ante/ante_test.go | 4 +- app/ante/eip712.go | 8 +- app/ante/eth.go | 8 +- app/ante/eth_test.go | 10 +- app/ante/fee_market_test.go | 6 +- app/ante/fees.go | 2 +- app/ante/fees_test.go | 6 +- app/ante/handler_options.go | 2 +- app/ante/interfaces.go | 6 +- app/ante/reject_msgs.go | 2 +- app/ante/sigs_test.go | 6 +- app/ante/utils_test.go | 18 +- app/app.go | 24 +- app/app_test.go | 2 +- app/benchmark_test.go | 2 +- app/export.go | 2 +- app/simulation_test.go | 2 +- app/utils.go | 8 +- app/utils_test.go | 6 +- client/config.go | 4 +- client/docs/statik/init.go | 2 +- client/export.go | 4 +- client/import.go | 4 +- client/keys.go | 4 +- client/keys/add.go | 2 +- client/testnet.go | 12 +- cmd/config/config.go | 2 +- cmd/config/config_test.go | 2 +- cmd/ethermintd/cmd_test.go | 4 +- cmd/ethermintd/flags.go | 2 +- cmd/ethermintd/genaccounts.go | 6 +- cmd/ethermintd/main.go | 4 +- cmd/ethermintd/root.go | 18 +- crypto/codec/amino.go | 2 +- crypto/codec/codec.go | 2 +- crypto/hd/algorithm.go | 2 +- crypto/hd/algorithm_test.go | 4 +- crypto/hd/benchmark_test.go | 2 +- encoding/codec/codec.go | 4 +- encoding/config.go | 2 +- encoding/config_test.go | 8 +- go.mod | 30 +- go.sum | 106 +- networks/local/ethermintnode/Dockerfile | 6 +- .../crypto/v1/ethsecp256k1/keys.proto | 2 +- proto/ethermint/evm/v1/evm.proto | 2 +- proto/ethermint/evm/v1/genesis.proto | 2 +- proto/ethermint/evm/v1/query.proto | 2 +- proto/ethermint/evm/v1/tx.proto | 2 +- proto/ethermint/feemarket/v1/feemarket.proto | 2 +- proto/ethermint/feemarket/v1/genesis.proto | 2 +- proto/ethermint/feemarket/v1/query.proto | 2 +- proto/ethermint/types/v1/account.proto | 2 +- proto/ethermint/types/v1/web3.proto | 2 +- rpc/apis.go | 20 +- rpc/backend/backend.go | 8 +- rpc/backend/evm_backend.go | 8 +- rpc/backend/utils.go | 4 +- rpc/namespaces/ethereum/debug/api.go | 6 +- rpc/namespaces/ethereum/eth/api.go | 14 +- rpc/namespaces/ethereum/eth/filters/api.go | 4 +- .../ethereum/eth/filters/filter_system.go | 4 +- .../ethereum/eth/filters/filters.go | 2 +- rpc/namespaces/ethereum/miner/api.go | 6 +- rpc/namespaces/ethereum/net/api.go | 2 +- rpc/namespaces/ethereum/personal/api.go | 10 +- rpc/namespaces/ethereum/txpool/api.go | 4 +- rpc/namespaces/ethereum/web3/api.go | 2 +- rpc/types/block.go | 2 +- rpc/types/events.go | 2 +- rpc/types/events_test.go | 2 +- rpc/types/query_client.go | 4 +- rpc/types/utils.go | 4 +- rpc/websockets.go | 10 +- scripts/protocgen.sh | 2 +- server/json_rpc.go | 4 +- server/start.go | 6 +- tests/e2e/integration_test.go | 10 +- tests/importer/importer_test.go | 8 +- tests/rpc/rpc_pending_test.go | 2 +- tests/rpc/rpc_test.go | 6 +- tests/signer.go | 2 +- testutil/fund.go | 2 +- testutil/network/network.go | 12 +- testutil/network/network_test.go | 2 +- testutil/network/util.go | 4 +- types/account_test.go | 8 +- types/validation_test.go | 2 +- x/evm/atlas/atlas-v0.3.1.md | 6 +- x/evm/atlas/atlas.toml | 6 +- x/evm/client/cli/query.go | 4 +- x/evm/client/cli/tx.go | 4 +- x/evm/client/rest/rest.go | 4 +- x/evm/genesis.go | 6 +- x/evm/genesis_test.go | 8 +- x/evm/handler.go | 2 +- x/evm/handler_test.go | 16 +- x/evm/keeper/benchmark_test.go | 4 +- x/evm/keeper/grpc_query.go | 6 +- x/evm/keeper/grpc_query_test.go | 10 +- x/evm/keeper/hooks.go | 2 +- x/evm/keeper/hooks_test.go | 6 +- x/evm/keeper/keeper.go | 6 +- x/evm/keeper/keeper_test.go | 20 +- x/evm/keeper/migrations.go | 16 - x/evm/keeper/msg_server.go | 2 +- x/evm/keeper/params.go | 2 +- x/evm/keeper/params_test.go | 2 +- x/evm/keeper/state_transition.go | 8 +- .../keeper/state_transition_benchmark_test.go | 2 +- x/evm/keeper/state_transition_test.go | 6 +- x/evm/keeper/statedb.go | 6 +- x/evm/keeper/statedb_benchmark_test.go | 2 +- x/evm/keeper/statedb_test.go | 6 +- x/evm/keeper/utils.go | 2 +- x/evm/keeper/utils_test.go | 4 +- x/evm/migrations/v3/migrate.go | 25 - x/evm/migrations/v3/migrate_test.go | 57 - x/evm/migrations/v3/types/chain_config.go | 164 - x/evm/migrations/v3/types/evm.pb.go | 3812 ----------------- x/evm/migrations/v3/types/params.go | 150 - x/evm/module.go | 18 +- x/evm/simulation/decoder.go | 2 +- x/evm/simulation/decoder_test.go | 2 +- x/evm/simulation/genesis.go | 2 +- x/evm/simulation/genesis_test.go | 4 +- x/evm/simulation/operations.go | 8 +- x/evm/simulation/params.go | 2 +- x/evm/simulation/params_test.go | 2 +- x/evm/spec/01_concepts.md | 8 +- x/evm/spec/README.md | 2 +- x/evm/statedb/mock_test.go | 2 +- x/evm/statedb/statedb_test.go | 2 +- x/evm/types/access_list_tx.go | 2 +- x/evm/types/dynamic_fee_tx.go | 2 +- x/evm/types/dynamic_fee_tx_test.go | 2 +- x/evm/types/genesis.go | 2 +- x/evm/types/genesis_test.go | 2 +- x/evm/types/interfaces.go | 2 +- x/evm/types/legacy_tx.go | 2 +- x/evm/types/logs.go | 2 +- x/evm/types/logs_test.go | 2 +- x/evm/types/msg.go | 2 +- x/evm/types/msg_test.go | 10 +- x/evm/types/params.go | 2 +- x/evm/types/utils_test.go | 6 +- x/feemarket/client/cli/query.go | 2 +- x/feemarket/genesis.go | 4 +- x/feemarket/keeper/abci.go | 4 +- x/feemarket/keeper/grpc_query.go | 2 +- x/feemarket/keeper/grpc_query_test.go | 2 +- x/feemarket/keeper/integration_test.go | 14 +- x/feemarket/keeper/keeper.go | 2 +- x/feemarket/keeper/keeper_test.go | 14 +- x/feemarket/keeper/migrations.go | 4 +- x/feemarket/keeper/migrations_test.go | 4 +- x/feemarket/keeper/params.go | 2 +- x/feemarket/keeper/params_test.go | 2 +- x/feemarket/migrations/v010/migrate.go | 4 +- x/feemarket/migrations/v010/migrate_test.go | 14 +- x/feemarket/migrations/v011/migrate.go | 4 +- x/feemarket/migrations/v011/migrate_test.go | 12 +- x/feemarket/module.go | 8 +- x/feemarket/simulation/genesis.go | 2 +- 170 files changed, 684 insertions(+), 4876 deletions(-) delete mode 100644 x/evm/migrations/v3/migrate.go delete mode 100644 x/evm/migrations/v3/migrate_test.go delete mode 100644 x/evm/migrations/v3/types/chain_config.go delete mode 100644 x/evm/migrations/v3/types/evm.pb.go delete mode 100644 x/evm/migrations/v3/types/params.go diff --git a/CHANGELOG.md b/CHANGELOG.md index db227b3039..815ae85051 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -46,395 +46,395 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### State Machine Breaking -* (feemarket) [tharsis#1105](https://github.com/tharsis/ethermint/pull/1105) Update `BaseFee` calculation based on `GasWanted` instead of `GasUsed`. +* (feemarket) [tharsis#1105](https://github.com/evmos/ethermint/pull/1105) Update `BaseFee` calculation based on `GasWanted` instead of `GasUsed`. ### API Breaking -* (feemarket) [tharsis#1104](https://github.com/tharsis/ethermint/pull/1104) Enforce a minimum gas price for Cosmos and EVM transactions through the `MinGasPrice` parameter. -* (rpc) [tharsis#1081](https://github.com/tharsis/ethermint/pull/1081) Deduplicate some json-rpc logic codes, cleanup several dead functions. -* (ante) [tharsis#1062](https://github.com/tharsis/ethermint/pull/1062) Emit event of eth tx hash in ante handler to support query failed transactions. -* (analytics) [tharsis#1106](https://github.com/tharsis/ethermint/pull/1106) Update telemetry to Ethermint modules. -* (rpc) [tharsis#1108](https://github.com/tharsis/ethermint/pull/1108) Update GetGasPrice RPC endpoint with global `MinGasPrice` +* (feemarket) [tharsis#1104](https://github.com/evmos/ethermint/pull/1104) Enforce a minimum gas price for Cosmos and EVM transactions through the `MinGasPrice` parameter. +* (rpc) [tharsis#1081](https://github.com/evmos/ethermint/pull/1081) Deduplicate some json-rpc logic codes, cleanup several dead functions. +* (ante) [tharsis#1062](https://github.com/evmos/ethermint/pull/1062) Emit event of eth tx hash in ante handler to support query failed transactions. +* (analytics) [tharsis#1106](https://github.com/evmos/ethermint/pull/1106) Update telemetry to Ethermint modules. +* (rpc) [tharsis#1108](https://github.com/evmos/ethermint/pull/1108) Update GetGasPrice RPC endpoint with global `MinGasPrice` -* (ante) [tharsis#964](https://github.com/tharsis/ethermint/pull/964) add NewInfiniteGasMeterWithLimit for storing the user provided gas limit. Fixes block's consumed gas calculation in the block creation phase. +* (ante) [tharsis#964](https://github.com/evmos/ethermint/pull/964) add NewInfiniteGasMeterWithLimit for storing the user provided gas limit. Fixes block's consumed gas calculation in the block creation phase. -* (cli) [tharsis#1086](https://github.com/tharsis/ethermint/pull/1086) Add rollback command. -* (specs) [tharsis#1095](https://github.com/tharsis/ethermint/pull/1095) Add more evm specs concepts. -* (evm) [tharsis#1101](https://github.com/tharsis/ethermint/pull/1101) Add tx_type, gas and counter telemetry for ethereum txs. +* (cli) [tharsis#1086](https://github.com/evmos/ethermint/pull/1086) Add rollback command. +* (specs) [tharsis#1095](https://github.com/evmos/ethermint/pull/1095) Add more evm specs concepts. +* (evm) [tharsis#1101](https://github.com/evmos/ethermint/pull/1101) Add tx_type, gas and counter telemetry for ethereum txs. ### Bug Fixes -* (rpc) [tharsis#1082](https://github.com/tharsis/ethermint/pull/1082) fix gas price returned in getTransaction api. -* (evm) [tharsis#1088](https://github.com/tharsis/ethermint/pull/1088) Fix ability to append log in tx post processing. -* (rpc) [tharsis#1081](https://github.com/tharsis/ethermint/pull/1081) fix `debug_getBlockRlp`/`debug_printBlock` don't filter failed transactions. -* (ante) [tharsis#1111](https://github.com/tharsis/ethermint/pull/1111) Move CanTransfer decorator before GasConsume decorator +* (rpc) [tharsis#1082](https://github.com/evmos/ethermint/pull/1082) fix gas price returned in getTransaction api. +* (evm) [tharsis#1088](https://github.com/evmos/ethermint/pull/1088) Fix ability to append log in tx post processing. +* (rpc) [tharsis#1081](https://github.com/evmos/ethermint/pull/1081) fix `debug_getBlockRlp`/`debug_printBlock` don't filter failed transactions. +* (ante) [tharsis#1111](https://github.com/evmos/ethermint/pull/1111) Move CanTransfer decorator before GasConsume decorator * (types) [tharsis#1112](https://github.com/cosmos/ethermint/pull/1112) Add `GetBaseAccount` to avoid invalid account error when create vesting account. ## [v0.15.0] - 2022-05-09 ### State Machine Breaking -* (ante) [tharsis#1060](https://github.com/tharsis/ethermint/pull/1060) Check `EnableCreate`/`EnableCall` in `AnteHandler` to short-circuit EVM transactions. -* (evm) [tharsis#1087](https://github.com/tharsis/ethermint/pull/1087) Minimum GasUsed proportional to GasLimit and `MinGasDenominator` EVM module param. +* (ante) [tharsis#1060](https://github.com/evmos/ethermint/pull/1060) Check `EnableCreate`/`EnableCall` in `AnteHandler` to short-circuit EVM transactions. +* (evm) [tharsis#1087](https://github.com/evmos/ethermint/pull/1087) Minimum GasUsed proportional to GasLimit and `MinGasDenominator` EVM module param. ### API Breaking -* (rpc) [tharsis#1070](https://github.com/tharsis/ethermint/pull/1070) Refactor `rpc/` package: +* (rpc) [tharsis#1070](https://github.com/evmos/ethermint/pull/1070) Refactor `rpc/` package: * `Backend` interface is now `BackendI`, which implements `EVMBackend` (for Ethereum namespaces) and `CosmosBackend` (for Cosmos namespaces) * Previous `EVMBackend` type is now `Backend`, which is the concrete implementation of `BackendI` * Move `rpc/ethereum/types` -> `rpc/types` * Move `rpc/ethereum/backend` -> `rpc/backend` * Move `rpc/ethereum/namespaces` -> `rpc/namespaces/ethereum` -* (rpc) [tharsis#1068](https://github.com/tharsis/ethermint/pull/1068) Fix London hard-fork check logic in JSON-RPC APIs. +* (rpc) [tharsis#1068](https://github.com/evmos/ethermint/pull/1068) Fix London hard-fork check logic in JSON-RPC APIs. ### Improvements -* (ci, evm) [tharsis#1063](https://github.com/tharsis/ethermint/pull/1063) Run simulations on CI. +* (ci, evm) [tharsis#1063](https://github.com/evmos/ethermint/pull/1063) Run simulations on CI. ### Bug Fixes -* (rpc) [tharsis#1059](https://github.com/tharsis/ethermint/pull/1059) Remove unnecessary event filtering logic on the `eth_baseFee` JSON-RPC endpoint. +* (rpc) [tharsis#1059](https://github.com/evmos/ethermint/pull/1059) Remove unnecessary event filtering logic on the `eth_baseFee` JSON-RPC endpoint. ## [v0.14.0] - 2022-04-19 ### API Breaking -* (evm) [tharsis#1051](https://github.com/tharsis/ethermint/pull/1051) Context block height fix on TraceTx. Removes `tx_index` on `QueryTraceTxRequest` proto type. -* (evm) [tharsis#1091](https://github.com/tharsis/ethermint/pull/1091) Add query params command on EVM Module +* (evm) [tharsis#1051](https://github.com/evmos/ethermint/pull/1051) Context block height fix on TraceTx. Removes `tx_index` on `QueryTraceTxRequest` proto type. +* (evm) [tharsis#1091](https://github.com/evmos/ethermint/pull/1091) Add query params command on EVM Module ### Improvements -* (deps) [tharsis#1046](https://github.com/tharsis/ethermint/pull/1046) Bump Cosmos SDK version to [`v0.45.3`](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.45.3) -* (rpc) [tharsis#1056](https://github.com/tharsis/ethermint/pull/1056) Make json-rpc namespaces extensible +* (deps) [tharsis#1046](https://github.com/evmos/ethermint/pull/1046) Bump Cosmos SDK version to [`v0.45.3`](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.45.3) +* (rpc) [tharsis#1056](https://github.com/evmos/ethermint/pull/1056) Make json-rpc namespaces extensible ### Bug Fixes -* (rpc) [tharsis#1050](https://github.com/tharsis/ethermint/pull/1050) `eth_getBlockByNumber` fix on batch transactions -* (app) [tharsis#658](https://github.com/tharsis/ethermint/issues/658) Support simulations for the EVM. +* (rpc) [tharsis#1050](https://github.com/evmos/ethermint/pull/1050) `eth_getBlockByNumber` fix on batch transactions +* (app) [tharsis#658](https://github.com/evmos/ethermint/issues/658) Support simulations for the EVM. ## [v0.13.0] - 2022-04-05 ### API Breaking -* (evm) [tharsis#1027](https://github.com/tharsis/ethermint/pull/1027) Change the `PostTxProcessing` hook interface to include the full message data. -* (feemarket) [tharsis#1026](https://github.com/tharsis/ethermint/pull/1026) Fix REST endpoints to use `/ethermint/feemarket/*` instead of `/feemarket/evm/*`. +* (evm) [tharsis#1027](https://github.com/evmos/ethermint/pull/1027) Change the `PostTxProcessing` hook interface to include the full message data. +* (feemarket) [tharsis#1026](https://github.com/evmos/ethermint/pull/1026) Fix REST endpoints to use `/ethermint/feemarket/*` instead of `/feemarket/evm/*`. ### Improvements -* (deps) [tharsis#1029](https://github.com/tharsis/ethermint/pull/1029) Bump Cosmos SDK version to [`v0.45.2`](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.45.2) -* (evm) [tharsis#1025](https://github.com/tharsis/ethermint/pull/1025) Allow to append logs after a post processing hook. +* (deps) [tharsis#1029](https://github.com/evmos/ethermint/pull/1029) Bump Cosmos SDK version to [`v0.45.2`](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.45.2) +* (evm) [tharsis#1025](https://github.com/evmos/ethermint/pull/1025) Allow to append logs after a post processing hook. ## [v0.12.2] - 2022-03-30 ### Bug Fixes -* (feemarket) [tharsis#1021](https://github.com/tharsis/ethermint/pull/1021) Fix fee market migration. +* (feemarket) [tharsis#1021](https://github.com/evmos/ethermint/pull/1021) Fix fee market migration. ## [v0.12.1] - 2022-03-29 ### Bug Fixes -* (evm) [tharsis#1016](https://github.com/tharsis/ethermint/pull/1016) Update validate basic check for storage state. +* (evm) [tharsis#1016](https://github.com/evmos/ethermint/pull/1016) Update validate basic check for storage state. ## [v0.12.0] - 2022-03-24 ### Bug Fixes -* (rpc) [tharsis#1012](https://github.com/tharsis/ethermint/pull/1012) fix the tx hash in filter entries created by `eth_newPendingTransactionFilter`. -* (rpc) [tharsis#1006](https://github.com/tharsis/ethermint/pull/1006) Use `string` as the parameters type to correct ambiguous results. -* (ante) [tharsis#1004](https://github.com/tharsis/ethermint/pull/1004) Make `MaxTxGasWanted` configurable. -* (ante) [tharsis#991](https://github.com/tharsis/ethermint/pull/991) Set an upper bound to gasWanted to prevent DoS attack. -* (rpc) [tharsis#990](https://github.com/tharsis/ethermint/pull/990) Calculate reward values from all `MsgEthereumTx` from a block in `eth_feeHistory`. +* (rpc) [tharsis#1012](https://github.com/evmos/ethermint/pull/1012) fix the tx hash in filter entries created by `eth_newPendingTransactionFilter`. +* (rpc) [tharsis#1006](https://github.com/evmos/ethermint/pull/1006) Use `string` as the parameters type to correct ambiguous results. +* (ante) [tharsis#1004](https://github.com/evmos/ethermint/pull/1004) Make `MaxTxGasWanted` configurable. +* (ante) [tharsis#991](https://github.com/evmos/ethermint/pull/991) Set an upper bound to gasWanted to prevent DoS attack. +* (rpc) [tharsis#990](https://github.com/evmos/ethermint/pull/990) Calculate reward values from all `MsgEthereumTx` from a block in `eth_feeHistory`. ## [v0.11.0] - 2022-03-06 ### State Machine Breaking -* (ante) [tharsis#964](https://github.com/tharsis/ethermint/pull/964) add NewInfiniteGasMeterWithLimit for storing the user provided gas limit. Fixes block's consumed gas calculation in the block creation phase. +* (ante) [tharsis#964](https://github.com/evmos/ethermint/pull/964) add NewInfiniteGasMeterWithLimit for storing the user provided gas limit. Fixes block's consumed gas calculation in the block creation phase. ### Bug Fixes -* (rpc) [tharsis#975](https://github.com/tharsis/ethermint/pull/975) Fix unexpected `nil` values for `reward`, returned by `EffectiveGasTipValue(blockBaseFee)` in the `eth_feeHistory` RPC method. +* (rpc) [tharsis#975](https://github.com/evmos/ethermint/pull/975) Fix unexpected `nil` values for `reward`, returned by `EffectiveGasTipValue(blockBaseFee)` in the `eth_feeHistory` RPC method. ### Improvements -- (rpc) [tharsis#979](https://github.com/tharsis/ethermint/pull/979) Add configurable timeouts to http server -- (rpc) [tharsis#988](https://github.com/tharsis/ethermint/pull/988) json-rpc server always use local rpc client +- (rpc) [tharsis#979](https://github.com/evmos/ethermint/pull/979) Add configurable timeouts to http server +- (rpc) [tharsis#988](https://github.com/evmos/ethermint/pull/988) json-rpc server always use local rpc client ## [v0.10.1] - 2022-03-04 ### Bug Fixes -* (rpc) [tharsis#970](https://github.com/tharsis/ethermint/pull/970) Fix unexpected nil reward values on `eth_feeHistory` response -* (evm) [tharsis#529](https://github.com/tharsis/ethermint/issues/529) Add support return value on trace tx response. +* (rpc) [tharsis#970](https://github.com/evmos/ethermint/pull/970) Fix unexpected nil reward values on `eth_feeHistory` response +* (evm) [tharsis#529](https://github.com/evmos/ethermint/issues/529) Add support return value on trace tx response. ### Improvements -* (rpc) [tharsis#968](https://github.com/tharsis/ethermint/pull/968) Add some buffer to returned gas price to provide better default UX for client. +* (rpc) [tharsis#968](https://github.com/evmos/ethermint/pull/968) Add some buffer to returned gas price to provide better default UX for client. ## [v0.10.0] - 2022-02-26 ### API Breaking -* (ante) [tharsis#866](https://github.com/tharsis/ethermint/pull/866) `NewAnteHandler` constructor now receives a `HandlerOptions` field. -* (evm) [tharsis#849](https://github.com/tharsis/ethermint/pull/849) `PostTxProcessing` hook now takes an Ethereum tx `Receipt` and a `from` `Address` as arguments. -* (ante) [tharsis#916](https://github.com/tharsis/ethermint/pull/916) Don't check min-gas-price for eth tx if london hardfork enabled and feemarket enabled. +* (ante) [tharsis#866](https://github.com/evmos/ethermint/pull/866) `NewAnteHandler` constructor now receives a `HandlerOptions` field. +* (evm) [tharsis#849](https://github.com/evmos/ethermint/pull/849) `PostTxProcessing` hook now takes an Ethereum tx `Receipt` and a `from` `Address` as arguments. +* (ante) [tharsis#916](https://github.com/evmos/ethermint/pull/916) Don't check min-gas-price for eth tx if london hardfork enabled and feemarket enabled. ### State Machine Breaking -* (deps) [tharsis#912](https://github.com/tharsis/ethermint/pull/912) Bump Cosmos SDK version to [`v0.45.1`](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.45.1) -* (evm) [tharsis#840](https://github.com/tharsis/ethermint/pull/840) Store empty topics as empty array rather than nil. -* (feemarket) [tharsis#822](https://github.com/tharsis/ethermint/pull/822) Update EIP1559 base fee in `BeginBlock`. -* (evm) [tharsis#817](https://github.com/tharsis/ethermint/pull/817) Use `effectiveGasPrice` in ante handler, add `effectiveGasPrice` to tx receipt. -* (evm) [tharsis#808](https://github.com/tharsis/ethermint/issues/808) increase nonce in ante handler for contract creation transaction. -* (evm) [tharsis#851](https://github.com/tharsis/ethermint/pull/851) fix contract address used in EVM, this issue is caused by [tharsis#808](https://github.com/tharsis/ethermint/issues/808). +* (deps) [tharsis#912](https://github.com/evmos/ethermint/pull/912) Bump Cosmos SDK version to [`v0.45.1`](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.45.1) +* (evm) [tharsis#840](https://github.com/evmos/ethermint/pull/840) Store empty topics as empty array rather than nil. +* (feemarket) [tharsis#822](https://github.com/evmos/ethermint/pull/822) Update EIP1559 base fee in `BeginBlock`. +* (evm) [tharsis#817](https://github.com/evmos/ethermint/pull/817) Use `effectiveGasPrice` in ante handler, add `effectiveGasPrice` to tx receipt. +* (evm) [tharsis#808](https://github.com/evmos/ethermint/issues/808) increase nonce in ante handler for contract creation transaction. +* (evm) [tharsis#851](https://github.com/evmos/ethermint/pull/851) fix contract address used in EVM, this issue is caused by [tharsis#808](https://github.com/evmos/ethermint/issues/808). * (evm) Reject invalid `MsgEthereumTx` wrapping tx * (evm) Fix `SelfDestruct` opcode by deleting account code and state. -* (feemarket) [tharsis#855](https://github.com/tharsis/ethermint/pull/855) Consistent `BaseFee` check logic. -* (evm) [tharsis#729](https://github.com/tharsis/ethermint/pull/729) Refactor EVM `StateDB` implementation. -* (evm) [tharsis#945](https://github.com/tharsis/ethermint/pull/945) Bumb Go-ethereum version to [`v1.10.16`](https://github.com/ethereum/go-ethereum/releases/tag/v1.10.16) +* (feemarket) [tharsis#855](https://github.com/evmos/ethermint/pull/855) Consistent `BaseFee` check logic. +* (evm) [tharsis#729](https://github.com/evmos/ethermint/pull/729) Refactor EVM `StateDB` implementation. +* (evm) [tharsis#945](https://github.com/evmos/ethermint/pull/945) Bumb Go-ethereum version to [`v1.10.16`](https://github.com/ethereum/go-ethereum/releases/tag/v1.10.16) ### Features -* (ante) [tharsis#950](https://github.com/tharsis/ethermint/pull/950) Add support for EIP712 signed Cosmos transactions +* (ante) [tharsis#950](https://github.com/evmos/ethermint/pull/950) Add support for EIP712 signed Cosmos transactions ### Improvements -* (types) [tharsis#884](https://github.com/tharsis/ethermint/pull/884) Introduce a new `EthAccountI` interface for EVM-compatible account types. -* (types) [tharsis#849](https://github.com/tharsis/ethermint/pull/849) Add `Type` function to distinguish EOAs from Contract accounts. -* (evm) [tharsis#826](https://github.com/tharsis/ethermint/issues/826) Improve allocation of bytes of `tx.To` address. -* (evm) [tharsis#827](https://github.com/tharsis/ethermint/issues/827) Speed up creation of event logs by using the slice insertion idiom with indices. -* (ante) [tharsis#819](https://github.com/tharsis/ethermint/pull/819) Remove redundant ante handlers -* (app) [tharsis#873](https://github.com/tharsis/ethermint/pull/873) Validate code hash in GenesisAccount -* (evm) [tharsis#901](https://github.com/tharsis/ethermint/pull/901) Support multiple `MsgEthereumTx` in single tx. -* (config) [tharsis#908](https://github.com/tharsis/ethermint/pull/908) Add `api.enable` flag for Cosmos SDK Rest server -* (feemarket) [tharsis#919](https://github.com/tharsis/ethermint/pull/919) Initialize baseFee in default genesis state. -* (feemarket) [tharsis#943](https://github.com/tharsis/ethermint/pull/943) Store the base fee as a module param instead of using state storage. +* (types) [tharsis#884](https://github.com/evmos/ethermint/pull/884) Introduce a new `EthAccountI` interface for EVM-compatible account types. +* (types) [tharsis#849](https://github.com/evmos/ethermint/pull/849) Add `Type` function to distinguish EOAs from Contract accounts. +* (evm) [tharsis#826](https://github.com/evmos/ethermint/issues/826) Improve allocation of bytes of `tx.To` address. +* (evm) [tharsis#827](https://github.com/evmos/ethermint/issues/827) Speed up creation of event logs by using the slice insertion idiom with indices. +* (ante) [tharsis#819](https://github.com/evmos/ethermint/pull/819) Remove redundant ante handlers +* (app) [tharsis#873](https://github.com/evmos/ethermint/pull/873) Validate code hash in GenesisAccount +* (evm) [tharsis#901](https://github.com/evmos/ethermint/pull/901) Support multiple `MsgEthereumTx` in single tx. +* (config) [tharsis#908](https://github.com/evmos/ethermint/pull/908) Add `api.enable` flag for Cosmos SDK Rest server +* (feemarket) [tharsis#919](https://github.com/evmos/ethermint/pull/919) Initialize baseFee in default genesis state. +* (feemarket) [tharsis#943](https://github.com/evmos/ethermint/pull/943) Store the base fee as a module param instead of using state storage. ### Bug Fixes -* (rpc) [tharsis#955](https://github.com/tharsis/ethermint/pull/955) Fix websocket server push duplicated messages to subscriber. -* (rpc) [tharsis#953](https://github.com/tharsis/ethermint/pull/953) Add `eth_signTypedData` api support. -* (log) [tharsis#948](https://github.com/tharsis/ethermint/pull/948) Redirect go-ethereum's logs to cosmos-sdk logger. -* (evm) [tharsis#884](https://github.com/tharsis/ethermint/pull/884) Support multiple account types on the EVM `StateDB`. -* (rpc) [tharsis#831](https://github.com/tharsis/ethermint/pull/831) Fix BaseFee value when height is specified. -* (evm) [tharsis#838](https://github.com/tharsis/ethermint/pull/838) Fix splitting of trace.Memory into 32 chunks. -* (rpc) [tharsis#860](https://github.com/tharsis/ethermint/pull/860) Fix `eth_getLogs` when specify blockHash without address/topics, and limit the response size. -* (rpc) [tharsis#865](https://github.com/tharsis/ethermint/pull/865) Fix RPC Filter parameters being ignored -* (evm) [tharsis#871](https://github.com/tharsis/ethermint/pull/871) Set correct nonce in `EthCall` and `EstimateGas` grpc query. -* (rpc) [tharsis#878](https://github.com/tharsis/ethermint/pull/878) Workaround to make GetBlock RPC api report correct block gas used. -* (rpc) [tharsis#900](https://github.com/tharsis/ethermint/pull/900) `newPendingTransactions` filter return ethereum tx hash. -* (rpc) [tharsis#933](https://github.com/tharsis/ethermint/pull/933) Fix `newPendingTransactions` subscription deadlock when a Websocket client exits without unsubscribing and the node errors. -* (evm) [tharsis#932](https://github.com/tharsis/ethermint/pull/932) Fix base fee check logic in state transition. +* (rpc) [tharsis#955](https://github.com/evmos/ethermint/pull/955) Fix websocket server push duplicated messages to subscriber. +* (rpc) [tharsis#953](https://github.com/evmos/ethermint/pull/953) Add `eth_signTypedData` api support. +* (log) [tharsis#948](https://github.com/evmos/ethermint/pull/948) Redirect go-ethereum's logs to cosmos-sdk logger. +* (evm) [tharsis#884](https://github.com/evmos/ethermint/pull/884) Support multiple account types on the EVM `StateDB`. +* (rpc) [tharsis#831](https://github.com/evmos/ethermint/pull/831) Fix BaseFee value when height is specified. +* (evm) [tharsis#838](https://github.com/evmos/ethermint/pull/838) Fix splitting of trace.Memory into 32 chunks. +* (rpc) [tharsis#860](https://github.com/evmos/ethermint/pull/860) Fix `eth_getLogs` when specify blockHash without address/topics, and limit the response size. +* (rpc) [tharsis#865](https://github.com/evmos/ethermint/pull/865) Fix RPC Filter parameters being ignored +* (evm) [tharsis#871](https://github.com/evmos/ethermint/pull/871) Set correct nonce in `EthCall` and `EstimateGas` grpc query. +* (rpc) [tharsis#878](https://github.com/evmos/ethermint/pull/878) Workaround to make GetBlock RPC api report correct block gas used. +* (rpc) [tharsis#900](https://github.com/evmos/ethermint/pull/900) `newPendingTransactions` filter return ethereum tx hash. +* (rpc) [tharsis#933](https://github.com/evmos/ethermint/pull/933) Fix `newPendingTransactions` subscription deadlock when a Websocket client exits without unsubscribing and the node errors. +* (evm) [tharsis#932](https://github.com/evmos/ethermint/pull/932) Fix base fee check logic in state transition. ## [v0.9.0] - 2021-12-01 ### State Machine Breaking -* (evm) [tharsis#802](https://github.com/tharsis/ethermint/pull/802) Clear access list for each transaction +* (evm) [tharsis#802](https://github.com/evmos/ethermint/pull/802) Clear access list for each transaction ### Improvements -* (app) [tharsis#794](https://github.com/tharsis/ethermint/pull/794) Setup in-place store migrators. -* (ci) [tharsis#784](https://github.com/tharsis/ethermint/pull/784) Enable automatic backport of PRs. -* (rpc) [tharsis#786](https://github.com/tharsis/ethermint/pull/786) Improve error message of `SendTransaction`/`SendRawTransaction` JSON-RPC APIs. -* (rpc) [tharsis#810](https://github.com/tharsis/ethermint/pull/810) Optimize tx index lookup in web3 rpc +* (app) [tharsis#794](https://github.com/evmos/ethermint/pull/794) Setup in-place store migrators. +* (ci) [tharsis#784](https://github.com/evmos/ethermint/pull/784) Enable automatic backport of PRs. +* (rpc) [tharsis#786](https://github.com/evmos/ethermint/pull/786) Improve error message of `SendTransaction`/`SendRawTransaction` JSON-RPC APIs. +* (rpc) [tharsis#810](https://github.com/evmos/ethermint/pull/810) Optimize tx index lookup in web3 rpc ### Bug Fixes -* (license) [tharsis#800](https://github.com/tharsis/ethermint/pull/800) Re-license project to [LGPLv3](https://choosealicense.com/licenses/lgpl-3.0/#) to comply with go-ethereum. -* (evm) [tharsis#794](https://github.com/tharsis/ethermint/pull/794) Register EVM gRPC `Msg` server. -* (rpc) [tharsis#781](https://github.com/tharsis/ethermint/pull/781) Fix get block invalid transactions filter. -* (rpc) [tharsis#782](https://github.com/tharsis/ethermint/pull/782) Fix wrong block gas limit returned by JSON-RPC. -* (evm) [tharsis#798](https://github.com/tharsis/ethermint/pull/798) Fix the semantic of `ForEachStorage` callback's return value +* (license) [tharsis#800](https://github.com/evmos/ethermint/pull/800) Re-license project to [LGPLv3](https://choosealicense.com/licenses/lgpl-3.0/#) to comply with go-ethereum. +* (evm) [tharsis#794](https://github.com/evmos/ethermint/pull/794) Register EVM gRPC `Msg` server. +* (rpc) [tharsis#781](https://github.com/evmos/ethermint/pull/781) Fix get block invalid transactions filter. +* (rpc) [tharsis#782](https://github.com/evmos/ethermint/pull/782) Fix wrong block gas limit returned by JSON-RPC. +* (evm) [tharsis#798](https://github.com/evmos/ethermint/pull/798) Fix the semantic of `ForEachStorage` callback's return value ## [v0.8.1] - 2021-11-23 ### Bug Fixes -* (feemarket) [tharsis#770](https://github.com/tharsis/ethermint/pull/770) Enable fee market (EIP1559) by default. -* (rpc) [tharsis#769](https://github.com/tharsis/ethermint/pull/769) Fix default Ethereum signer for JSON-RPC. +* (feemarket) [tharsis#770](https://github.com/evmos/ethermint/pull/770) Enable fee market (EIP1559) by default. +* (rpc) [tharsis#769](https://github.com/evmos/ethermint/pull/769) Fix default Ethereum signer for JSON-RPC. ## [v0.8.0] - 2021-11-17 ### State Machine Breaking -* (evm, ante) [tharsis#620](https://github.com/tharsis/ethermint/pull/620) Add fee market field to EVM `Keeper` and `AnteHandler`. -* (all) [tharsis#231](https://github.com/tharsis/ethermint/pull/231) Bump go-ethereum version to [`v1.10.9`](https://github.com/ethereum/go-ethereum/releases/tag/v1.10.9) -* (ante) [tharsis#703](https://github.com/tharsis/ethermint/pull/703) Fix some fields in transaction are not authenticated by signature. -* (evm) [tharsis#751](https://github.com/tharsis/ethermint/pull/751) don't revert gas refund logic when transaction reverted +* (evm, ante) [tharsis#620](https://github.com/evmos/ethermint/pull/620) Add fee market field to EVM `Keeper` and `AnteHandler`. +* (all) [tharsis#231](https://github.com/evmos/ethermint/pull/231) Bump go-ethereum version to [`v1.10.9`](https://github.com/ethereum/go-ethereum/releases/tag/v1.10.9) +* (ante) [tharsis#703](https://github.com/evmos/ethermint/pull/703) Fix some fields in transaction are not authenticated by signature. +* (evm) [tharsis#751](https://github.com/evmos/ethermint/pull/751) don't revert gas refund logic when transaction reverted ### Features -* (rpc, evm) [tharsis#673](https://github.com/tharsis/ethermint/pull/673) Use tendermint events to store fee market basefee. -* (rpc) [tharsis#624](https://github.com/tharsis/ethermint/pull/624) Implement new JSON-RPC endpoints from latest geth version -* (evm) [tharsis#662](https://github.com/tharsis/ethermint/pull/662) Disable basefee for non london blocks -* (cmd) [tharsis#712](https://github.com/tharsis/ethermint/pull/712) add tx cli to build evm transaction -* (rpc) [tharsis#733](https://github.com/tharsis/ethermint/pull/733) add JSON_RPC endpoint `personal_unpair` -* (rpc) [tharsis#734](https://github.com/tharsis/ethermint/pull/734) add JSON_RPC endpoint `eth_feeHistory` -* (rpc) [tharsis#740](https://github.com/tharsis/ethermint/pull/740) add JSON_RPC endpoint `personal_initializeWallet` -* (rpc) [tharsis#743](https://github.com/tharsis/ethermint/pull/743) add JSON_RPC endpoint `debug_traceBlockByHash` -* (rpc) [tharsis#748](https://github.com/tharsis/ethermint/pull/748) add JSON_RPC endpoint `personal_listWallets` -* (rpc) [tharsis#754](https://github.com/tharsis/ethermint/pull/754) add JSON_RPC endpoint `debug_intermediateRoots` +* (rpc, evm) [tharsis#673](https://github.com/evmos/ethermint/pull/673) Use tendermint events to store fee market basefee. +* (rpc) [tharsis#624](https://github.com/evmos/ethermint/pull/624) Implement new JSON-RPC endpoints from latest geth version +* (evm) [tharsis#662](https://github.com/evmos/ethermint/pull/662) Disable basefee for non london blocks +* (cmd) [tharsis#712](https://github.com/evmos/ethermint/pull/712) add tx cli to build evm transaction +* (rpc) [tharsis#733](https://github.com/evmos/ethermint/pull/733) add JSON_RPC endpoint `personal_unpair` +* (rpc) [tharsis#734](https://github.com/evmos/ethermint/pull/734) add JSON_RPC endpoint `eth_feeHistory` +* (rpc) [tharsis#740](https://github.com/evmos/ethermint/pull/740) add JSON_RPC endpoint `personal_initializeWallet` +* (rpc) [tharsis#743](https://github.com/evmos/ethermint/pull/743) add JSON_RPC endpoint `debug_traceBlockByHash` +* (rpc) [tharsis#748](https://github.com/evmos/ethermint/pull/748) add JSON_RPC endpoint `personal_listWallets` +* (rpc) [tharsis#754](https://github.com/evmos/ethermint/pull/754) add JSON_RPC endpoint `debug_intermediateRoots` ### Bug Fixes -* (evm) [tharsis#746](https://github.com/tharsis/ethermint/pull/746) Set EVM debugging based on tracer configuration. -* (app,cli) [tharsis#725](https://github.com/tharsis/ethermint/pull/725) Fix cli-config for `keys` command. -* (rpc) [tharsis#727](https://github.com/tharsis/ethermint/pull/727) Decode raw transaction using RLP. -* (rpc) [tharsis#661](https://github.com/tharsis/ethermint/pull/661) Fix OOM bug when creating too many filters using JSON-RPC. -* (evm) [tharsis#660](https://github.com/tharsis/ethermint/pull/660) Fix `nil` pointer panic in `ApplyNativeMessage`. -* (evm, test) [tharsis#649](https://github.com/tharsis/ethermint/pull/649) Test DynamicFeeTx. -* (evm) [tharsis#702](https://github.com/tharsis/ethermint/pull/702) Fix panic in web3 RPC handlers -* (rpc) [tharsis#720](https://github.com/tharsis/ethermint/pull/720) Fix `debug_traceTransaction` failure -* (rpc) [tharsis#741](https://github.com/tharsis/ethermint/pull/741) Fix `eth_getBlockByNumberAndHash` return with non eth txs -* (rpc) [tharsis#743](https://github.com/tharsis/ethermint/pull/743) Fix debug JSON RPC handler crash on non-existing block +* (evm) [tharsis#746](https://github.com/evmos/ethermint/pull/746) Set EVM debugging based on tracer configuration. +* (app,cli) [tharsis#725](https://github.com/evmos/ethermint/pull/725) Fix cli-config for `keys` command. +* (rpc) [tharsis#727](https://github.com/evmos/ethermint/pull/727) Decode raw transaction using RLP. +* (rpc) [tharsis#661](https://github.com/evmos/ethermint/pull/661) Fix OOM bug when creating too many filters using JSON-RPC. +* (evm) [tharsis#660](https://github.com/evmos/ethermint/pull/660) Fix `nil` pointer panic in `ApplyNativeMessage`. +* (evm, test) [tharsis#649](https://github.com/evmos/ethermint/pull/649) Test DynamicFeeTx. +* (evm) [tharsis#702](https://github.com/evmos/ethermint/pull/702) Fix panic in web3 RPC handlers +* (rpc) [tharsis#720](https://github.com/evmos/ethermint/pull/720) Fix `debug_traceTransaction` failure +* (rpc) [tharsis#741](https://github.com/evmos/ethermint/pull/741) Fix `eth_getBlockByNumberAndHash` return with non eth txs +* (rpc) [tharsis#743](https://github.com/evmos/ethermint/pull/743) Fix debug JSON RPC handler crash on non-existing block ### Improvements -* (tests) [tharsis#704](https://github.com/tharsis/ethermint/pull/704) Introduce E2E testing framework for clients -* (deps) [tharsis#737](https://github.com/tharsis/ethermint/pull/737) Bump ibc-go to [`v2.0.0`](https://github.com/cosmos/ibc-go/releases/tag/v2.0.0) -* (rpc) [tharsis#671](https://github.com/tharsis/ethermint/pull/671) Don't pass base fee externally for `EthCall`/`EthEstimateGas` apis. -* (evm) [tharsis#674](https://github.com/tharsis/ethermint/pull/674) Refactor `ApplyMessage`, remove +* (tests) [tharsis#704](https://github.com/evmos/ethermint/pull/704) Introduce E2E testing framework for clients +* (deps) [tharsis#737](https://github.com/evmos/ethermint/pull/737) Bump ibc-go to [`v2.0.0`](https://github.com/cosmos/ibc-go/releases/tag/v2.0.0) +* (rpc) [tharsis#671](https://github.com/evmos/ethermint/pull/671) Don't pass base fee externally for `EthCall`/`EthEstimateGas` apis. +* (evm) [tharsis#674](https://github.com/evmos/ethermint/pull/674) Refactor `ApplyMessage`, remove `ApplyNativeMessage`. -* (rpc) [tharsis#714](https://github.com/tharsis/ethermint/pull/714) remove `MsgEthereumTx` support in `TxConfig` +* (rpc) [tharsis#714](https://github.com/evmos/ethermint/pull/714) remove `MsgEthereumTx` support in `TxConfig` ## [v0.7.2] - 2021-10-24 ### Improvements -* (deps) [tharsis#692](https://github.com/tharsis/ethermint/pull/692) Bump Cosmos SDK version to [`v0.44.3`](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.44.3). -* (rpc) [tharsis#679](https://github.com/tharsis/ethermint/pull/679) Fix file close handle. -* (deps) [tharsis#668](https://github.com/tharsis/ethermint/pull/668) Bump Tendermint version to [`v0.34.14`](https://github.com/tendermint/tendermint/releases/tag/v0.34.14). +* (deps) [tharsis#692](https://github.com/evmos/ethermint/pull/692) Bump Cosmos SDK version to [`v0.44.3`](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.44.3). +* (rpc) [tharsis#679](https://github.com/evmos/ethermint/pull/679) Fix file close handle. +* (deps) [tharsis#668](https://github.com/evmos/ethermint/pull/668) Bump Tendermint version to [`v0.34.14`](https://github.com/tendermint/tendermint/releases/tag/v0.34.14). ### Bug Fixes -* (rpc) [tharsis#667](https://github.com/tharsis/ethermint/issues/667) Fix `ExpandHome` restrictions bypass +* (rpc) [tharsis#667](https://github.com/evmos/ethermint/issues/667) Fix `ExpandHome` restrictions bypass ## [v0.7.1] - 2021-10-08 ### Bug Fixes -* (evm) [tharsis#650](https://github.com/tharsis/ethermint/pull/650) Fix panic when flattening the cache context in case transaction is reverted. -* (rpc, test) [tharsis#608](https://github.com/tharsis/ethermint/pull/608) Fix rpc test. +* (evm) [tharsis#650](https://github.com/evmos/ethermint/pull/650) Fix panic when flattening the cache context in case transaction is reverted. +* (rpc, test) [tharsis#608](https://github.com/evmos/ethermint/pull/608) Fix rpc test. ## [v0.7.0] - 2021-10-07 ### API Breaking -* (rpc) [tharsis#400](https://github.com/tharsis/ethermint/issues/400) Restructure JSON-RPC directory and rename server config +* (rpc) [tharsis#400](https://github.com/evmos/ethermint/issues/400) Restructure JSON-RPC directory and rename server config ### Improvements -* (deps) [tharsis#621](https://github.com/tharsis/ethermint/pull/621) Bump IBC-go to [`v1.2.1`](https://github.com/cosmos/ibc-go/releases/tag/v1.2.1) -* (evm) [tharsis#613](https://github.com/tharsis/ethermint/pull/613) Refactor `traceTx` -* (deps) [tharsis#610](https://github.com/tharsis/ethermint/pull/610) Bump Cosmos SDK to [v0.44.1](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.44.1). +* (deps) [tharsis#621](https://github.com/evmos/ethermint/pull/621) Bump IBC-go to [`v1.2.1`](https://github.com/cosmos/ibc-go/releases/tag/v1.2.1) +* (evm) [tharsis#613](https://github.com/evmos/ethermint/pull/613) Refactor `traceTx` +* (deps) [tharsis#610](https://github.com/evmos/ethermint/pull/610) Bump Cosmos SDK to [v0.44.1](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.44.1). ### Bug Fixes -* (rpc) [tharsis#642](https://github.com/tharsis/ethermint/issues/642) Fix `eth_getLogs` when string is specified in filter's from or to fields -* (evm) [tharsis#616](https://github.com/tharsis/ethermint/issues/616) Fix halt on deeply nested stack of cache context. Stack is now flattened before iterating over the tx logs. -* (rpc, evm) [tharsis#614](https://github.com/tharsis/ethermint/issues/614) Use JSON for (un)marshaling tx `Log`s from events. -* (rpc) [tharsis#611](https://github.com/tharsis/ethermint/pull/611) Fix panic on JSON-RPC when querying for an invalid block height. -* (cmd) [tharsis#483](https://github.com/tharsis/ethermint/pull/483) Use config values on genesis accounts. +* (rpc) [tharsis#642](https://github.com/evmos/ethermint/issues/642) Fix `eth_getLogs` when string is specified in filter's from or to fields +* (evm) [tharsis#616](https://github.com/evmos/ethermint/issues/616) Fix halt on deeply nested stack of cache context. Stack is now flattened before iterating over the tx logs. +* (rpc, evm) [tharsis#614](https://github.com/evmos/ethermint/issues/614) Use JSON for (un)marshaling tx `Log`s from events. +* (rpc) [tharsis#611](https://github.com/evmos/ethermint/pull/611) Fix panic on JSON-RPC when querying for an invalid block height. +* (cmd) [tharsis#483](https://github.com/evmos/ethermint/pull/483) Use config values on genesis accounts. ## [v0.6.0] - 2021-09-29 ### State Machine Breaking -* (app) [tharsis#476](https://github.com/tharsis/ethermint/pull/476) Update Bech32 HRP to `ethm`. -* (evm) [tharsis#556](https://github.com/tharsis/ethermint/pull/556) Remove tx logs and block bloom from chain state -* (evm) [tharsis#590](https://github.com/tharsis/ethermint/pull/590) Contract storage key is not hashed anymore +* (app) [tharsis#476](https://github.com/evmos/ethermint/pull/476) Update Bech32 HRP to `ethm`. +* (evm) [tharsis#556](https://github.com/evmos/ethermint/pull/556) Remove tx logs and block bloom from chain state +* (evm) [tharsis#590](https://github.com/evmos/ethermint/pull/590) Contract storage key is not hashed anymore ### API Breaking -* (evm) [tharsis#469](https://github.com/tharsis/ethermint/pull/469) Deprecate `YoloV3Block` and `EWASMBlock` from `ChainConfig` +* (evm) [tharsis#469](https://github.com/evmos/ethermint/pull/469) Deprecate `YoloV3Block` and `EWASMBlock` from `ChainConfig` ### Features -* (evm) [tharsis#469](https://github.com/tharsis/ethermint/pull/469) Support [EIP-1559](https://eips.ethereum.org/EIPS/eip-1559) -* (evm) [tharsis#417](https://github.com/tharsis/ethermint/pull/417) Add `EvmHooks` for tx post-processing -* (rpc) [tharsis#506](https://github.com/tharsis/ethermint/pull/506) Support for `debug_traceTransaction` RPC endpoint -* (rpc) [tharsis#555](https://github.com/tharsis/ethermint/pull/555) Support for `debug_traceBlockByNumber` RPC endpoint +* (evm) [tharsis#469](https://github.com/evmos/ethermint/pull/469) Support [EIP-1559](https://eips.ethereum.org/EIPS/eip-1559) +* (evm) [tharsis#417](https://github.com/evmos/ethermint/pull/417) Add `EvmHooks` for tx post-processing +* (rpc) [tharsis#506](https://github.com/evmos/ethermint/pull/506) Support for `debug_traceTransaction` RPC endpoint +* (rpc) [tharsis#555](https://github.com/evmos/ethermint/pull/555) Support for `debug_traceBlockByNumber` RPC endpoint ### Bug Fixes -* (rpc, server) [tharsis#600](https://github.com/tharsis/ethermint/pull/600) Add TLS configuration for websocket API -* (rpc) [tharsis#598](https://github.com/tharsis/ethermint/pull/598) Check truncation when creating a `BlockNumber` from `big.Int` -* (evm) [tharsis#597](https://github.com/tharsis/ethermint/pull/597) Check for `uint64` -> `int64` block height overflow on `GetHashFn` -* (evm) [tharsis#579](https://github.com/tharsis/ethermint/pull/579) Update `DeriveChainID` function to handle `v` signature values `< 35`. -* (encoding) [tharsis#478](https://github.com/tharsis/ethermint/pull/478) Register `Evidence` to amino codec. -* (rpc) [tharsis#478](https://github.com/tharsis/ethermint/pull/481) Getting the node configuration when calling the `miner` rpc methods. -* (cli) [tharsis#561](https://github.com/tharsis/ethermint/pull/561) `Export` and `Start` commands now use the same home directory. +* (rpc, server) [tharsis#600](https://github.com/evmos/ethermint/pull/600) Add TLS configuration for websocket API +* (rpc) [tharsis#598](https://github.com/evmos/ethermint/pull/598) Check truncation when creating a `BlockNumber` from `big.Int` +* (evm) [tharsis#597](https://github.com/evmos/ethermint/pull/597) Check for `uint64` -> `int64` block height overflow on `GetHashFn` +* (evm) [tharsis#579](https://github.com/evmos/ethermint/pull/579) Update `DeriveChainID` function to handle `v` signature values `< 35`. +* (encoding) [tharsis#478](https://github.com/evmos/ethermint/pull/478) Register `Evidence` to amino codec. +* (rpc) [tharsis#478](https://github.com/evmos/ethermint/pull/481) Getting the node configuration when calling the `miner` rpc methods. +* (cli) [tharsis#561](https://github.com/evmos/ethermint/pull/561) `Export` and `Start` commands now use the same home directory. ### Improvements -* (evm) [tharsis#461](https://github.com/tharsis/ethermint/pull/461) Increase performance of `StateDB` transaction log storage (r/w). -* (evm) [tharsis#566](https://github.com/tharsis/ethermint/pull/566) Introduce `stateErr` store in `StateDB` to avoid meaningless operations if any error happened before -* (rpc, evm) [tharsis#587](https://github.com/tharsis/ethermint/pull/587) Apply bloom filter when query ethlogs with range of blocks -* (evm) [tharsis#586](https://github.com/tharsis/ethermint/pull/586) Benchmark evm keeper +* (evm) [tharsis#461](https://github.com/evmos/ethermint/pull/461) Increase performance of `StateDB` transaction log storage (r/w). +* (evm) [tharsis#566](https://github.com/evmos/ethermint/pull/566) Introduce `stateErr` store in `StateDB` to avoid meaningless operations if any error happened before +* (rpc, evm) [tharsis#587](https://github.com/evmos/ethermint/pull/587) Apply bloom filter when query ethlogs with range of blocks +* (evm) [tharsis#586](https://github.com/evmos/ethermint/pull/586) Benchmark evm keeper ## [v0.5.0] - 2021-08-20 ### State Machine Breaking -* (app, rpc) [tharsis#447](https://github.com/tharsis/ethermint/pull/447) Chain ID format has been changed from `-` to `_-` +* (app, rpc) [tharsis#447](https://github.com/evmos/ethermint/pull/447) Chain ID format has been changed from `-` to `_-` in order to clearly distinguish permanent vs impermanent components. -* (app, evm) [tharsis#434](https://github.com/tharsis/ethermint/pull/434) EVM `Keeper` struct and `NewEVM` function now have a new `trace` field to define +* (app, evm) [tharsis#434](https://github.com/evmos/ethermint/pull/434) EVM `Keeper` struct and `NewEVM` function now have a new `trace` field to define the Tracer type used to collect execution traces from the EVM transaction execution. -* (evm) [tharsis#175](https://github.com/tharsis/ethermint/issues/175) The msg `TxData` field is now represented as a `*proto.Any`. -* (evm) [tharsis#84](https://github.com/tharsis/ethermint/pull/84) Remove `journal`, `CommitStateDB` and `stateObjects`. -* (rpc, evm) [tharsis#81](https://github.com/tharsis/ethermint/pull/81) Remove tx `Receipt` from store and replace it with fields obtained from the Tendermint RPC client. -* (evm) [tharsis#72](https://github.com/tharsis/ethermint/issues/72) Update `AccessList` to use `TransientStore` instead of map. -* (evm) [tharsis#68](https://github.com/tharsis/ethermint/issues/68) Replace block hash storage map to use staking `HistoricalInfo`. -* (evm) [tharsis#276](https://github.com/tharsis/ethermint/pull/276) Vm errors don't result in cosmos tx failure, just +* (evm) [tharsis#175](https://github.com/evmos/ethermint/issues/175) The msg `TxData` field is now represented as a `*proto.Any`. +* (evm) [tharsis#84](https://github.com/evmos/ethermint/pull/84) Remove `journal`, `CommitStateDB` and `stateObjects`. +* (rpc, evm) [tharsis#81](https://github.com/evmos/ethermint/pull/81) Remove tx `Receipt` from store and replace it with fields obtained from the Tendermint RPC client. +* (evm) [tharsis#72](https://github.com/evmos/ethermint/issues/72) Update `AccessList` to use `TransientStore` instead of map. +* (evm) [tharsis#68](https://github.com/evmos/ethermint/issues/68) Replace block hash storage map to use staking `HistoricalInfo`. +* (evm) [tharsis#276](https://github.com/evmos/ethermint/pull/276) Vm errors don't result in cosmos tx failure, just different tx state and events. -* (evm) [tharsis#342](https://github.com/tharsis/ethermint/issues/342) Don't clear balance when resetting the account. -* (evm) [tharsis#334](https://github.com/tharsis/ethermint/pull/334) Log index changed to the index in block rather than +* (evm) [tharsis#342](https://github.com/evmos/ethermint/issues/342) Don't clear balance when resetting the account. +* (evm) [tharsis#334](https://github.com/evmos/ethermint/pull/334) Log index changed to the index in block rather than tx. -* (evm) [tharsis#399](https://github.com/tharsis/ethermint/pull/399) Exception in sub-message call reverts the call if it's not propagated. +* (evm) [tharsis#399](https://github.com/evmos/ethermint/pull/399) Exception in sub-message call reverts the call if it's not propagated. ### API Breaking -* (proto) [tharsis#448](https://github.com/tharsis/ethermint/pull/448) Bump version for all Ethermint messages to `v1` -* (server) [tharsis#434](https://github.com/tharsis/ethermint/pull/434) `evm-rpc` flags and app config have been renamed to `json-rpc`. -* (proto, evm) [tharsis#207](https://github.com/tharsis/ethermint/issues/207) Replace `big.Int` in favor of `sdk.Int` for `TxData` fields -* (proto, evm) [tharsis#81](https://github.com/tharsis/ethermint/pull/81) gRPC Query and Tx service changes: +* (proto) [tharsis#448](https://github.com/evmos/ethermint/pull/448) Bump version for all Ethermint messages to `v1` +* (server) [tharsis#434](https://github.com/evmos/ethermint/pull/434) `evm-rpc` flags and app config have been renamed to `json-rpc`. +* (proto, evm) [tharsis#207](https://github.com/evmos/ethermint/issues/207) Replace `big.Int` in favor of `sdk.Int` for `TxData` fields +* (proto, evm) [tharsis#81](https://github.com/evmos/ethermint/pull/81) gRPC Query and Tx service changes: * The `TxReceipt`, `TxReceiptsByBlockHeight` endpoints have been removed from the Query service. * The `ContractAddress`, `Bloom` have been removed from the `MsgEthereumTxResponse` and the response now contains the ethereum-formatted `Hash` in hex format. * (eth) [tharsis#845](https://github.com/cosmos/ethermint/pull/845) The `eth` namespace must be included in the list of API's as default to run the rpc server without error. -* (evm) [tharsis#202](https://github.com/tharsis/ethermint/pull/202) Web3 api `SendTransaction`/`SendRawTransaction` returns ethereum compatible transaction hash, and query api `GetTransaction*` also accept that. -* (rpc) [tharsis#258](https://github.com/tharsis/ethermint/pull/258) Return empty `BloomFilter` instead of throwing an error when it cannot be found (`nil` or empty). -* (rpc) [tharsis#277](https://github.com/tharsis/ethermint/pull/321) Fix `BloomFilter` response. +* (evm) [tharsis#202](https://github.com/evmos/ethermint/pull/202) Web3 api `SendTransaction`/`SendRawTransaction` returns ethereum compatible transaction hash, and query api `GetTransaction*` also accept that. +* (rpc) [tharsis#258](https://github.com/evmos/ethermint/pull/258) Return empty `BloomFilter` instead of throwing an error when it cannot be found (`nil` or empty). +* (rpc) [tharsis#277](https://github.com/evmos/ethermint/pull/321) Fix `BloomFilter` response. ### Improvements -* (client) [tharsis#450](https://github.com/tharsis/ethermint/issues/450) Add EIP55 hex address support on `debug addr` command. -* (server) [tharsis#343](https://github.com/tharsis/ethermint/pull/343) Define a wrap tendermint logger `Handler` go-ethereum's `root` logger. -* (rpc) [tharsis#457](https://github.com/tharsis/ethermint/pull/457) Configure RPC gas cap through app config. -* (evm) [tharsis#434](https://github.com/tharsis/ethermint/pull/434) Support different `Tracer` types for the EVM. -* (deps) [tharsis#427](https://github.com/tharsis/ethermint/pull/427) Bump ibc-go to [`v1.0.0`](https://github.com/cosmos/ibc-go/releases/tag/v1.0.0) -* (gRPC) [tharsis#239](https://github.com/tharsis/ethermint/pull/239) Query `ChainConfig` via gRPC. -* (rpc) [tharsis#181](https://github.com/tharsis/ethermint/pull/181) Use evm denomination for params on tx fee. -* (deps) [tharsis#423](https://github.com/tharsis/ethermint/pull/423) Bump Cosmos SDK and Tendermint versions to [v0.43.0](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.43.0) and [v0.34.11](https://github.com/tendermint/tendermint/releases/tag/v0.34.11), respectively. -* (evm) [tharsis#66](https://github.com/tharsis/ethermint/issues/66) Support legacy transaction types for signing. -* (evm) [tharsis#24](https://github.com/tharsis/ethermint/pull/24) Implement metrics for `MsgEthereumTx`, state transitions, `BeginBlock` and `EndBlock`. -* (rpc) [tharsis#124](https://github.com/tharsis/ethermint/issues/124) Implement `txpool_content`, `txpool_inspect` and `txpool_status` RPC methods -* (rpc) [tharsis#112](https://github.com/tharsis/ethermint/pull/153) Fix `eth_coinbase` to return the ethereum address of the validator -* (rpc) [tharsis#176](https://github.com/tharsis/ethermint/issues/176) Support fetching pending nonce -* (rpc) [tharsis#272](https://github.com/tharsis/ethermint/pull/272) do binary search to estimate gas accurately -* (rpc) [tharsis#313](https://github.com/tharsis/ethermint/pull/313) Implement internal debug namespace (Not including logger functions nor traces). -* (rpc) [tharsis#349](https://github.com/tharsis/ethermint/pull/349) Implement configurable JSON-RPC APIs to manage enabled namespaces. -* (rpc) [tharsis#377](https://github.com/tharsis/ethermint/pull/377) Implement `miner_` namespace. `miner_setEtherbase` and `miner_setGasPrice` are working as intended. All the other calls are not applicable and return `unsupported`. -* (eth) [tharsis#460](https://github.com/tharsis/ethermint/issues/460) Add support for EIP-1898. +* (client) [tharsis#450](https://github.com/evmos/ethermint/issues/450) Add EIP55 hex address support on `debug addr` command. +* (server) [tharsis#343](https://github.com/evmos/ethermint/pull/343) Define a wrap tendermint logger `Handler` go-ethereum's `root` logger. +* (rpc) [tharsis#457](https://github.com/evmos/ethermint/pull/457) Configure RPC gas cap through app config. +* (evm) [tharsis#434](https://github.com/evmos/ethermint/pull/434) Support different `Tracer` types for the EVM. +* (deps) [tharsis#427](https://github.com/evmos/ethermint/pull/427) Bump ibc-go to [`v1.0.0`](https://github.com/cosmos/ibc-go/releases/tag/v1.0.0) +* (gRPC) [tharsis#239](https://github.com/evmos/ethermint/pull/239) Query `ChainConfig` via gRPC. +* (rpc) [tharsis#181](https://github.com/evmos/ethermint/pull/181) Use evm denomination for params on tx fee. +* (deps) [tharsis#423](https://github.com/evmos/ethermint/pull/423) Bump Cosmos SDK and Tendermint versions to [v0.43.0](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.43.0) and [v0.34.11](https://github.com/tendermint/tendermint/releases/tag/v0.34.11), respectively. +* (evm) [tharsis#66](https://github.com/evmos/ethermint/issues/66) Support legacy transaction types for signing. +* (evm) [tharsis#24](https://github.com/evmos/ethermint/pull/24) Implement metrics for `MsgEthereumTx`, state transitions, `BeginBlock` and `EndBlock`. +* (rpc) [tharsis#124](https://github.com/evmos/ethermint/issues/124) Implement `txpool_content`, `txpool_inspect` and `txpool_status` RPC methods +* (rpc) [tharsis#112](https://github.com/evmos/ethermint/pull/153) Fix `eth_coinbase` to return the ethereum address of the validator +* (rpc) [tharsis#176](https://github.com/evmos/ethermint/issues/176) Support fetching pending nonce +* (rpc) [tharsis#272](https://github.com/evmos/ethermint/pull/272) do binary search to estimate gas accurately +* (rpc) [tharsis#313](https://github.com/evmos/ethermint/pull/313) Implement internal debug namespace (Not including logger functions nor traces). +* (rpc) [tharsis#349](https://github.com/evmos/ethermint/pull/349) Implement configurable JSON-RPC APIs to manage enabled namespaces. +* (rpc) [tharsis#377](https://github.com/evmos/ethermint/pull/377) Implement `miner_` namespace. `miner_setEtherbase` and `miner_setGasPrice` are working as intended. All the other calls are not applicable and return `unsupported`. +* (eth) [tharsis#460](https://github.com/evmos/ethermint/issues/460) Add support for EIP-1898. ### Bug Fixes -* (keys) [tharsis#346](https://github.com/tharsis/ethermint/pull/346) Fix `keys add` command with `--ledger` flag for the `secp256k1` signing algorithm. -* (evm) [tharsis#291](https://github.com/tharsis/ethermint/pull/291) Use block proposer address (validator operator) for `COINBASE` opcode. -* (rpc) [tharsis#81](https://github.com/tharsis/ethermint/pull/81) Fix transaction hashing and decoding on `eth_sendTransaction`. -* (rpc) [tharsis#45](https://github.com/tharsis/ethermint/pull/45) Use `EmptyUncleHash` and `EmptyRootHash` for empty ethereum `Header` fields. +* (keys) [tharsis#346](https://github.com/evmos/ethermint/pull/346) Fix `keys add` command with `--ledger` flag for the `secp256k1` signing algorithm. +* (evm) [tharsis#291](https://github.com/evmos/ethermint/pull/291) Use block proposer address (validator operator) for `COINBASE` opcode. +* (rpc) [tharsis#81](https://github.com/evmos/ethermint/pull/81) Fix transaction hashing and decoding on `eth_sendTransaction`. +* (rpc) [tharsis#45](https://github.com/evmos/ethermint/pull/45) Use `EmptyUncleHash` and `EmptyRootHash` for empty ethereum `Header` fields. ## [v0.4.1] - 2021-03-01 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index ee37f42a54..92b1ed1645 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -25,8 +25,8 @@ Contributing to this repo can mean many things such as participating in discussion or proposing code changes. To ensure a smooth workflow for all contributors, the general procedure for contributing has been established: -1. Either [open](https://github.com/tharsis/ethermint/issues/new/choose) or - [find](https://github.com/tharsis/ethermint/issues) an issue you'd like to help with +1. Either [open](https://github.com/evmos/ethermint/issues/new/choose) or + [find](https://github.com/evmos/ethermint/issues) an issue you'd like to help with 2. Participate in thoughtful discussion on that issue 3. If you would like to contribute: 1. If the issue is a proposal, ensure that the proposal has been accepted @@ -55,7 +55,7 @@ taken place in a GitHub issue, that PR runs a high likelihood of being rejected. Other notes: - Looking for a good place to start contributing? How about checking out some - [good first issues](https://github.com/tharsis/ethermint/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22) + [good first issues](https://github.com/evmos/ethermint/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22) - Please make sure to run `make format` before every commit - the easiest way to do this is have your editor run it for you upon saving a file. Additionally please ensure that your code is lint compliant by running `make lint-fix`. @@ -64,7 +64,7 @@ Other notes: ## Architecture Decision Records (ADR) -When proposing an architecture decision for Ethermint, please start by opening an [issue](https://github.com/tharsis/ethermint/issues/new/choose) or a [discussion](https://github.com/tharsis/ethermint/discussions/new) with a summary of the proposal. Once the proposal has been discussed and there is rough alignment on a high-level approach to the design, the [ADR creation process](https://github.com/tharsis/ethermint/blob/main/docs/architecture/PROCESS.md) can begin. We are following this process to ensure all involved parties are in agreement before any party begins coding the proposed implementation. If you would like to see examples of how these are written, please refer to the current [ADRs](https://github.com/tharsis/ethermint/tree/main/docs/architecture). +When proposing an architecture decision for Ethermint, please start by opening an [issue](https://github.com/evmos/ethermint/issues/new/choose) or a [discussion](https://github.com/evmos/ethermint/discussions/new) with a summary of the proposal. Once the proposal has been discussed and there is rough alignment on a high-level approach to the design, the [ADR creation process](https://github.com/evmos/ethermint/blob/main/docs/architecture/PROCESS.md) can begin. We are following this process to ensure all involved parties are in agreement before any party begins coding the proposed implementation. If you would like to see examples of how these are written, please refer to the current [ADRs](https://github.com/evmos/ethermint/tree/main/docs/architecture). ## Pull Requests @@ -112,12 +112,12 @@ Go requires code to live under absolute paths, and this requirement complicates While my fork lives at `https://github.com/rigeyrigerige/ethermint`, the code should never exist at `$GOPATH/src/github.com/rigeyrigerige/ethermint`. Instead, we use `git remote` to add the fork as a new remote for the original repo, -`$GOPATH/src/github.com/tharsis/ethermint`, and do all the work there. +`$GOPATH/src/github.com/evmos/ethermint`, and do all the work there. For instance, to create a fork and work on a branch of it, I would: - Create the fork on GitHub, using the fork button. -- Go to the original repo checked out locally (i.e. `$GOPATH/src/github.com/tharsis/ethermint`) +- Go to the original repo checked out locally (i.e. `$GOPATH/src/github.com/evmos/ethermint`) - `git remote rename origin upstream` - `git remote add origin git@github.com:rigeyrigerige/ethermint.git` @@ -220,7 +220,7 @@ should be targeted against the release candidate branch. - `main` must never fail `make lint test test-race` - `main` should not fail `make lint` - no `--force` onto `main` (except when reverting a broken commit, which should seldom happen) -- create a development branch either on github.com/tharsis/ethermint, or your fork (using `git remote add origin`) +- create a development branch either on github.com/evmos/ethermint, or your fork (using `git remote add origin`) - before submitting a pull request, begin `git rebase` on top of `main` ### Pull Merge Procedure @@ -343,7 +343,7 @@ is broken up into three distinct stages: **Strategy Discovery**, **Concept Appro - Architecture Decision Records (ADRs) may be proposed by any contributors or maintainers of Ethermint, and should follow the guidelines outlined in the - [ADR Creation Process](https://github.com/tharsis/ethermint/blob/main/docs/architecture/PROCESS.md) + [ADR Creation Process](https://github.com/evmos/ethermint/blob/main/docs/architecture/PROCESS.md) - After proposal, a time bound period for Request for Comment (RFC) on ADRs commences - ADRs are intended to be iterative, and may be merged into `main` while still in a `Proposed` status diff --git a/Dockerfile b/Dockerfile index b4b43805d7..105a475499 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,7 @@ FROM golang:alpine AS build-env ENV PACKAGES git build-base # Set working directory for the build -WORKDIR /go/src/github.com/tharsis/ethermint +WORKDIR /go/src/github.com/evmos/ethermint # Install dependencies RUN apk add --update $PACKAGES @@ -24,7 +24,7 @@ RUN apk add --update ca-certificates jq WORKDIR / # Copy over binaries from the build-env -COPY --from=build-env /go/src/github.com/tharsis/ethermint/build/ethermintd /usr/bin/ethermintd +COPY --from=build-env /go/src/github.com/evmos/ethermint/build/ethermintd /usr/bin/ethermintd # Run ethermintd by default CMD ["ethermintd"] diff --git a/Makefile b/Makefile index 5ea14722a3..ca66108c4e 100755 --- a/Makefile +++ b/Makefile @@ -11,7 +11,7 @@ ETHERMINT_BINARY = ethermintd ETHERMINT_DIR = ethermint BUILDDIR ?= $(CURDIR)/build SIMAPP = ./app -HTTPS_GIT := https://github.com/tharsis/ethermint.git +HTTPS_GIT := https://github.com/evmos/ethermint.git DOCKER := $(shell which docker) DOCKER_BUF := $(DOCKER) run --rm -v $(CURDIR):/workspace --workdir /workspace bufbuild/buf @@ -152,7 +152,7 @@ build-all: tools build lint test ### Releasing ### ############################################################################### -PACKAGE_NAME:=github.com/tharsis/ethermint +PACKAGE_NAME:=github.com/evmos/ethermint GOLANG_CROSS_VERSION = v1.17.1 GOPATH ?= '$(HOME)/go' release-dry-run: @@ -285,7 +285,7 @@ update-swagger-docs: statik .PHONY: update-swagger-docs godocs: - @echo "--> Wait a few seconds and visit http://localhost:6060/pkg/github.com/tharsis/ethermint/types" + @echo "--> Wait a few seconds and visit http://localhost:6060/pkg/github.com/evmos/ethermint/types" godoc -http=:6060 ############################################################################### @@ -319,7 +319,7 @@ else endif test-import: - go test -run TestImporterTestSuite -v --vet=off github.com/tharsis/ethermint/tests/importer + go test -run TestImporterTestSuite -v --vet=off github.com/evmos/ethermint/tests/importer test-rpc: ./scripts/integration-test-all.sh -t "rpc" -q 1 -z 1 -s 2 -m "rpc" -r "true" diff --git a/README.md b/README.md index fabeab8c9b..90f579bd1a 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Ethermint -Celestiaorg fork of https://github.com/tharsis/ethermint +Celestiaorg fork of https://github.com/evmos/ethermint Replaces usage of https://github.com/tendermint/tendermint with https://github.com/celestiaorg/optimint diff --git a/app/ante/ante.go b/app/ante/ante.go index fbf1e9c760..94cc70289c 100644 --- a/app/ante/ante.go +++ b/app/ante/ante.go @@ -12,7 +12,7 @@ import ( authante "github.com/cosmos/cosmos-sdk/x/auth/ante" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/crypto/ethsecp256k1" ) const ( diff --git a/app/ante/ante_test.go b/app/ante/ante_test.go index 7779559b94..ff14e8b901 100644 --- a/app/ante/ante_test.go +++ b/app/ante/ante_test.go @@ -11,8 +11,8 @@ import ( "github.com/ethereum/go-ethereum/core/types" ethparams "github.com/ethereum/go-ethereum/params" - "github.com/tharsis/ethermint/tests" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/tests" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) func (suite AnteTestSuite) TestAnteHandler() { diff --git a/app/ante/eip712.go b/app/ante/eip712.go index 9de0d191b4..f9f2abc1c2 100644 --- a/app/ante/eip712.go +++ b/app/ante/eip712.go @@ -15,10 +15,10 @@ import ( ethcrypto "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/crypto/secp256k1" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/ethereum/eip712" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/ethereum/eip712" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) var ethermintCodec codec.ProtoCodecMarshaler diff --git a/app/ante/eth.go b/app/ante/eth.go index 314263157e..e82d14b0f9 100644 --- a/app/ante/eth.go +++ b/app/ante/eth.go @@ -9,10 +9,10 @@ import ( sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" authante "github.com/cosmos/cosmos-sdk/x/auth/ante" - ethermint "github.com/tharsis/ethermint/types" - evmkeeper "github.com/tharsis/ethermint/x/evm/keeper" - "github.com/tharsis/ethermint/x/evm/statedb" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + ethermint "github.com/evmos/ethermint/types" + evmkeeper "github.com/evmos/ethermint/x/evm/keeper" + "github.com/evmos/ethermint/x/evm/statedb" + evmtypes "github.com/evmos/ethermint/x/evm/types" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" diff --git a/app/ante/eth_test.go b/app/ante/eth_test.go index 04f387e5a5..ab99316221 100644 --- a/app/ante/eth_test.go +++ b/app/ante/eth_test.go @@ -5,11 +5,11 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/app/ante" - "github.com/tharsis/ethermint/server/config" - "github.com/tharsis/ethermint/tests" - "github.com/tharsis/ethermint/x/evm/statedb" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/app/ante" + "github.com/evmos/ethermint/server/config" + "github.com/evmos/ethermint/tests" + "github.com/evmos/ethermint/x/evm/statedb" + evmtypes "github.com/evmos/ethermint/x/evm/types" ethtypes "github.com/ethereum/go-ethereum/core/types" ) diff --git a/app/ante/fee_market_test.go b/app/ante/fee_market_test.go index 33eb9225fa..48491a6606 100644 --- a/app/ante/fee_market_test.go +++ b/app/ante/fee_market_test.go @@ -6,9 +6,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/app/ante" - "github.com/tharsis/ethermint/tests" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/app/ante" + "github.com/evmos/ethermint/tests" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) func (suite AnteTestSuite) TestGasWantedDecorator() { diff --git a/app/ante/fees.go b/app/ante/fees.go index 3aab89db1b..d2b130343d 100644 --- a/app/ante/fees.go +++ b/app/ante/fees.go @@ -7,7 +7,7 @@ import ( sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ethtypes "github.com/ethereum/go-ethereum/core/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) // MinGasPriceDecorator will check if the transaction's fee is at least as large diff --git a/app/ante/fees_test.go b/app/ante/fees_test.go index 837f98e1e5..047328a024 100644 --- a/app/ante/fees_test.go +++ b/app/ante/fees_test.go @@ -6,9 +6,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/app/ante" - "github.com/tharsis/ethermint/tests" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/app/ante" + "github.com/evmos/ethermint/tests" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) var execTypes = []struct { diff --git a/app/ante/handler_options.go b/app/ante/handler_options.go index 7a24125d34..79271e3ddd 100644 --- a/app/ante/handler_options.go +++ b/app/ante/handler_options.go @@ -11,7 +11,7 @@ import ( ibcante "github.com/cosmos/ibc-go/v3/modules/core/ante" ibckeeper "github.com/cosmos/ibc-go/v3/modules/core/keeper" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) // HandlerOptions extend the SDK's AnteHandler options by requiring the IBC diff --git a/app/ante/interfaces.go b/app/ante/interfaces.go index 666e9cb0ce..216b0aa4f0 100644 --- a/app/ante/interfaces.go +++ b/app/ante/interfaces.go @@ -9,9 +9,9 @@ import ( "github.com/ethereum/go-ethereum/core" "github.com/ethereum/go-ethereum/core/vm" "github.com/ethereum/go-ethereum/params" - "github.com/tharsis/ethermint/x/evm/statedb" - evmtypes "github.com/tharsis/ethermint/x/evm/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/evm/statedb" + evmtypes "github.com/evmos/ethermint/x/evm/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" ) // EVMKeeper defines the expected keeper interface used on the Eth AnteHandler diff --git a/app/ante/reject_msgs.go b/app/ante/reject_msgs.go index fafb159ed3..ce752cc09b 100644 --- a/app/ante/reject_msgs.go +++ b/app/ante/reject_msgs.go @@ -3,7 +3,7 @@ package ante import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) // RejectMessagesDecorator prevents invalid msg types from being executed diff --git a/app/ante/sigs_test.go b/app/ante/sigs_test.go index f07d0986ba..0c7b0539c8 100644 --- a/app/ante/sigs_test.go +++ b/app/ante/sigs_test.go @@ -3,9 +3,9 @@ package ante_test import ( "math/big" - "github.com/tharsis/ethermint/tests" - "github.com/tharsis/ethermint/x/evm/statedb" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/tests" + "github.com/evmos/ethermint/x/evm/statedb" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) func (suite AnteTestSuite) TestSignatures() { diff --git a/app/ante/utils_test.go b/app/ante/utils_test.go index 5b8ccd4b86..04a76350a7 100644 --- a/app/ante/utils_test.go +++ b/app/ante/utils_test.go @@ -11,8 +11,8 @@ import ( types2 "github.com/cosmos/cosmos-sdk/x/bank/types" types3 "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/ethereum/go-ethereum/crypto" - "github.com/tharsis/ethermint/ethereum/eip712" - "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/ethereum/eip712" + "github.com/evmos/ethermint/types" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" @@ -31,13 +31,13 @@ import ( authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/tharsis/ethermint/app" - ante "github.com/tharsis/ethermint/app/ante" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/tests" - "github.com/tharsis/ethermint/x/evm/statedb" - evmtypes "github.com/tharsis/ethermint/x/evm/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/app" + ante "github.com/evmos/ethermint/app/ante" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/tests" + "github.com/evmos/ethermint/x/evm/statedb" + evmtypes "github.com/evmos/ethermint/x/evm/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" ) diff --git a/app/app.go b/app/app.go index c7c57393c0..c0acf7d426 100644 --- a/app/app.go +++ b/app/app.go @@ -94,18 +94,18 @@ import ( ibckeeper "github.com/cosmos/ibc-go/v3/modules/core/keeper" // unnamed import of statik for swagger UI support - _ "github.com/tharsis/ethermint/client/docs/statik" - - "github.com/tharsis/ethermint/app/ante" - srvflags "github.com/tharsis/ethermint/server/flags" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm" - evmrest "github.com/tharsis/ethermint/x/evm/client/rest" - evmkeeper "github.com/tharsis/ethermint/x/evm/keeper" - evmtypes "github.com/tharsis/ethermint/x/evm/types" - "github.com/tharsis/ethermint/x/feemarket" - feemarketkeeper "github.com/tharsis/ethermint/x/feemarket/keeper" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + _ "github.com/evmos/ethermint/client/docs/statik" + + "github.com/evmos/ethermint/app/ante" + srvflags "github.com/evmos/ethermint/server/flags" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm" + evmrest "github.com/evmos/ethermint/x/evm/client/rest" + evmkeeper "github.com/evmos/ethermint/x/evm/keeper" + evmtypes "github.com/evmos/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/feemarket" + feemarketkeeper "github.com/evmos/ethermint/x/feemarket/keeper" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" // Force-load the tracer engines to trigger registration due to Go-Ethereum v1.10.15 changes _ "github.com/ethereum/go-ethereum/eth/tracers/js" diff --git a/app/app_test.go b/app/app_test.go index 6ddf51284f..f23467671f 100644 --- a/app/app_test.go +++ b/app/app_test.go @@ -13,7 +13,7 @@ import ( "github.com/tendermint/tendermint/libs/log" dbm "github.com/tendermint/tm-db" - "github.com/tharsis/ethermint/encoding" + "github.com/evmos/ethermint/encoding" ) func TestEthermintAppExport(t *testing.T) { diff --git a/app/benchmark_test.go b/app/benchmark_test.go index a88712e7fb..f7fac75810 100644 --- a/app/benchmark_test.go +++ b/app/benchmark_test.go @@ -6,10 +6,10 @@ import ( "testing" "github.com/cosmos/cosmos-sdk/simapp" + "github.com/evmos/ethermint/encoding" abci "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/libs/log" dbm "github.com/tendermint/tm-db" - "github.com/tharsis/ethermint/encoding" ) func BenchmarkEthermintApp_ExportAppStateAndValidators(b *testing.B) { diff --git a/app/export.go b/app/export.go index f2cb346aba..a14d15c1c8 100644 --- a/app/export.go +++ b/app/export.go @@ -13,7 +13,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/staking" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/tharsis/ethermint/encoding" + "github.com/evmos/ethermint/encoding" ) // NewDefaultGenesisState generates the default state for the application. diff --git a/app/simulation_test.go b/app/simulation_test.go index 98ef022290..9d563e2cd4 100644 --- a/app/simulation_test.go +++ b/app/simulation_test.go @@ -28,11 +28,11 @@ import ( stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" ibctransfertypes "github.com/cosmos/ibc-go/v3/modules/apps/transfer/types" ibchost "github.com/cosmos/ibc-go/v3/modules/core/24-host" + evmenc "github.com/evmos/ethermint/encoding" abci "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/libs/log" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" dbm "github.com/tendermint/tm-db" - evmenc "github.com/tharsis/ethermint/encoding" ) // MakeEncodingConfig creates the EncodingConfig diff --git a/app/utils.go b/app/utils.go index 95fb576fc9..de4d402768 100644 --- a/app/utils.go +++ b/app/utils.go @@ -12,21 +12,21 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/tharsis/ethermint/encoding" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/encoding" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" sdk "github.com/cosmos/cosmos-sdk/types" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" + "github.com/evmos/ethermint/crypto/ethsecp256k1" abci "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/libs/log" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" tmtypes "github.com/tendermint/tendermint/types" dbm "github.com/tendermint/tm-db" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" ) // DefaultConsensusParams defines the default Tendermint consensus params used in diff --git a/app/utils_test.go b/app/utils_test.go index 6029e059af..cb40c78d92 100644 --- a/app/utils_test.go +++ b/app/utils_test.go @@ -14,10 +14,10 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - ethermint "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + ethermint "github.com/evmos/ethermint/types" "github.com/cosmos/cosmos-sdk/simapp" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/client/config.go b/client/config.go index 6edb08bff8..56e6e118b7 100644 --- a/client/config.go +++ b/client/config.go @@ -12,7 +12,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" - ethermint "github.com/tharsis/ethermint/types" + ethermint "github.com/evmos/ethermint/types" ) // InitConfig adds the chain-id, encoding and output flags to the persistent flag set. @@ -26,7 +26,7 @@ func InitConfig(cmd *cobra.Command) error { _, err = os.Stat(configFile) if err != nil && !os.IsNotExist(err) { // Immediately return if the error isn't related to the file not existing. - // See issue https://github.com/tharsis/ethermint/issues/539 + // See issue https://github.com/evmos/ethermint/issues/539 return err } if err == nil { diff --git a/client/docs/statik/init.go b/client/docs/statik/init.go index 49c0d09e9d..15c11ef622 100644 --- a/client/docs/statik/init.go +++ b/client/docs/statik/init.go @@ -1,3 +1,3 @@ package statik -// This just for fixing the error in importing empty github.com/tharsis/ethermint/client/docs/statik +// This just for fixing the error in importing empty github.com/evmos/ethermint/client/docs/statik diff --git a/client/export.go b/client/export.go index 64975fa78f..dd304dbb8c 100644 --- a/client/export.go +++ b/client/export.go @@ -14,8 +14,8 @@ import ( "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/crypto/keyring" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/crypto/hd" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/crypto/hd" ) // UnsafeExportEthKeyCommand exports a key with the given name as a private key in hex format. diff --git a/client/import.go b/client/import.go index baa761953e..5b6efa3431 100644 --- a/client/import.go +++ b/client/import.go @@ -11,9 +11,9 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/keyring" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/ethereum/go-ethereum/common" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/crypto/hd" + "github.com/evmos/ethermint/crypto/hd" ) // UnsafeImportKeyCommand imports private keys from a keyfile. diff --git a/client/keys.go b/client/keys.go index 06bc345c56..691c9a3de9 100644 --- a/client/keys.go +++ b/client/keys.go @@ -11,8 +11,8 @@ import ( "github.com/tendermint/tendermint/libs/cli" "github.com/cosmos/cosmos-sdk/crypto/keyring" - clientkeys "github.com/tharsis/ethermint/client/keys" - "github.com/tharsis/ethermint/crypto/hd" + clientkeys "github.com/evmos/ethermint/client/keys" + "github.com/evmos/ethermint/crypto/hd" ) // KeyCommands registers a sub-tree of commands to interact with diff --git a/client/keys/add.go b/client/keys/add.go index d765a22899..d9080b0484 100644 --- a/client/keys/add.go +++ b/client/keys/add.go @@ -7,7 +7,7 @@ import ( "fmt" "sort" - etherminthd "github.com/tharsis/ethermint/crypto/hd" + etherminthd "github.com/evmos/ethermint/crypto/hd" bip39 "github.com/cosmos/go-bip39" "github.com/spf13/cobra" diff --git a/client/testnet.go b/client/testnet.go index 3a518df986..6cc12b7ec7 100644 --- a/client/testnet.go +++ b/client/testnet.go @@ -37,13 +37,13 @@ import ( mintypes "github.com/cosmos/cosmos-sdk/x/mint/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/tharsis/ethermint/crypto/hd" - "github.com/tharsis/ethermint/server/config" - srvflags "github.com/tharsis/ethermint/server/flags" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/crypto/hd" + "github.com/evmos/ethermint/server/config" + srvflags "github.com/evmos/ethermint/server/flags" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" - "github.com/tharsis/ethermint/testutil/network" + "github.com/evmos/ethermint/testutil/network" ) var ( diff --git a/cmd/config/config.go b/cmd/config/config.go index c9220a3a07..8fcce595ac 100644 --- a/cmd/config/config.go +++ b/cmd/config/config.go @@ -3,7 +3,7 @@ package config import ( sdk "github.com/cosmos/cosmos-sdk/types" - ethermint "github.com/tharsis/ethermint/types" + ethermint "github.com/evmos/ethermint/types" ) const ( diff --git a/cmd/config/config_test.go b/cmd/config/config_test.go index 187031a2eb..7970828b5d 100644 --- a/cmd/config/config_test.go +++ b/cmd/config/config_test.go @@ -3,8 +3,8 @@ package config import ( "testing" + ethermint "github.com/evmos/ethermint/types" "github.com/stretchr/testify/require" - ethermint "github.com/tharsis/ethermint/types" "github.com/cosmos/cosmos-sdk/crypto/hd" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/cmd/ethermintd/cmd_test.go b/cmd/ethermintd/cmd_test.go index 3fe91e5adf..eb0482a21f 100644 --- a/cmd/ethermintd/cmd_test.go +++ b/cmd/ethermintd/cmd_test.go @@ -10,8 +10,8 @@ import ( svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" - "github.com/tharsis/ethermint/app" - ethermintd "github.com/tharsis/ethermint/cmd/ethermintd" + "github.com/evmos/ethermint/app" + ethermintd "github.com/evmos/ethermint/cmd/ethermintd" ) func TestInitCmd(t *testing.T) { diff --git a/cmd/ethermintd/flags.go b/cmd/ethermintd/flags.go index 098bc0639c..ed835f5905 100644 --- a/cmd/ethermintd/flags.go +++ b/cmd/ethermintd/flags.go @@ -5,7 +5,7 @@ import ( "github.com/spf13/cobra" - "github.com/tharsis/ethermint/version" + "github.com/evmos/ethermint/version" ) const ( diff --git a/cmd/ethermintd/genaccounts.go b/cmd/ethermintd/genaccounts.go index 1ceee6362b..0f4784dfad 100644 --- a/cmd/ethermintd/genaccounts.go +++ b/cmd/ethermintd/genaccounts.go @@ -20,9 +20,9 @@ import ( "github.com/cosmos/cosmos-sdk/x/genutil" genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" - "github.com/tharsis/ethermint/crypto/hd" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/crypto/hd" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) const ( diff --git a/cmd/ethermintd/main.go b/cmd/ethermintd/main.go index f67973af1b..a506678990 100644 --- a/cmd/ethermintd/main.go +++ b/cmd/ethermintd/main.go @@ -7,8 +7,8 @@ import ( svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/app" - cmdcfg "github.com/tharsis/ethermint/cmd/config" + "github.com/evmos/ethermint/app" + cmdcfg "github.com/evmos/ethermint/cmd/config" ) func main() { diff --git a/cmd/ethermintd/root.go b/cmd/ethermintd/root.go index 277bf1b5f3..0470d5d934 100644 --- a/cmd/ethermintd/root.go +++ b/cmd/ethermintd/root.go @@ -30,15 +30,15 @@ import ( "github.com/cosmos/cosmos-sdk/x/crisis" genutilcli "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" - "github.com/tharsis/ethermint/app" - ethermintclient "github.com/tharsis/ethermint/client" - "github.com/tharsis/ethermint/client/debug" - "github.com/tharsis/ethermint/crypto/hd" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/server" - servercfg "github.com/tharsis/ethermint/server/config" - srvflags "github.com/tharsis/ethermint/server/flags" - ethermint "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/app" + ethermintclient "github.com/evmos/ethermint/client" + "github.com/evmos/ethermint/client/debug" + "github.com/evmos/ethermint/crypto/hd" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/server" + servercfg "github.com/evmos/ethermint/server/config" + srvflags "github.com/evmos/ethermint/server/flags" + ethermint "github.com/evmos/ethermint/types" ) const EnvPrefix = "ETHERMINT" diff --git a/crypto/codec/amino.go b/crypto/codec/amino.go index 06a8339748..80edab9ad4 100644 --- a/crypto/codec/amino.go +++ b/crypto/codec/amino.go @@ -7,7 +7,7 @@ import ( cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keyring" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/crypto/ethsecp256k1" ) // RegisterCrypto registers all crypto dependency types with the provided Amino diff --git a/crypto/codec/codec.go b/crypto/codec/codec.go index 86451e20bf..0f77f59377 100644 --- a/crypto/codec/codec.go +++ b/crypto/codec/codec.go @@ -4,7 +4,7 @@ import ( codectypes "github.com/cosmos/cosmos-sdk/codec/types" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/crypto/ethsecp256k1" ) // RegisterInterfaces register the Ethermint key concrete types. diff --git a/crypto/hd/algorithm.go b/crypto/hd/algorithm.go index 53b92a0c6f..4453fb3260 100644 --- a/crypto/hd/algorithm.go +++ b/crypto/hd/algorithm.go @@ -12,7 +12,7 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/keyring" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/crypto/ethsecp256k1" ) const ( diff --git a/crypto/hd/algorithm_test.go b/crypto/hd/algorithm_test.go index 8d2eda772b..3dd7bb27eb 100644 --- a/crypto/hd/algorithm_test.go +++ b/crypto/hd/algorithm_test.go @@ -13,8 +13,8 @@ import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/crypto/keyring" - cryptocodec "github.com/tharsis/ethermint/crypto/codec" - ethermint "github.com/tharsis/ethermint/types" + cryptocodec "github.com/evmos/ethermint/crypto/codec" + ethermint "github.com/evmos/ethermint/types" ) func init() { diff --git a/crypto/hd/benchmark_test.go b/crypto/hd/benchmark_test.go index 0ad376cec0..1a2bf19d24 100644 --- a/crypto/hd/benchmark_test.go +++ b/crypto/hd/benchmark_test.go @@ -4,7 +4,7 @@ import ( "testing" "github.com/cosmos/cosmos-sdk/crypto/keyring" - ethermint "github.com/tharsis/ethermint/types" + ethermint "github.com/evmos/ethermint/types" ) func BenchmarkEthSecp256k1Algo_Derive(b *testing.B) { diff --git a/encoding/codec/codec.go b/encoding/codec/codec.go index 957d00a1e3..c9600cd4d7 100644 --- a/encoding/codec/codec.go +++ b/encoding/codec/codec.go @@ -6,8 +6,8 @@ import ( "github.com/cosmos/cosmos-sdk/std" sdk "github.com/cosmos/cosmos-sdk/types" - cryptocodec "github.com/tharsis/ethermint/crypto/codec" - ethermint "github.com/tharsis/ethermint/types" + cryptocodec "github.com/evmos/ethermint/crypto/codec" + ethermint "github.com/evmos/ethermint/types" ) // RegisterLegacyAminoCodec registers Interfaces from types, crypto, and SDK std. diff --git a/encoding/config.go b/encoding/config.go index 8e778954f7..83eb652930 100644 --- a/encoding/config.go +++ b/encoding/config.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" "github.com/cosmos/cosmos-sdk/x/auth/tx" - enccodec "github.com/tharsis/ethermint/encoding/codec" + enccodec "github.com/evmos/ethermint/encoding/codec" ) // MakeConfig creates an EncodingConfig for testing diff --git a/encoding/config_test.go b/encoding/config_test.go index bcd086ccc8..5a90f18438 100644 --- a/encoding/config_test.go +++ b/encoding/config_test.go @@ -8,10 +8,10 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/app" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/tests" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/app" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/tests" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) func TestTxEncoding(t *testing.T) { diff --git a/go.mod b/go.mod index 5d8af3479c..8e5c62593e 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/tharsis/ethermint +module github.com/evmos/ethermint go 1.17 @@ -8,7 +8,7 @@ require ( github.com/btcsuite/btcutil v1.0.3-0.20201208143702-a53e38424cce github.com/cosmos/cosmos-sdk v0.45.5-0.20220523154235-2921a1c3c918 github.com/cosmos/go-bip39 v1.0.0 - github.com/cosmos/ibc-go/v3 v3.0.0 + github.com/cosmos/ibc-go/v3 v3.1.0 github.com/davecgh/go-spew v1.1.1 github.com/ethereum/go-ethereum v1.10.19 github.com/gogo/protobuf v1.3.3 @@ -26,14 +26,14 @@ require ( github.com/rs/cors v1.8.2 github.com/rs/zerolog v1.26.0 // indirect github.com/spf13/cast v1.5.0 - github.com/spf13/cobra v1.4.0 + github.com/spf13/cobra v1.5.0 github.com/spf13/viper v1.12.0 github.com/status-im/keycard-go v0.0.0-20200402102358-957c09536969 - github.com/stretchr/testify v1.7.2 - github.com/tendermint/tendermint v0.34.19 + github.com/stretchr/testify v1.7.5 + github.com/tendermint/tendermint v0.34.20-0.20220517115723-e6f071164839 github.com/tendermint/tm-db v0.6.7 github.com/tyler-smith/go-bip39 v1.1.0 - golang.org/x/text v0.3.7 + golang.org/x/text v0.3.7 // indirect google.golang.org/genproto v0.0.0-20220628213854-d9e0b6570c03 google.golang.org/grpc v1.47.0 google.golang.org/protobuf v1.28.0 @@ -79,6 +79,7 @@ require ( github.com/dgraph-io/ristretto v0.1.0 // indirect github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91 // indirect + github.com/docker/go-units v0.4.0 // indirect github.com/dop251/goja v0.0.0-20220405120441-9037c2b61cbf // indirect github.com/dustin/go-humanize v1.0.0 // indirect github.com/dvsekhvalnov/jose2go v0.0.0-20200901110807-248326c1351b // indirect @@ -90,10 +91,10 @@ require ( github.com/fsnotify/fsnotify v1.5.4 // indirect github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff // indirect github.com/go-kit/kit v0.12.0 // indirect - github.com/go-kit/log v0.2.0 // indirect + github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.5.1 // indirect - github.com/go-ole/go-ole v1.2.1 // indirect - github.com/go-playground/validator/v10 v10.4.1 // indirect + github.com/go-ole/go-ole v1.2.5 // indirect + github.com/go-resty/resty/v2 v2.7.0 // indirect github.com/go-sourcemap/sourcemap v2.1.3+incompatible // indirect github.com/go-stack/stack v1.8.0 // indirect github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0 // indirect @@ -139,7 +140,7 @@ require ( github.com/klauspost/compress v1.15.1 // indirect github.com/klauspost/cpuid/v2 v2.0.12 // indirect github.com/koron/go-ssdp v0.0.2 // indirect - github.com/lib/pq v1.10.4 // indirect + github.com/lib/pq v1.10.6 // indirect github.com/libp2p/go-buffer-pool v0.0.2 // indirect github.com/libp2p/go-cidranger v1.1.0 // indirect github.com/libp2p/go-conn-security-multistream v0.3.0 // indirect @@ -242,16 +243,21 @@ require ( github.com/whyrusleeping/timecache v0.0.0-20160911033111-cfcb2f1abfee // indirect github.com/zondax/hid v0.9.0 // indirect go.etcd.io/bbolt v1.3.6 // indirect + go.opencensus.io v0.23.0 // indirect + go.uber.org/atomic v1.9.0 // indirect + go.uber.org/multierr v1.8.0 // indirect + go.uber.org/zap v1.21.0 // indirect golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d // indirect + golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3 // indirect golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2 // indirect - golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect + golang.org/x/sync v0.0.0-20220513210516-0976fa681c29 // indirect golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a // indirect golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 // indirect - golang.org/x/text v0.3.7 // indirect golang.org/x/tools v0.1.10 // indirect golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df // indirect gopkg.in/ini.v1 v1.66.4 // indirect gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect + gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect lukechampine.com/blake3 v1.1.7 // indirect nhooyr.io/websocket v1.8.6 // indirect diff --git a/go.sum b/go.sum index b886d935a1..d9ae4f9137 100644 --- a/go.sum +++ b/go.sum @@ -32,6 +32,7 @@ cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+Y cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4= cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc= cloud.google.com/go v0.99.0/go.mod h1:w0Xx2nLzqWJPuozYQX+hFfCSI8WioryfRDzkoI/Y2ZA= +cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w99A= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= @@ -39,6 +40,9 @@ cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUM cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= cloud.google.com/go/bigtable v1.2.0/go.mod h1:JcVAOl45lrTmQfLj7T6TxyMzIN/3FGGcFm+2xVAli2o= +cloud.google.com/go/compute v0.1.0/go.mod h1:GAesmwr110a34z04OlxYkATPBEfVhkymfTBXtfbBFow= +cloud.google.com/go/compute v1.3.0/go.mod h1:cCZiE1NHEtai4wiufUhW8I8S1JKkAnhnQJWM7YD99wM= +cloud.google.com/go/compute v1.5.0/go.mod h1:9SMHyhJlzhlkJqrPAc839t2BZFTSk6Jdj6mkzQJeu0M= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk= @@ -224,7 +228,6 @@ github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QH github.com/cenkalti/backoff/v4 v4.1.1 h1:G2HAfAmvm/GcKan2oOQpBXOd2tT2G57ZnZGWa1PxPBQ= github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/census-instrumentation/opencensus-proto v0.3.0/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/cespare/cp v0.1.0 h1:SE+dxFebS7Iik5LK0tsi1k9ZCxEaFX4AjQmoyA+1dJk= github.com/cespare/cp v0.1.0/go.mod h1:SOGHArjBr4JWaSDEVpWpo/hNg6RoKrls6Oh40hiwW+s= github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= @@ -248,10 +251,6 @@ github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4 github.com/cloudflare/cloudflare-go v0.10.2-0.20190916151808-a80f83b9add9/go.mod h1:1MxXX1Ux4x6mqPmjkUgTP1CdXIBXKX7T+Jk9Gxrmx+U= github.com/cloudflare/cloudflare-go v0.14.0/go.mod h1:EnwdgGMaFOruiPZRFSgn+TsQ3hQ7C/YWzIGLeu5c304= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= -github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= -github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cncf/xds/go v0.0.0-20211130200136-a8f946100490/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= github.com/coinbase/rosetta-sdk-go v0.7.0 h1:lmTO/JEpCvZgpbkOITL95rA80CPKb5CtMzLaqF2mCNg= @@ -294,8 +293,8 @@ github.com/cosmos/gorocksdb v1.2.0 h1:d0l3jJG8M4hBouIZq0mDUHZ+zjOx044J3nGRskwTb4 github.com/cosmos/gorocksdb v1.2.0/go.mod h1:aaKvKItm514hKfNJpUJXnnOWeBnk2GL4+Qw9NHizILw= github.com/cosmos/iavl v0.17.3 h1:s2N819a2olOmiauVa0WAhoIJq9EhSXE9HDBAoR9k+8Y= github.com/cosmos/iavl v0.17.3/go.mod h1:prJoErZFABYZGDHka1R6Oay4z9PrNeFFiMKHDAMOi4w= -github.com/cosmos/ibc-go/v3 v3.0.0 h1:XUNplHVS51Q2gMnTFsFsH9QJ7flsovMamnltKbEgPQ4= -github.com/cosmos/ibc-go/v3 v3.0.0/go.mod h1:Mb+1NXiPOLd+CPFlOC6BKeAUaxXlhuWenMmRiUiSmwY= +github.com/cosmos/ibc-go/v3 v3.1.0 h1:aVPqkrGBluz6t9+d/sLZIG/zQ9O1KJzVeR4UlL/IFTQ= +github.com/cosmos/ibc-go/v3 v3.1.0/go.mod h1:DbOlOa4yKumaHGKApKkJN90L88PCjSD9ZBdAfL9tT40= github.com/cosmos/keyring v1.1.7-0.20210622111912-ef00f8ac3d76 h1:DdzS1m6o/pCqeZ8VOAit/gyATedRgjvkVI+UCrLpyuU= github.com/cosmos/keyring v1.1.7-0.20210622111912-ef00f8ac3d76/go.mod h1:0mkLWIoZuQ7uBoospo5Q9zIpqq6rYCPJDSUdeCJvPM8= github.com/cosmos/ledger-cosmos-go v0.11.1 h1:9JIYsGnXP613pb2vPjFeMMjBI5lEDsEaF6oYorTy6J4= @@ -306,6 +305,7 @@ github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwc github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= @@ -378,9 +378,7 @@ github.com/elastic/gosigar v0.12.0/go.mod h1:iXRIGg2tLnu7LBdpqzyQfGDEidKCfWcCMS0 github.com/elastic/gosigar v0.14.2 h1:Dg80n8cr90OZ7x+bAax/QjoW/XqTI11RmA79ZwIm9/4= github.com/elastic/gosigar v0.14.2/go.mod h1:iXRIGg2tLnu7LBdpqzyQfGDEidKCfWcCMS0WKyPWoMs= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= -github.com/envoyproxy/go-control-plane v0.10.1/go.mod h1:AY7fTTXNdv/aJ2O5jwpxAPOWUZ7hQAEvzN5Pf27BkQQ= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/envoyproxy/protoc-gen-validate v0.6.2/go.mod h1:2t7qjJNvHPx8IjnBOzl9E9/baC+qXE/TeeyBRzgJDws= github.com/ethereum/go-ethereum v1.9.25/go.mod h1:vMkFiYLHI4tgPw4k2j4MHKoovchFE8plZ0M9VMk4/oM= github.com/ethereum/go-ethereum v1.10.4/go.mod h1:nEE0TP5MtxGzOMd7egIrbPJMQBnhVU3ELNxhBglIzhg= github.com/ethereum/go-ethereum v1.10.19 h1:EOR5JbL4MD5yeOqv8W2iC1s4NximrTjqFccUz8lyBRA= @@ -431,6 +429,8 @@ github.com/gin-gonic/gin v1.7.0 h1:jGB9xAJQ12AIGNB4HguylppmDK1Am9ppF7XnGXXJuoU= github.com/gliderlabs/ssh v0.1.1/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= github.com/glycerine/go-unsnap-stream v0.0.0-20180323001048-9f0cb55181dd/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE= github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24= +github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= +github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -440,8 +440,9 @@ github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgO 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/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= -github.com/go-kit/log v0.2.0 h1:7i2K3eKTos3Vc0enKCfnVcgHh2olr/MyfboYq7cAcFw= github.com/go-kit/log v0.2.0/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= +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= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= @@ -451,6 +452,8 @@ github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbV github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-ole/go-ole v1.2.1/go.mod h1:7FAglXiTm7HKlQRDeOQ6ZNUHidzCWXuZWq/1dTyBNF8= +github.com/go-ole/go-ole v1.2.5 h1:t4MGB5xEDZvXI+0rMjjsfBsD7yAgp/s9ZDkL1JndXwY= +github.com/go-ole/go-ole v1.2.5/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.13.0 h1:HyWk6mgj5qFqCT5fjGBuRArbVDfE4hi8+e8ceBS/t7Q= github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= @@ -599,6 +602,8 @@ github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+ github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0= github.com/googleapis/gax-go/v2 v2.1.1/go.mod h1:hddJymUZASv3XPyGkUpKj8pPO47Rmb0eJc8R6ouapiM= +github.com/googleapis/gax-go/v2 v2.2.0/go.mod h1:as02EH8zWkzwUoLbBaFeQ+arQaj/OthfcblKl4IGNaM= +github.com/googleapis/gax-go/v2 v2.3.0/go.mod h1:b8LNqSzNabLiUpXKkY7HAR5jr6bIT99EXz9pXxye9YM= github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gopherjs/gopherjs v0.0.0-20190812055157-5d271430af9f h1:KMlcu9X58lhTA/KrfX8Bi1LQSO4pzoVjTiL3h4Jk+Zk= @@ -621,6 +626,7 @@ github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/ad github.com/gotestyourself/gotestyourself v2.2.0+incompatible/go.mod h1:zZKM6oeNM8k+FRljX1mnzVYeS8wiGgQyvST1/GafPbY= github.com/graph-gophers/graphql-go v0.0.0-20191115155744-f33e81362277/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= github.com/graph-gophers/graphql-go v0.0.0-20201113091052-beb923fada29/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= +github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.2.2/go.mod h1:EaizFBKfUKtMIF5iaDEhniwNedqGo9FuLFzppDr3uwI= @@ -658,7 +664,7 @@ github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtng github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= github.com/hashicorp/go-hclog v0.12.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= github.com/hashicorp/go-hclog v0.16.2/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= -github.com/hashicorp/go-hclog v1.0.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= +github.com/hashicorp/go-hclog v1.2.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= @@ -694,6 +700,7 @@ github.com/hashicorp/memberlist v0.3.0/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOn github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc= github.com/hashicorp/serf v0.9.5/go.mod h1:UWDWwZeL5cuWDJdl0C6wrvrUwEqtQ4ZKBKKENpqIUyk= github.com/hashicorp/serf v0.9.6/go.mod h1:TXZNMjZQijwlDvp+r0b63xZ45H7JmCmgg4gpTwn9UV4= +github.com/hashicorp/serf v0.9.7/go.mod h1:TXZNMjZQijwlDvp+r0b63xZ45H7JmCmgg4gpTwn9UV4= github.com/hdevalence/ed25519consensus v0.0.0-20210204194344-59a8610d2b87 h1:uUjLpLt6bVvZ72SQc/B4dXcPBw4Vgd7soowdRl52qEM= github.com/hdevalence/ed25519consensus v0.0.0-20210204194344-59a8610d2b87/go.mod h1:XGsKKeXxeRr95aEOgipvluMPlgjr7dGlk9ZTWOjcUcg= github.com/holiman/bloomfilter/v2 v2.0.3 h1:73e0e/V0tCydx14a0SCYS/EWCxgwLZ18CZcZKVu0fao= @@ -706,10 +713,10 @@ github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmK github.com/hudl/fargo v1.4.0/go.mod h1:9Ai6uvFy5fQNq6VPKtg+Ceq1+eTY4nKUlR2JElEOcDo= github.com/huin/goupnp v1.0.0/go.mod h1:n9v9KO1tAxYH82qOn+UTIFQDmx5n1Zxd/ClZDMX7Bnc= github.com/huin/goupnp v1.0.1-0.20210310174557-0ca763054c88/go.mod h1:nNs7wvRfN1eKaMknBydLNQU6146XQim8t4h+q90biWo= +github.com/huin/goupnp v1.0.2/go.mod h1:0dxJBVBHqTMjIUMkESDTNgOOx/Mw5wYIfyFmdzSamkM= github.com/huin/goupnp v1.0.3 h1:N8No57ls+MnjlB+JPiCVSOyy/ot7MJTqlo7rn+NYSqQ= github.com/huin/goupnp v1.0.3/go.mod h1:ZxNlw5WqJj6wSsRK5+YfflQGXYfccj5VgQsMNixHM7Y= github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150/go.mod h1:PpLOETDnJ0o3iZrZfqZzyLl6l7F3c6L1oWn7OICBi6o= -github.com/iancoleman/strcase v0.2.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= @@ -859,8 +866,9 @@ github.com/leodido/go-urn v1.2.0 h1:hpXL4XnriNwQ/ABnpepYM/1vCLWNDfUNts8dX3xTG6Y= github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/lib/pq v1.10.4 h1:SO9z7FRPzA03QhHKJrH5BXA6HU1rS4V2nIVrrNC1iYk= github.com/lib/pq v1.10.4/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= +github.com/lib/pq v1.10.6 h1:jbk+ZieJ0D7EVGJYpL9QTz7/YW6UHbmdnZWYyK5cdBs= +github.com/lib/pq v1.10.6/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/libp2p/go-addr-util v0.1.0/go.mod h1:6I3ZYuFr2O/9D+SoyM0zEw0EF3YkldtTX406BpdQMqw= github.com/libp2p/go-buffer-pool v0.0.1/go.mod h1:xtyIz9PMobb13WaxR6Zo1Pd1zXJKYg0a8KiIvDp3TzQ= github.com/libp2p/go-buffer-pool v0.0.2 h1:QNK2iAFa8gjAe1SPz6mHSMuCcjs+X1wlHzeOSqcmlfs= @@ -1024,14 +1032,28 @@ github.com/lucas-clemente/quic-go v0.27.0 h1:v6WY87q9zD4dKASbG8hy/LpzAVNzEQzw8sE github.com/lucas-clemente/quic-go v0.27.0/go.mod h1:AzgQoPda7N+3IqMMMkywBKggIFo2KT6pfnlrQ2QieeI= github.com/lucasjones/reggen v0.0.0-20180717132126-cdb49ff09d77/go.mod h1:5ELEyG+X8f+meRWHuqUOewBOhvHkl7M76pdGEansxW4= github.com/lunixbochs/vtclean v1.0.0/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI= -github.com/lyft/protoc-gen-star v0.5.3/go.mod h1:V0xaHgaf5oCCqmcxYcWiDfTiKsZsRc87/1qhoTACD8w= github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= -github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= github.com/magiconair/properties v1.8.6 h1:5ibWZ6iY0NctNGWo87LalDlEZ6R41TqbbDamhfG/Qzo= github.com/magiconair/properties v1.8.6/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= +github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/marten-seemann/qpack v0.2.1/go.mod h1:F7Gl5L1jIgN1D11ucXefiuJS9UMVP2opoCp2jDKb7wc= +github.com/marten-seemann/qtls-go1-15 v0.1.4/go.mod h1:GyFwywLKkRt+6mfU99csTEY1joMZz5vmB1WNZH3P81I= +github.com/marten-seemann/qtls-go1-16 v0.1.4/go.mod h1:gNpI2Ol+lRS3WwSOtIUUtRwZEQMXjYK+dQSBFbethAk= +github.com/marten-seemann/qtls-go1-16 v0.1.5 h1:o9JrYPPco/Nukd/HpOHMHZoBDXQqoNtUCmny98/1uqQ= +github.com/marten-seemann/qtls-go1-16 v0.1.5/go.mod h1:gNpI2Ol+lRS3WwSOtIUUtRwZEQMXjYK+dQSBFbethAk= +github.com/marten-seemann/qtls-go1-17 v0.1.0/go.mod h1:fz4HIxByo+LlWcreM4CZOYNuz3taBQ8rN2X6FqvaWo8= +github.com/marten-seemann/qtls-go1-17 v0.1.1 h1:DQjHPq+aOzUeh9/lixAGunn6rIOQyWChPSI4+hgW7jc= +github.com/marten-seemann/qtls-go1-17 v0.1.1/go.mod h1:C2ekUKcDdz9SDWxec1N/MvcXBpaX9l3Nx67XaR84L5s= +github.com/marten-seemann/qtls-go1-18 v0.1.0-beta.1/go.mod h1:PUhIQk19LoFt2174H4+an8TYvWOGjb/hHwphBeaDHwI= +github.com/marten-seemann/qtls-go1-18 v0.1.1 h1:qp7p7XXUFL7fpBvSS1sWD+uSqPvzNQK43DH+/qEkj0Y= +github.com/marten-seemann/qtls-go1-18 v0.1.1/go.mod h1:mJttiymBAByA49mhlNZZGrH5u1uXYZJ+RW28Py7f4m4= +github.com/marten-seemann/tcp v0.0.0-20210406111302-dfbc87cc63fd h1:br0buuQ854V8u83wA0rVZ8ttrq5CpaPZdvrK0LP2lOk= +github.com/marten-seemann/tcp v0.0.0-20210406111302-dfbc87cc63fd/go.mod h1:QuCEs1Nt24+FYQEqAAncTDPJIuGs+LxK1MCiFL25pMU= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.0/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= +github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= 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= @@ -1273,6 +1295,7 @@ github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/9 github.com/pelletier/go-toml v1.9.4/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= 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.0-beta.8/go.mod h1:r9LEWfGN8R5k0VXJ+0BkIe7MYkRdwZOjgMj2KwnJFUo= github.com/pelletier/go-toml/v2 v2.0.1 h1:8e3L2cCQzLFi2CR4g7vGFuFxX7Jl1kKX8gW+iV0GUKU= github.com/pelletier/go-toml/v2 v2.0.1/go.mod h1:r9LEWfGN8R5k0VXJ+0BkIe7MYkRdwZOjgMj2KwnJFUo= github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= @@ -1291,7 +1314,6 @@ github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINE github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/profile v1.2.1/go.mod h1:hJw3o1OdXxsrSjjVksARp5W95eeEaEfptyVZyv6JUPA= -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/term v0.0.0-20180730021639-bffc007b7fd5/go.mod h1:eCbImbZ95eXtAUIbLAuAVnBnwf83mjf6QIVH8SHYwqQ= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= @@ -1388,7 +1410,7 @@ github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/sagikazarmark/crypt v0.4.0/go.mod h1:ALv2SRj7GxYV4HO9elxH9nS6M9gW+xDNxqmyJ6RfDFM= +github.com/sagikazarmark/crypt v0.5.0/go.mod h1:l+nzl7KWh51rpzp2h7t4MZWyiEWdhNpOAnclKvg+mdA= github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= github.com/sasha-s/go-deadlock v0.2.1-0.20190427202633-1595213edefa h1:0U2s5loxrTy6/VgfVoLuVLFJcURKLH49ie0zSch7gh4= github.com/sasha-s/go-deadlock v0.2.1-0.20190427202633-1595213edefa/go.mod h1:F73l+cr82YSh10GxyRI6qZiCgK64VaZjwesgfQ1/iLM= @@ -1448,8 +1470,6 @@ github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasO 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.3.3/go.mod h1:5KUK8ByomD5Ti5Artl0RtHeI5pTF7MIDuXL3yY520V4= -github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I= github.com/spf13/afero v1.8.2 h1:xehSyVa0YnHWsJ49JFljMpg1HX19V6NDZ1fkm1Xznbo= 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= @@ -1460,8 +1480,9 @@ github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3 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.1.1/go.mod h1:WnodtKOvamDL/PwE2M4iKs8aMDBZ5Q5klgD3qfVJQMI= -github.com/spf13/cobra v1.4.0 h1:y+wJpx64xcgO1V+RcnwW0LEHxTKRi2ZDPSBjWnrg88Q= github.com/spf13/cobra v1.4.0/go.mod h1:Wo4iy3BUC+X2Fybo0PDqwJIv3dNRiZLHQymsfxlB84g= +github.com/spf13/cobra v1.5.0 h1:X+jTBEBqF0bHN+9cSMgmfuvv2VHJ9ezmFNf9Y/XstYU= +github.com/spf13/cobra v1.5.0/go.mod h1:dWXEIy2H428czQCjInthrTRUg7yKbok+2Qi/yBIJoUM= 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= @@ -1473,7 +1494,7 @@ github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DM github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE= github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= -github.com/spf13/viper v1.10.1/go.mod h1:IGlFPqhNAPKRxohIzWpI5QEy4kuI7tcl5WvR+8qy1rU= +github.com/spf13/viper v1.11.0/go.mod h1:djo0X/bA5+tYVoCn+C7cAYJGcVn/qYLFTG8gdUsX7Zk= github.com/spf13/viper v1.12.0 h1:CZ7eSOd3kZoaYDLbXnmzgQI5RlciuXBMA+18HwHRfZQ= github.com/spf13/viper v1.12.0/go.mod h1:b6COn30jlNxbm/V2IqWiNWkJ+vZNiMNksliPCiuKtSI= github.com/src-d/envconfig v1.0.0/go.mod h1:Q9YQZ7BKITldTBnoxsE5gOeB5y66RyPXeue/R4aaNBc= @@ -1489,8 +1510,9 @@ github.com/streadway/handy v0.0.0-20190108123426-d5acb3125c2a/go.mod h1:qNTQ5P5J github.com/streadway/handy v0.0.0-20200128134331-0f66f006fb2e/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.2.0 h1:Hbg2NidpLE8veEBkEZTL3CvlkUIVzuU9jDplZO54c48= github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= +github.com/stretchr/objx v0.4.0 h1:M2gUjqZET1qApGOWNSnZ49BAIMX4F/1plDv3+l31EJ4= +github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/testify v1.2.0/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= @@ -1499,8 +1521,8 @@ github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5 github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.2 h1:4jaiDzPyXQvSd7D0EjG45355tLlV3VOECpq10pLC+8s= -github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= +github.com/stretchr/testify v1.7.5 h1:s5PTfem8p8EbKQOctVV53k6jCJt3UX4IEJzwh+C324Q= +github.com/stretchr/testify v1.7.5/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/subosito/gotenv v1.3.0 h1:mjC+YW8QpAdXibNi+vNWgzmgBH4+5l5dCXv8cNysBLI= github.com/subosito/gotenv v1.3.0/go.mod h1:YzJjq/33h7nrwdY+iHMhEOEEbW0ovIz0tB6t6PwAXzs= @@ -1519,8 +1541,8 @@ github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15/go.mod h1:z4YtwM github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tendermint/tendermint v0.34.14/go.mod h1:FrwVm3TvsVicI9Z7FlucHV6Znfd5KBc/Lpp69cCwtk0= -github.com/tendermint/tendermint v0.34.19 h1:y0P1qI5wSa9IRuhKnTDA6IUcOrLi1hXJuALR+R7HFEk= -github.com/tendermint/tendermint v0.34.19/go.mod h1:R5+wgIwSxMdKQcmOaeudL0Cjkr3HDkhpcdum6VeU3R4= +github.com/tendermint/tendermint v0.34.20-0.20220517115723-e6f071164839 h1:84fLknaRpFmZ33teqQSKq5tksqPDk90vhbz53Ngp4a8= +github.com/tendermint/tendermint v0.34.20-0.20220517115723-e6f071164839/go.mod h1:Rlthqx2Hq440neL9pfBGV1TJGqqTqT++bvkL1yvpytY= github.com/tendermint/tm-db v0.6.4/go.mod h1:dptYhIpJ2M5kUuenLr+Yyf3zQOv1SgBZcl8/BmWlMBw= github.com/tendermint/tm-db v0.6.6/go.mod h1:wP8d49A85B7/erz/r4YbKssKw6ylsO/hKtFk7E1aWZI= github.com/tendermint/tm-db v0.6.7 h1:fE00Cbl0jayAoqlExN6oyQJ7fR/ZtoVOmvPJ//+shu8= @@ -1556,6 +1578,8 @@ github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijb github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli v1.22.2/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli/v2 v2.3.0/go.mod h1:LJmUH05zAU44vOAcrfzZQKsZbVcdbOG8rtL3/XcUArI= +github.com/viant/assertly v0.4.8/go.mod h1:aGifi++jvCrUaklKEKT0BU95igDNaqkvz+49uaYMPRU= +github.com/viant/toolbox v0.24.0/go.mod h1:OxMCG57V0PXuIP2HNQrtJf2CjqdmbrOx5EkMILuUhzM= github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE= github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df/go.mod h1:JP3t17pCcGlemwknint6hfoeCVQrEMVwxRLRjXpq+BU= github.com/vmihailenco/msgpack/v5 v5.1.4/go.mod h1:C5gboKD0TJPqWDTVTtrQNfRbiBwHZGo8UTqP/9/XvLI= @@ -1594,11 +1618,11 @@ go.etcd.io/bbolt v1.3.6 h1:/ecaJf0sk1l4l6V4awd65v2C3ILy7MSj+s/x1ADCIMU= go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4= go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg= go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs= -go.etcd.io/etcd/api/v3 v3.5.1/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs= +go.etcd.io/etcd/api/v3 v3.5.2/go.mod h1:5GB2vv4A4AOn3yk7MftYGHkUfGtDHnEraIjym4dYz5A= go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g= -go.etcd.io/etcd/client/pkg/v3 v3.5.1/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g= +go.etcd.io/etcd/client/pkg/v3 v3.5.2/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g= go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ= -go.etcd.io/etcd/client/v2 v2.305.1/go.mod h1:pMEacxZW7o8pg4CrFE7pquyCJJzZvkvdD2RibOCCCGs= +go.etcd.io/etcd/client/v2 v2.305.2/go.mod h1:2D7ZejHVMIfog1221iLSYlQRzrtECw3kz4I4VAQm3qI= go.etcd.io/etcd/client/v3 v3.5.0/go.mod h1:AIKXXVX/DQXtfTEqBryiLTUXwON+GuvO6Z7lLS/oTh0= go.opencensus.io v0.18.0/go.mod h1:vKdFvxhtzZ9onBp9VKHK8z/sRpBMnKAsufL7wlDrCOA= go.opencensus.io v0.20.1/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= @@ -1614,7 +1638,6 @@ go.opencensus.io v0.23.0 h1:gqCw0LfLxScz8irSi8exQc7fyQ0fKQU/qnC/X8+V/1M= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opentelemetry.io/otel v1.7.0/go.mod h1:5BdUoMIz5WEs0vt0CUEMtSSaTSHBBVwrhnz7+nrD5xk= go.opentelemetry.io/otel/trace v1.7.0/go.mod h1:fzLSB9nqR2eXzxPXb2JW9IKE+ScyXA48yyE4TNvoHqU= -go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= @@ -1662,7 +1685,6 @@ golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190618222545-ea8f1a30c443/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190909091759-094676da4a83/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-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= @@ -1677,16 +1699,17 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201117144127-c1f2f97bffc9/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= +golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= golang.org/x/crypto v0.0.0-20210314154223-e6e6c4f2bb5b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= 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-20210506145944-38f3c27a63bf/go.mod h1:P+XmwS30IXTQdn5tA2iutPOUgjI07+tq3H3K9MVA1s8= golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210813211128-0a44fdfbc16e/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20210817164053-32db794688a5/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210915214749-c084706c2272/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220411220226-7b82a4e95df4/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.0.0-20220518034528-6f7dac969898/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d h1:sK3txAijHtOK88l68nt020reeT1ZdKLIYetKl95FzVY= golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -1731,7 +1754,6 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= 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.5.0/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3 h1:kQgndtyPBW/JIYERgdxfwMYh3AVStj88WQTlNDi2a+o= golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -1806,6 +1828,8 @@ golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qx golang.org/x/net v0.0.0-20211208012354-db4efeb81f4b/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220517181318-183a9ca12b87/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2 h1:NWy5+hlRbC7HK+PmcXVUmW1IMyFce7to56IUvhUFm7Y= golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= @@ -1829,6 +1853,8 @@ golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20211005180243-6b3c2da341f1/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= golang.org/x/perf v0.0.0-20180704124530-6e6d33e29852/go.mod h1:JLpeXjPJfIyPr5TlbXLkXWLhP8nz10XfvxElABhCtcw= 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= @@ -1840,8 +1866,9 @@ golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20210220032951-036812b2e83c h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220513210516-0976fa681c29 h1:w8s32wxx3sY+OjLlv9qltkLU5yvJzxjjgiHWLjdIcw4= +golang.org/x/sync v0.0.0-20220513210516-0976fa681c29/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20180810173357-98c5dad5d1a0/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1949,6 +1976,7 @@ golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210903071746-97244b99971b/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1960,6 +1988,10 @@ golang.org/x/sys v0.0.0-20211205182925-97ca703d548d/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220517195934-5e4e11fc645e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a h1:dGzPydgVsqGcTRVwiLJ1jVbufYwmzD3LfVPLKsKg+0k= @@ -2062,6 +2094,7 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20220411194840-2f41105eb62f/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df h1:5Pf6pFKu98ODmgnpvkJ3kFUOQGGLIzLIkbzUHp47618= golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= @@ -2107,6 +2140,10 @@ google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdr google.golang.org/api v0.59.0/go.mod h1:sT2boj7M9YJxZzgeZqXogmhfmRWDtPzT31xkieUbuZU= google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I= google.golang.org/api v0.63.0/go.mod h1:gs4ij2ffTRXwuzzgJl/56BdwJaA194ijkfn++9tDuPo= +google.golang.org/api v0.67.0/go.mod h1:ShHKP8E60yPsKNw/w8w+VYaj9H6buA5UqDp8dhbQZ6g= +google.golang.org/api v0.70.0/go.mod h1:Bs4ZM2HGifEvXwd50TtW70ovgJffJYw2oRCOFU/SkfA= +google.golang.org/api v0.71.0/go.mod h1:4PyU6e6JogV1f9eA4voyrTY2batOLdgZ5qZ5HOCc4j8= +google.golang.org/api v0.74.0/go.mod h1:ZpfMZOVRMywNyvJFeqL9HRWBgAuRfSjJFpe9QtRRyDs= google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.3.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -2233,7 +2270,6 @@ gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMy gopkg.in/gcfg.v1 v1.2.3/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/ini.v1 v1.66.2/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/ini.v1 v1.66.4 h1:SsAcf+mM7mRZo2nJNGt8mZCjG8ZRaNGMURJw7BsIST4= gopkg.in/ini.v1 v1.66.4/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce h1:+JknDZhAj8YMt7GC73Ei8pv4MzjDUNPHgQWJdtMAaDU= diff --git a/networks/local/ethermintnode/Dockerfile b/networks/local/ethermintnode/Dockerfile index 041890632b..3fbf0b3e5d 100644 --- a/networks/local/ethermintnode/Dockerfile +++ b/networks/local/ethermintnode/Dockerfile @@ -6,7 +6,7 @@ RUN apt-get update && apt-get upgrade -y && \ apt-get install -y $PACKAGES # Set working directory for the build -WORKDIR /go/src/github.com/tharsis/ethermint +WORKDIR /go/src/github.com/evmos/ethermint # Add source files COPY . . @@ -22,8 +22,8 @@ WORKDIR / RUN apt-get update # Copy over binaries from the build-env -COPY --from=build-env /go/src/github.com/tharsis/ethermint/build/ethermintd / -COPY --from=build-env /go/src/github.com/tharsis/ethermint/scripts/start-docker.sh / +COPY --from=build-env /go/src/github.com/evmos/ethermint/build/ethermintd / +COPY --from=build-env /go/src/github.com/evmos/ethermint/scripts/start-docker.sh / EXPOSE 26656 26657 1317 8545 8546 diff --git a/proto/ethermint/crypto/v1/ethsecp256k1/keys.proto b/proto/ethermint/crypto/v1/ethsecp256k1/keys.proto index 788382abf8..4bde4739bc 100644 --- a/proto/ethermint/crypto/v1/ethsecp256k1/keys.proto +++ b/proto/ethermint/crypto/v1/ethsecp256k1/keys.proto @@ -3,7 +3,7 @@ package ethermint.crypto.v1.ethsecp256k1; import "gogoproto/gogo.proto"; -option go_package = "github.com/tharsis/ethermint/crypto/ethsecp256k1"; +option go_package = "github.com/evmos/ethermint/crypto/ethsecp256k1"; // PubKey defines a type alias for an ecdsa.PublicKey that implements // Tendermint's PubKey interface. It represents the 33-byte compressed public diff --git a/proto/ethermint/evm/v1/evm.proto b/proto/ethermint/evm/v1/evm.proto index fe9c450e02..444b39e63f 100644 --- a/proto/ethermint/evm/v1/evm.proto +++ b/proto/ethermint/evm/v1/evm.proto @@ -3,7 +3,7 @@ package ethermint.evm.v1; import "gogoproto/gogo.proto"; -option go_package = "github.com/tharsis/ethermint/x/evm/types"; +option go_package = "github.com/evmos/ethermint/x/evm/types"; // Params defines the EVM module parameters message Params { diff --git a/proto/ethermint/evm/v1/genesis.proto b/proto/ethermint/evm/v1/genesis.proto index 65d27321d9..196bbd23a9 100644 --- a/proto/ethermint/evm/v1/genesis.proto +++ b/proto/ethermint/evm/v1/genesis.proto @@ -4,7 +4,7 @@ package ethermint.evm.v1; import "gogoproto/gogo.proto"; import "ethermint/evm/v1/evm.proto"; -option go_package = "github.com/tharsis/ethermint/x/evm/types"; +option go_package = "github.com/evmos/ethermint/x/evm/types"; // GenesisState defines the evm module's genesis state. message GenesisState { diff --git a/proto/ethermint/evm/v1/query.proto b/proto/ethermint/evm/v1/query.proto index 7a875e1639..537bc7cf63 100644 --- a/proto/ethermint/evm/v1/query.proto +++ b/proto/ethermint/evm/v1/query.proto @@ -8,7 +8,7 @@ import "ethermint/evm/v1/evm.proto"; import "ethermint/evm/v1/tx.proto"; import "google/protobuf/timestamp.proto"; -option go_package = "github.com/tharsis/ethermint/x/evm/types"; +option go_package = "github.com/evmos/ethermint/x/evm/types"; // Query defines the gRPC querier service. service Query { diff --git a/proto/ethermint/evm/v1/tx.proto b/proto/ethermint/evm/v1/tx.proto index 1a2396895c..c91878ff4a 100644 --- a/proto/ethermint/evm/v1/tx.proto +++ b/proto/ethermint/evm/v1/tx.proto @@ -7,7 +7,7 @@ import "google/protobuf/any.proto"; import "cosmos_proto/cosmos.proto"; import "ethermint/evm/v1/evm.proto"; -option go_package = "github.com/tharsis/ethermint/x/evm/types"; +option go_package = "github.com/evmos/ethermint/x/evm/types"; // Msg defines the evm Msg service. service Msg { diff --git a/proto/ethermint/feemarket/v1/feemarket.proto b/proto/ethermint/feemarket/v1/feemarket.proto index df6f3ed5b1..8508ec715f 100644 --- a/proto/ethermint/feemarket/v1/feemarket.proto +++ b/proto/ethermint/feemarket/v1/feemarket.proto @@ -3,7 +3,7 @@ package ethermint.feemarket.v1; import "gogoproto/gogo.proto"; -option go_package = "github.com/tharsis/ethermint/x/feemarket/types"; +option go_package = "github.com/evmos/ethermint/x/feemarket/types"; // Params defines the EVM module parameters message Params { diff --git a/proto/ethermint/feemarket/v1/genesis.proto b/proto/ethermint/feemarket/v1/genesis.proto index dd23631b9e..e3307844fb 100644 --- a/proto/ethermint/feemarket/v1/genesis.proto +++ b/proto/ethermint/feemarket/v1/genesis.proto @@ -4,7 +4,7 @@ package ethermint.feemarket.v1; import "gogoproto/gogo.proto"; import "ethermint/feemarket/v1/feemarket.proto"; -option go_package = "github.com/tharsis/ethermint/x/feemarket/types"; +option go_package = "github.com/evmos/ethermint/x/feemarket/types"; // GenesisState defines the feemarket module's genesis state. message GenesisState { diff --git a/proto/ethermint/feemarket/v1/query.proto b/proto/ethermint/feemarket/v1/query.proto index b960808d88..f8b672b026 100644 --- a/proto/ethermint/feemarket/v1/query.proto +++ b/proto/ethermint/feemarket/v1/query.proto @@ -6,7 +6,7 @@ import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; import "ethermint/feemarket/v1/feemarket.proto"; -option go_package = "github.com/tharsis/ethermint/x/feemarket/types"; +option go_package = "github.com/evmos/ethermint/x/feemarket/types"; // Query defines the gRPC querier service. service Query { diff --git a/proto/ethermint/types/v1/account.proto b/proto/ethermint/types/v1/account.proto index 6beffb273e..4a3a5d5d78 100644 --- a/proto/ethermint/types/v1/account.proto +++ b/proto/ethermint/types/v1/account.proto @@ -5,7 +5,7 @@ import "cosmos/auth/v1beta1/auth.proto"; import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; -option go_package = "github.com/tharsis/ethermint/types"; +option go_package = "github.com/evmos/ethermint/types"; // EthAccount implements the authtypes.AccountI interface and embeds an // authtypes.BaseAccount type. It is compatible with the auth AccountKeeper. diff --git a/proto/ethermint/types/v1/web3.proto b/proto/ethermint/types/v1/web3.proto index 7bcab06d6a..df6bf65b22 100644 --- a/proto/ethermint/types/v1/web3.proto +++ b/proto/ethermint/types/v1/web3.proto @@ -3,7 +3,7 @@ package ethermint.types.v1; import "gogoproto/gogo.proto"; -option go_package = "github.com/tharsis/ethermint/types"; +option go_package = "github.com/evmos/ethermint/types"; message ExtensionOptionsWeb3Tx { option (gogoproto.goproto_getters) = false; diff --git a/rpc/apis.go b/rpc/apis.go index 4eb0438e47..15e056cd7c 100644 --- a/rpc/apis.go +++ b/rpc/apis.go @@ -10,16 +10,16 @@ import ( "github.com/ethereum/go-ethereum/rpc" - "github.com/tharsis/ethermint/rpc/backend" - "github.com/tharsis/ethermint/rpc/namespaces/ethereum/debug" - "github.com/tharsis/ethermint/rpc/namespaces/ethereum/eth" - "github.com/tharsis/ethermint/rpc/namespaces/ethereum/eth/filters" - "github.com/tharsis/ethermint/rpc/namespaces/ethereum/miner" - "github.com/tharsis/ethermint/rpc/namespaces/ethereum/net" - "github.com/tharsis/ethermint/rpc/namespaces/ethereum/personal" - "github.com/tharsis/ethermint/rpc/namespaces/ethereum/txpool" - "github.com/tharsis/ethermint/rpc/namespaces/ethereum/web3" - "github.com/tharsis/ethermint/rpc/types" + "github.com/evmos/ethermint/rpc/backend" + "github.com/evmos/ethermint/rpc/namespaces/ethereum/debug" + "github.com/evmos/ethermint/rpc/namespaces/ethereum/eth" + "github.com/evmos/ethermint/rpc/namespaces/ethereum/eth/filters" + "github.com/evmos/ethermint/rpc/namespaces/ethereum/miner" + "github.com/evmos/ethermint/rpc/namespaces/ethereum/net" + "github.com/evmos/ethermint/rpc/namespaces/ethereum/personal" + "github.com/evmos/ethermint/rpc/namespaces/ethereum/txpool" + "github.com/evmos/ethermint/rpc/namespaces/ethereum/web3" + "github.com/evmos/ethermint/rpc/types" rpcclient "github.com/tendermint/tendermint/rpc/jsonrpc/client" ) diff --git a/rpc/backend/backend.go b/rpc/backend/backend.go index 98fc55d96c..4736568745 100644 --- a/rpc/backend/backend.go +++ b/rpc/backend/backend.go @@ -13,12 +13,12 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/params" "github.com/ethereum/go-ethereum/rpc" + "github.com/evmos/ethermint/rpc/types" + "github.com/evmos/ethermint/server/config" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" "github.com/tendermint/tendermint/libs/log" tmrpctypes "github.com/tendermint/tendermint/rpc/core/types" - "github.com/tharsis/ethermint/rpc/types" - "github.com/tharsis/ethermint/server/config" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" ) // BackendI implements the Cosmos and EVM backend. diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index d5d8a84a86..925774b3a6 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -26,10 +26,10 @@ import ( sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" grpctypes "github.com/cosmos/cosmos-sdk/types/grpc" - "github.com/tharsis/ethermint/rpc/types" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/rpc/types" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" ) var bAttributeKeyEthereumBloom = []byte(evmtypes.AttributeKeyEthereumBloom) diff --git a/rpc/backend/utils.go b/rpc/backend/utils.go index 019806f8af..5c4c9ec4a6 100644 --- a/rpc/backend/utils.go +++ b/rpc/backend/utils.go @@ -20,8 +20,8 @@ import ( "github.com/tendermint/tendermint/libs/log" tmrpctypes "github.com/tendermint/tendermint/rpc/core/types" - "github.com/tharsis/ethermint/rpc/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/rpc/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) // ExceedBlockGasLimitError defines the error message when tx execution exceeds the block gas limit. diff --git a/rpc/namespaces/ethereum/debug/api.go b/rpc/namespaces/ethereum/debug/api.go index 6cf5272b5d..f4b91d9d64 100644 --- a/rpc/namespaces/ethereum/debug/api.go +++ b/rpc/namespaces/ethereum/debug/api.go @@ -16,7 +16,7 @@ import ( "github.com/davecgh/go-spew/spew" tmrpctypes "github.com/tendermint/tendermint/rpc/core/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" "github.com/cosmos/cosmos-sdk/client" stderrors "github.com/pkg/errors" @@ -27,9 +27,9 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/consensus/ethash" "github.com/ethereum/go-ethereum/rlp" + "github.com/evmos/ethermint/rpc/backend" + rpctypes "github.com/evmos/ethermint/rpc/types" "github.com/tendermint/tendermint/libs/log" - "github.com/tharsis/ethermint/rpc/backend" - rpctypes "github.com/tharsis/ethermint/rpc/types" ) // HandlerT keeps track of the cpu profiler and trace execution diff --git a/rpc/namespaces/ethereum/eth/api.go b/rpc/namespaces/ethereum/eth/api.go index 07add625ac..ed11f08e37 100644 --- a/rpc/namespaces/ethereum/eth/api.go +++ b/rpc/namespaces/ethereum/eth/api.go @@ -7,7 +7,7 @@ import ( "math" "math/big" - "github.com/tharsis/ethermint/ethereum/eip712" + "github.com/evmos/ethermint/ethereum/eip712" "github.com/ethereum/go-ethereum/signer/core/apitypes" @@ -35,11 +35,11 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" - "github.com/tharsis/ethermint/crypto/hd" - "github.com/tharsis/ethermint/rpc/backend" - rpctypes "github.com/tharsis/ethermint/rpc/types" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/crypto/hd" + "github.com/evmos/ethermint/rpc/backend" + rpctypes "github.com/evmos/ethermint/rpc/types" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) // PublicAPI is the eth_ prefixed set of APIs in the Web3 JSON-RPC spec. @@ -625,7 +625,7 @@ func (e *PublicAPI) Resend(ctx context.Context, args evmtypes.TransactionArgs, g } for _, tx := range pending { - // FIXME does Resend api possible at all? https://github.com/tharsis/ethermint/issues/905 + // FIXME does Resend api possible at all? https://github.com/evmos/ethermint/issues/905 p, err := evmtypes.UnwrapEthereumMsg(tx, common.Hash{}) if err != nil { // not valid ethereum tx diff --git a/rpc/namespaces/ethereum/eth/filters/api.go b/rpc/namespaces/ethereum/eth/filters/api.go index 745876f58c..00a13e96c4 100644 --- a/rpc/namespaces/ethereum/eth/filters/api.go +++ b/rpc/namespaces/ethereum/eth/filters/api.go @@ -7,7 +7,7 @@ import ( "time" "github.com/cosmos/cosmos-sdk/client" - "github.com/tharsis/ethermint/rpc/types" + "github.com/evmos/ethermint/rpc/types" "github.com/tendermint/tendermint/libs/log" @@ -20,7 +20,7 @@ import ( "github.com/ethereum/go-ethereum/eth/filters" "github.com/ethereum/go-ethereum/rpc" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) // Backend defines the methods requided by the PublicFilterAPI backend diff --git a/rpc/namespaces/ethereum/eth/filters/filter_system.go b/rpc/namespaces/ethereum/eth/filters/filter_system.go index 02685ca80e..a990074e50 100644 --- a/rpc/namespaces/ethereum/eth/filters/filter_system.go +++ b/rpc/namespaces/ethereum/eth/filters/filter_system.go @@ -22,8 +22,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/rpc/ethereum/pubsub" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/rpc/ethereum/pubsub" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) var ( diff --git a/rpc/namespaces/ethereum/eth/filters/filters.go b/rpc/namespaces/ethereum/eth/filters/filters.go index 80e5d36dc2..531dff4d3b 100644 --- a/rpc/namespaces/ethereum/eth/filters/filters.go +++ b/rpc/namespaces/ethereum/eth/filters/filters.go @@ -5,7 +5,7 @@ import ( "encoding/binary" "math/big" - "github.com/tharsis/ethermint/rpc/types" + "github.com/evmos/ethermint/rpc/types" "github.com/pkg/errors" "github.com/tendermint/tendermint/libs/log" diff --git a/rpc/namespaces/ethereum/miner/api.go b/rpc/namespaces/ethereum/miner/api.go index ee3299b9a8..8c5f192292 100644 --- a/rpc/namespaces/ethereum/miner/api.go +++ b/rpc/namespaces/ethereum/miner/api.go @@ -21,9 +21,9 @@ import ( "github.com/tendermint/tendermint/libs/log" tmtypes "github.com/tendermint/tendermint/types" - "github.com/tharsis/ethermint/rpc/backend" - rpctypes "github.com/tharsis/ethermint/rpc/types" - "github.com/tharsis/ethermint/server/config" + "github.com/evmos/ethermint/rpc/backend" + rpctypes "github.com/evmos/ethermint/rpc/types" + "github.com/evmos/ethermint/server/config" ) // API is the private miner prefixed set of APIs in the Miner JSON-RPC spec. diff --git a/rpc/namespaces/ethereum/net/api.go b/rpc/namespaces/ethereum/net/api.go index a8e679ef3f..b183d8a89a 100644 --- a/rpc/namespaces/ethereum/net/api.go +++ b/rpc/namespaces/ethereum/net/api.go @@ -5,8 +5,8 @@ import ( "fmt" "github.com/cosmos/cosmos-sdk/client" + ethermint "github.com/evmos/ethermint/types" rpcclient "github.com/tendermint/tendermint/rpc/client" - ethermint "github.com/tharsis/ethermint/types" ) // PublicAPI is the eth_ prefixed set of APIs in the Web3 JSON-RPC spec. diff --git a/rpc/namespaces/ethereum/personal/api.go b/rpc/namespaces/ethereum/personal/api.go index 0f39bc152d..a10ac38149 100644 --- a/rpc/namespaces/ethereum/personal/api.go +++ b/rpc/namespaces/ethereum/personal/api.go @@ -6,12 +6,12 @@ import ( "os" "time" - "github.com/tharsis/ethermint/rpc/backend" + "github.com/evmos/ethermint/rpc/backend" "github.com/cosmos/cosmos-sdk/client" - "github.com/tharsis/ethermint/crypto/hd" - ethermint "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/crypto/hd" + ethermint "github.com/evmos/ethermint/types" "github.com/tendermint/tendermint/libs/log" @@ -24,8 +24,8 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/crypto" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) // PrivateAccountAPI is the personal_ prefixed set of APIs in the Web3 JSON-RPC spec. diff --git a/rpc/namespaces/ethereum/txpool/api.go b/rpc/namespaces/ethereum/txpool/api.go index 8d4725c89c..22771abfc6 100644 --- a/rpc/namespaces/ethereum/txpool/api.go +++ b/rpc/namespaces/ethereum/txpool/api.go @@ -5,11 +5,11 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" - "github.com/tharsis/ethermint/rpc/types" + "github.com/evmos/ethermint/rpc/types" ) // PublicAPI offers and API for the transaction pool. It only operates on data that is non-confidential. -// NOTE: For more info about the current status of this endpoints see https://github.com/tharsis/ethermint/issues/124 +// NOTE: For more info about the current status of this endpoints see https://github.com/evmos/ethermint/issues/124 type PublicAPI struct { logger log.Logger } diff --git a/rpc/namespaces/ethereum/web3/api.go b/rpc/namespaces/ethereum/web3/api.go index 04fbee76bc..7dd9988571 100644 --- a/rpc/namespaces/ethereum/web3/api.go +++ b/rpc/namespaces/ethereum/web3/api.go @@ -1,7 +1,7 @@ package web3 import ( - "github.com/tharsis/ethermint/version" + "github.com/evmos/ethermint/version" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/crypto" diff --git a/rpc/types/block.go b/rpc/types/block.go index 24d2876d67..4296ed6804 100644 --- a/rpc/types/block.go +++ b/rpc/types/block.go @@ -17,7 +17,7 @@ import ( grpctypes "github.com/cosmos/cosmos-sdk/types/grpc" - ethermint "github.com/tharsis/ethermint/types" + ethermint "github.com/evmos/ethermint/types" ) // BlockNumber represents decoding hex string to block values diff --git a/rpc/types/events.go b/rpc/types/events.go index 68324b1dad..db50301eac 100644 --- a/rpc/types/events.go +++ b/rpc/types/events.go @@ -6,8 +6,8 @@ import ( "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" abci "github.com/tendermint/tendermint/abci/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" ) // EventFormat is the format version of the events. diff --git a/rpc/types/events_test.go b/rpc/types/events_test.go index 55f8a361ff..922d3a4f3a 100644 --- a/rpc/types/events_test.go +++ b/rpc/types/events_test.go @@ -5,9 +5,9 @@ import ( "testing" "github.com/ethereum/go-ethereum/common" + evmtypes "github.com/evmos/ethermint/x/evm/types" "github.com/stretchr/testify/require" abci "github.com/tendermint/tendermint/abci/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" ) func TestParseTxResult(t *testing.T) { diff --git a/rpc/types/query_client.go b/rpc/types/query_client.go index b11ba3f7d7..6268e5f799 100644 --- a/rpc/types/query_client.go +++ b/rpc/types/query_client.go @@ -10,8 +10,8 @@ import ( "github.com/cosmos/cosmos-sdk/client" - evmtypes "github.com/tharsis/ethermint/x/evm/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" ) // QueryClient defines a gRPC Client used for: diff --git a/rpc/types/utils.go b/rpc/types/utils.go index e6eaa9154c..15da24489a 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -12,8 +12,8 @@ import ( "github.com/cosmos/cosmos-sdk/client" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - evmtypes "github.com/tharsis/ethermint/x/evm/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" diff --git a/rpc/websockets.go b/rpc/websockets.go index b3663c575a..89fb89230e 100644 --- a/rpc/websockets.go +++ b/rpc/websockets.go @@ -26,11 +26,11 @@ import ( rpcclient "github.com/tendermint/tendermint/rpc/jsonrpc/client" tmtypes "github.com/tendermint/tendermint/types" - "github.com/tharsis/ethermint/rpc/ethereum/pubsub" - rpcfilters "github.com/tharsis/ethermint/rpc/namespaces/ethereum/eth/filters" - "github.com/tharsis/ethermint/rpc/types" - "github.com/tharsis/ethermint/server/config" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/rpc/ethereum/pubsub" + rpcfilters "github.com/evmos/ethermint/rpc/namespaces/ethereum/eth/filters" + "github.com/evmos/ethermint/rpc/types" + "github.com/evmos/ethermint/server/config" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) type WebsocketsServer interface { diff --git a/scripts/protocgen.sh b/scripts/protocgen.sh index 9f62213397..cba0247da2 100755 --- a/scripts/protocgen.sh +++ b/scripts/protocgen.sh @@ -40,5 +40,5 @@ $(find "$(pwd)/proto" -maxdepth 5 -name '*.proto') # go mod tidy # move proto files to the right places -cp -r github.com/tharsis/ethermint/* ./ +cp -r github.com/evmos/ethermint/* ./ rm -rf github.com diff --git a/server/json_rpc.go b/server/json_rpc.go index 244ad4dc98..49779c9cdf 100644 --- a/server/json_rpc.go +++ b/server/json_rpc.go @@ -12,9 +12,9 @@ import ( "github.com/cosmos/cosmos-sdk/server/types" ethlog "github.com/ethereum/go-ethereum/log" ethrpc "github.com/ethereum/go-ethereum/rpc" - "github.com/tharsis/ethermint/rpc" + "github.com/evmos/ethermint/rpc" - "github.com/tharsis/ethermint/server/config" + "github.com/evmos/ethermint/server/config" ) // StartJSONRPC starts the JSON-RPC server diff --git a/server/start.go b/server/start.go index ac5ec9e941..7cf7b0c065 100644 --- a/server/start.go +++ b/server/start.go @@ -41,9 +41,9 @@ import ( storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - ethdebug "github.com/tharsis/ethermint/rpc/namespaces/ethereum/debug" - "github.com/tharsis/ethermint/server/config" - srvflags "github.com/tharsis/ethermint/server/flags" + ethdebug "github.com/evmos/ethermint/rpc/namespaces/ethereum/debug" + "github.com/evmos/ethermint/server/config" + srvflags "github.com/evmos/ethermint/server/flags" opticonf "github.com/celestiaorg/optimint/config" opticonv "github.com/celestiaorg/optimint/conv" diff --git a/tests/e2e/integration_test.go b/tests/e2e/integration_test.go index bd18051d5c..a92c2b436e 100644 --- a/tests/e2e/integration_test.go +++ b/tests/e2e/integration_test.go @@ -10,10 +10,10 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" codectypes "github.com/cosmos/cosmos-sdk/codec/types" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" - "github.com/tharsis/ethermint/rpc/types" + "github.com/evmos/ethermint/rpc/types" sdk "github.com/cosmos/cosmos-sdk/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" // . "github.com/onsi/ginkgo/v2" // . "github.com/onsi/gomega" @@ -28,9 +28,9 @@ import ( "github.com/ethereum/go-ethereum/ethclient/gethclient" "github.com/ethereum/go-ethereum/rpc" - "github.com/tharsis/ethermint/server/config" - "github.com/tharsis/ethermint/testutil/network" - ethermint "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/server/config" + "github.com/evmos/ethermint/testutil/network" + ethermint "github.com/evmos/ethermint/types" ) // var _ = Describe("E2e", func() { diff --git a/tests/importer/importer_test.go b/tests/importer/importer_test.go index e141f40a2a..4b6d5173e3 100644 --- a/tests/importer/importer_test.go +++ b/tests/importer/importer_test.go @@ -9,15 +9,15 @@ import ( "testing" "time" - "github.com/tharsis/ethermint/app" + "github.com/evmos/ethermint/app" "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" sdk "github.com/cosmos/cosmos-sdk/types" - evmkeeper "github.com/tharsis/ethermint/x/evm/keeper" - "github.com/tharsis/ethermint/x/evm/statedb" + evmkeeper "github.com/evmos/ethermint/x/evm/keeper" + "github.com/evmos/ethermint/x/evm/statedb" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/consensus/ethash" @@ -28,12 +28,12 @@ import ( ethparams "github.com/ethereum/go-ethereum/params" ethrlp "github.com/ethereum/go-ethereum/rlp" + "github.com/evmos/ethermint/crypto/ethsecp256k1" "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/crypto/tmhash" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" tmversion "github.com/tendermint/tendermint/proto/tendermint/version" "github.com/tendermint/tendermint/version" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" ) var ( diff --git a/tests/rpc/rpc_pending_test.go b/tests/rpc/rpc_pending_test.go index d3137fc603..abaaba4464 100644 --- a/tests/rpc/rpc_pending_test.go +++ b/tests/rpc/rpc_pending_test.go @@ -16,7 +16,7 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" "github.com/stretchr/testify/require" - rpctypes "github.com/tharsis/ethermint/rpc/types" + rpctypes "github.com/evmos/ethermint/rpc/types" ) // func TestMain(m *testing.M) { diff --git a/tests/rpc/rpc_test.go b/tests/rpc/rpc_test.go index 9043819c06..8c70b89933 100644 --- a/tests/rpc/rpc_test.go +++ b/tests/rpc/rpc_test.go @@ -17,9 +17,9 @@ import ( "github.com/stretchr/testify/require" - rpctypes "github.com/tharsis/ethermint/rpc/types" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + rpctypes "github.com/evmos/ethermint/rpc/types" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" diff --git a/tests/signer.go b/tests/signer.go index b90ecd6d7e..c675480f9c 100644 --- a/tests/signer.go +++ b/tests/signer.go @@ -10,7 +10,7 @@ import ( cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/crypto/ethsecp256k1" ) // NewAddrKey generates an Ethereum address and its corresponding private key. diff --git a/testutil/fund.go b/testutil/fund.go index bcf73684fc..99c601c31d 100644 --- a/testutil/fund.go +++ b/testutil/fund.go @@ -3,7 +3,7 @@ package testutil import ( sdk "github.com/cosmos/cosmos-sdk/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) // FundAccount is a utility function that funds an account by minting and diff --git a/testutil/network/network.go b/testutil/network/network.go index 468240bd5f..9866d58981 100644 --- a/testutil/network/network.go +++ b/testutil/network/network.go @@ -47,15 +47,15 @@ import ( "github.com/cosmos/cosmos-sdk/x/genutil" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/tharsis/ethermint/crypto/hd" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/server/config" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/crypto/hd" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/server/config" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" optinode "github.com/celestiaorg/optimint/node" - "github.com/tharsis/ethermint/app" + "github.com/evmos/ethermint/app" ) // package-wide network lock to only allow one test network at a time diff --git a/testutil/network/network_test.go b/testutil/network/network_test.go index 6f9b19a5a2..ab15dc410e 100644 --- a/testutil/network/network_test.go +++ b/testutil/network/network_test.go @@ -9,7 +9,7 @@ import ( "github.com/stretchr/testify/suite" - "github.com/tharsis/ethermint/testutil/network" + "github.com/evmos/ethermint/testutil/network" ) type IntegrationTestSuite struct { diff --git a/testutil/network/util.go b/testutil/network/util.go index 2c23811bbd..1390ef30c4 100644 --- a/testutil/network/util.go +++ b/testutil/network/util.go @@ -34,8 +34,8 @@ import ( mintypes "github.com/cosmos/cosmos-sdk/x/mint/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/tharsis/ethermint/server" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/server" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) func startInProcess(cfg Config, val *Validator) error { diff --git a/types/account_test.go b/types/account_test.go index 10b18a60a5..31f869daf9 100644 --- a/types/account_test.go +++ b/types/account_test.go @@ -12,10 +12,10 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - cryptocodec "github.com/tharsis/ethermint/crypto/codec" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - ethermintcodec "github.com/tharsis/ethermint/encoding/codec" - "github.com/tharsis/ethermint/types" + cryptocodec "github.com/evmos/ethermint/crypto/codec" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + ethermintcodec "github.com/evmos/ethermint/encoding/codec" + "github.com/evmos/ethermint/types" ) func init() { diff --git a/types/validation_test.go b/types/validation_test.go index ee60a19f45..d88cd7fc9e 100644 --- a/types/validation_test.go +++ b/types/validation_test.go @@ -4,8 +4,8 @@ import ( "testing" "github.com/ethereum/go-ethereum/common" + "github.com/evmos/ethermint/tests" "github.com/stretchr/testify/require" - "github.com/tharsis/ethermint/tests" ) func TestIsEmptyHash(t *testing.T) { diff --git a/x/evm/atlas/atlas-v0.3.1.md b/x/evm/atlas/atlas-v0.3.1.md index 9d76996273..d38bd46374 100644 --- a/x/evm/atlas/atlas-v0.3.1.md +++ b/x/evm/atlas/atlas-v0.3.1.md @@ -11,9 +11,9 @@ The `x/evm` module is responsible for executing Ethereum Virtual Machine (EVM) s "github.com/cosmos/cosmos-sdk/x/auth" "github.com/cosmos/cosmos-sdk/x/bank" - "github.com/tharsis/ethermint/app/ante" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm" + "github.com/evmos/ethermint/app/ante" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm" ) ``` diff --git a/x/evm/atlas/atlas.toml b/x/evm/atlas/atlas.toml index 51abaca417..224d07260d 100644 --- a/x/evm/atlas/atlas.toml +++ b/x/evm/atlas/atlas.toml @@ -1,6 +1,6 @@ [module] description = "The evm module executes Ethereum Virtual Machine (EVM) state transitions." -homepage = "https://github.com/tharsis/ethermint" +homepage = "https://github.com/evmos/ethermint" keywords = [ "evm", "ethereum", @@ -10,7 +10,7 @@ keywords = [ name = "x/evm" [bug_tracker] -url = "https://github.com/tharsis/ethermint/issues" +url = "https://github.com/evmos/ethermint/issues" [[authors]] name = "fedekunze" @@ -29,6 +29,6 @@ name = "araskachoi" [version] documentation = "https://raw.githubusercontent.com/tharsis/ethermint/main/x/evm/atlas/atlas-v0.3.1.md" -repo = "https://github.com/tharsis/ethermint/releases/tag/v0.3.1" +repo = "https://github.com/evmos/ethermint/releases/tag/v0.3.1" sdk_compat = "v0.39.x" version = "v0.3.1" \ No newline at end of file diff --git a/x/evm/client/cli/query.go b/x/evm/client/cli/query.go index edb802b370..252705f6f5 100644 --- a/x/evm/client/cli/query.go +++ b/x/evm/client/cli/query.go @@ -1,13 +1,13 @@ package cli import ( + rpctypes "github.com/evmos/ethermint/rpc/types" "github.com/spf13/cobra" - rpctypes "github.com/tharsis/ethermint/rpc/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) // GetQueryCmd returns the parent command for all x/bank CLi query commands. diff --git a/x/evm/client/cli/tx.go b/x/evm/client/cli/tx.go index 0fc0d17882..13e9051b91 100644 --- a/x/evm/client/cli/tx.go +++ b/x/evm/client/cli/tx.go @@ -12,8 +12,8 @@ import ( "github.com/pkg/errors" "github.com/spf13/cobra" - rpctypes "github.com/tharsis/ethermint/rpc/types" - "github.com/tharsis/ethermint/x/evm/types" + rpctypes "github.com/evmos/ethermint/rpc/types" + "github.com/evmos/ethermint/x/evm/types" ) // GetTxCmd returns the transaction commands for this module diff --git a/x/evm/client/rest/rest.go b/x/evm/client/rest/rest.go index e296cc85e4..f7de95ee4e 100644 --- a/x/evm/client/rest/rest.go +++ b/x/evm/client/rest/rest.go @@ -16,8 +16,8 @@ import ( "github.com/cosmos/cosmos-sdk/types/rest" authrest "github.com/cosmos/cosmos-sdk/x/auth/client/rest" - rpctypes "github.com/tharsis/ethermint/rpc/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + rpctypes "github.com/evmos/ethermint/rpc/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" "github.com/ethereum/go-ethereum/common" ) diff --git a/x/evm/genesis.go b/x/evm/genesis.go index 00c45d463a..a4440c6141 100644 --- a/x/evm/genesis.go +++ b/x/evm/genesis.go @@ -10,9 +10,9 @@ import ( "github.com/ethereum/go-ethereum/crypto" abci "github.com/tendermint/tendermint/abci/types" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm/keeper" - "github.com/tharsis/ethermint/x/evm/types" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm/keeper" + "github.com/evmos/ethermint/x/evm/types" ) // InitGenesis initializes genesis state based on exported genesis diff --git a/x/evm/genesis_test.go b/x/evm/genesis_test.go index 9a35390bc8..4be1c74ced 100644 --- a/x/evm/genesis_test.go +++ b/x/evm/genesis_test.go @@ -6,10 +6,10 @@ import ( "github.com/ethereum/go-ethereum/common" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/x/evm" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/x/evm" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" ) func (suite *EvmTestSuite) TestInitGenesis() { diff --git a/x/evm/handler.go b/x/evm/handler.go index 150a403102..609a93c8e6 100644 --- a/x/evm/handler.go +++ b/x/evm/handler.go @@ -4,7 +4,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) // NewHandler returns a handler for Ethermint type messages. diff --git a/x/evm/handler_test.go b/x/evm/handler_test.go index c78a2420d2..909058fe79 100644 --- a/x/evm/handler_test.go +++ b/x/evm/handler_test.go @@ -14,7 +14,7 @@ import ( "github.com/cosmos/cosmos-sdk/simapp" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/ethereum/go-ethereum/common" @@ -29,13 +29,13 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/keyring" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/app" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/tests" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/app" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/tests" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" "github.com/tendermint/tendermint/crypto/tmhash" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" diff --git a/x/evm/keeper/benchmark_test.go b/x/evm/keeper/benchmark_test.go index c4461f86ba..231c7a9cfa 100644 --- a/x/evm/keeper/benchmark_test.go +++ b/x/evm/keeper/benchmark_test.go @@ -11,8 +11,8 @@ import ( "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm/types" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm/types" ) func SetupContract(b *testing.B) (*KeeperTestSuite, common.Address) { diff --git a/x/evm/keeper/grpc_query.go b/x/evm/keeper/grpc_query.go index 1303f18025..76b79301a2 100644 --- a/x/evm/keeper/grpc_query.go +++ b/x/evm/keeper/grpc_query.go @@ -24,9 +24,9 @@ import ( "github.com/ethereum/go-ethereum/core/vm" ethparams "github.com/ethereum/go-ethereum/params" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" ) var _ types.QueryServer = Keeper{} diff --git a/x/evm/keeper/grpc_query_test.go b/x/evm/keeper/grpc_query_test.go index 19e317a859..46e4207915 100644 --- a/x/evm/keeper/grpc_query_test.go +++ b/x/evm/keeper/grpc_query_test.go @@ -10,14 +10,14 @@ import ( "github.com/ethereum/go-ethereum/core/vm" "github.com/ethereum/go-ethereum/crypto" ethparams "github.com/ethereum/go-ethereum/params" - "github.com/tharsis/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/statedb" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/server/config" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/server/config" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm/types" ) // Not valid Ethereum address diff --git a/x/evm/keeper/hooks.go b/x/evm/keeper/hooks.go index 6499655574..fc1c740516 100644 --- a/x/evm/keeper/hooks.go +++ b/x/evm/keeper/hooks.go @@ -5,7 +5,7 @@ import ( sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/ethereum/go-ethereum/core" ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) var _ types.EvmHooks = MultiEvmHooks{} diff --git a/x/evm/keeper/hooks_test.go b/x/evm/keeper/hooks_test.go index b471f13a2e..b635cf4cd4 100644 --- a/x/evm/keeper/hooks_test.go +++ b/x/evm/keeper/hooks_test.go @@ -9,9 +9,9 @@ import ( "github.com/ethereum/go-ethereum/core" ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/x/evm/keeper" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/keeper" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" ) // LogRecordHook records all the logs diff --git a/x/evm/keeper/keeper.go b/x/evm/keeper/keeper.go index 740bee10f7..f3044aa319 100644 --- a/x/evm/keeper/keeper.go +++ b/x/evm/keeper/keeper.go @@ -15,9 +15,9 @@ import ( "github.com/ethereum/go-ethereum/params" "github.com/tendermint/tendermint/libs/log" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" ) // Keeper grants access to the EVM module state and implements the go-ethereum StateDB interface. diff --git a/x/evm/keeper/keeper_test.go b/x/evm/keeper/keeper_test.go index 5340b71dc8..9236def842 100644 --- a/x/evm/keeper/keeper_test.go +++ b/x/evm/keeper/keeper_test.go @@ -20,17 +20,17 @@ import ( 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" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" tmjson "github.com/tendermint/tendermint/libs/json" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" - - "github.com/tharsis/ethermint/app" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/server/config" - "github.com/tharsis/ethermint/tests" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + + "github.com/evmos/ethermint/app" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/server/config" + "github.com/evmos/ethermint/tests" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" diff --git a/x/evm/keeper/migrations.go b/x/evm/keeper/migrations.go index acc0cf6629..3be1ada66f 100644 --- a/x/evm/keeper/migrations.go +++ b/x/evm/keeper/migrations.go @@ -1,11 +1,5 @@ package keeper -import ( - sdk "github.com/cosmos/cosmos-sdk/types" - v2 "github.com/evmos/ethermint/x/evm/migrations/v2" - v3 "github.com/evmos/ethermint/x/evm/migrations/v3" -) - // Migrator is a struct for handling in-place store migrations. type Migrator struct { keeper Keeper @@ -17,13 +11,3 @@ func NewMigrator(keeper Keeper) Migrator { keeper: keeper, } } - -// Migrate1to2 migrates the store from consensus version v1 to v2 -func (m Migrator) Migrate1to2(ctx sdk.Context) error { - return v2.MigrateStore(ctx, &m.keeper.paramSpace) -} - -// Migrate2to3 migrates the store from consensus version v2 to v3 -func (m Migrator) Migrate2to3(ctx sdk.Context) error { - return v3.MigrateStore(ctx, &m.keeper.paramSpace) -} diff --git a/x/evm/keeper/msg_server.go b/x/evm/keeper/msg_server.go index cc893666b3..8329f040cb 100644 --- a/x/evm/keeper/msg_server.go +++ b/x/evm/keeper/msg_server.go @@ -14,7 +14,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) var _ types.MsgServer = &Keeper{} diff --git a/x/evm/keeper/params.go b/x/evm/keeper/params.go index dbf0a0fcc8..f9de24bfaf 100644 --- a/x/evm/keeper/params.go +++ b/x/evm/keeper/params.go @@ -3,7 +3,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) // GetParams returns the total set of evm parameters. diff --git a/x/evm/keeper/params_test.go b/x/evm/keeper/params_test.go index 9cc6577fe2..59598bd6ac 100644 --- a/x/evm/keeper/params_test.go +++ b/x/evm/keeper/params_test.go @@ -1,7 +1,7 @@ package keeper_test import ( - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) func (suite *KeeperTestSuite) TestParams() { diff --git a/x/evm/keeper/state_transition.go b/x/evm/keeper/state_transition.go index 431b634ceb..2303c6d583 100644 --- a/x/evm/keeper/state_transition.go +++ b/x/evm/keeper/state_transition.go @@ -11,9 +11,9 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core" @@ -420,7 +420,7 @@ func (k *Keeper) ApplyMessageWithConfig(ctx sdk.Context, msg core.Message, trace // calculate a minimum amount of gas to be charged to sender if GasLimit // is considerably higher than GasUsed to stay more aligned with Tendermint gas mechanics - // for more info https://github.com/tharsis/ethermint/issues/1085 + // for more info https://github.com/evmos/ethermint/issues/1085 gasLimit := sdk.NewDec(int64(msg.Gas())) minGasMultiplier := k.GetMinGasMultiplier(ctx) minimumGasUsed := gasLimit.Mul(minGasMultiplier) diff --git a/x/evm/keeper/state_transition_benchmark_test.go b/x/evm/keeper/state_transition_benchmark_test.go index 9b4f912d6d..a1987a547b 100644 --- a/x/evm/keeper/state_transition_benchmark_test.go +++ b/x/evm/keeper/state_transition_benchmark_test.go @@ -11,8 +11,8 @@ import ( "github.com/ethereum/go-ethereum/core" ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/params" + evmtypes "github.com/evmos/ethermint/x/evm/types" "github.com/stretchr/testify/require" - evmtypes "github.com/tharsis/ethermint/x/evm/types" ) var templateAccessListTx = ðtypes.AccessListTx{ diff --git a/x/evm/keeper/state_transition_test.go b/x/evm/keeper/state_transition_test.go index 37314ccbb5..08237f25d2 100644 --- a/x/evm/keeper/state_transition_test.go +++ b/x/evm/keeper/state_transition_test.go @@ -11,12 +11,12 @@ import ( "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/params" + "github.com/evmos/ethermint/tests" + "github.com/evmos/ethermint/x/evm/keeper" + "github.com/evmos/ethermint/x/evm/types" "github.com/tendermint/tendermint/crypto/tmhash" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" tmtypes "github.com/tendermint/tendermint/types" - "github.com/tharsis/ethermint/tests" - "github.com/tharsis/ethermint/x/evm/keeper" - "github.com/tharsis/ethermint/x/evm/types" ) func (suite *KeeperTestSuite) TestGetHashFn() { diff --git a/x/evm/keeper/statedb.go b/x/evm/keeper/statedb.go index 1dbd6f9b72..a70d1427d6 100644 --- a/x/evm/keeper/statedb.go +++ b/x/evm/keeper/statedb.go @@ -9,9 +9,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/ethereum/go-ethereum/common" - ethermint "github.com/tharsis/ethermint/types" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + ethermint "github.com/evmos/ethermint/types" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" ) var _ statedb.Keeper = &Keeper{} diff --git a/x/evm/keeper/statedb_benchmark_test.go b/x/evm/keeper/statedb_benchmark_test.go index 834a816155..ade6e83efc 100644 --- a/x/evm/keeper/statedb_benchmark_test.go +++ b/x/evm/keeper/statedb_benchmark_test.go @@ -10,7 +10,7 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" - "github.com/tharsis/ethermint/tests" + "github.com/evmos/ethermint/tests" ) func BenchmarkCreateAccountNew(b *testing.B) { diff --git a/x/evm/keeper/statedb_test.go b/x/evm/keeper/statedb_test.go index 65a985bd6f..52b29e20a5 100644 --- a/x/evm/keeper/statedb_test.go +++ b/x/evm/keeper/statedb_test.go @@ -15,9 +15,9 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/core/vm" "github.com/ethereum/go-ethereum/crypto" - "github.com/tharsis/ethermint/tests" - "github.com/tharsis/ethermint/x/evm/statedb" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/tests" + "github.com/evmos/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/types" ) func (suite *KeeperTestSuite) TestCreateAccount() { diff --git a/x/evm/keeper/utils.go b/x/evm/keeper/utils.go index fd37cec1bf..894d76b6a6 100644 --- a/x/evm/keeper/utils.go +++ b/x/evm/keeper/utils.go @@ -7,7 +7,7 @@ import ( sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" authante "github.com/cosmos/cosmos-sdk/x/auth/ante" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" "github.com/ethereum/go-ethereum/core" ethtypes "github.com/ethereum/go-ethereum/core/types" diff --git a/x/evm/keeper/utils_test.go b/x/evm/keeper/utils_test.go index e892102033..7684b7a2f0 100644 --- a/x/evm/keeper/utils_test.go +++ b/x/evm/keeper/utils_test.go @@ -7,8 +7,8 @@ import ( "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" ethparams "github.com/ethereum/go-ethereum/params" - evmkeeper "github.com/tharsis/ethermint/x/evm/keeper" - evmtypes "github.com/tharsis/ethermint/x/evm/types" + evmkeeper "github.com/evmos/ethermint/x/evm/keeper" + evmtypes "github.com/evmos/ethermint/x/evm/types" ) func (suite *KeeperTestSuite) TestCheckSenderBalance() { diff --git a/x/evm/migrations/v3/migrate.go b/x/evm/migrations/v3/migrate.go deleted file mode 100644 index 22ce74e86b..0000000000 --- a/x/evm/migrations/v3/migrate.go +++ /dev/null @@ -1,25 +0,0 @@ -package v3 - -import ( - sdk "github.com/cosmos/cosmos-sdk/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/evmos/ethermint/x/evm/types" -) - -// MigrateStore sets the default for GrayGlacierBlock and MergeNetsplitBlock in ChainConfig parameter. -func MigrateStore(ctx sdk.Context, paramstore *paramtypes.Subspace) error { - if !paramstore.HasKeyTable() { - ps := paramstore.WithKeyTable(types.ParamKeyTable()) - paramstore = &ps - } - prevConfig := &types.ChainConfig{} - paramstore.GetIfExists(ctx, types.ParamStoreKeyChainConfig, prevConfig) - - defaultConfig := types.DefaultChainConfig() - - prevConfig.GrayGlacierBlock = defaultConfig.GrayGlacierBlock - prevConfig.MergeNetsplitBlock = defaultConfig.MergeNetsplitBlock - - paramstore.Set(ctx, types.ParamStoreKeyChainConfig, prevConfig) - return nil -} diff --git a/x/evm/migrations/v3/migrate_test.go b/x/evm/migrations/v3/migrate_test.go deleted file mode 100644 index 3d77ea0dca..0000000000 --- a/x/evm/migrations/v3/migrate_test.go +++ /dev/null @@ -1,57 +0,0 @@ -package v3_test - -import ( - "fmt" - v3 "github.com/evmos/ethermint/x/evm/migrations/v3" - "testing" - - "github.com/stretchr/testify/require" - - "github.com/cosmos/cosmos-sdk/testutil" - sdk "github.com/cosmos/cosmos-sdk/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - - "github.com/evmos/ethermint/encoding" - - "github.com/evmos/ethermint/app" - v3types "github.com/evmos/ethermint/x/evm/migrations/v3/types" - "github.com/evmos/ethermint/x/evm/types" -) - -func TestMigrateStore(t *testing.T) { - encCfg := encoding.MakeConfig(app.ModuleBasics) - evmKey := sdk.NewKVStoreKey(types.StoreKey) - tEvmKey := sdk.NewTransientStoreKey(fmt.Sprintf("%s_test", types.StoreKey)) - ctx := testutil.DefaultContext(evmKey, tEvmKey) - paramstore := paramtypes.NewSubspace( - encCfg.Marshaler, encCfg.Amino, evmKey, tEvmKey, "evm", - ).WithKeyTable(v3types.ParamKeyTable()) - - params := v3types.DefaultParams() - paramstore.SetParamSet(ctx, ¶ms) - - require.Panics(t, func() { - var preMigrationConfig types.ChainConfig - paramstore.Get(ctx, types.ParamStoreKeyChainConfig, &preMigrationConfig) - }) - var preMigrationConfig v3types.ChainConfig - paramstore.Get(ctx, types.ParamStoreKeyChainConfig, &preMigrationConfig) - require.NotNil(t, preMigrationConfig.MergeForkBlock) - - paramstore = paramtypes.NewSubspace( - encCfg.Marshaler, encCfg.Amino, evmKey, tEvmKey, "evm", - ).WithKeyTable(types.ParamKeyTable()) - err := v3.MigrateStore(ctx, ¶mstore) - require.NoError(t, err) - - updatedDefaultConfig := types.DefaultChainConfig() - - var postMigrationConfig types.ChainConfig - paramstore.Get(ctx, types.ParamStoreKeyChainConfig, &postMigrationConfig) - require.Equal(t, postMigrationConfig.GrayGlacierBlock, updatedDefaultConfig.GrayGlacierBlock) - require.Equal(t, postMigrationConfig.MergeNetsplitBlock, updatedDefaultConfig.MergeNetsplitBlock) - require.Panics(t, func() { - var preMigrationConfig v3types.ChainConfig - paramstore.Get(ctx, types.ParamStoreKeyChainConfig, &preMigrationConfig) - }) -} diff --git a/x/evm/migrations/v3/types/chain_config.go b/x/evm/migrations/v3/types/chain_config.go deleted file mode 100644 index d939cd6b6d..0000000000 --- a/x/evm/migrations/v3/types/chain_config.go +++ /dev/null @@ -1,164 +0,0 @@ -package types - -import ( - "math/big" - "strings" - - "github.com/evmos/ethermint/x/evm/types" - - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/params" -) - -// 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, - HomesteadBlock: getBlockValue(cc.HomesteadBlock), - DAOForkBlock: getBlockValue(cc.DAOForkBlock), - DAOForkSupport: cc.DAOForkSupport, - EIP150Block: getBlockValue(cc.EIP150Block), - EIP150Hash: common.HexToHash(cc.EIP150Hash), - EIP155Block: getBlockValue(cc.EIP155Block), - EIP158Block: getBlockValue(cc.EIP158Block), - ByzantiumBlock: getBlockValue(cc.ByzantiumBlock), - ConstantinopleBlock: getBlockValue(cc.ConstantinopleBlock), - PetersburgBlock: getBlockValue(cc.PetersburgBlock), - IstanbulBlock: getBlockValue(cc.IstanbulBlock), - MuirGlacierBlock: getBlockValue(cc.MuirGlacierBlock), - BerlinBlock: getBlockValue(cc.BerlinBlock), - LondonBlock: getBlockValue(cc.LondonBlock), - ArrowGlacierBlock: getBlockValue(cc.ArrowGlacierBlock), - TerminalTotalDifficulty: nil, - Ethash: nil, - Clique: nil, - } -} - -// DefaultChainConfig returns default evm parameters. -func DefaultChainConfig() ChainConfig { - homesteadBlock := sdk.ZeroInt() - daoForkBlock := sdk.ZeroInt() - eip150Block := sdk.ZeroInt() - eip155Block := sdk.ZeroInt() - eip158Block := sdk.ZeroInt() - byzantiumBlock := sdk.ZeroInt() - constantinopleBlock := sdk.ZeroInt() - petersburgBlock := sdk.ZeroInt() - istanbulBlock := sdk.ZeroInt() - muirGlacierBlock := sdk.ZeroInt() - berlinBlock := sdk.ZeroInt() - londonBlock := sdk.ZeroInt() - arrowGlacierBlock := sdk.ZeroInt() - mergeForkBlock := sdk.ZeroInt() - - return ChainConfig{ - HomesteadBlock: &homesteadBlock, - DAOForkBlock: &daoForkBlock, - DAOForkSupport: true, - EIP150Block: &eip150Block, - EIP150Hash: common.Hash{}.String(), - EIP155Block: &eip155Block, - EIP158Block: &eip158Block, - ByzantiumBlock: &byzantiumBlock, - ConstantinopleBlock: &constantinopleBlock, - PetersburgBlock: &petersburgBlock, - IstanbulBlock: &istanbulBlock, - MuirGlacierBlock: &muirGlacierBlock, - BerlinBlock: &berlinBlock, - LondonBlock: &londonBlock, - ArrowGlacierBlock: &arrowGlacierBlock, - MergeForkBlock: &mergeForkBlock, - } -} - -func getBlockValue(block *sdk.Int) *big.Int { - if block == nil || block.IsNegative() { - return nil - } - - return block.BigInt() -} - -// Validate performs a basic validation of the ChainConfig params. The function will return an error -// if any of the block values is uninitialized (i.e nil) or if the EIP150Hash is an invalid hash. -func (cc ChainConfig) Validate() error { - if err := validateBlock(cc.HomesteadBlock); err != nil { - return sdkerrors.Wrap(err, "homesteadBlock") - } - if err := validateBlock(cc.DAOForkBlock); err != nil { - return sdkerrors.Wrap(err, "daoForkBlock") - } - if err := validateBlock(cc.EIP150Block); err != nil { - return sdkerrors.Wrap(err, "eip150Block") - } - if err := validateHash(cc.EIP150Hash); err != nil { - return err - } - if err := validateBlock(cc.EIP155Block); err != nil { - return sdkerrors.Wrap(err, "eip155Block") - } - if err := validateBlock(cc.EIP158Block); err != nil { - return sdkerrors.Wrap(err, "eip158Block") - } - if err := validateBlock(cc.ByzantiumBlock); err != nil { - return sdkerrors.Wrap(err, "byzantiumBlock") - } - if err := validateBlock(cc.ConstantinopleBlock); err != nil { - return sdkerrors.Wrap(err, "constantinopleBlock") - } - if err := validateBlock(cc.PetersburgBlock); err != nil { - return sdkerrors.Wrap(err, "petersburgBlock") - } - if err := validateBlock(cc.IstanbulBlock); err != nil { - return sdkerrors.Wrap(err, "istanbulBlock") - } - if err := validateBlock(cc.MuirGlacierBlock); err != nil { - return sdkerrors.Wrap(err, "muirGlacierBlock") - } - if err := validateBlock(cc.BerlinBlock); err != nil { - return sdkerrors.Wrap(err, "berlinBlock") - } - if err := validateBlock(cc.LondonBlock); err != nil { - return sdkerrors.Wrap(err, "londonBlock") - } - if err := validateBlock(cc.ArrowGlacierBlock); err != nil { - return sdkerrors.Wrap(err, "arrowGlacierBlock") - } - if err := validateBlock(cc.MergeForkBlock); err != nil { - return sdkerrors.Wrap(err, "mergeForkBlock") - } - - // NOTE: chain ID is not needed to check config order - if err := cc.EthereumConfig(nil).CheckConfigForkOrder(); err != nil { - return sdkerrors.Wrap(err, "invalid config fork order") - } - return nil -} - -func validateHash(hex string) error { - if hex != "" && strings.TrimSpace(hex) == "" { - return sdkerrors.Wrap(types.ErrInvalidChainConfig, "hash cannot be blank") - } - - return nil -} - -func validateBlock(block *sdk.Int) error { - // nil value means that the fork has not yet been applied - if block == nil { - return nil - } - - if block.IsNegative() { - return sdkerrors.Wrapf( - types.ErrInvalidChainConfig, "block value cannot be negative: %s", block, - ) - } - - return nil -} diff --git a/x/evm/migrations/v3/types/evm.pb.go b/x/evm/migrations/v3/types/evm.pb.go deleted file mode 100644 index 7d20b3ec5b..0000000000 --- a/x/evm/migrations/v3/types/evm.pb.go +++ /dev/null @@ -1,3812 +0,0 @@ -// Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: ethermint/evm/v1/evm.proto - -package types - -import ( - fmt "fmt" - github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" - io "io" - math "math" - math_bits "math/bits" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package - -// Params defines the EVM module parameters -type Params struct { - // evm denom represents the token denomination used to run the EVM state - // transitions. - EvmDenom string `protobuf:"bytes,1,opt,name=evm_denom,json=evmDenom,proto3" json:"evm_denom,omitempty" yaml:"evm_denom"` - // enable create toggles state transitions that use the vm.Create function - EnableCreate bool `protobuf:"varint,2,opt,name=enable_create,json=enableCreate,proto3" json:"enable_create,omitempty" yaml:"enable_create"` - // enable call toggles state transitions that use the vm.Call function - EnableCall bool `protobuf:"varint,3,opt,name=enable_call,json=enableCall,proto3" json:"enable_call,omitempty" yaml:"enable_call"` - // extra eips defines the additional EIPs for the vm.Config - ExtraEIPs []int64 `protobuf:"varint,4,rep,packed,name=extra_eips,json=extraEips,proto3" json:"extra_eips,omitempty" yaml:"extra_eips"` - // chain config defines the EVM chain configuration parameters - ChainConfig ChainConfig `protobuf:"bytes,5,opt,name=chain_config,json=chainConfig,proto3" json:"chain_config" yaml:"chain_config"` - // Allow unprotected transactions defines if replay-protected (i.e non EIP155 - // signed) transactions can be executed on the state machine. - AllowUnprotectedTxs bool `protobuf:"varint,6,opt,name=allow_unprotected_txs,json=allowUnprotectedTxs,proto3" json:"allow_unprotected_txs,omitempty"` -} - -func (m *Params) Reset() { *m = Params{} } -func (m *Params) String() string { return proto.CompactTextString(m) } -func (*Params) ProtoMessage() {} -func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_d21ecc92c8c8583e, []int{0} -} -func (m *Params) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_Params.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 *Params) XXX_Merge(src proto.Message) { - xxx_messageInfo_Params.Merge(m, src) -} -func (m *Params) XXX_Size() int { - return m.Size() -} -func (m *Params) XXX_DiscardUnknown() { - xxx_messageInfo_Params.DiscardUnknown(m) -} - -var xxx_messageInfo_Params proto.InternalMessageInfo - -func (m *Params) GetEvmDenom() string { - if m != nil { - return m.EvmDenom - } - return "" -} - -func (m *Params) GetEnableCreate() bool { - if m != nil { - return m.EnableCreate - } - return false -} - -func (m *Params) GetEnableCall() bool { - if m != nil { - return m.EnableCall - } - return false -} - -func (m *Params) GetExtraEIPs() []int64 { - if m != nil { - return m.ExtraEIPs - } - return nil -} - -func (m *Params) GetChainConfig() ChainConfig { - if m != nil { - return m.ChainConfig - } - return ChainConfig{} -} - -func (m *Params) GetAllowUnprotectedTxs() bool { - if m != nil { - return m.AllowUnprotectedTxs - } - return false -} - -// ChainConfig defines the Ethereum ChainConfig parameters using *sdk.Int values -// instead of *big.Int. -type ChainConfig struct { - // Homestead switch block (nil no fork, 0 = already homestead) - HomesteadBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,1,opt,name=homestead_block,json=homesteadBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"homestead_block,omitempty" yaml:"homestead_block"` - // TheDAO hard-fork switch block (nil no fork) - DAOForkBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,2,opt,name=dao_fork_block,json=daoForkBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"dao_fork_block,omitempty" yaml:"dao_fork_block"` - // Whether the nodes supports or opposes the DAO hard-fork - DAOForkSupport bool `protobuf:"varint,3,opt,name=dao_fork_support,json=daoForkSupport,proto3" json:"dao_fork_support,omitempty" yaml:"dao_fork_support"` - // EIP150 implements the Gas price changes - // (https://github.com/ethereum/EIPs/issues/150) EIP150 HF block (nil no fork) - EIP150Block *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,4,opt,name=eip150_block,json=eip150Block,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"eip150_block,omitempty" yaml:"eip150_block"` - // EIP150 HF hash (needed for header only clients as only gas pricing changed) - EIP150Hash string `protobuf:"bytes,5,opt,name=eip150_hash,json=eip150Hash,proto3" json:"eip150_hash,omitempty" yaml:"byzantium_block"` - // EIP155Block HF block - EIP155Block *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,6,opt,name=eip155_block,json=eip155Block,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"eip155_block,omitempty" yaml:"eip155_block"` - // EIP158 HF block - EIP158Block *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,7,opt,name=eip158_block,json=eip158Block,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"eip158_block,omitempty" yaml:"eip158_block"` - // Byzantium switch block (nil no fork, 0 = already on byzantium) - ByzantiumBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,8,opt,name=byzantium_block,json=byzantiumBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"byzantium_block,omitempty" yaml:"byzantium_block"` - // Constantinople switch block (nil no fork, 0 = already activated) - ConstantinopleBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,9,opt,name=constantinople_block,json=constantinopleBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"constantinople_block,omitempty" yaml:"constantinople_block"` - // Petersburg switch block (nil same as Constantinople) - PetersburgBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,10,opt,name=petersburg_block,json=petersburgBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"petersburg_block,omitempty" yaml:"petersburg_block"` - // Istanbul switch block (nil no fork, 0 = already on istanbul) - IstanbulBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,11,opt,name=istanbul_block,json=istanbulBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"istanbul_block,omitempty" yaml:"istanbul_block"` - // Eip-2384 (bomb delay) switch block (nil no fork, 0 = already activated) - MuirGlacierBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,12,opt,name=muir_glacier_block,json=muirGlacierBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"muir_glacier_block,omitempty" yaml:"muir_glacier_block"` - // Berlin switch block (nil = no fork, 0 = already on berlin) - BerlinBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,13,opt,name=berlin_block,json=berlinBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"berlin_block,omitempty" yaml:"berlin_block"` - // London switch block (nil = no fork, 0 = already on london) - LondonBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,17,opt,name=london_block,json=londonBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"london_block,omitempty" yaml:"london_block"` - // Eip-4345 (bomb delay) switch block (nil = no fork, 0 = already activated) - ArrowGlacierBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,18,opt,name=arrow_glacier_block,json=arrowGlacierBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"arrow_glacier_block,omitempty" yaml:"arrow_glacier_block"` - // EIP-3675 (TheMerge) switch block (nil = no fork, 0 = already in merge proceedings) - MergeForkBlock *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,19,opt,name=merge_fork_block,json=mergeForkBlock,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"merge_fork_block,omitempty" yaml:"merge_fork_block"` -} - -func (m *ChainConfig) Reset() { *m = ChainConfig{} } -func (m *ChainConfig) String() string { return proto.CompactTextString(m) } -func (*ChainConfig) ProtoMessage() {} -func (*ChainConfig) Descriptor() ([]byte, []int) { - return fileDescriptor_d21ecc92c8c8583e, []int{1} -} -func (m *ChainConfig) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ChainConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_ChainConfig.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 *ChainConfig) XXX_Merge(src proto.Message) { - xxx_messageInfo_ChainConfig.Merge(m, src) -} -func (m *ChainConfig) XXX_Size() int { - return m.Size() -} -func (m *ChainConfig) XXX_DiscardUnknown() { - xxx_messageInfo_ChainConfig.DiscardUnknown(m) -} - -var xxx_messageInfo_ChainConfig proto.InternalMessageInfo - -func (m *ChainConfig) GetDAOForkSupport() bool { - if m != nil { - return m.DAOForkSupport - } - return false -} - -func (m *ChainConfig) GetEIP150Hash() string { - if m != nil { - return m.EIP150Hash - } - return "" -} - -// State represents a single Storage key value pair item. -type State struct { - Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` - Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` -} - -func (m *State) Reset() { *m = State{} } -func (m *State) String() string { return proto.CompactTextString(m) } -func (*State) ProtoMessage() {} -func (*State) Descriptor() ([]byte, []int) { - return fileDescriptor_d21ecc92c8c8583e, []int{2} -} -func (m *State) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *State) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_State.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 *State) XXX_Merge(src proto.Message) { - xxx_messageInfo_State.Merge(m, src) -} -func (m *State) XXX_Size() int { - return m.Size() -} -func (m *State) XXX_DiscardUnknown() { - xxx_messageInfo_State.DiscardUnknown(m) -} - -var xxx_messageInfo_State proto.InternalMessageInfo - -func (m *State) GetKey() string { - if m != nil { - return m.Key - } - return "" -} - -func (m *State) GetValue() string { - if m != nil { - return m.Value - } - return "" -} - -// TransactionLogs define the logs generated from a transaction execution -// with a given hash. It it used for import/export data as transactions are not -// persisted on blockchain state after an upgrade. -type TransactionLogs struct { - Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"` - Logs []*Log `protobuf:"bytes,2,rep,name=logs,proto3" json:"logs,omitempty"` -} - -func (m *TransactionLogs) Reset() { *m = TransactionLogs{} } -func (m *TransactionLogs) String() string { return proto.CompactTextString(m) } -func (*TransactionLogs) ProtoMessage() {} -func (*TransactionLogs) Descriptor() ([]byte, []int) { - return fileDescriptor_d21ecc92c8c8583e, []int{3} -} -func (m *TransactionLogs) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TransactionLogs) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_TransactionLogs.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 *TransactionLogs) XXX_Merge(src proto.Message) { - xxx_messageInfo_TransactionLogs.Merge(m, src) -} -func (m *TransactionLogs) XXX_Size() int { - return m.Size() -} -func (m *TransactionLogs) XXX_DiscardUnknown() { - xxx_messageInfo_TransactionLogs.DiscardUnknown(m) -} - -var xxx_messageInfo_TransactionLogs proto.InternalMessageInfo - -func (m *TransactionLogs) GetHash() string { - if m != nil { - return m.Hash - } - return "" -} - -func (m *TransactionLogs) GetLogs() []*Log { - if m != nil { - return m.Logs - } - return nil -} - -// Log represents an protobuf compatible Ethereum Log that defines a contract -// log event. These events are generated by the LOG opcode and stored/indexed by -// the node. -type Log struct { - // address of the contract that generated the event - Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` - // list of topics provided by the contract. - Topics []string `protobuf:"bytes,2,rep,name=topics,proto3" json:"topics,omitempty"` - // supplied by the contract, usually ABI-encoded - Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` - // block in which the transaction was included - BlockNumber uint64 `protobuf:"varint,4,opt,name=block_number,json=blockNumber,proto3" json:"blockNumber"` - // hash of the transaction - TxHash string `protobuf:"bytes,5,opt,name=tx_hash,json=txHash,proto3" json:"transactionHash"` - // index of the transaction in the block - TxIndex uint64 `protobuf:"varint,6,opt,name=tx_index,json=txIndex,proto3" json:"transactionIndex"` - // hash of the block in which the transaction was included - BlockHash string `protobuf:"bytes,7,opt,name=block_hash,json=blockHash,proto3" json:"blockHash"` - // index of the log in the block - Index uint64 `protobuf:"varint,8,opt,name=index,proto3" json:"logIndex"` - // The Removed field is true if this log was reverted due to a chain - // reorganisation. You must pay attention to this field if you receive logs - // through a filter query. - Removed bool `protobuf:"varint,9,opt,name=removed,proto3" json:"removed,omitempty"` -} - -func (m *Log) Reset() { *m = Log{} } -func (m *Log) String() string { return proto.CompactTextString(m) } -func (*Log) ProtoMessage() {} -func (*Log) Descriptor() ([]byte, []int) { - return fileDescriptor_d21ecc92c8c8583e, []int{4} -} -func (m *Log) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Log) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_Log.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 *Log) XXX_Merge(src proto.Message) { - xxx_messageInfo_Log.Merge(m, src) -} -func (m *Log) XXX_Size() int { - return m.Size() -} -func (m *Log) XXX_DiscardUnknown() { - xxx_messageInfo_Log.DiscardUnknown(m) -} - -var xxx_messageInfo_Log proto.InternalMessageInfo - -func (m *Log) GetAddress() string { - if m != nil { - return m.Address - } - return "" -} - -func (m *Log) GetTopics() []string { - if m != nil { - return m.Topics - } - return nil -} - -func (m *Log) GetData() []byte { - if m != nil { - return m.Data - } - return nil -} - -func (m *Log) GetBlockNumber() uint64 { - if m != nil { - return m.BlockNumber - } - return 0 -} - -func (m *Log) GetTxHash() string { - if m != nil { - return m.TxHash - } - return "" -} - -func (m *Log) GetTxIndex() uint64 { - if m != nil { - return m.TxIndex - } - return 0 -} - -func (m *Log) GetBlockHash() string { - if m != nil { - return m.BlockHash - } - return "" -} - -func (m *Log) GetIndex() uint64 { - if m != nil { - return m.Index - } - return 0 -} - -func (m *Log) GetRemoved() bool { - if m != nil { - return m.Removed - } - return false -} - -// TxResult stores results of Tx execution. -type TxResult struct { - // contract_address contains the ethereum address of the created contract (if - // any). If the state transition is an evm.Call, the contract address will be - // empty. - ContractAddress string `protobuf:"bytes,1,opt,name=contract_address,json=contractAddress,proto3" json:"contract_address,omitempty" yaml:"contract_address"` - // bloom represents the bloom filter bytes - Bloom []byte `protobuf:"bytes,2,opt,name=bloom,proto3" json:"bloom,omitempty"` - // tx_logs contains the transaction hash and the proto-compatible ethereum - // logs. - TxLogs TransactionLogs `protobuf:"bytes,3,opt,name=tx_logs,json=txLogs,proto3" json:"tx_logs" yaml:"tx_logs"` - // ret defines the bytes from the execution. - Ret []byte `protobuf:"bytes,4,opt,name=ret,proto3" json:"ret,omitempty"` - // reverted flag is set to true when the call has been reverted - Reverted bool `protobuf:"varint,5,opt,name=reverted,proto3" json:"reverted,omitempty"` - // gas_used notes the amount of gas consumed while execution - GasUsed uint64 `protobuf:"varint,6,opt,name=gas_used,json=gasUsed,proto3" json:"gas_used,omitempty"` -} - -func (m *TxResult) Reset() { *m = TxResult{} } -func (m *TxResult) String() string { return proto.CompactTextString(m) } -func (*TxResult) ProtoMessage() {} -func (*TxResult) Descriptor() ([]byte, []int) { - return fileDescriptor_d21ecc92c8c8583e, []int{5} -} -func (m *TxResult) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TxResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_TxResult.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 *TxResult) XXX_Merge(src proto.Message) { - xxx_messageInfo_TxResult.Merge(m, src) -} -func (m *TxResult) XXX_Size() int { - return m.Size() -} -func (m *TxResult) XXX_DiscardUnknown() { - xxx_messageInfo_TxResult.DiscardUnknown(m) -} - -var xxx_messageInfo_TxResult proto.InternalMessageInfo - -// AccessTuple is the element type of an access list. -type AccessTuple struct { - // hex formatted ethereum address - Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` - // hex formatted hashes of the storage keys - StorageKeys []string `protobuf:"bytes,2,rep,name=storage_keys,json=storageKeys,proto3" json:"storageKeys"` -} - -func (m *AccessTuple) Reset() { *m = AccessTuple{} } -func (m *AccessTuple) String() string { return proto.CompactTextString(m) } -func (*AccessTuple) ProtoMessage() {} -func (*AccessTuple) Descriptor() ([]byte, []int) { - return fileDescriptor_d21ecc92c8c8583e, []int{6} -} -func (m *AccessTuple) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *AccessTuple) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_AccessTuple.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 *AccessTuple) XXX_Merge(src proto.Message) { - xxx_messageInfo_AccessTuple.Merge(m, src) -} -func (m *AccessTuple) XXX_Size() int { - return m.Size() -} -func (m *AccessTuple) XXX_DiscardUnknown() { - xxx_messageInfo_AccessTuple.DiscardUnknown(m) -} - -var xxx_messageInfo_AccessTuple proto.InternalMessageInfo - -// TraceConfig holds extra parameters to trace functions. -type TraceConfig struct { - // custom javascript tracer - Tracer string `protobuf:"bytes,1,opt,name=tracer,proto3" json:"tracer,omitempty"` - // overrides the default timeout of 5 seconds for JavaScript-based tracing - // calls - Timeout string `protobuf:"bytes,2,opt,name=timeout,proto3" json:"timeout,omitempty"` - // number of blocks the tracer is willing to go back - Reexec uint64 `protobuf:"varint,3,opt,name=reexec,proto3" json:"reexec,omitempty"` - // disable stack capture - DisableStack bool `protobuf:"varint,5,opt,name=disable_stack,json=disableStack,proto3" json:"disableStack"` - // disable storage capture - DisableStorage bool `protobuf:"varint,6,opt,name=disable_storage,json=disableStorage,proto3" json:"disableStorage"` - // print output during capture end - Debug bool `protobuf:"varint,8,opt,name=debug,proto3" json:"debug,omitempty"` - // maximum length of output, but zero means unlimited - Limit int32 `protobuf:"varint,9,opt,name=limit,proto3" json:"limit,omitempty"` - // Chain overrides, can be used to execute a trace using future fork rules - Overrides *ChainConfig `protobuf:"bytes,10,opt,name=overrides,proto3" json:"overrides,omitempty"` - // enable memory capture - EnableMemory bool `protobuf:"varint,11,opt,name=enable_memory,json=enableMemory,proto3" json:"enableMemory"` - // enable return data capture - EnableReturnData bool `protobuf:"varint,12,opt,name=enable_return_data,json=enableReturnData,proto3" json:"enableReturnData"` -} - -func (m *TraceConfig) Reset() { *m = TraceConfig{} } -func (m *TraceConfig) String() string { return proto.CompactTextString(m) } -func (*TraceConfig) ProtoMessage() {} -func (*TraceConfig) Descriptor() ([]byte, []int) { - return fileDescriptor_d21ecc92c8c8583e, []int{7} -} -func (m *TraceConfig) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TraceConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_TraceConfig.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 *TraceConfig) XXX_Merge(src proto.Message) { - xxx_messageInfo_TraceConfig.Merge(m, src) -} -func (m *TraceConfig) XXX_Size() int { - return m.Size() -} -func (m *TraceConfig) XXX_DiscardUnknown() { - xxx_messageInfo_TraceConfig.DiscardUnknown(m) -} - -var xxx_messageInfo_TraceConfig proto.InternalMessageInfo - -func (m *TraceConfig) GetTracer() string { - if m != nil { - return m.Tracer - } - return "" -} - -func (m *TraceConfig) GetTimeout() string { - if m != nil { - return m.Timeout - } - return "" -} - -func (m *TraceConfig) GetReexec() uint64 { - if m != nil { - return m.Reexec - } - return 0 -} - -func (m *TraceConfig) GetDisableStack() bool { - if m != nil { - return m.DisableStack - } - return false -} - -func (m *TraceConfig) GetDisableStorage() bool { - if m != nil { - return m.DisableStorage - } - return false -} - -func (m *TraceConfig) GetDebug() bool { - if m != nil { - return m.Debug - } - return false -} - -func (m *TraceConfig) GetLimit() int32 { - if m != nil { - return m.Limit - } - return 0 -} - -func (m *TraceConfig) GetOverrides() *ChainConfig { - if m != nil { - return m.Overrides - } - return nil -} - -func (m *TraceConfig) GetEnableMemory() bool { - if m != nil { - return m.EnableMemory - } - return false -} - -func (m *TraceConfig) GetEnableReturnData() bool { - if m != nil { - return m.EnableReturnData - } - return false -} - -var fileDescriptor_d21ecc92c8c8583e = []byte{ - // 1503 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x57, 0x5d, 0x4f, 0x1b, 0xc7, - 0x1a, 0x06, 0x6c, 0x60, 0x3d, 0x36, 0xf6, 0x32, 0x10, 0x8e, 0x43, 0x74, 0x58, 0xce, 0x5e, 0x1c, - 0x71, 0xa4, 0x04, 0x02, 0x11, 0x3a, 0x51, 0xa2, 0x23, 0x1d, 0x0c, 0x24, 0x81, 0x93, 0xd3, 0xa2, - 0x81, 0xa8, 0x52, 0xa5, 0x6a, 0x35, 0xde, 0x9d, 0x2c, 0x5b, 0x76, 0x77, 0xac, 0x99, 0x59, 0xc7, - 0xae, 0xfa, 0x03, 0x5a, 0xf5, 0xa6, 0x3f, 0xa1, 0x7f, 0xa1, 0xff, 0x22, 0xea, 0x55, 0x2e, 0xab, - 0x5e, 0xac, 0x22, 0x72, 0xc7, 0xa5, 0x7f, 0x41, 0x35, 0x1f, 0xfe, 0x04, 0xb5, 0x85, 0x2b, 0xcf, - 0xf3, 0x7e, 0x3c, 0xcf, 0xcc, 0x3b, 0xef, 0xce, 0x8c, 0xc1, 0x2a, 0x11, 0xe7, 0x84, 0x25, 0x51, - 0x2a, 0xb6, 0x48, 0x3b, 0xd9, 0x6a, 0x6f, 0xcb, 0x9f, 0xcd, 0x16, 0xa3, 0x82, 0x42, 0x7b, 0xe0, - 0xdb, 0x94, 0xc6, 0xf6, 0xf6, 0xea, 0x72, 0x48, 0x43, 0xaa, 0x9c, 0x5b, 0x72, 0xa4, 0xe3, 0xdc, - 0xef, 0x0b, 0x60, 0xee, 0x04, 0x33, 0x9c, 0x70, 0xb8, 0x0d, 0x4a, 0xa4, 0x9d, 0x78, 0x01, 0x49, - 0x69, 0x52, 0x9f, 0x5e, 0x9f, 0xde, 0x28, 0x35, 0x96, 0x7b, 0xb9, 0x63, 0x77, 0x71, 0x12, 0x3f, - 0x73, 0x07, 0x2e, 0x17, 0x59, 0xa4, 0x9d, 0x1c, 0xc8, 0x21, 0xfc, 0x0f, 0x58, 0x20, 0x29, 0x6e, - 0xc6, 0xc4, 0xf3, 0x19, 0xc1, 0x82, 0xd4, 0x67, 0xd6, 0xa7, 0x37, 0xac, 0x46, 0xbd, 0x97, 0x3b, - 0xcb, 0x26, 0x6d, 0xd4, 0xed, 0xa2, 0x8a, 0xc6, 0xfb, 0x0a, 0xc2, 0x7f, 0x83, 0x72, 0xdf, 0x8f, - 0xe3, 0xb8, 0x5e, 0x50, 0xc9, 0x2b, 0xbd, 0xdc, 0x81, 0xe3, 0xc9, 0x38, 0x8e, 0x5d, 0x04, 0x4c, - 0x2a, 0x8e, 0x63, 0xb8, 0x07, 0x00, 0xe9, 0x08, 0x86, 0x3d, 0x12, 0xb5, 0x78, 0xbd, 0xb8, 0x5e, - 0xd8, 0x28, 0x34, 0xdc, 0xcb, 0xdc, 0x29, 0x1d, 0x4a, 0xeb, 0xe1, 0xd1, 0x09, 0xef, 0xe5, 0xce, - 0xa2, 0x21, 0x19, 0x04, 0xba, 0xa8, 0xa4, 0xc0, 0x61, 0xd4, 0xe2, 0xf0, 0x2b, 0x50, 0xf1, 0xcf, - 0x71, 0x94, 0x7a, 0x3e, 0x4d, 0xdf, 0x46, 0x61, 0x7d, 0x76, 0x7d, 0x7a, 0xa3, 0xbc, 0xf3, 0xf7, - 0xcd, 0xc9, 0xba, 0x6d, 0xee, 0xcb, 0xa8, 0x7d, 0x15, 0xd4, 0x78, 0xf0, 0x3e, 0x77, 0xa6, 0x7a, - 0xb9, 0xb3, 0xa4, 0xa9, 0x47, 0x09, 0x5c, 0x54, 0xf6, 0x87, 0x91, 0x70, 0x07, 0xdc, 0xc3, 0x71, - 0x4c, 0xdf, 0x79, 0x59, 0x2a, 0x0b, 0x4d, 0x7c, 0x41, 0x02, 0x4f, 0x74, 0x78, 0x7d, 0x4e, 0x2e, - 0x12, 0x2d, 0x29, 0xe7, 0x9b, 0xa1, 0xef, 0xac, 0xc3, 0xdd, 0x9f, 0xab, 0xa0, 0x3c, 0xa2, 0x06, - 0x13, 0x50, 0x3b, 0xa7, 0x09, 0xe1, 0x82, 0xe0, 0xc0, 0x6b, 0xc6, 0xd4, 0xbf, 0x30, 0xdb, 0x72, - 0xf0, 0x5b, 0xee, 0xfc, 0x33, 0x8c, 0xc4, 0x79, 0xd6, 0xdc, 0xf4, 0x69, 0xb2, 0xe5, 0x53, 0x9e, - 0x50, 0x6e, 0x7e, 0x1e, 0xf1, 0xe0, 0x62, 0x4b, 0x74, 0x5b, 0x84, 0x6f, 0x1e, 0xa5, 0xa2, 0x97, - 0x3b, 0x2b, 0x7a, 0xb2, 0x13, 0x54, 0x2e, 0xaa, 0x0e, 0x2c, 0x0d, 0x69, 0x80, 0x5d, 0x50, 0x0d, - 0x30, 0xf5, 0xde, 0x52, 0x76, 0x61, 0xd4, 0x66, 0x94, 0xda, 0xe9, 0x5f, 0x57, 0xbb, 0xcc, 0x9d, - 0xca, 0xc1, 0xde, 0xe7, 0x2f, 0x28, 0xbb, 0x50, 0x9c, 0xbd, 0xdc, 0xb9, 0xa7, 0xd5, 0xc7, 0x99, - 0x5d, 0x54, 0x09, 0x30, 0x1d, 0x84, 0xc1, 0x2f, 0x80, 0x3d, 0x08, 0xe0, 0x59, 0xab, 0x45, 0x99, - 0x30, 0xdd, 0xf0, 0xe8, 0x32, 0x77, 0xaa, 0x86, 0xf2, 0x54, 0x7b, 0x7a, 0xb9, 0xf3, 0xb7, 0x09, - 0x52, 0x93, 0xe3, 0xa2, 0xaa, 0xa1, 0x35, 0xa1, 0x90, 0x83, 0x0a, 0x89, 0x5a, 0xdb, 0xbb, 0x8f, - 0xcd, 0x8a, 0x8a, 0x6a, 0x45, 0x27, 0xb7, 0x5a, 0x51, 0xf9, 0xf0, 0xe8, 0x64, 0x7b, 0xf7, 0x71, - 0x7f, 0x41, 0x66, 0xef, 0x47, 0x69, 0x5d, 0x54, 0xd6, 0x50, 0xaf, 0xe6, 0x08, 0x18, 0xe8, 0x9d, - 0x63, 0x7e, 0xae, 0x3a, 0xab, 0xd4, 0xd8, 0xb8, 0xcc, 0x1d, 0xa0, 0x99, 0x5e, 0x61, 0x7e, 0x3e, - 0xdc, 0x97, 0x66, 0xf7, 0x1b, 0x9c, 0x8a, 0x28, 0x4b, 0xfa, 0x5c, 0x40, 0x27, 0xcb, 0xa8, 0xc1, - 0xfc, 0x77, 0xcd, 0xfc, 0xe7, 0xee, 0x3c, 0xff, 0xdd, 0x9b, 0xe6, 0xbf, 0x3b, 0x3e, 0x7f, 0x1d, - 0x33, 0x10, 0x7d, 0x6a, 0x44, 0xe7, 0xef, 0x2c, 0xfa, 0xf4, 0x26, 0xd1, 0xa7, 0xe3, 0xa2, 0x3a, - 0x46, 0x36, 0xfb, 0x44, 0x25, 0xea, 0xd6, 0xdd, 0x9b, 0xfd, 0x5a, 0x51, 0xab, 0x03, 0x8b, 0x96, - 0xfb, 0x16, 0x2c, 0xfb, 0x34, 0xe5, 0x42, 0xda, 0x52, 0xda, 0x8a, 0x89, 0xd1, 0x2c, 0x29, 0xcd, - 0xa3, 0x5b, 0x69, 0x3e, 0x30, 0xa7, 0xc1, 0x0d, 0x7c, 0x2e, 0x5a, 0x1a, 0x37, 0x6b, 0xf5, 0x16, - 0xb0, 0x5b, 0x44, 0x10, 0xc6, 0x9b, 0x19, 0x0b, 0x8d, 0x32, 0x50, 0xca, 0x87, 0xb7, 0x52, 0x36, - 0xdf, 0xc1, 0x24, 0x97, 0x8b, 0x6a, 0x43, 0x93, 0x56, 0xfc, 0x1a, 0x54, 0x23, 0x39, 0x8d, 0x66, - 0x16, 0x1b, 0xbd, 0xb2, 0xd2, 0xdb, 0xbf, 0x95, 0x9e, 0xf9, 0x98, 0xc7, 0x99, 0x5c, 0xb4, 0xd0, - 0x37, 0x68, 0xad, 0x0c, 0xc0, 0x24, 0x8b, 0x98, 0x17, 0xc6, 0xd8, 0x8f, 0x08, 0x33, 0x7a, 0x15, - 0xa5, 0xf7, 0xf2, 0x56, 0x7a, 0xf7, 0xb5, 0xde, 0x75, 0x36, 0x17, 0xd9, 0xd2, 0xf8, 0x52, 0xdb, - 0xb4, 0x6c, 0x00, 0x2a, 0x4d, 0xc2, 0xe2, 0x28, 0x35, 0x82, 0x0b, 0x4a, 0x70, 0xef, 0x56, 0x82, - 0xa6, 0x4f, 0x47, 0x79, 0x5c, 0x54, 0xd6, 0x70, 0xa0, 0x12, 0xd3, 0x34, 0xa0, 0x7d, 0x95, 0xc5, - 0xbb, 0xab, 0x8c, 0xf2, 0xb8, 0xa8, 0xac, 0xa1, 0x56, 0xe9, 0x80, 0x25, 0xcc, 0x18, 0x7d, 0x37, - 0x51, 0x43, 0xa8, 0xc4, 0x5e, 0xdd, 0x4a, 0x6c, 0x55, 0x8b, 0xdd, 0x40, 0xe7, 0xa2, 0x45, 0x65, - 0x1d, 0xab, 0x22, 0x05, 0x76, 0x42, 0x58, 0x48, 0x46, 0xef, 0x81, 0xa5, 0xbb, 0xb7, 0xe6, 0x24, - 0x97, 0x8b, 0xaa, 0xca, 0x34, 0x38, 0xfb, 0x8f, 0x8b, 0x56, 0xd5, 0xae, 0x1d, 0x17, 0xad, 0x9a, - 0x6d, 0x1f, 0x17, 0x2d, 0xdb, 0x5e, 0x44, 0x0b, 0x5d, 0x1a, 0x53, 0xaf, 0xfd, 0x44, 0x67, 0xa0, - 0x32, 0x79, 0x87, 0xb9, 0xf9, 0x90, 0x51, 0xd5, 0xc7, 0x02, 0xc7, 0x5d, 0x2e, 0x0c, 0xdd, 0x16, - 0x98, 0x3d, 0x15, 0xf2, 0x2d, 0x61, 0x83, 0xc2, 0x05, 0xe9, 0xea, 0x0b, 0x12, 0xc9, 0x21, 0x5c, - 0x06, 0xb3, 0x6d, 0x1c, 0x67, 0xfa, 0x51, 0x52, 0x42, 0x1a, 0xb8, 0x27, 0xa0, 0x76, 0xc6, 0x70, - 0xca, 0xb1, 0x2f, 0x22, 0x9a, 0xbe, 0xa6, 0x21, 0x87, 0x10, 0x14, 0xd5, 0x41, 0xad, 0x73, 0xd5, - 0x18, 0xfe, 0x0b, 0x14, 0x63, 0x1a, 0xf2, 0xfa, 0xcc, 0x7a, 0x61, 0xa3, 0xbc, 0x73, 0xef, 0xfa, - 0xb3, 0xe0, 0x35, 0x0d, 0x91, 0x0a, 0x71, 0x7f, 0x99, 0x01, 0x85, 0xd7, 0x34, 0x84, 0x75, 0x30, - 0x8f, 0x83, 0x80, 0x11, 0xce, 0x0d, 0x53, 0x1f, 0xc2, 0x15, 0x30, 0x27, 0x68, 0x2b, 0xf2, 0x35, - 0x5d, 0x09, 0x19, 0x24, 0x85, 0x03, 0x2c, 0xb0, 0xba, 0xea, 0x2a, 0x48, 0x8d, 0xe1, 0x0e, 0xa8, - 0xa8, 0x95, 0x79, 0x69, 0x96, 0x34, 0x09, 0x53, 0x37, 0x56, 0xb1, 0x51, 0xbb, 0xca, 0x9d, 0xb2, - 0xb2, 0x7f, 0xa6, 0xcc, 0x68, 0x14, 0xc0, 0x87, 0x60, 0x5e, 0x74, 0x46, 0x2f, 0x9b, 0xa5, 0xab, - 0xdc, 0xa9, 0x89, 0xe1, 0x32, 0xe5, 0x5d, 0x82, 0xe6, 0x44, 0x47, 0xdd, 0x29, 0x5b, 0xc0, 0x12, - 0x1d, 0x2f, 0x4a, 0x03, 0xd2, 0x51, 0xf7, 0x49, 0xb1, 0xb1, 0x7c, 0x95, 0x3b, 0xf6, 0x48, 0xf8, - 0x91, 0xf4, 0xa1, 0x79, 0xd1, 0x51, 0x03, 0xf8, 0x10, 0x00, 0x3d, 0x25, 0xa5, 0xa0, 0x6f, 0x83, - 0x85, 0xab, 0xdc, 0x29, 0x29, 0xab, 0xe2, 0x1e, 0x0e, 0xa1, 0x0b, 0x66, 0x35, 0xb7, 0xa5, 0xb8, - 0x2b, 0x57, 0xb9, 0x63, 0xc5, 0x34, 0xd4, 0x9c, 0xda, 0x25, 0x4b, 0xc5, 0x48, 0x42, 0xdb, 0x24, - 0x50, 0x07, 0xae, 0x85, 0xfa, 0xd0, 0xfd, 0x61, 0x06, 0x58, 0x67, 0x1d, 0x44, 0x78, 0x16, 0x0b, - 0xf8, 0x02, 0xd8, 0x3e, 0x4d, 0x05, 0xc3, 0xbe, 0xf0, 0xc6, 0x4a, 0xdb, 0x78, 0x30, 0xec, 0xb0, - 0xc9, 0x08, 0x17, 0xd5, 0xfa, 0xa6, 0x3d, 0x53, 0xff, 0x65, 0x30, 0xdb, 0x8c, 0x29, 0x4d, 0x54, - 0x27, 0x54, 0x90, 0x06, 0x10, 0xa9, 0xaa, 0xa9, 0x5d, 0x2e, 0xa8, 0xc7, 0xdf, 0x3f, 0xae, 0xef, - 0xf2, 0x44, 0xab, 0x34, 0x56, 0xcc, 0x03, 0xb0, 0xaa, 0xb5, 0x4d, 0xbe, 0x2b, 0x6b, 0xab, 0x5a, - 0xc9, 0x06, 0x05, 0x46, 0x84, 0xda, 0xb4, 0x0a, 0x92, 0x43, 0xb8, 0x0a, 0x2c, 0x46, 0xda, 0x84, - 0x09, 0x12, 0xa8, 0xcd, 0xb1, 0xd0, 0x00, 0xc3, 0xfb, 0xc0, 0x0a, 0x31, 0xf7, 0x32, 0x4e, 0x02, - 0xbd, 0x13, 0x68, 0x3e, 0xc4, 0xfc, 0x0d, 0x27, 0xc1, 0xb3, 0xe2, 0x77, 0x3f, 0x39, 0x53, 0x2e, - 0x06, 0xe5, 0x3d, 0xdf, 0x27, 0x9c, 0x9f, 0x65, 0xad, 0x98, 0xfc, 0x41, 0x87, 0xed, 0x80, 0x0a, - 0x17, 0x94, 0xe1, 0x90, 0x78, 0x17, 0xa4, 0x6b, 0xfa, 0x4c, 0x77, 0x8d, 0xb1, 0xff, 0x8f, 0x74, - 0x39, 0x1a, 0x05, 0x46, 0xe2, 0x63, 0x01, 0x94, 0xcf, 0x18, 0xf6, 0x89, 0x79, 0x74, 0xca, 0x5e, - 0x95, 0x90, 0x19, 0x09, 0x83, 0xa4, 0xb6, 0x88, 0x12, 0x42, 0x33, 0x61, 0xbe, 0xa7, 0x3e, 0x94, - 0x19, 0x8c, 0x90, 0x0e, 0xf1, 0x55, 0x19, 0x8b, 0xc8, 0x20, 0xb8, 0x0b, 0x16, 0x82, 0x88, 0xab, - 0x17, 0x3c, 0x17, 0xd8, 0xbf, 0xd0, 0xcb, 0x6f, 0xd8, 0x57, 0xb9, 0x53, 0x31, 0x8e, 0x53, 0x69, - 0x47, 0x63, 0x08, 0x3e, 0x07, 0xb5, 0x61, 0x9a, 0x9a, 0xad, 0x7e, 0x33, 0x37, 0xe0, 0x55, 0xee, - 0x54, 0x07, 0xa1, 0xca, 0x83, 0x26, 0xb0, 0xdc, 0xe9, 0x80, 0x34, 0xb3, 0x50, 0x35, 0x9f, 0x85, - 0x34, 0x90, 0xd6, 0x38, 0x4a, 0x22, 0xa1, 0x9a, 0x6d, 0x16, 0x69, 0x00, 0x9f, 0x83, 0x12, 0x6d, - 0x13, 0xc6, 0xa2, 0x80, 0x70, 0x75, 0xfb, 0xfe, 0xd9, 0xf3, 0x1f, 0x0d, 0xe3, 0xe5, 0xe2, 0xcc, - 0xbf, 0x93, 0x84, 0x24, 0x94, 0x75, 0xd5, 0x75, 0x6a, 0x16, 0xa7, 0x1d, 0xff, 0x57, 0x76, 0x34, - 0x86, 0x60, 0x03, 0x40, 0x93, 0xc6, 0x88, 0xc8, 0x58, 0xea, 0xa9, 0xef, 0xbf, 0xa2, 0x72, 0xd5, - 0x57, 0xa8, 0xbd, 0x48, 0x39, 0x0f, 0xb0, 0xc0, 0xe8, 0x9a, 0xe5, 0xb8, 0x68, 0x15, 0xed, 0xd9, - 0xe3, 0xa2, 0x35, 0x6f, 0x5b, 0x83, 0xf5, 0x9b, 0x59, 0xa0, 0xa5, 0x3e, 0x1e, 0xa1, 0x6f, 0xfc, - 0xf7, 0xfd, 0xe5, 0xda, 0xf4, 0x87, 0xcb, 0xb5, 0xe9, 0x8f, 0x97, 0x6b, 0xd3, 0x3f, 0x7e, 0x5a, - 0x9b, 0xfa, 0xf0, 0x69, 0x6d, 0xea, 0xd7, 0x4f, 0x6b, 0x53, 0x5f, 0x8e, 0x1e, 0xe7, 0xa4, 0x2d, - 0x4f, 0xf3, 0xe1, 0x5f, 0xca, 0x8e, 0xfa, 0x53, 0xa9, 0x8e, 0xf4, 0xe6, 0x9c, 0xfa, 0xb3, 0xf8, - 0xe4, 0xf7, 0x00, 0x00, 0x00, 0xff, 0xff, 0x33, 0x43, 0xe0, 0x76, 0x72, 0x0e, 0x00, 0x00, -} - -func (m *Params) 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 *Params) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.AllowUnprotectedTxs { - i-- - if m.AllowUnprotectedTxs { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x30 - } - { - size, err := m.ChainConfig.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x2a - if len(m.ExtraEIPs) > 0 { - dAtA3 := make([]byte, len(m.ExtraEIPs)*10) - var j2 int - for _, num1 := range m.ExtraEIPs { - num := uint64(num1) - for num >= 1<<7 { - dAtA3[j2] = uint8(uint64(num)&0x7f | 0x80) - num >>= 7 - j2++ - } - dAtA3[j2] = uint8(num) - j2++ - } - i -= j2 - copy(dAtA[i:], dAtA3[:j2]) - i = encodeVarintEvm(dAtA, i, uint64(j2)) - i-- - dAtA[i] = 0x22 - } - if m.EnableCall { - i-- - if m.EnableCall { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x18 - } - if m.EnableCreate { - i-- - if m.EnableCreate { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x10 - } - if len(m.EvmDenom) > 0 { - i -= len(m.EvmDenom) - copy(dAtA[i:], m.EvmDenom) - i = encodeVarintEvm(dAtA, i, uint64(len(m.EvmDenom))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *ChainConfig) 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 *ChainConfig) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *ChainConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.MergeForkBlock != nil { - { - size := m.MergeForkBlock.Size() - i -= size - if _, err := m.MergeForkBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1 - i-- - dAtA[i] = 0x9a - } - if m.ArrowGlacierBlock != nil { - { - size := m.ArrowGlacierBlock.Size() - i -= size - if _, err := m.ArrowGlacierBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1 - i-- - dAtA[i] = 0x92 - } - if m.LondonBlock != nil { - { - size := m.LondonBlock.Size() - i -= size - if _, err := m.LondonBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1 - i-- - dAtA[i] = 0x8a - } - if m.BerlinBlock != nil { - { - size := m.BerlinBlock.Size() - i -= size - if _, err := m.BerlinBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x6a - } - if m.MuirGlacierBlock != nil { - { - size := m.MuirGlacierBlock.Size() - i -= size - if _, err := m.MuirGlacierBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x62 - } - if m.IstanbulBlock != nil { - { - size := m.IstanbulBlock.Size() - i -= size - if _, err := m.IstanbulBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x5a - } - if m.PetersburgBlock != nil { - { - size := m.PetersburgBlock.Size() - i -= size - if _, err := m.PetersburgBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x52 - } - if m.ConstantinopleBlock != nil { - { - size := m.ConstantinopleBlock.Size() - i -= size - if _, err := m.ConstantinopleBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x4a - } - if m.ByzantiumBlock != nil { - { - size := m.ByzantiumBlock.Size() - i -= size - if _, err := m.ByzantiumBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x42 - } - if m.EIP158Block != nil { - { - size := m.EIP158Block.Size() - i -= size - if _, err := m.EIP158Block.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x3a - } - if m.EIP155Block != nil { - { - size := m.EIP155Block.Size() - i -= size - if _, err := m.EIP155Block.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x32 - } - if len(m.EIP150Hash) > 0 { - i -= len(m.EIP150Hash) - copy(dAtA[i:], m.EIP150Hash) - i = encodeVarintEvm(dAtA, i, uint64(len(m.EIP150Hash))) - i-- - dAtA[i] = 0x2a - } - if m.EIP150Block != nil { - { - size := m.EIP150Block.Size() - i -= size - if _, err := m.EIP150Block.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x22 - } - if m.DAOForkSupport { - i-- - if m.DAOForkSupport { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x18 - } - if m.DAOForkBlock != nil { - { - size := m.DAOForkBlock.Size() - i -= size - if _, err := m.DAOForkBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - if m.HomesteadBlock != nil { - { - size := m.HomesteadBlock.Size() - i -= size - if _, err := m.HomesteadBlock.MarshalTo(dAtA[i:]); err != nil { - return 0, err - } - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *State) 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 *State) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *State) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Value) > 0 { - i -= len(m.Value) - copy(dAtA[i:], m.Value) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Value))) - i-- - dAtA[i] = 0x12 - } - if len(m.Key) > 0 { - i -= len(m.Key) - copy(dAtA[i:], m.Key) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Key))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *TransactionLogs) 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 *TransactionLogs) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *TransactionLogs) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Logs) > 0 { - for iNdEx := len(m.Logs) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Logs[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - } - if len(m.Hash) > 0 { - i -= len(m.Hash) - copy(dAtA[i:], m.Hash) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Hash))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *Log) 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 *Log) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *Log) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.Removed { - i-- - if m.Removed { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x48 - } - if m.Index != 0 { - i = encodeVarintEvm(dAtA, i, uint64(m.Index)) - i-- - dAtA[i] = 0x40 - } - if len(m.BlockHash) > 0 { - i -= len(m.BlockHash) - copy(dAtA[i:], m.BlockHash) - i = encodeVarintEvm(dAtA, i, uint64(len(m.BlockHash))) - i-- - dAtA[i] = 0x3a - } - if m.TxIndex != 0 { - i = encodeVarintEvm(dAtA, i, uint64(m.TxIndex)) - i-- - dAtA[i] = 0x30 - } - if len(m.TxHash) > 0 { - i -= len(m.TxHash) - copy(dAtA[i:], m.TxHash) - i = encodeVarintEvm(dAtA, i, uint64(len(m.TxHash))) - i-- - dAtA[i] = 0x2a - } - if m.BlockNumber != 0 { - i = encodeVarintEvm(dAtA, i, uint64(m.BlockNumber)) - i-- - dAtA[i] = 0x20 - } - if len(m.Data) > 0 { - i -= len(m.Data) - copy(dAtA[i:], m.Data) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Data))) - i-- - dAtA[i] = 0x1a - } - if len(m.Topics) > 0 { - for iNdEx := len(m.Topics) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.Topics[iNdEx]) - copy(dAtA[i:], m.Topics[iNdEx]) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Topics[iNdEx]))) - i-- - dAtA[i] = 0x12 - } - } - if len(m.Address) > 0 { - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Address))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *TxResult) 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 *TxResult) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *TxResult) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.GasUsed != 0 { - i = encodeVarintEvm(dAtA, i, uint64(m.GasUsed)) - i-- - dAtA[i] = 0x30 - } - if m.Reverted { - i-- - if m.Reverted { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x28 - } - if len(m.Ret) > 0 { - i -= len(m.Ret) - copy(dAtA[i:], m.Ret) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Ret))) - i-- - dAtA[i] = 0x22 - } - { - size, err := m.TxLogs.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1a - if len(m.Bloom) > 0 { - i -= len(m.Bloom) - copy(dAtA[i:], m.Bloom) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Bloom))) - i-- - dAtA[i] = 0x12 - } - if len(m.ContractAddress) > 0 { - i -= len(m.ContractAddress) - copy(dAtA[i:], m.ContractAddress) - i = encodeVarintEvm(dAtA, i, uint64(len(m.ContractAddress))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *AccessTuple) 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 *AccessTuple) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *AccessTuple) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.StorageKeys) > 0 { - for iNdEx := len(m.StorageKeys) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.StorageKeys[iNdEx]) - copy(dAtA[i:], m.StorageKeys[iNdEx]) - i = encodeVarintEvm(dAtA, i, uint64(len(m.StorageKeys[iNdEx]))) - i-- - dAtA[i] = 0x12 - } - } - if len(m.Address) > 0 { - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Address))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *TraceConfig) 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 *TraceConfig) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *TraceConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.EnableReturnData { - i-- - if m.EnableReturnData { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x60 - } - if m.EnableMemory { - i-- - if m.EnableMemory { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x58 - } - if m.Overrides != nil { - { - size, err := m.Overrides.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintEvm(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x52 - } - if m.Limit != 0 { - i = encodeVarintEvm(dAtA, i, uint64(m.Limit)) - i-- - dAtA[i] = 0x48 - } - if m.Debug { - i-- - if m.Debug { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x40 - } - if m.DisableStorage { - i-- - if m.DisableStorage { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x30 - } - if m.DisableStack { - i-- - if m.DisableStack { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x28 - } - if m.Reexec != 0 { - i = encodeVarintEvm(dAtA, i, uint64(m.Reexec)) - i-- - dAtA[i] = 0x18 - } - if len(m.Timeout) > 0 { - i -= len(m.Timeout) - copy(dAtA[i:], m.Timeout) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Timeout))) - i-- - dAtA[i] = 0x12 - } - if len(m.Tracer) > 0 { - i -= len(m.Tracer) - copy(dAtA[i:], m.Tracer) - i = encodeVarintEvm(dAtA, i, uint64(len(m.Tracer))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func encodeVarintEvm(dAtA []byte, offset int, v uint64) int { - offset -= sovEvm(v) - base := offset - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - dAtA[offset] = uint8(v) - return base -} -func (m *Params) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.EvmDenom) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if m.EnableCreate { - n += 2 - } - if m.EnableCall { - n += 2 - } - if len(m.ExtraEIPs) > 0 { - l = 0 - for _, e := range m.ExtraEIPs { - l += sovEvm(uint64(e)) - } - n += 1 + sovEvm(uint64(l)) + l - } - l = m.ChainConfig.Size() - n += 1 + l + sovEvm(uint64(l)) - if m.AllowUnprotectedTxs { - n += 2 - } - return n -} - -func (m *ChainConfig) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - if m.HomesteadBlock != nil { - l = m.HomesteadBlock.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.DAOForkBlock != nil { - l = m.DAOForkBlock.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.DAOForkSupport { - n += 2 - } - if m.EIP150Block != nil { - l = m.EIP150Block.Size() - n += 1 + l + sovEvm(uint64(l)) - } - l = len(m.EIP150Hash) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if m.EIP155Block != nil { - l = m.EIP155Block.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.EIP158Block != nil { - l = m.EIP158Block.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.ByzantiumBlock != nil { - l = m.ByzantiumBlock.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.ConstantinopleBlock != nil { - l = m.ConstantinopleBlock.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.PetersburgBlock != nil { - l = m.PetersburgBlock.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.IstanbulBlock != nil { - l = m.IstanbulBlock.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.MuirGlacierBlock != nil { - l = m.MuirGlacierBlock.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.BerlinBlock != nil { - l = m.BerlinBlock.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.LondonBlock != nil { - l = m.LondonBlock.Size() - n += 2 + l + sovEvm(uint64(l)) - } - if m.ArrowGlacierBlock != nil { - l = m.ArrowGlacierBlock.Size() - n += 2 + l + sovEvm(uint64(l)) - } - if m.MergeForkBlock != nil { - l = m.MergeForkBlock.Size() - n += 2 + l + sovEvm(uint64(l)) - } - return n -} - -func (m *State) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Key) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - l = len(m.Value) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - return n -} - -func (m *TransactionLogs) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Hash) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if len(m.Logs) > 0 { - for _, e := range m.Logs { - l = e.Size() - n += 1 + l + sovEvm(uint64(l)) - } - } - return n -} - -func (m *Log) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Address) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if len(m.Topics) > 0 { - for _, s := range m.Topics { - l = len(s) - n += 1 + l + sovEvm(uint64(l)) - } - } - l = len(m.Data) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if m.BlockNumber != 0 { - n += 1 + sovEvm(uint64(m.BlockNumber)) - } - l = len(m.TxHash) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if m.TxIndex != 0 { - n += 1 + sovEvm(uint64(m.TxIndex)) - } - l = len(m.BlockHash) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if m.Index != 0 { - n += 1 + sovEvm(uint64(m.Index)) - } - if m.Removed { - n += 2 - } - return n -} - -func (m *TxResult) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.ContractAddress) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - l = len(m.Bloom) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - l = m.TxLogs.Size() - n += 1 + l + sovEvm(uint64(l)) - l = len(m.Ret) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if m.Reverted { - n += 2 - } - if m.GasUsed != 0 { - n += 1 + sovEvm(uint64(m.GasUsed)) - } - return n -} - -func (m *AccessTuple) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Address) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if len(m.StorageKeys) > 0 { - for _, s := range m.StorageKeys { - l = len(s) - n += 1 + l + sovEvm(uint64(l)) - } - } - return n -} - -func (m *TraceConfig) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Tracer) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - l = len(m.Timeout) - if l > 0 { - n += 1 + l + sovEvm(uint64(l)) - } - if m.Reexec != 0 { - n += 1 + sovEvm(uint64(m.Reexec)) - } - if m.DisableStack { - n += 2 - } - if m.DisableStorage { - n += 2 - } - if m.Debug { - n += 2 - } - if m.Limit != 0 { - n += 1 + sovEvm(uint64(m.Limit)) - } - if m.Overrides != nil { - l = m.Overrides.Size() - n += 1 + l + sovEvm(uint64(l)) - } - if m.EnableMemory { - n += 2 - } - if m.EnableReturnData { - n += 2 - } - return n -} - -func sovEvm(x uint64) (n int) { - return (math_bits.Len64(x|1) + 6) / 7 -} -func sozEvm(x uint64) (n int) { - return sovEvm(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (m *Params) 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 ErrIntOverflowEvm - } - 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: Params: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field EvmDenom", 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.EvmDenom = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field EnableCreate", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.EnableCreate = bool(v != 0) - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field EnableCall", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.EnableCall = bool(v != 0) - case 4: - if wireType == 0 { - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int64(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.ExtraEIPs = append(m.ExtraEIPs, v) - } else if wireType == 2 { - var packedLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - packedLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if packedLen < 0 { - return ErrInvalidLengthEvm - } - postIndex := iNdEx + packedLen - if postIndex < 0 { - return ErrInvalidLengthEvm - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - var elementCount int - var count int - for _, integer := range dAtA[iNdEx:postIndex] { - if integer < 128 { - count++ - } - } - elementCount = count - if elementCount != 0 && len(m.ExtraEIPs) == 0 { - m.ExtraEIPs = make([]int64, 0, elementCount) - } - for iNdEx < postIndex { - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int64(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.ExtraEIPs = append(m.ExtraEIPs, v) - } - } else { - return fmt.Errorf("proto: wrong wireType = %d for field ExtraEIPs", wireType) - } - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ChainConfig", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthEvm - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthEvm - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ChainConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field AllowUnprotectedTxs", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.AllowUnprotectedTxs = bool(v != 0) - default: - iNdEx = preIndex - skippy, err := skipEvm(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthEvm - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ChainConfig) 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 ErrIntOverflowEvm - } - 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: ChainConfig: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ChainConfig: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field HomesteadBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.HomesteadBlock = &v - if err := m.HomesteadBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DAOForkBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.DAOForkBlock = &v - if err := m.DAOForkBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field DAOForkSupport", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.DAOForkSupport = bool(v != 0) - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field EIP150Block", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.EIP150Block = &v - if err := m.EIP150Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field EIP150Hash", 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.EIP150Hash = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field EIP155Block", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.EIP155Block = &v - if err := m.EIP155Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 7: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field EIP158Block", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.EIP158Block = &v - if err := m.EIP158Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 8: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ByzantiumBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.ByzantiumBlock = &v - if err := m.ByzantiumBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 9: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConstantinopleBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.ConstantinopleBlock = &v - if err := m.ConstantinopleBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 10: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PetersburgBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.PetersburgBlock = &v - if err := m.PetersburgBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 11: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field IstanbulBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.IstanbulBlock = &v - if err := m.IstanbulBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 12: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MuirGlacierBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.MuirGlacierBlock = &v - if err := m.MuirGlacierBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 13: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field BerlinBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.BerlinBlock = &v - if err := m.BerlinBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 17: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LondonBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.LondonBlock = &v - if err := m.LondonBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 18: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ArrowGlacierBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.ArrowGlacierBlock = &v - if err := m.ArrowGlacierBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 19: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MergeForkBlock", 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 - } - var v github_com_cosmos_cosmos_sdk_types.Int - m.MergeForkBlock = &v - if err := m.MergeForkBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipEvm(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthEvm - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *State) 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 ErrIntOverflowEvm - } - 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: State: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: State: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Key", 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.Key = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", 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.Value = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipEvm(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthEvm - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TransactionLogs) 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 ErrIntOverflowEvm - } - 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: TransactionLogs: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TransactionLogs: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Hash", 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.Hash = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Logs", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthEvm - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthEvm - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Logs = append(m.Logs, &Log{}) - if err := m.Logs[len(m.Logs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipEvm(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthEvm - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Log) 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 ErrIntOverflowEvm - } - 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: Log: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Log: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", 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.Address = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Topics", 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.Topics = append(m.Topics, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthEvm - } - postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthEvm - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...) - if m.Data == nil { - m.Data = []byte{} - } - iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field BlockNumber", wireType) - } - m.BlockNumber = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.BlockNumber |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TxHash", 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.TxHash = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field TxIndex", wireType) - } - m.TxIndex = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.TxIndex |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 7: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field BlockHash", 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.BlockHash = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 8: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType) - } - m.Index = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Index |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 9: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Removed", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.Removed = bool(v != 0) - default: - iNdEx = preIndex - skippy, err := skipEvm(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthEvm - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TxResult) 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 ErrIntOverflowEvm - } - 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: TxResult: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TxResult: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContractAddress", 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.ContractAddress = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Bloom", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthEvm - } - postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthEvm - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Bloom = append(m.Bloom[:0], dAtA[iNdEx:postIndex]...) - if m.Bloom == nil { - m.Bloom = []byte{} - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TxLogs", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthEvm - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthEvm - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.TxLogs.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - 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 ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthEvm - } - postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthEvm - } - 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 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Reverted", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.Reverted = bool(v != 0) - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field GasUsed", wireType) - } - m.GasUsed = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.GasUsed |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipEvm(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthEvm - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *AccessTuple) 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 ErrIntOverflowEvm - } - 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: AccessTuple: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: AccessTuple: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", 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.Address = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field StorageKeys", 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.StorageKeys = append(m.StorageKeys, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipEvm(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthEvm - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TraceConfig) 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 ErrIntOverflowEvm - } - 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: TraceConfig: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TraceConfig: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Tracer", 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.Tracer = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Timeout", 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.Timeout = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Reexec", wireType) - } - m.Reexec = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Reexec |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field DisableStack", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.DisableStack = bool(v != 0) - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field DisableStorage", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.DisableStorage = bool(v != 0) - case 8: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Debug", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.Debug = bool(v != 0) - case 9: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType) - } - m.Limit = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Limit |= int32(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 10: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Overrides", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthEvm - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthEvm - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Overrides == nil { - m.Overrides = &ChainConfig{} - } - if err := m.Overrides.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 11: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field EnableMemory", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.EnableMemory = bool(v != 0) - case 12: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field EnableReturnData", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowEvm - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.EnableReturnData = bool(v != 0) - default: - iNdEx = preIndex - skippy, err := skipEvm(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthEvm - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func skipEvm(dAtA []byte) (n int, err error) { - l := len(dAtA) - iNdEx := 0 - depth := 0 - for iNdEx < l { - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowEvm - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - wireType := int(wire & 0x7) - switch wireType { - case 0: - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowEvm - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - iNdEx++ - if dAtA[iNdEx-1] < 0x80 { - break - } - } - case 1: - iNdEx += 8 - case 2: - var length int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowEvm - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - length |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if length < 0 { - return 0, ErrInvalidLengthEvm - } - iNdEx += length - case 3: - depth++ - case 4: - if depth == 0 { - return 0, ErrUnexpectedEndOfGroupEvm - } - depth-- - case 5: - iNdEx += 4 - default: - return 0, fmt.Errorf("proto: illegal wireType %d", wireType) - } - if iNdEx < 0 { - return 0, ErrInvalidLengthEvm - } - if depth == 0 { - return iNdEx, nil - } - } - return 0, io.ErrUnexpectedEOF -} - -var ( - ErrInvalidLengthEvm = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowEvm = fmt.Errorf("proto: integer overflow") - ErrUnexpectedEndOfGroupEvm = fmt.Errorf("proto: unexpected end of group") -) diff --git a/x/evm/migrations/v3/types/params.go b/x/evm/migrations/v3/types/params.go deleted file mode 100644 index 91f9b32914..0000000000 --- a/x/evm/migrations/v3/types/params.go +++ /dev/null @@ -1,150 +0,0 @@ -package types - -import ( - "fmt" - "math/big" - - "github.com/ethereum/go-ethereum/params" - - sdk "github.com/cosmos/cosmos-sdk/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/ethereum/go-ethereum/core/vm" - "github.com/evmos/ethermint/types" -) - -var _ paramtypes.ParamSet = &Params{} - -var ( - // DefaultEVMDenom defines the default EVM denomination on Ethermint - DefaultEVMDenom = types.AttoPhoton - // DefaultMinGasMultiplier is 0.5 or 50% - DefaultMinGasMultiplier = sdk.NewDecWithPrec(50, 2) - // DefaultAllowUnprotectedTxs rejects all unprotected txs (i.e false) - DefaultAllowUnprotectedTxs = false -) - -// Parameter keys -var ( - ParamStoreKeyEVMDenom = []byte("EVMDenom") - ParamStoreKeyEnableCreate = []byte("EnableCreate") - ParamStoreKeyEnableCall = []byte("EnableCall") - ParamStoreKeyExtraEIPs = []byte("EnableExtraEIPs") - ParamStoreKeyChainConfig = []byte("ChainConfig") - ParamStoreKeyAllowUnprotectedTxs = []byte("AllowUnprotectedTxs") - - // AvailableExtraEIPs define the list of all EIPs that can be enabled by the - // EVM interpreter. These EIPs are applied in order and can override the - // instruction sets from the latest hard fork enabled by the ChainConfig. For - // more info check: - // https://github.com/ethereum/go-ethereum/blob/master/core/vm/interpreter.go#L97 - AvailableExtraEIPs = []int64{1344, 1884, 2200, 2929, 3198, 3529} -) - -// ParamKeyTable returns the parameter key table. -func ParamKeyTable() paramtypes.KeyTable { - return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) -} - -// NewParams creates a new Params instance -func NewParams(evmDenom string, enableCreate, enableCall bool, config ChainConfig, extraEIPs ...int64) Params { - return Params{ - EvmDenom: evmDenom, - EnableCreate: enableCreate, - EnableCall: enableCall, - ExtraEIPs: extraEIPs, - ChainConfig: config, - } -} - -// DefaultParams returns default evm parameters -// ExtraEIPs is empty to prevent overriding the latest hard fork instruction set -func DefaultParams() Params { - return Params{ - EvmDenom: DefaultEVMDenom, - EnableCreate: true, - EnableCall: true, - ChainConfig: DefaultChainConfig(), - ExtraEIPs: nil, - AllowUnprotectedTxs: DefaultAllowUnprotectedTxs, - } -} - -// ParamSetPairs returns the parameter set pairs. -func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { - return paramtypes.ParamSetPairs{ - paramtypes.NewParamSetPair(ParamStoreKeyEVMDenom, &p.EvmDenom, validateEVMDenom), - paramtypes.NewParamSetPair(ParamStoreKeyEnableCreate, &p.EnableCreate, validateBool), - paramtypes.NewParamSetPair(ParamStoreKeyEnableCall, &p.EnableCall, validateBool), - paramtypes.NewParamSetPair(ParamStoreKeyExtraEIPs, &p.ExtraEIPs, validateEIPs), - paramtypes.NewParamSetPair(ParamStoreKeyChainConfig, &p.ChainConfig, validateChainConfig), - paramtypes.NewParamSetPair(ParamStoreKeyAllowUnprotectedTxs, &p.AllowUnprotectedTxs, validateBool), - } -} - -// Validate performs basic validation on evm parameters. -func (p Params) Validate() error { - if err := sdk.ValidateDenom(p.EvmDenom); err != nil { - return err - } - - if err := validateEIPs(p.ExtraEIPs); err != nil { - return err - } - - return p.ChainConfig.Validate() -} - -// EIPs returns the ExtraEips as a int slice -func (p Params) EIPs() []int { - eips := make([]int, len(p.ExtraEIPs)) - for i, eip := range p.ExtraEIPs { - eips[i] = int(eip) - } - return eips -} - -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 { - return fmt.Errorf("invalid parameter type: %T", i) - } - return nil -} - -func validateEIPs(i interface{}) error { - eips, ok := i.([]int64) - if !ok { - return fmt.Errorf("invalid EIP slice type: %T", i) - } - - for _, eip := range eips { - if !vm.ValidEip(int(eip)) { - return fmt.Errorf("EIP %d is not activateable, valid EIPS are: %s", eip, vm.ActivateableEips()) - } - } - - 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() -} - -// IsLondon returns if london hardfork is enabled. -func IsLondon(ethConfig *params.ChainConfig, height int64) bool { - return ethConfig.IsLondon(big.NewInt(height)) -} diff --git a/x/evm/module.go b/x/evm/module.go index 73c245afbc..17aac6cf1f 100644 --- a/x/evm/module.go +++ b/x/evm/module.go @@ -19,10 +19,10 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/tharsis/ethermint/x/evm/client/cli" - "github.com/tharsis/ethermint/x/evm/keeper" - "github.com/tharsis/ethermint/x/evm/simulation" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/client/cli" + "github.com/evmos/ethermint/x/evm/keeper" + "github.com/evmos/ethermint/x/evm/simulation" + "github.com/evmos/ethermint/x/evm/types" ) var ( @@ -122,16 +122,6 @@ func (am AppModule) RegisterInvariants(ir sdk.InvariantRegistry) { func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), am.keeper) types.RegisterQueryServer(cfg.QueryServer(), am.keeper) - - m := keeper.NewMigrator(*am.keeper) - err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2) - if err != nil { - panic(err) - } - err = cfg.RegisterMigration(types.ModuleName, 2, m.Migrate2to3) - if err != nil { - panic(err) - } } // Route returns the message routing key for the evm module. diff --git a/x/evm/simulation/decoder.go b/x/evm/simulation/decoder.go index 5f646851b0..ec2cdf4230 100644 --- a/x/evm/simulation/decoder.go +++ b/x/evm/simulation/decoder.go @@ -6,7 +6,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/kv" "github.com/ethereum/go-ethereum/common" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) // NewDecodeStore returns a decoder function closure that unmarshals the KVPair's diff --git a/x/evm/simulation/decoder_test.go b/x/evm/simulation/decoder_test.go index 2dbd85c66b..f4e5372b12 100644 --- a/x/evm/simulation/decoder_test.go +++ b/x/evm/simulation/decoder_test.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/kv" "github.com/ethereum/go-ethereum/common" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) // TestDecodeStore tests that evm simulation decoder decodes the key value pairs as expected. diff --git a/x/evm/simulation/genesis.go b/x/evm/simulation/genesis.go index 73110b89d7..00132925c9 100644 --- a/x/evm/simulation/genesis.go +++ b/x/evm/simulation/genesis.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) const ( diff --git a/x/evm/simulation/genesis_test.go b/x/evm/simulation/genesis_test.go index b45e35396d..90e5ab6eb1 100644 --- a/x/evm/simulation/genesis_test.go +++ b/x/evm/simulation/genesis_test.go @@ -11,8 +11,8 @@ import ( codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/tharsis/ethermint/x/evm/simulation" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/simulation" + "github.com/evmos/ethermint/x/evm/types" ) // TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. diff --git a/x/evm/simulation/operations.go b/x/evm/simulation/operations.go index d0ad101c70..7e6608ea06 100644 --- a/x/evm/simulation/operations.go +++ b/x/evm/simulation/operations.go @@ -24,10 +24,10 @@ import ( cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/x/auth/signing" "github.com/ethereum/go-ethereum/crypto" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/tests" - "github.com/tharsis/ethermint/x/evm/keeper" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/tests" + "github.com/evmos/ethermint/x/evm/keeper" + "github.com/evmos/ethermint/x/evm/types" ) const ( diff --git a/x/evm/simulation/params.go b/x/evm/simulation/params.go index e7b9914374..1ebc811e69 100644 --- a/x/evm/simulation/params.go +++ b/x/evm/simulation/params.go @@ -9,7 +9,7 @@ import ( amino "github.com/cosmos/cosmos-sdk/codec" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/evm/types" ) // ParamChanges defines the parameters that can be modified by param change proposals diff --git a/x/evm/simulation/params_test.go b/x/evm/simulation/params_test.go index a67d0c9d21..9c6ad371ad 100644 --- a/x/evm/simulation/params_test.go +++ b/x/evm/simulation/params_test.go @@ -8,7 +8,7 @@ import ( "github.com/stretchr/testify/require" - "github.com/tharsis/ethermint/x/evm/simulation" + "github.com/evmos/ethermint/x/evm/simulation" ) // TestParamChanges tests the paramChanges are generated as expected. diff --git a/x/evm/spec/01_concepts.md b/x/evm/spec/01_concepts.md index 4d7f4f8bec..91d1d51b1b 100644 --- a/x/evm/spec/01_concepts.md +++ b/x/evm/spec/01_concepts.md @@ -82,10 +82,10 @@ In the Geth implementation, calling the endpoint roughly goes through the follow The ethermint implementatiom is similar and makes use of the gRPC query client which is included in the Cosmos SDK: 1. `eth_call` request is transformed to call the `func (e *PublicAPI) Call` function using the `eth` namespace -2. [`Call()`](https://github.com/tharsis/ethermint/blob/main/rpc/namespaces/ethereum/eth/api.go#L639) calls `doCall()` -3. [`doCall()`](https://github.com/tharsis/ethermint/blob/main/rpc/namespaces/ethereum/eth/api.go#L656) transforms the arguments into a `EthCallRequest` and calls `EthCall()` using the query client of the evm module. -4. [`EthCall()`](https://github.com/tharsis/ethermint/blob/main/x/evm/keeper/grpc_query.go#L212) transforms the arguments into a `ethtypes.message` and calls `ApplyMessageWithConfig() -5. [`ApplyMessageWithConfig()`](https://github.com/tharsis/ethermint/blob/d5598932a7f06158b7a5e3aa031bbc94eaaae32c/x/evm/keeper/state_transition.go#L341) instantiates an EVM and either `Create()`s a new contract or `Call()`s a contract using the Geth implementation. +2. [`Call()`](https://github.com/evmos/ethermint/blob/main/rpc/namespaces/ethereum/eth/api.go#L639) calls `doCall()` +3. [`doCall()`](https://github.com/evmos/ethermint/blob/main/rpc/namespaces/ethereum/eth/api.go#L656) transforms the arguments into a `EthCallRequest` and calls `EthCall()` using the query client of the evm module. +4. [`EthCall()`](https://github.com/evmos/ethermint/blob/main/x/evm/keeper/grpc_query.go#L212) transforms the arguments into a `ethtypes.message` and calls `ApplyMessageWithConfig() +5. [`ApplyMessageWithConfig()`](https://github.com/evmos/ethermint/blob/d5598932a7f06158b7a5e3aa031bbc94eaaae32c/x/evm/keeper/state_transition.go#L341) instantiates an EVM and either `Create()`s a new contract or `Call()`s a contract using the Geth implementation. ### StateDB diff --git a/x/evm/spec/README.md b/x/evm/spec/README.md index 978c997f8d..8645a805ac 100644 --- a/x/evm/spec/README.md +++ b/x/evm/spec/README.md @@ -17,7 +17,7 @@ The growth of EVM-based chains (e.g. Ethereum), however, has uncovered several s The `x/evm` module provides this EVM familiarity on a scalable, high-throughput Proof-of-Stake blockchain. It is built as a [Cosmos SDK module](https://docs.cosmos.network/master/building-modules/intro.html) which allows for the deployment of smart contracts, interaction with the EVM state machine (state transitions), and the use of EVM tooling. It can be used on Cosmos application-specific blockchains, which alleviate the aforementioned concerns through high transaction throughput via [Tendermint Core](https://github.com/tendermint/tendermint), fast transaction finality, and horizontal scalability via [IBC](https://ibcprotocol.org/). -The `x/evm` is part of the [ethermint library](https://pkg.go.dev/github.com/tharsis/ethermint). For an example of how Ethermint can be used on any Cosmos-SDK chain, please refer to [Evmos](https://www.github.com/tharsis/evmos). +The `x/evm` is part of the [ethermint library](https://pkg.go.dev/github.com/evmos/ethermint). For an example of how Ethermint can be used on any Cosmos-SDK chain, please refer to [Evmos](https://www.github.com/evmos/evmos). ## Contents diff --git a/x/evm/statedb/mock_test.go b/x/evm/statedb/mock_test.go index 7031419d64..544cbfa1b4 100644 --- a/x/evm/statedb/mock_test.go +++ b/x/evm/statedb/mock_test.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" - "github.com/tharsis/ethermint/x/evm/statedb" + "github.com/evmos/ethermint/x/evm/statedb" ) var ( diff --git a/x/evm/statedb/statedb_test.go b/x/evm/statedb/statedb_test.go index ec390cfc78..3a491aa8cc 100644 --- a/x/evm/statedb/statedb_test.go +++ b/x/evm/statedb/statedb_test.go @@ -9,8 +9,8 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/core/vm" "github.com/ethereum/go-ethereum/crypto" + "github.com/evmos/ethermint/x/evm/statedb" "github.com/stretchr/testify/suite" - "github.com/tharsis/ethermint/x/evm/statedb" ) var ( diff --git a/x/evm/types/access_list_tx.go b/x/evm/types/access_list_tx.go index d318c426d0..a6fb9b71dd 100644 --- a/x/evm/types/access_list_tx.go +++ b/x/evm/types/access_list_tx.go @@ -7,7 +7,7 @@ import ( sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/types" ) func newAccessListTx(tx *ethtypes.Transaction) (*AccessListTx, error) { diff --git a/x/evm/types/dynamic_fee_tx.go b/x/evm/types/dynamic_fee_tx.go index 76c621729b..d1656a386d 100644 --- a/x/evm/types/dynamic_fee_tx.go +++ b/x/evm/types/dynamic_fee_tx.go @@ -10,7 +10,7 @@ import ( "github.com/ethereum/go-ethereum/common/math" ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/types" ) func newDynamicFeeTx(tx *ethtypes.Transaction) (*DynamicFeeTx, error) { diff --git a/x/evm/types/dynamic_fee_tx_test.go b/x/evm/types/dynamic_fee_tx_test.go index da8db93836..7c39fefb9d 100644 --- a/x/evm/types/dynamic_fee_tx_test.go +++ b/x/evm/types/dynamic_fee_tx_test.go @@ -7,8 +7,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" + "github.com/evmos/ethermint/tests" "github.com/stretchr/testify/suite" - "github.com/tharsis/ethermint/tests" ) type TxDataTestSuite struct { diff --git a/x/evm/types/genesis.go b/x/evm/types/genesis.go index b71c85d04f..da6313b45b 100644 --- a/x/evm/types/genesis.go +++ b/x/evm/types/genesis.go @@ -3,7 +3,7 @@ package types import ( "fmt" - ethermint "github.com/tharsis/ethermint/types" + ethermint "github.com/evmos/ethermint/types" ) // Validate performs a basic validation of a GenesisAccount fields. diff --git a/x/evm/types/genesis_test.go b/x/evm/types/genesis_test.go index 4f260ee57a..300f59875a 100644 --- a/x/evm/types/genesis_test.go +++ b/x/evm/types/genesis_test.go @@ -6,7 +6,7 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/stretchr/testify/suite" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/crypto/ethsecp256k1" ) type GenesisTestSuite struct { diff --git a/x/evm/types/interfaces.go b/x/evm/types/interfaces.go index ddd7cccde2..f5e16f7fe8 100644 --- a/x/evm/types/interfaces.go +++ b/x/evm/types/interfaces.go @@ -9,7 +9,7 @@ import ( "github.com/ethereum/go-ethereum/core" ethtypes "github.com/ethereum/go-ethereum/core/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" ) // AccountKeeper defines the expected account keeper interface diff --git a/x/evm/types/legacy_tx.go b/x/evm/types/legacy_tx.go index 1846d7be20..9f8014d135 100644 --- a/x/evm/types/legacy_tx.go +++ b/x/evm/types/legacy_tx.go @@ -6,7 +6,7 @@ import ( sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/types" ) func newLegacyTx(tx *ethtypes.Transaction) (*LegacyTx, error) { diff --git a/x/evm/types/logs.go b/x/evm/types/logs.go index 4cf73c94dc..b21bece6c0 100644 --- a/x/evm/types/logs.go +++ b/x/evm/types/logs.go @@ -7,7 +7,7 @@ import ( "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" - ethermint "github.com/tharsis/ethermint/types" + ethermint "github.com/evmos/ethermint/types" ) // NewTransactionLogs creates a new NewTransactionLogs instance. diff --git a/x/evm/types/logs_test.go b/x/evm/types/logs_test.go index ebfcba655c..143c323894 100644 --- a/x/evm/types/logs_test.go +++ b/x/evm/types/logs_test.go @@ -5,7 +5,7 @@ import ( "github.com/stretchr/testify/require" - "github.com/tharsis/ethermint/tests" + "github.com/evmos/ethermint/tests" "github.com/ethereum/go-ethereum/common" ) diff --git a/x/evm/types/msg.go b/x/evm/types/msg.go index 7cec50c944..8bd40f5f4c 100644 --- a/x/evm/types/msg.go +++ b/x/evm/types/msg.go @@ -14,7 +14,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/auth/signing" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" - "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/types" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core" diff --git a/x/evm/types/msg_test.go b/x/evm/types/msg_test.go index dba487ef72..2bc02bdb25 100644 --- a/x/evm/types/msg_test.go +++ b/x/evm/types/msg_test.go @@ -12,16 +12,16 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/crypto/keyring" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/tests" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/tests" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" - "github.com/tharsis/ethermint/app" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/x/evm/types" + "github.com/evmos/ethermint/app" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/x/evm/types" ) const invalidFromAddress = "0x0000" diff --git a/x/evm/types/params.go b/x/evm/types/params.go index eb798e85e0..d7fe8c8837 100644 --- a/x/evm/types/params.go +++ b/x/evm/types/params.go @@ -9,7 +9,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" "github.com/ethereum/go-ethereum/core/vm" - "github.com/tharsis/ethermint/types" + "github.com/evmos/ethermint/types" ) var _ paramtypes.ParamSet = &Params{} diff --git a/x/evm/types/utils_test.go b/x/evm/types/utils_test.go index d3ec00e565..3804288f88 100644 --- a/x/evm/types/utils_test.go +++ b/x/evm/types/utils_test.go @@ -8,10 +8,10 @@ import ( "github.com/cosmos/cosmos-sdk/client" sdk "github.com/cosmos/cosmos-sdk/types" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" + "github.com/evmos/ethermint/app" + "github.com/evmos/ethermint/encoding" + evmtypes "github.com/evmos/ethermint/x/evm/types" proto "github.com/gogo/protobuf/proto" - "github.com/tharsis/ethermint/app" - "github.com/tharsis/ethermint/encoding" - evmtypes "github.com/tharsis/ethermint/x/evm/types" "github.com/stretchr/testify/require" diff --git a/x/feemarket/client/cli/query.go b/x/feemarket/client/cli/query.go index db51c1f0a7..8bbc50add3 100644 --- a/x/feemarket/client/cli/query.go +++ b/x/feemarket/client/cli/query.go @@ -12,7 +12,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" grpctypes "github.com/cosmos/cosmos-sdk/types/grpc" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/types" ) // GetQueryCmd returns the parent command for all x/feemarket CLI query commands. diff --git a/x/feemarket/genesis.go b/x/feemarket/genesis.go index 295789d56f..90cc1432c0 100644 --- a/x/feemarket/genesis.go +++ b/x/feemarket/genesis.go @@ -4,8 +4,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" abci "github.com/tendermint/tendermint/abci/types" - "github.com/tharsis/ethermint/x/feemarket/keeper" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/keeper" + "github.com/evmos/ethermint/x/feemarket/types" ) // InitGenesis initializes genesis state based on exported genesis diff --git a/x/feemarket/keeper/abci.go b/x/feemarket/keeper/abci.go index c76932ee34..cb23e77a7f 100644 --- a/x/feemarket/keeper/abci.go +++ b/x/feemarket/keeper/abci.go @@ -3,8 +3,8 @@ package keeper import ( "fmt" + "github.com/evmos/ethermint/x/feemarket/types" abci "github.com/tendermint/tendermint/abci/types" - "github.com/tharsis/ethermint/x/feemarket/types" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" @@ -49,7 +49,7 @@ func (k *Keeper) EndBlock(ctx sdk.Context, req abci.RequestEndBlock) { // to prevent BaseFee manipulation we limit the gasWanted so that // gasWanted = max(gasWanted * MinGasMultiplier, gasUsed) // this will be keep BaseFee protected from un-penalized manipulation - // more info here https://github.com/tharsis/ethermint/pull/1105#discussion_r888798925 + // more info here https://github.com/evmos/ethermint/pull/1105#discussion_r888798925 minGasMultiplier := k.GetParams(ctx).MinGasMultiplier limitedGasWanted := sdk.NewDec(int64(gasWanted)).Mul(minGasMultiplier) gasWanted = sdk.MaxDec(limitedGasWanted, sdk.NewDec(int64(gasUsed))).TruncateInt().Uint64() diff --git a/x/feemarket/keeper/grpc_query.go b/x/feemarket/keeper/grpc_query.go index d86e0fc9b7..96c21a0075 100644 --- a/x/feemarket/keeper/grpc_query.go +++ b/x/feemarket/keeper/grpc_query.go @@ -5,7 +5,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/types" ) var _ types.QueryServer = Keeper{} diff --git a/x/feemarket/keeper/grpc_query_test.go b/x/feemarket/keeper/grpc_query_test.go index e2a7006e53..2f7c8fa571 100644 --- a/x/feemarket/keeper/grpc_query_test.go +++ b/x/feemarket/keeper/grpc_query_test.go @@ -3,7 +3,7 @@ package keeper_test import ( sdk "github.com/cosmos/cosmos-sdk/types" ethparams "github.com/ethereum/go-ethereum/params" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/types" ) func (suite *KeeperTestSuite) TestQueryParams() { diff --git a/x/feemarket/keeper/integration_test.go b/x/feemarket/keeper/integration_test.go index 1ad9486dc4..1d79f45701 100644 --- a/x/feemarket/keeper/integration_test.go +++ b/x/feemarket/keeper/integration_test.go @@ -17,19 +17,19 @@ import ( authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" - "github.com/tharsis/ethermint/app" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/tests" - "github.com/tharsis/ethermint/testutil" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/app" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/tests" + "github.com/evmos/ethermint/testutil" + "github.com/evmos/ethermint/x/feemarket/types" "github.com/cosmos/cosmos-sdk/simapp" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" abci "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/libs/log" dbm "github.com/tendermint/tm-db" - evmtypes "github.com/tharsis/ethermint/x/evm/types" ) var _ = Describe("Ethermint App min gas prices settings: ", func() { diff --git a/x/feemarket/keeper/keeper.go b/x/feemarket/keeper/keeper.go index c73aa1cf84..bae38bdfb0 100644 --- a/x/feemarket/keeper/keeper.go +++ b/x/feemarket/keeper/keeper.go @@ -6,7 +6,7 @@ import ( paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" "github.com/tendermint/tendermint/libs/log" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/types" ) // Keeper grants access to the Fee Market module state. diff --git a/x/feemarket/keeper/keeper_test.go b/x/feemarket/keeper/keeper_test.go index b66445ce90..daa7816758 100644 --- a/x/feemarket/keeper/keeper_test.go +++ b/x/feemarket/keeper/keeper_test.go @@ -21,13 +21,13 @@ import ( stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/tharsis/ethermint/app" - "github.com/tharsis/ethermint/crypto/ethsecp256k1" - "github.com/tharsis/ethermint/encoding" - "github.com/tharsis/ethermint/tests" - ethermint "github.com/tharsis/ethermint/types" - evmtypes "github.com/tharsis/ethermint/x/evm/types" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/app" + "github.com/evmos/ethermint/crypto/ethsecp256k1" + "github.com/evmos/ethermint/encoding" + "github.com/evmos/ethermint/tests" + ethermint "github.com/evmos/ethermint/types" + evmtypes "github.com/evmos/ethermint/x/evm/types" + "github.com/evmos/ethermint/x/feemarket/types" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" diff --git a/x/feemarket/keeper/migrations.go b/x/feemarket/keeper/migrations.go index ff5d3491bf..9a16c8d92d 100644 --- a/x/feemarket/keeper/migrations.go +++ b/x/feemarket/keeper/migrations.go @@ -3,8 +3,8 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - v010 "github.com/tharsis/ethermint/x/feemarket/migrations/v010" - v011 "github.com/tharsis/ethermint/x/feemarket/migrations/v011" + v010 "github.com/evmos/ethermint/x/feemarket/migrations/v010" + v011 "github.com/evmos/ethermint/x/feemarket/migrations/v011" ) // Migrator is a struct for handling in-place store migrations. diff --git a/x/feemarket/keeper/migrations_test.go b/x/feemarket/keeper/migrations_test.go index 9c7f8ff274..9dbf82480d 100644 --- a/x/feemarket/keeper/migrations_test.go +++ b/x/feemarket/keeper/migrations_test.go @@ -3,8 +3,8 @@ package keeper_test import ( "math/big" - "github.com/tharsis/ethermint/x/feemarket/keeper" - v010 "github.com/tharsis/ethermint/x/feemarket/migrations/v010" + "github.com/evmos/ethermint/x/feemarket/keeper" + v010 "github.com/evmos/ethermint/x/feemarket/migrations/v010" ) func (suite *KeeperTestSuite) TestMigration1To2() { diff --git a/x/feemarket/keeper/params.go b/x/feemarket/keeper/params.go index 5e7f2c62b0..1fb9e28f96 100644 --- a/x/feemarket/keeper/params.go +++ b/x/feemarket/keeper/params.go @@ -4,7 +4,7 @@ import ( "math/big" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/types" ) // GetParams returns the total set of fee market parameters. diff --git a/x/feemarket/keeper/params_test.go b/x/feemarket/keeper/params_test.go index 68decf1586..83543ec3d9 100644 --- a/x/feemarket/keeper/params_test.go +++ b/x/feemarket/keeper/params_test.go @@ -1,7 +1,7 @@ package keeper_test import ( - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/types" ) func (suite *KeeperTestSuite) TestSetGetParams() { diff --git a/x/feemarket/migrations/v010/migrate.go b/x/feemarket/migrations/v010/migrate.go index 6db1f55838..4584c3e3a7 100644 --- a/x/feemarket/migrations/v010/migrate.go +++ b/x/feemarket/migrations/v010/migrate.go @@ -6,8 +6,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/tharsis/ethermint/x/feemarket/migrations/v010/types" - v09types "github.com/tharsis/ethermint/x/feemarket/migrations/v09/types" + "github.com/evmos/ethermint/x/feemarket/migrations/v010/types" + v09types "github.com/evmos/ethermint/x/feemarket/migrations/v09/types" ) // KeyPrefixBaseFeeV1 is the base fee key prefix used in version 1 diff --git a/x/feemarket/migrations/v010/migrate_test.go b/x/feemarket/migrations/v010/migrate_test.go index f87d77290d..8d2bb70968 100644 --- a/x/feemarket/migrations/v010/migrate_test.go +++ b/x/feemarket/migrations/v010/migrate_test.go @@ -10,14 +10,14 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/tharsis/ethermint/encoding" + "github.com/evmos/ethermint/encoding" - "github.com/tharsis/ethermint/app" - feemarketkeeper "github.com/tharsis/ethermint/x/feemarket/keeper" - v010 "github.com/tharsis/ethermint/x/feemarket/migrations/v010" - v09types "github.com/tharsis/ethermint/x/feemarket/migrations/v09/types" - "github.com/tharsis/ethermint/x/feemarket/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/app" + feemarketkeeper "github.com/evmos/ethermint/x/feemarket/keeper" + v010 "github.com/evmos/ethermint/x/feemarket/migrations/v010" + v09types "github.com/evmos/ethermint/x/feemarket/migrations/v09/types" + "github.com/evmos/ethermint/x/feemarket/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" ) func TestMigrateStore(t *testing.T) { diff --git a/x/feemarket/migrations/v011/migrate.go b/x/feemarket/migrations/v011/migrate.go index dd574c0b9a..33b5a4b0c7 100644 --- a/x/feemarket/migrations/v011/migrate.go +++ b/x/feemarket/migrations/v011/migrate.go @@ -4,8 +4,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - v010types "github.com/tharsis/ethermint/x/feemarket/migrations/v010/types" - "github.com/tharsis/ethermint/x/feemarket/types" + v010types "github.com/evmos/ethermint/x/feemarket/migrations/v010/types" + "github.com/evmos/ethermint/x/feemarket/types" ) // MigrateStore adds the MinGasPrice param with a value of 0 diff --git a/x/feemarket/migrations/v011/migrate_test.go b/x/feemarket/migrations/v011/migrate_test.go index 90da16d12d..727eb32414 100644 --- a/x/feemarket/migrations/v011/migrate_test.go +++ b/x/feemarket/migrations/v011/migrate_test.go @@ -10,13 +10,13 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/tharsis/ethermint/encoding" + "github.com/evmos/ethermint/encoding" - "github.com/tharsis/ethermint/app" - v010types "github.com/tharsis/ethermint/x/feemarket/migrations/v010/types" - v011 "github.com/tharsis/ethermint/x/feemarket/migrations/v011" - "github.com/tharsis/ethermint/x/feemarket/types" - feemarkettypes "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/app" + v010types "github.com/evmos/ethermint/x/feemarket/migrations/v010/types" + v011 "github.com/evmos/ethermint/x/feemarket/migrations/v011" + "github.com/evmos/ethermint/x/feemarket/types" + feemarkettypes "github.com/evmos/ethermint/x/feemarket/types" ) func init() { diff --git a/x/feemarket/module.go b/x/feemarket/module.go index c1757189a4..078eaecb07 100644 --- a/x/feemarket/module.go +++ b/x/feemarket/module.go @@ -19,10 +19,10 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/tharsis/ethermint/x/feemarket/client/cli" - "github.com/tharsis/ethermint/x/feemarket/keeper" - "github.com/tharsis/ethermint/x/feemarket/simulation" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/client/cli" + "github.com/evmos/ethermint/x/feemarket/keeper" + "github.com/evmos/ethermint/x/feemarket/simulation" + "github.com/evmos/ethermint/x/feemarket/types" ) var ( diff --git a/x/feemarket/simulation/genesis.go b/x/feemarket/simulation/genesis.go index 0266683c00..bae2c26d9e 100644 --- a/x/feemarket/simulation/genesis.go +++ b/x/feemarket/simulation/genesis.go @@ -7,7 +7,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/tharsis/ethermint/x/feemarket/types" + "github.com/evmos/ethermint/x/feemarket/types" ) // RandomizedGenState generates a random GenesisState for nft From ac6959864f4a863518cca4d94a87590f1eab1e96 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Fri, 29 Jul 2022 16:00:16 -0600 Subject: [PATCH 03/19] local optimint --- go.mod | 2 ++ 1 file changed, 2 insertions(+) diff --git a/go.mod b/go.mod index 8e5c62593e..d7e84a4da9 100644 --- a/go.mod +++ b/go.mod @@ -268,3 +268,5 @@ replace ( github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 google.golang.org/grpc => google.golang.org/grpc v1.33.2 ) + +replace github.com/celestiaorg/optimint => ./optimint From 07caf2abeeaab084a49a90c19b637ad73f2b7cf2 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Sun, 31 Jul 2022 14:23:58 -0600 Subject: [PATCH 04/19] mod --- go.mod | 16 ++++++++-------- go.sum | 39 +++++++++++++++++++++++---------------- 2 files changed, 31 insertions(+), 24 deletions(-) diff --git a/go.mod b/go.mod index d7e84a4da9..c034d6683c 100644 --- a/go.mod +++ b/go.mod @@ -10,7 +10,7 @@ require ( github.com/cosmos/go-bip39 v1.0.0 github.com/cosmos/ibc-go/v3 v3.1.0 github.com/davecgh/go-spew v1.1.1 - github.com/ethereum/go-ethereum v1.10.19 + github.com/ethereum/go-ethereum v1.10.21 github.com/gogo/protobuf v1.3.3 github.com/golang/protobuf v1.5.2 github.com/gorilla/mux v1.8.0 @@ -29,7 +29,7 @@ require ( github.com/spf13/cobra v1.5.0 github.com/spf13/viper v1.12.0 github.com/status-im/keycard-go v0.0.0-20200402102358-957c09536969 - github.com/stretchr/testify v1.7.5 + github.com/stretchr/testify v1.8.0 github.com/tendermint/tendermint v0.34.20-0.20220517115723-e6f071164839 github.com/tendermint/tm-db v0.6.7 github.com/tyler-smith/go-bip39 v1.1.0 @@ -76,7 +76,7 @@ require ( github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect github.com/dgraph-io/badger/v2 v2.2007.2 // indirect github.com/dgraph-io/badger/v3 v3.2103.2 // indirect - github.com/dgraph-io/ristretto v0.1.0 // indirect + github.com/dgraph-io/ristretto v0.1.1-0.20210901224026-c2901dc76889 // indirect github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91 // indirect github.com/docker/go-units v0.4.0 // indirect @@ -101,7 +101,7 @@ require ( github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/godbus/dbus/v5 v5.1.0 // indirect github.com/gogo/gateway v1.1.0 // indirect - github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b // indirect + github.com/golang/glog v1.0.0 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/snappy v0.0.4 // indirect github.com/google/btree v1.0.1 // indirect @@ -157,7 +157,7 @@ require ( github.com/libp2p/go-libp2p-noise v0.4.0 // indirect github.com/libp2p/go-libp2p-peerstore v0.6.0 // indirect github.com/libp2p/go-libp2p-pnet v0.2.0 // indirect - github.com/libp2p/go-libp2p-pubsub v0.7.0 // indirect + github.com/libp2p/go-libp2p-pubsub v0.7.1 // indirect github.com/libp2p/go-libp2p-quic-transport v0.17.0 // indirect github.com/libp2p/go-libp2p-record v0.1.3 // indirect github.com/libp2p/go-libp2p-resource-manager v0.2.1 // indirect @@ -196,7 +196,7 @@ require ( github.com/mtibben/percent v0.2.1 // indirect github.com/multiformats/go-base32 v0.0.4 // indirect github.com/multiformats/go-base36 v0.1.0 // indirect - github.com/multiformats/go-multiaddr v0.5.0 // indirect + github.com/multiformats/go-multiaddr v0.6.0 // indirect github.com/multiformats/go-multiaddr-dns v0.3.1 // indirect github.com/multiformats/go-multiaddr-fmt v0.1.0 // indirect github.com/multiformats/go-multibase v0.0.3 // indirect @@ -249,9 +249,9 @@ require ( go.uber.org/zap v1.21.0 // indirect golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d // indirect golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3 // indirect - golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2 // indirect + golang.org/x/net v0.0.0-20220607020251-c690dde0001d // indirect golang.org/x/sync v0.0.0-20220513210516-0976fa681c29 // indirect - golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a // indirect + golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c // indirect golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 // indirect golang.org/x/tools v0.1.10 // indirect golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df // indirect diff --git a/go.sum b/go.sum index d9ae4f9137..222b5af33d 100644 --- a/go.sum +++ b/go.sum @@ -221,8 +221,6 @@ github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n github.com/casbin/casbin/v2 v2.37.0/go.mod h1:vByNa/Fchek0KZUgG5wEsl7iFsiviAYKRtgrQfcJqHg= github.com/celestiaorg/go-cnc v0.1.0 h1:u986OnTc7AtbUZ4reY+zRCiar4fDdR1KehyP78uwsXg= github.com/celestiaorg/go-cnc v0.1.0/go.mod h1:Zf03bWWq6aldv5cYEaWvJ+I+z34bT/exrS0tO0y/jN8= -github.com/celestiaorg/optimint v0.3.2 h1:v4ZVxivSaiEBlFi6oAxh5njLrjOFy0Xmm9LeVm2a6rI= -github.com/celestiaorg/optimint v0.3.2/go.mod h1:FfwVphwJ/hwAWAxynrN52FODcrWbC2hf0fVWRaSO/Pw= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= github.com/cenkalti/backoff/v4 v4.1.1 h1:G2HAfAmvm/GcKan2oOQpBXOd2tT2G57ZnZGWa1PxPBQ= @@ -301,10 +299,12 @@ github.com/cosmos/ledger-cosmos-go v0.11.1 h1:9JIYsGnXP613pb2vPjFeMMjBI5lEDsEaF6 github.com/cosmos/ledger-cosmos-go v0.11.1/go.mod h1:J8//BsAGTo3OC/vDLjMRFLW6q0WAaXvHnVc7ZmE8iUY= github.com/cosmos/ledger-go v0.9.2 h1:Nnao/dLwaVTk1Q5U9THldpUMMXU94BOTWPddSmVB6pI= github.com/cosmos/ledger-go v0.9.2/go.mod h1:oZJ2hHAZROdlHiwTg4t7kP+GKIIkBT+o6c9QWFanOyI= +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-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= @@ -340,8 +340,9 @@ github.com/dgraph-io/badger/v3 v3.2103.2/go.mod h1:RHo4/GmYcKKh5Lxu63wLEMHJ70Pac github.com/dgraph-io/ristretto v0.0.2/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= github.com/dgraph-io/ristretto v0.0.3-0.20200630154024-f66de99634de/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= github.com/dgraph-io/ristretto v0.0.3/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= -github.com/dgraph-io/ristretto v0.1.0 h1:Jv3CGQHp9OjuMBSne1485aDpUkTKEcUqF+jm/LuerPI= github.com/dgraph-io/ristretto v0.1.0/go.mod h1:fux0lOrBhrVCJd3lcTHsIJhq1T2rokOu6v9Vcb3Q9ug= +github.com/dgraph-io/ristretto v0.1.1-0.20210901224026-c2901dc76889 h1:X4757+QSn4tJTO6+dTzxtbeN4xoParuWLjnVjhUoR2g= +github.com/dgraph-io/ristretto v0.1.1-0.20210901224026-c2901dc76889/go.mod h1:fux0lOrBhrVCJd3lcTHsIJhq1T2rokOu6v9Vcb3Q9ug= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/dgryski/go-bitstream v0.0.0-20180413035011-3522498ce2c8/go.mod h1:VMaSuZ+SZcx/wljOQKvp5srsbCiKDEb6K2wC4+PiBmQ= github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= @@ -381,8 +382,8 @@ github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1m github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/ethereum/go-ethereum v1.9.25/go.mod h1:vMkFiYLHI4tgPw4k2j4MHKoovchFE8plZ0M9VMk4/oM= github.com/ethereum/go-ethereum v1.10.4/go.mod h1:nEE0TP5MtxGzOMd7egIrbPJMQBnhVU3ELNxhBglIzhg= -github.com/ethereum/go-ethereum v1.10.19 h1:EOR5JbL4MD5yeOqv8W2iC1s4NximrTjqFccUz8lyBRA= -github.com/ethereum/go-ethereum v1.10.19/go.mod h1:IJBNMtzKcNHPtllYihy6BL2IgK1u+32JriaTbdt4v+w= +github.com/ethereum/go-ethereum v1.10.21 h1:5lqsEx92ZaZzRyOqBEXux4/UR06m296RGzN3ol3teJY= +github.com/ethereum/go-ethereum v1.10.21/go.mod h1:EYFyF19u3ezGLD4RqOkLq+ZCXzYbLoNDdZlMt7kyKFg= github.com/facebookgo/ensure v0.0.0-20160127193407-b4ab57deab51/go.mod h1:Yg+htXGokKKdzcwhuNDwVvN+uBxDGXJ7G/VN1d8fa64= github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c h1:8ISkoahWXwZR41ois5lSJBSVw4D0OV19Ht/JSTzvSv0= github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 h1:JWuenKqqX8nojtoVVWjGfOF9635RETekkoH6Cc9SX0A= @@ -495,8 +496,9 @@ github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2V github.com/golang-sql/sqlexp v0.0.0-20170517235910-f1bb20e5a188/go.mod h1:vXjM/+wXQnTPR4KqTKDgJukSZ6amVRtWMPEjE6sQoK8= github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= github.com/golang/geo v0.0.0-20190916061304-5b978397cfec/go.mod h1:QZ0nwyI2jOfgRAoBvP+ab5aRr7c9x7lhGEJrKvBwjWI= -github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= +github.com/golang/glog v1.0.0 h1:nfP3RFugxnNRyKgeWd4oI1nYvXpxrx8ck8ZrcizshdQ= +github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -940,8 +942,8 @@ github.com/libp2p/go-libp2p-peerstore v0.6.0 h1:HJminhQSGISBIRb93N6WK3t6Fa8OOTnH github.com/libp2p/go-libp2p-peerstore v0.6.0/go.mod h1:DGEmKdXrcYpK9Jha3sS7MhqYdInxJy84bIPtSu65bKc= github.com/libp2p/go-libp2p-pnet v0.2.0 h1:J6htxttBipJujEjz1y0a5+eYoiPcFHhSYHH6na5f0/k= github.com/libp2p/go-libp2p-pnet v0.2.0/go.mod h1:Qqvq6JH/oMZGwqs3N1Fqhv8NVhrdYcO0BW4wssv21LA= -github.com/libp2p/go-libp2p-pubsub v0.7.0 h1:Fd9198JVc3pCsKuzd37TclzM0QcHA+uDyoiG2pvT7s4= -github.com/libp2p/go-libp2p-pubsub v0.7.0/go.mod h1:EuyBJFtF8qF67IEA98biwK8Xnw5MNJpJ/Z+8iWCMFwc= +github.com/libp2p/go-libp2p-pubsub v0.7.1 h1:e2CPBP5uxvDkE0FiS0obZGZPzt+xuBOc6PpG+50pIAo= +github.com/libp2p/go-libp2p-pubsub v0.7.1/go.mod h1:EuyBJFtF8qF67IEA98biwK8Xnw5MNJpJ/Z+8iWCMFwc= github.com/libp2p/go-libp2p-quic-transport v0.13.0/go.mod h1:39/ZWJ1TW/jx1iFkKzzUg00W6tDJh73FC0xYudjr7Hc= github.com/libp2p/go-libp2p-quic-transport v0.16.0/go.mod h1:1BXjVMzr+w7EkPfiHkKnwsWjPjtfaNT0q8RS3tGDvEQ= github.com/libp2p/go-libp2p-quic-transport v0.16.1/go.mod h1:1BXjVMzr+w7EkPfiHkKnwsWjPjtfaNT0q8RS3tGDvEQ= @@ -1162,8 +1164,9 @@ github.com/multiformats/go-multiaddr v0.3.1/go.mod h1:uPbspcUPd5AfaP6ql3ujFY+QWz github.com/multiformats/go-multiaddr v0.3.3/go.mod h1:lCKNGP1EQ1eZ35Za2wlqnabm9xQkib3fyB+nZXHLag0= github.com/multiformats/go-multiaddr v0.4.0/go.mod h1:YcpyLH8ZPudLxQlemYBPhSm0/oCXAT8Z4mzFpyoPyRc= github.com/multiformats/go-multiaddr v0.4.1/go.mod h1:3afI9HfVW8csiF8UZqtpYRiDyew8pRX7qLIGHu9FLuM= -github.com/multiformats/go-multiaddr v0.5.0 h1:i/JuOoVg4szYQ4YEzDGtb2h0o8M7CG/Yq6cGlcjWZpM= github.com/multiformats/go-multiaddr v0.5.0/go.mod h1:3KAxNkUqLTJ20AAwN4XVX4kZar+bR+gh4zgbfr3SNug= +github.com/multiformats/go-multiaddr v0.6.0 h1:qMnoOPj2s8xxPU5kZ57Cqdr0hHhARz7mFsPMIiYNqzg= +github.com/multiformats/go-multiaddr v0.6.0/go.mod h1:F4IpaKZuPP360tOMn2Tpyu0At8w23aRyVqeK0DbFeGM= github.com/multiformats/go-multiaddr-dns v0.3.1 h1:QgQgR+LQVt3NPTjbrLLpsaT2ufAA2y0Mkk+QRVJbW3A= github.com/multiformats/go-multiaddr-dns v0.3.1/go.mod h1:G/245BRQ6FJGmryJCrOuTdB37AMA5AMOVuO6NY3JwTk= github.com/multiformats/go-multiaddr-fmt v0.1.0 h1:WLEFClPycPkp4fnIzoFoV9FVd49/eQsuaL3/CWe167E= @@ -1406,8 +1409,10 @@ github.com/rs/xhandler v0.0.0-20160618193221-ed27b6fd6521/go.mod h1:RvLn4FgxWubr github.com/rs/xid v1.3.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/zerolog v1.26.0 h1:ORM4ibhEZeTeQlCojCK2kPz1ogAY4bGs4tD+SaAdGaE= github.com/rs/zerolog v1.26.0/go.mod h1:yBiM87lvSqX8h0Ww4sdzNSkVYZ8dL2xjZJG1lAuGZEo= +github.com/russross/blackfriday v1.5.2 h1:HyvC0ARfnZBqnXwABFeSZHpKvJHJJfPz81GNueLj0oo= github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/sagikazarmark/crypt v0.5.0/go.mod h1:l+nzl7KWh51rpzp2h7t4MZWyiEWdhNpOAnclKvg+mdA= @@ -1521,8 +1526,8 @@ github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5 github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.5 h1:s5PTfem8p8EbKQOctVV53k6jCJt3UX4IEJzwh+C324Q= -github.com/stretchr/testify v1.7.5/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= +github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk= +github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/subosito/gotenv v1.3.0 h1:mjC+YW8QpAdXibNi+vNWgzmgBH4+5l5dCXv8cNysBLI= github.com/subosito/gotenv v1.3.0/go.mod h1:YzJjq/33h7nrwdY+iHMhEOEEbW0ovIz0tB6t6PwAXzs= @@ -1576,8 +1581,10 @@ github.com/ugorji/go/codec v1.1.7 h1:2SvQaVZ1ouYrrKKwoSk2pzd4A9evlKJb9oTL+OaLUSs github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= +github.com/urfave/cli v1.22.2 h1:gsqYFH8bb9ekPA12kRo0hfjngWQjkJPlN9R0N78BoUo= github.com/urfave/cli v1.22.2/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli/v2 v2.3.0/go.mod h1:LJmUH05zAU44vOAcrfzZQKsZbVcdbOG8rtL3/XcUArI= +github.com/urfave/cli/v2 v2.10.2 h1:x3p8awjp/2arX+Nl/G2040AZpOCHS/eMJJ1/a+mye4Y= github.com/viant/assertly v0.4.8/go.mod h1:aGifi++jvCrUaklKEKT0BU95igDNaqkvz+49uaYMPRU= github.com/viant/toolbox v0.24.0/go.mod h1:OxMCG57V0PXuIP2HNQrtJf2CjqdmbrOx5EkMILuUhzM= github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE= @@ -1602,6 +1609,7 @@ github.com/x-cray/logrus-prefixed-formatter v0.5.2/go.mod h1:2duySbKsL6M18s5GU7V github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/xlab/treeprint v0.0.0-20180616005107-d6fb6747feb6/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg= github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= +github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRTfdpNzjtPYqr8smhKouy9mxVdGPU= github.com/ybbus/jsonrpc v2.1.2+incompatible/go.mod h1:XJrh1eMSzdIYFbM08flv0wp5G35eRniyeGut1z+LSiE= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -1831,8 +1839,8 @@ golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220517181318-183a9ca12b87/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2 h1:NWy5+hlRbC7HK+PmcXVUmW1IMyFce7to56IUvhUFm7Y= -golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220607020251-c690dde0001d h1:4SFsTMi4UahlKoloni7L4eYzhFRifURQLw+yv0QDCx8= +golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20181017192945-9dcd33a902f4/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20181203162652-d668ce993890/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= @@ -1994,8 +2002,8 @@ golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220517195934-5e4e11fc645e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a h1:dGzPydgVsqGcTRVwiLJ1jVbufYwmzD3LfVPLKsKg+0k= -golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c h1:aFV+BgZ4svzjfabn8ERpuB4JI4N6/rdy1iusx77G3oU= +golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 h1:JGgROgKl9N8DuW20oFS5gxc+lE67/N3FcwmBPMe7ArY= @@ -2280,7 +2288,6 @@ gopkg.in/src-d/go-cli.v0 v0.0.0-20181105080154-d492247bbc0d/go.mod h1:z+K8VcOYVY gopkg.in/src-d/go-log.v1 v1.0.1/go.mod h1:GN34hKP0g305ysm2/hctJ0Y8nWP3zxXXJ8GFabTyABE= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/urfave/cli.v1 v1.20.0 h1:NdAVW6RYxDif9DhDHaAortIu956m2c0v+09AZBPTbE0= gopkg.in/urfave/cli.v1 v1.20.0/go.mod h1:vuBzUtMdQeixQj8LVd+/98pzhxNGQoyuPBlsXHOQNO0= gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= From aeb3fb01429927bd1d289ce57f3ce78c0d9fb88d Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Mon, 1 Aug 2022 12:19:56 -0600 Subject: [PATCH 05/19] hash=eth_hash and add tm_hash --- rpc/backend/evm_backend.go | 18 ++++++++++++++++++ rpc/types/utils.go | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 925774b3a6..9ce24e3832 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -305,6 +305,24 @@ func (b *Backend) EthBlockFromTendermint( gasLimit, new(big.Int).SetUint64(gasUsed), ethRPCTxs, bloom, validatorAddr, baseFee, ) + + blockJson, err := json.Marshal(formattedBlock) + if err != nil { + return nil, err + } + b.logger.Info("headerJson", "headerJson", string(blockJson)) + var ethHeader ethtypes.Header + err = json.Unmarshal(blockJson, ðHeader) + if err != nil { + return nil, err + } + b.logger.Info("ethHeader", "ethHeader", ethHeader) + + ethHash := ethHeader.Hash() + b.logger.Info("ethHash", "ethHash", ethHash) + + formattedBlock["hash"] = ethHash + return formattedBlock, nil } diff --git a/rpc/types/utils.go b/rpc/types/utils.go index 15da24489a..7335564960 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -101,7 +101,7 @@ func FormatBlock( result := map[string]interface{}{ "number": hexutil.Uint64(header.Height), - "hash": hexutil.Bytes(header.Hash()), + "tm_hash": hexutil.Bytes(header.Hash()), "parentHash": common.BytesToHash(header.LastBlockID.Hash.Bytes()), "nonce": ethtypes.BlockNonce{}, // PoW specific "sha3Uncles": ethtypes.EmptyUncleHash, // No uncles in Tendermint From b8890e00314781586fd08245257a260b8c35768a Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Mon, 1 Aug 2022 12:59:49 -0600 Subject: [PATCH 06/19] modify getTransactionReceipt to use eth hash --- rpc/backend/backend.go | 2 ++ rpc/namespaces/ethereum/eth/api.go | 9 ++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/rpc/backend/backend.go b/rpc/backend/backend.go index 4736568745..2abf3a086f 100644 --- a/rpc/backend/backend.go +++ b/rpc/backend/backend.go @@ -80,6 +80,8 @@ type EVMBackend interface { ChainConfig() *params.ChainConfig SetTxDefaults(args evmtypes.TransactionArgs) (evmtypes.TransactionArgs, error) GetEthereumMsgsFromTendermintBlock(block *tmrpctypes.ResultBlock, blockRes *tmrpctypes.ResultBlockResults) []*evmtypes.MsgEthereumTx + + EthBlockFromTendermint(resBlock *tmrpctypes.ResultBlock, fullTx bool) (map[string]interface{}, error) } var _ BackendI = (*Backend)(nil) diff --git a/rpc/namespaces/ethereum/eth/api.go b/rpc/namespaces/ethereum/eth/api.go index ed11f08e37..4fc70e967c 100644 --- a/rpc/namespaces/ethereum/eth/api.go +++ b/rpc/namespaces/ethereum/eth/api.go @@ -872,6 +872,12 @@ func (e *PublicAPI) GetTransactionReceipt(hash common.Hash) (map[string]interfac return nil, nil } + ethBlock, err := e.backend.EthBlockFromTendermint(resBlock, true) + if err != nil { + e.logger.Debug("ethBlock not found", "height", res.Height, "error", err.Error()) + return nil, nil + } + tx, err := e.clientCtx.TxConfig.TxDecoder()(res.Tx) if err != nil { e.logger.Debug("decoding failed", "error", err.Error()) @@ -957,7 +963,8 @@ func (e *PublicAPI) GetTransactionReceipt(hash common.Hash) (map[string]interfac // Inclusion information: These fields provide information about the inclusion of the // transaction corresponding to this receipt. - "blockHash": common.BytesToHash(resBlock.Block.Header.Hash()).Hex(), + "blockHash": ethBlock["hash"], + // "blockHash": common.BytesToHash(resBlock.Block.Header.Hash()).Hex(), "blockNumber": hexutil.Uint64(res.Height), "transactionIndex": hexutil.Uint64(parsedTx.EthTxIndex), From ae3207925bb519c4bf8dd7ee9cb5546b318e2d45 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Tue, 2 Aug 2022 15:21:22 -0600 Subject: [PATCH 07/19] logging proposer --- rpc/backend/evm_backend.go | 1 + 1 file changed, 1 insertion(+) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 9ce24e3832..58f7bd57b4 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -261,6 +261,7 @@ func (b *Backend) EthBlockFromTendermint( b.logger.Debug("failed to query BlockBloom", "height", block.Height, "error", err.Error()) } + b.logger.Info("ProposerAddress", "block.Header.ProposerAddress", block.Header.ProposerAddress) req := &evmtypes.QueryValidatorAccountRequest{ ConsAddress: sdk.ConsAddress(block.Header.ProposerAddress).String(), } From 2d6260a70e9ae640cdaa2f7da2d0a33d81cfdc90 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Tue, 2 Aug 2022 15:35:10 -0600 Subject: [PATCH 08/19] use proposer in header --- rpc/backend/evm_backend.go | 44 +++++++++++++++++++------------------- rpc/types/utils.go | 4 ++-- 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 58f7bd57b4..fe80b37edd 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -261,29 +261,29 @@ func (b *Backend) EthBlockFromTendermint( b.logger.Debug("failed to query BlockBloom", "height", block.Height, "error", err.Error()) } - b.logger.Info("ProposerAddress", "block.Header.ProposerAddress", block.Header.ProposerAddress) - req := &evmtypes.QueryValidatorAccountRequest{ - ConsAddress: sdk.ConsAddress(block.Header.ProposerAddress).String(), - } + // b.logger.Info("ProposerAddress", "block.Header.ProposerAddress", block.Header.ProposerAddress) + // req := &evmtypes.QueryValidatorAccountRequest{ + // ConsAddress: sdk.ConsAddress(block.Header.ProposerAddress).String(), + // } ctx := types.ContextWithHeight(block.Height) - res, err := b.queryClient.ValidatorAccount(ctx, req) - if err != nil { - b.logger.Debug( - "failed to query validator operator address", - "height", block.Height, - "cons-address", req.ConsAddress, - "error", err.Error(), - ) - return nil, err - } - - addr, err := sdk.AccAddressFromBech32(res.AccountAddress) - if err != nil { - return nil, err - } - - validatorAddr := common.BytesToAddress(addr) + // res, err := b.queryClient.ValidatorAccount(ctx, req) + // if err != nil { + // b.logger.Debug( + // "failed to query validator operator address", + // "height", block.Height, + // "cons-address", req.ConsAddress, + // "error", err.Error(), + // ) + // return nil, err + // } + + // addr, err := sdk.AccAddressFromBech32(res.AccountAddress) + // if err != nil { + // return nil, err + // } + + // validatorAddr := common.BytesToAddress(addr) gasLimit, err := types.BlockMaxGasFromConsensusParams(ctx, b.clientCtx, block.Height) if err != nil { @@ -304,7 +304,7 @@ func (b *Backend) EthBlockFromTendermint( formattedBlock := types.FormatBlock( block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), - ethRPCTxs, bloom, validatorAddr, baseFee, + ethRPCTxs, bloom, baseFee, ) blockJson, err := json.Marshal(formattedBlock) diff --git a/rpc/types/utils.go b/rpc/types/utils.go index 7335564960..925c53b93a 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -90,7 +90,7 @@ func BlockMaxGasFromConsensusParams(goCtx context.Context, clientCtx client.Cont func FormatBlock( header tmtypes.Header, size int, gasLimit int64, gasUsed *big.Int, transactions []interface{}, bloom ethtypes.Bloom, - validatorAddr common.Address, baseFee *big.Int, + baseFee *big.Int, ) map[string]interface{} { var transactionsRoot common.Hash if len(transactions) == 0 { @@ -107,7 +107,7 @@ func FormatBlock( "sha3Uncles": ethtypes.EmptyUncleHash, // No uncles in Tendermint "logsBloom": bloom, "stateRoot": hexutil.Bytes(header.AppHash), - "miner": validatorAddr, + "miner": header.ProposerAddress, "mixHash": common.Hash{}, "difficulty": (*hexutil.Big)(big.NewInt(0)), "extraData": "0x", From d2907a991189f27821a69070dcd10c1e7887b8ee Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Tue, 2 Aug 2022 15:44:22 -0600 Subject: [PATCH 09/19] fix type --- rpc/types/utils.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpc/types/utils.go b/rpc/types/utils.go index 925c53b93a..456cce1b78 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -107,7 +107,7 @@ func FormatBlock( "sha3Uncles": ethtypes.EmptyUncleHash, // No uncles in Tendermint "logsBloom": bloom, "stateRoot": hexutil.Bytes(header.AppHash), - "miner": header.ProposerAddress, + "miner": common.BytesToAddress(header.ProposerAddress), "mixHash": common.Hash{}, "difficulty": (*hexutil.Big)(big.NewInt(0)), "extraData": "0x", From 43eacd0685771012df404b026b7eaf6543faf879 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Tue, 2 Aug 2022 17:31:21 -0600 Subject: [PATCH 10/19] log datahash --- rpc/backend/evm_backend.go | 1 + 1 file changed, 1 insertion(+) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index fe80b37edd..ad5436d187 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -222,6 +222,7 @@ func (b *Backend) EthBlockFromTendermint( ) (map[string]interface{}, error) { ethRPCTxs := []interface{}{} block := resBlock.Block + b.logger.Info("EthBlockFromTendermint", "block.DataHash", block.DataHash) baseFee, err := b.BaseFee(block.Height) if err != nil { From fce9d3c99d7e174dfa904208d43623f8cbe0b75d Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Tue, 2 Aug 2022 17:58:40 -0600 Subject: [PATCH 11/19] nil basefee --- rpc/backend/evm_backend.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index ad5436d187..4edd3d66df 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -305,7 +305,7 @@ func (b *Backend) EthBlockFromTendermint( formattedBlock := types.FormatBlock( block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), - ethRPCTxs, bloom, baseFee, + ethRPCTxs, bloom, nil, ) blockJson, err := json.Marshal(formattedBlock) From 868214b5c7fda092fa8f3bae83ee8667aebbfc93 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Tue, 2 Aug 2022 18:09:43 -0600 Subject: [PATCH 12/19] 0 not nil basefee --- rpc/backend/evm_backend.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 4edd3d66df..7cf7f23e50 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -305,7 +305,7 @@ func (b *Backend) EthBlockFromTendermint( formattedBlock := types.FormatBlock( block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), - ethRPCTxs, bloom, nil, + ethRPCTxs, bloom, big.NewInt(0), ) blockJson, err := json.Marshal(formattedBlock) From 730d53ef505d5fd3e67c2e82677f6aec3be5884e Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Wed, 3 Aug 2022 14:36:48 -0600 Subject: [PATCH 13/19] fix tx blockHash --- rpc/backend/evm_backend.go | 80 ++++++++++++++++---------------------- rpc/types/utils.go | 48 ++++++++++------------- 2 files changed, 54 insertions(+), 74 deletions(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 7cf7f23e50..de0254a388 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -234,57 +234,12 @@ func (b *Backend) EthBlockFromTendermint( return nil, err } - msgs := b.GetEthereumMsgsFromTendermintBlock(resBlock, resBlockResult) - for txIndex, ethMsg := range msgs { - if !fullTx { - hash := common.HexToHash(ethMsg.Hash) - ethRPCTxs = append(ethRPCTxs, hash) - continue - } - - tx := ethMsg.AsTransaction() - rpcTx, err := types.NewRPCTransaction( - tx, - common.BytesToHash(block.Hash()), - uint64(block.Height), - uint64(txIndex), - baseFee, - ) - if err != nil { - b.logger.Debug("NewTransactionFromData for receipt failed", "hash", tx.Hash().Hex(), "error", err.Error()) - continue - } - ethRPCTxs = append(ethRPCTxs, rpcTx) - } - bloom, err := b.BlockBloom(&block.Height) if err != nil { b.logger.Debug("failed to query BlockBloom", "height", block.Height, "error", err.Error()) } - // b.logger.Info("ProposerAddress", "block.Header.ProposerAddress", block.Header.ProposerAddress) - // req := &evmtypes.QueryValidatorAccountRequest{ - // ConsAddress: sdk.ConsAddress(block.Header.ProposerAddress).String(), - // } - ctx := types.ContextWithHeight(block.Height) - // res, err := b.queryClient.ValidatorAccount(ctx, req) - // if err != nil { - // b.logger.Debug( - // "failed to query validator operator address", - // "height", block.Height, - // "cons-address", req.ConsAddress, - // "error", err.Error(), - // ) - // return nil, err - // } - - // addr, err := sdk.AccAddressFromBech32(res.AccountAddress) - // if err != nil { - // return nil, err - // } - - // validatorAddr := common.BytesToAddress(addr) gasLimit, err := types.BlockMaxGasFromConsensusParams(ctx, b.clientCtx, block.Height) if err != nil { @@ -302,10 +257,11 @@ func (b *Backend) EthBlockFromTendermint( gasUsed += uint64(txsResult.GetGasUsed()) } + // TODO(jbowen93): Base Fee shouldn't be hardcoded to 0 formattedBlock := types.FormatBlock( block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), - ethRPCTxs, bloom, big.NewInt(0), + bloom, big.NewInt(0), ) blockJson, err := json.Marshal(formattedBlock) @@ -322,9 +278,39 @@ func (b *Backend) EthBlockFromTendermint( ethHash := ethHeader.Hash() b.logger.Info("ethHash", "ethHash", ethHash) - formattedBlock["hash"] = ethHash + msgs := b.GetEthereumMsgsFromTendermintBlock(resBlock, resBlockResult) + for txIndex, ethMsg := range msgs { + if !fullTx { + hash := common.HexToHash(ethMsg.Hash) + ethRPCTxs = append(ethRPCTxs, hash) + continue + } + + tx := ethMsg.AsTransaction() + rpcTx, err := types.NewRPCTransaction( + tx, + ethHash, + uint64(block.Height), + uint64(txIndex), + baseFee, + ) + if err != nil { + b.logger.Debug("NewTransactionFromData for receipt failed", "hash", tx.Hash().Hex(), "error", err.Error()) + continue + } + ethRPCTxs = append(ethRPCTxs, rpcTx) + } + transactionsRoot := common.Hash{} + if len(ethRPCTxs) == 0 { + transactionsRoot = ethtypes.EmptyRootHash + } else { + transactionsRoot = common.BytesToHash(block.Header.DataHash) + } + formattedBlock["transactions"] = ethRPCTxs + formattedBlock["transactionsRoot"] = transactionsRoot + return formattedBlock, nil } diff --git a/rpc/types/utils.go b/rpc/types/utils.go index 456cce1b78..045f527efb 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -89,37 +89,31 @@ func BlockMaxGasFromConsensusParams(goCtx context.Context, clientCtx client.Cont // transactions. func FormatBlock( header tmtypes.Header, size int, gasLimit int64, - gasUsed *big.Int, transactions []interface{}, bloom ethtypes.Bloom, + gasUsed *big.Int, bloom ethtypes.Bloom, baseFee *big.Int, ) map[string]interface{} { - var transactionsRoot common.Hash - if len(transactions) == 0 { - transactionsRoot = ethtypes.EmptyRootHash - } else { - transactionsRoot = common.BytesToHash(header.DataHash) - } result := map[string]interface{}{ - "number": hexutil.Uint64(header.Height), - "tm_hash": hexutil.Bytes(header.Hash()), - "parentHash": common.BytesToHash(header.LastBlockID.Hash.Bytes()), - "nonce": ethtypes.BlockNonce{}, // PoW specific - "sha3Uncles": ethtypes.EmptyUncleHash, // No uncles in Tendermint - "logsBloom": bloom, - "stateRoot": hexutil.Bytes(header.AppHash), - "miner": common.BytesToAddress(header.ProposerAddress), - "mixHash": common.Hash{}, - "difficulty": (*hexutil.Big)(big.NewInt(0)), - "extraData": "0x", - "size": hexutil.Uint64(size), - "gasLimit": hexutil.Uint64(gasLimit), // Static gas limit - "gasUsed": (*hexutil.Big)(gasUsed), - "timestamp": hexutil.Uint64(header.Time.Unix()), - "transactionsRoot": transactionsRoot, - "receiptsRoot": ethtypes.EmptyRootHash, - - "uncles": []common.Hash{}, - "transactions": transactions, + "number": hexutil.Uint64(header.Height), + "tm_hash": hexutil.Bytes(header.Hash()), + "parentHash": common.BytesToHash(header.LastBlockID.Hash.Bytes()), + "nonce": ethtypes.BlockNonce{}, // PoW specific + "sha3Uncles": ethtypes.EmptyUncleHash, // No uncles in Tendermint + "logsBloom": bloom, + "stateRoot": hexutil.Bytes(header.AppHash), + "miner": common.BytesToAddress(header.ProposerAddress), + "mixHash": common.Hash{}, + "difficulty": (*hexutil.Big)(big.NewInt(0)), + "extraData": "0x", + "size": hexutil.Uint64(size), + "gasLimit": hexutil.Uint64(gasLimit), // Static gas limit + "gasUsed": (*hexutil.Big)(gasUsed), + "timestamp": hexutil.Uint64(header.Time.Unix()), + // "transactionsRoot": transactionsRoot, + "receiptsRoot": ethtypes.EmptyRootHash, + + "uncles": []common.Hash{}, + // "transactions": transactions, "totalDifficulty": (*hexutil.Big)(big.NewInt(0)), } From 6e754aaae11ffe7cb7860ac306591d71da5e7f30 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Wed, 3 Aug 2022 14:52:56 -0600 Subject: [PATCH 14/19] 2nd try at tx --- rpc/backend/evm_backend.go | 12 +++------ rpc/types/utils.go | 50 ++++++++++++++++++++------------------ 2 files changed, 30 insertions(+), 32 deletions(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index de0254a388..56e32c8daa 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -241,6 +241,8 @@ func (b *Backend) EthBlockFromTendermint( ctx := types.ContextWithHeight(block.Height) + msgs := b.GetEthereumMsgsFromTendermintBlock(resBlock, resBlockResult) + gasLimit, err := types.BlockMaxGasFromConsensusParams(ctx, b.clientCtx, block.Height) if err != nil { b.logger.Error("failed to query consensus params", "error", err.Error()) @@ -261,7 +263,7 @@ func (b *Backend) EthBlockFromTendermint( formattedBlock := types.FormatBlock( block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), - bloom, big.NewInt(0), + bloom, msgs, big.NewInt(0), ) blockJson, err := json.Marshal(formattedBlock) @@ -280,7 +282,6 @@ func (b *Backend) EthBlockFromTendermint( b.logger.Info("ethHash", "ethHash", ethHash) formattedBlock["hash"] = ethHash - msgs := b.GetEthereumMsgsFromTendermintBlock(resBlock, resBlockResult) for txIndex, ethMsg := range msgs { if !fullTx { hash := common.HexToHash(ethMsg.Hash) @@ -302,14 +303,7 @@ func (b *Backend) EthBlockFromTendermint( } ethRPCTxs = append(ethRPCTxs, rpcTx) } - transactionsRoot := common.Hash{} - if len(ethRPCTxs) == 0 { - transactionsRoot = ethtypes.EmptyRootHash - } else { - transactionsRoot = common.BytesToHash(block.Header.DataHash) - } formattedBlock["transactions"] = ethRPCTxs - formattedBlock["transactionsRoot"] = transactionsRoot return formattedBlock, nil } diff --git a/rpc/types/utils.go b/rpc/types/utils.go index 045f527efb..2de2d356b4 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -89,32 +89,36 @@ func BlockMaxGasFromConsensusParams(goCtx context.Context, clientCtx client.Cont // transactions. func FormatBlock( header tmtypes.Header, size int, gasLimit int64, - gasUsed *big.Int, bloom ethtypes.Bloom, + gasUsed *big.Int, bloom ethtypes.Bloom, msgs []*evmtypes.MsgEthereumTx, baseFee *big.Int, ) map[string]interface{} { - + var transactionsRoot common.Hash + if len(msgs) == 0 { + transactionsRoot = ethtypes.EmptyRootHash + } else { + transactionsRoot = common.BytesToHash(header.DataHash) + } result := map[string]interface{}{ - "number": hexutil.Uint64(header.Height), - "tm_hash": hexutil.Bytes(header.Hash()), - "parentHash": common.BytesToHash(header.LastBlockID.Hash.Bytes()), - "nonce": ethtypes.BlockNonce{}, // PoW specific - "sha3Uncles": ethtypes.EmptyUncleHash, // No uncles in Tendermint - "logsBloom": bloom, - "stateRoot": hexutil.Bytes(header.AppHash), - "miner": common.BytesToAddress(header.ProposerAddress), - "mixHash": common.Hash{}, - "difficulty": (*hexutil.Big)(big.NewInt(0)), - "extraData": "0x", - "size": hexutil.Uint64(size), - "gasLimit": hexutil.Uint64(gasLimit), // Static gas limit - "gasUsed": (*hexutil.Big)(gasUsed), - "timestamp": hexutil.Uint64(header.Time.Unix()), - // "transactionsRoot": transactionsRoot, - "receiptsRoot": ethtypes.EmptyRootHash, - - "uncles": []common.Hash{}, - // "transactions": transactions, - "totalDifficulty": (*hexutil.Big)(big.NewInt(0)), + "number": hexutil.Uint64(header.Height), + "tm_hash": hexutil.Bytes(header.Hash()), + "parentHash": common.BytesToHash(header.LastBlockID.Hash.Bytes()), + "nonce": ethtypes.BlockNonce{}, // PoW specific + "sha3Uncles": ethtypes.EmptyUncleHash, // No uncles in Tendermint + "logsBloom": bloom, + "stateRoot": hexutil.Bytes(header.AppHash), + "miner": common.BytesToAddress(header.ProposerAddress), + "mixHash": common.Hash{}, + "difficulty": (*hexutil.Big)(big.NewInt(0)), + "extraData": "0x", + "size": hexutil.Uint64(size), + "gasLimit": hexutil.Uint64(gasLimit), // Static gas limit + "gasUsed": (*hexutil.Big)(gasUsed), + "timestamp": hexutil.Uint64(header.Time.Unix()), + "transactionsRoot": transactionsRoot, + "receiptsRoot": ethtypes.EmptyRootHash, + "uncles": []common.Hash{}, + "transactions": msgs, + "totalDifficulty": (*hexutil.Big)(big.NewInt(0)), } if baseFee != nil { From 8fe67bcc1eae6900dce9c3c6fc22ff4138310c2f Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Wed, 3 Aug 2022 15:25:44 -0600 Subject: [PATCH 15/19] fix bug --- rpc/backend/evm_backend.go | 30 +++++++++++++++--------------- rpc/types/utils.go | 15 +++++---------- 2 files changed, 20 insertions(+), 25 deletions(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 56e32c8daa..3a2d48c6c1 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -220,14 +220,15 @@ func (b *Backend) EthBlockFromTendermint( resBlock *tmrpctypes.ResultBlock, fullTx bool, ) (map[string]interface{}, error) { - ethRPCTxs := []interface{}{} block := resBlock.Block b.logger.Info("EthBlockFromTendermint", "block.DataHash", block.DataHash) - baseFee, err := b.BaseFee(block.Height) - if err != nil { - return nil, err - } + // TODO(jbowen93): Base Fee shouldn't be hardcoded to 0 + baseFee := big.NewInt(0) + // baseFee, err := b.BaseFee(block.Height) + // if err != nil { + // return nil, err + // } resBlockResult, err := b.clientCtx.Client.BlockResults(b.ctx, &block.Height) if err != nil { @@ -241,8 +242,6 @@ func (b *Backend) EthBlockFromTendermint( ctx := types.ContextWithHeight(block.Height) - msgs := b.GetEthereumMsgsFromTendermintBlock(resBlock, resBlockResult) - gasLimit, err := types.BlockMaxGasFromConsensusParams(ctx, b.clientCtx, block.Height) if err != nil { b.logger.Error("failed to query consensus params", "error", err.Error()) @@ -258,14 +257,14 @@ func (b *Backend) EthBlockFromTendermint( } gasUsed += uint64(txsResult.GetGasUsed()) } - - // TODO(jbowen93): Base Fee shouldn't be hardcoded to 0 - formattedBlock := types.FormatBlock( - block.Header, block.Size(), - gasLimit, new(big.Int).SetUint64(gasUsed), - bloom, msgs, big.NewInt(0), - ) - + msgs := b.GetEthereumMsgsFromTendermintBlock(resBlock, resBlockResult) + var transactionsRoot common.Hash + if len(msgs) == 0 { + transactionsRoot = ethtypes.EmptyRootHash + } else { + transactionsRoot = common.BytesToHash(block.Header.DataHash) + } + formattedBlock := types.FormatBlock(block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), bloom, transactionsRoot, baseFee) blockJson, err := json.Marshal(formattedBlock) if err != nil { return nil, err @@ -282,6 +281,7 @@ func (b *Backend) EthBlockFromTendermint( b.logger.Info("ethHash", "ethHash", ethHash) formattedBlock["hash"] = ethHash + ethRPCTxs := []interface{}{} for txIndex, ethMsg := range msgs { if !fullTx { hash := common.HexToHash(ethMsg.Hash) diff --git a/rpc/types/utils.go b/rpc/types/utils.go index 2de2d356b4..d013874433 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -89,15 +89,10 @@ func BlockMaxGasFromConsensusParams(goCtx context.Context, clientCtx client.Cont // transactions. func FormatBlock( header tmtypes.Header, size int, gasLimit int64, - gasUsed *big.Int, bloom ethtypes.Bloom, msgs []*evmtypes.MsgEthereumTx, + gasUsed *big.Int, bloom ethtypes.Bloom, txRoot common.Hash, baseFee *big.Int, ) map[string]interface{} { - var transactionsRoot common.Hash - if len(msgs) == 0 { - transactionsRoot = ethtypes.EmptyRootHash - } else { - transactionsRoot = common.BytesToHash(header.DataHash) - } + result := map[string]interface{}{ "number": hexutil.Uint64(header.Height), "tm_hash": hexutil.Bytes(header.Hash()), @@ -114,11 +109,11 @@ func FormatBlock( "gasLimit": hexutil.Uint64(gasLimit), // Static gas limit "gasUsed": (*hexutil.Big)(gasUsed), "timestamp": hexutil.Uint64(header.Time.Unix()), - "transactionsRoot": transactionsRoot, + "transactionsRoot": txRoot, "receiptsRoot": ethtypes.EmptyRootHash, "uncles": []common.Hash{}, - "transactions": msgs, - "totalDifficulty": (*hexutil.Big)(big.NewInt(0)), + // "transactions": txs, + "totalDifficulty": (*hexutil.Big)(big.NewInt(0)), } if baseFee != nil { From 68243021b7a87aa8f890397e385d56df5a821a6b Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Fri, 5 Aug 2022 19:02:44 -0600 Subject: [PATCH 16/19] tx --- rpc/backend/evm_backend.go | 19 +++++++++++++------ rpc/types/utils.go | 4 ++-- 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 3a2d48c6c1..3c958c0c0c 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -18,6 +18,7 @@ import ( ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/params" "github.com/ethereum/go-ethereum/rpc" + "github.com/ethereum/go-ethereum/trie" tmrpctypes "github.com/tendermint/tendermint/rpc/core/types" @@ -257,30 +258,35 @@ func (b *Backend) EthBlockFromTendermint( } gasUsed += uint64(txsResult.GetGasUsed()) } + msgs := b.GetEthereumMsgsFromTendermintBlock(resBlock, resBlockResult) + ethTxs := []*ethtypes.Transaction{} + for _, ethMsg := range msgs { + tx := ethMsg.AsTransaction() + ethTxs = append(ethTxs, tx) + } var transactionsRoot common.Hash if len(msgs) == 0 { transactionsRoot = ethtypes.EmptyRootHash } else { + hasher := trie.NewStackTrie(nil) + transactionsRoot = ethtypes.DeriveSha(ethtypes.Transactions(ethTxs), hasher) transactionsRoot = common.BytesToHash(block.Header.DataHash) } - formattedBlock := types.FormatBlock(block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), bloom, transactionsRoot, baseFee) + formattedBlock := types.FormatBlock(block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), bloom, baseFee) + blockJson, err := json.Marshal(formattedBlock) if err != nil { return nil, err } - b.logger.Info("headerJson", "headerJson", string(blockJson)) var ethHeader ethtypes.Header err = json.Unmarshal(blockJson, ðHeader) if err != nil { return nil, err } b.logger.Info("ethHeader", "ethHeader", ethHeader) - ethHash := ethHeader.Hash() b.logger.Info("ethHash", "ethHash", ethHash) - formattedBlock["hash"] = ethHash - ethRPCTxs := []interface{}{} for txIndex, ethMsg := range msgs { if !fullTx { @@ -303,8 +309,9 @@ func (b *Backend) EthBlockFromTendermint( } ethRPCTxs = append(ethRPCTxs, rpcTx) } + formattedBlock["hash"] = ethHash + formattedBlock["transactionsRoot"] = transactionsRoot formattedBlock["transactions"] = ethRPCTxs - return formattedBlock, nil } diff --git a/rpc/types/utils.go b/rpc/types/utils.go index d013874433..3aee6244a5 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -89,7 +89,7 @@ func BlockMaxGasFromConsensusParams(goCtx context.Context, clientCtx client.Cont // transactions. func FormatBlock( header tmtypes.Header, size int, gasLimit int64, - gasUsed *big.Int, bloom ethtypes.Bloom, txRoot common.Hash, + gasUsed *big.Int, bloom ethtypes.Bloom, baseFee *big.Int, ) map[string]interface{} { @@ -109,7 +109,7 @@ func FormatBlock( "gasLimit": hexutil.Uint64(gasLimit), // Static gas limit "gasUsed": (*hexutil.Big)(gasUsed), "timestamp": hexutil.Uint64(header.Time.Unix()), - "transactionsRoot": txRoot, + "transactionsRoot": ethtypes.EmptyRootHash, "receiptsRoot": ethtypes.EmptyRootHash, "uncles": []common.Hash{}, // "transactions": txs, From f4c298c709fe88b376acbf4591f30ce190a13615 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Fri, 5 Aug 2022 19:05:26 -0600 Subject: [PATCH 17/19] txRoot --- rpc/backend/evm_backend.go | 2 +- rpc/types/utils.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 3c958c0c0c..a4d172c975 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -273,7 +273,7 @@ func (b *Backend) EthBlockFromTendermint( transactionsRoot = ethtypes.DeriveSha(ethtypes.Transactions(ethTxs), hasher) transactionsRoot = common.BytesToHash(block.Header.DataHash) } - formattedBlock := types.FormatBlock(block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), bloom, baseFee) + formattedBlock := types.FormatBlock(block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), transactionsRoot, bloom, baseFee) blockJson, err := json.Marshal(formattedBlock) if err != nil { diff --git a/rpc/types/utils.go b/rpc/types/utils.go index 3aee6244a5..2a70eba370 100644 --- a/rpc/types/utils.go +++ b/rpc/types/utils.go @@ -89,7 +89,7 @@ func BlockMaxGasFromConsensusParams(goCtx context.Context, clientCtx client.Cont // transactions. func FormatBlock( header tmtypes.Header, size int, gasLimit int64, - gasUsed *big.Int, bloom ethtypes.Bloom, + gasUsed *big.Int, txRoot common.Hash, bloom ethtypes.Bloom, baseFee *big.Int, ) map[string]interface{} { @@ -109,7 +109,7 @@ func FormatBlock( "gasLimit": hexutil.Uint64(gasLimit), // Static gas limit "gasUsed": (*hexutil.Big)(gasUsed), "timestamp": hexutil.Uint64(header.Time.Unix()), - "transactionsRoot": ethtypes.EmptyRootHash, + "transactionsRoot": txRoot, "receiptsRoot": ethtypes.EmptyRootHash, "uncles": []common.Hash{}, // "transactions": txs, From 89e406ca863c4b86bb97f6808c4761ef34475c04 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Fri, 5 Aug 2022 19:16:41 -0600 Subject: [PATCH 18/19] json log --- rpc/backend/evm_backend.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index a4d172c975..96449790b9 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -265,6 +265,11 @@ func (b *Backend) EthBlockFromTendermint( tx := ethMsg.AsTransaction() ethTxs = append(ethTxs, tx) } + JSONtxs, err := json.MarshalIndent(ethTxs, "", " ") + if err != nil { + panic(err) + } + fmt.Printf("JSONtxs: %s\n", string(JSONtxs)) var transactionsRoot common.Hash if len(msgs) == 0 { transactionsRoot = ethtypes.EmptyRootHash From f73dae6885faf2ae4db1fc99cfb0c3a4212964f2 Mon Sep 17 00:00:00 2001 From: Josh Bowen Date: Wed, 10 Aug 2022 12:01:53 -0600 Subject: [PATCH 19/19] update to fix txRoot --- rpc/backend/evm_backend.go | 5 ++-- x/evm/keeper/abci.go | 21 +++++++++++++++ x/evm/keeper/keeper.go | 45 ++++++++++++++++++++++++++++++++ x/evm/keeper/state_transition.go | 2 ++ x/evm/types/events.go | 2 ++ x/evm/types/key.go | 10 ++++--- 6 files changed, 78 insertions(+), 7 deletions(-) diff --git a/rpc/backend/evm_backend.go b/rpc/backend/evm_backend.go index 96449790b9..e9081f3675 100644 --- a/rpc/backend/evm_backend.go +++ b/rpc/backend/evm_backend.go @@ -269,14 +269,13 @@ func (b *Backend) EthBlockFromTendermint( if err != nil { panic(err) } - fmt.Printf("JSONtxs: %s\n", string(JSONtxs)) + fmt.Printf("EVM Backend txs: %s\n", string(JSONtxs)) var transactionsRoot common.Hash if len(msgs) == 0 { transactionsRoot = ethtypes.EmptyRootHash } else { hasher := trie.NewStackTrie(nil) transactionsRoot = ethtypes.DeriveSha(ethtypes.Transactions(ethTxs), hasher) - transactionsRoot = common.BytesToHash(block.Header.DataHash) } formattedBlock := types.FormatBlock(block.Header, block.Size(), gasLimit, new(big.Int).SetUint64(gasUsed), transactionsRoot, bloom, baseFee) @@ -315,7 +314,7 @@ func (b *Backend) EthBlockFromTendermint( ethRPCTxs = append(ethRPCTxs, rpcTx) } formattedBlock["hash"] = ethHash - formattedBlock["transactionsRoot"] = transactionsRoot + // formattedBlock["transactionsRoot"] = transactionsRoot formattedBlock["transactions"] = ethRPCTxs return formattedBlock, nil } diff --git a/x/evm/keeper/abci.go b/x/evm/keeper/abci.go index e619b626d8..7ed975a156 100644 --- a/x/evm/keeper/abci.go +++ b/x/evm/keeper/abci.go @@ -1,11 +1,16 @@ package keeper import ( + "encoding/json" + "fmt" + abci "github.com/tendermint/tendermint/abci/types" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/trie" ) // BeginBlock sets the sdk Context and EIP155 chain id to the Keeper. @@ -23,5 +28,21 @@ func (k *Keeper) EndBlock(ctx sdk.Context, req abci.RequestEndBlock) []abci.Vali bloom := ethtypes.BytesToBloom(k.GetBlockBloomTransient(infCtx).Bytes()) k.EmitBlockBloomEvent(infCtx, bloom) + ethTxs := k.GetTxs(ctx) + JSONtxs, err := json.MarshalIndent(ethTxs, "", " ") + if err != nil { + panic(err) + } + fmt.Printf("End Block Txs: %s\n", string(JSONtxs)) + var txRoot common.Hash + if len(ethTxs) == 0 { + txRoot = ethtypes.EmptyRootHash + } else { + hasher := trie.NewStackTrie(nil) + txRoot = ethtypes.DeriveSha(ethtypes.Transactions(ethTxs), hasher) + } + fmt.Printf("End Block TxRoot: %s\n", txRoot) + k.EmitTxRootEvent(ctx, txRoot) + return []abci.ValidatorUpdate{} } diff --git a/x/evm/keeper/keeper.go b/x/evm/keeper/keeper.go index f3044aa319..905c0f0755 100644 --- a/x/evm/keeper/keeper.go +++ b/x/evm/keeper/keeper.go @@ -2,6 +2,7 @@ package keeper import ( "math/big" + "strconv" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/store/prefix" @@ -167,6 +168,50 @@ func (k Keeper) GetTxIndexTransient(ctx sdk.Context) uint64 { return sdk.BigEndianToUint64(bz) } +func (k Keeper) SetTx(ctx sdk.Context, index uint, tx *ethtypes.Transaction) { + store := ctx.TransientStore(k.transientKey) + data, err := tx.MarshalBinary() + if err != nil { + panic(err) + } + store.Set(append(types.KeyPrefixTransientTransaction, []byte(strconv.Itoa(int(index)))...), data) +} + +func (k Keeper) GetTx(ctx sdk.Context, index uint) *ethtypes.Transaction { + store := ctx.TransientStore(k.transientKey) + txData := store.Get(append(types.KeyPrefixTransientTransaction, []byte(strconv.Itoa(int(index)))...)) + parsedTx := ðtypes.Transaction{} + if err := parsedTx.UnmarshalBinary(txData); err != nil { + panic(err) + } + return parsedTx +} + +func (k Keeper) GetTxs(ctx sdk.Context) []*ethtypes.Transaction { + store := ctx.TransientStore(k.transientKey) + iterator := sdk.KVStorePrefixIterator(store, types.KeyPrefixTransientTransaction) + ethereumTxs := []*ethtypes.Transaction{} + defer iterator.Close() + for ; iterator.Valid(); iterator.Next() { + parsedTx := ðtypes.Transaction{} + if err := parsedTx.UnmarshalBinary(iterator.Value()); err != nil { + panic(err) + } + ethereumTxs = append(ethereumTxs, parsedTx) + } + return ethereumTxs +} + +// EmitBlockBloomEvent emit block bloom events +func (k Keeper) EmitTxRootEvent(ctx sdk.Context, txRoot common.Hash) { + ctx.EventManager().EmitEvent( + sdk.NewEvent( + types.EventTypeTxRoot, + sdk.NewAttribute(types.AttributeKeyEthereumTxRoot, txRoot.String()), + ), + ) +} + // ---------------------------------------------------------------------------- // Log // ---------------------------------------------------------------------------- diff --git a/x/evm/keeper/state_transition.go b/x/evm/keeper/state_transition.go index 2303c6d583..b91b793d16 100644 --- a/x/evm/keeper/state_transition.go +++ b/x/evm/keeper/state_transition.go @@ -277,6 +277,8 @@ func (k *Keeper) ApplyTransaction(ctx sdk.Context, tx *ethtypes.Transaction) (*t } } + k.SetTx(ctx, txConfig.TxIndex, tx) + // 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 { return nil, sdkerrors.Wrapf(err, "failed to refund gas leftover gas to sender %s", msg.From()) diff --git a/x/evm/types/events.go b/x/evm/types/events.go index d9e8592892..52c12a48ca 100644 --- a/x/evm/types/events.go +++ b/x/evm/types/events.go @@ -5,6 +5,7 @@ const ( EventTypeEthereumTx = TypeMsgEthereumTx EventTypeBlockBloom = "block_bloom" EventTypeTxLog = "tx_log" + EventTypeTxRoot = "tx_root" AttributeKeyContractAddress = "contract" AttributeKeyRecipient = "recipient" @@ -18,6 +19,7 @@ const ( AttributeKeyEthereumTxFailed = "ethereumTxFailed" AttributeValueCategory = ModuleName AttributeKeyEthereumBloom = "bloom" + AttributeKeyEthereumTxRoot = "ethTxRoot" MetricKeyTransitionDB = "transition_db" MetricKeyStaticCall = "static_call" diff --git a/x/evm/types/key.go b/x/evm/types/key.go index ade14eb20a..544190e029 100644 --- a/x/evm/types/key.go +++ b/x/evm/types/key.go @@ -33,6 +33,7 @@ const ( prefixTransientTxIndex prefixTransientLogSize prefixTransientGasUsed + prefixTransientTransaction ) // KVStore key prefixes @@ -43,10 +44,11 @@ var ( // Transient Store key prefixes var ( - KeyPrefixTransientBloom = []byte{prefixTransientBloom} - KeyPrefixTransientTxIndex = []byte{prefixTransientTxIndex} - KeyPrefixTransientLogSize = []byte{prefixTransientLogSize} - KeyPrefixTransientGasUsed = []byte{prefixTransientGasUsed} + KeyPrefixTransientBloom = []byte{prefixTransientBloom} + KeyPrefixTransientTxIndex = []byte{prefixTransientTxIndex} + KeyPrefixTransientLogSize = []byte{prefixTransientLogSize} + KeyPrefixTransientGasUsed = []byte{prefixTransientGasUsed} + KeyPrefixTransientTransaction = []byte{prefixTransientTransaction} ) // AddressStoragePrefix returns a prefix to iterate over a given account storage.