Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,6 @@ import (
"github.com/cosmos/evm/x/feemarket"
feemarketkeeper "github.com/cosmos/evm/x/feemarket/keeper"
feemarkettypes "github.com/cosmos/evm/x/feemarket/types"
transfer "github.com/cosmos/evm/x/ibc/transfer"
ibctransferkeeper "github.com/cosmos/evm/x/ibc/transfer/keeper"
"github.com/cosmos/evm/x/vm"

// _ "github.com/ethereum/go-ethereum/core/tracers/js"
Expand All @@ -145,6 +143,8 @@ import (
icahostkeeper "github.com/cosmos/ibc-go/v10/modules/apps/27-interchain-accounts/host/keeper"
icahosttypes "github.com/cosmos/ibc-go/v10/modules/apps/27-interchain-accounts/host/types"
icatypes "github.com/cosmos/ibc-go/v10/modules/apps/27-interchain-accounts/types"
transfer "github.com/cosmos/ibc-go/v10/modules/apps/transfer"
ibctransferkeeper "github.com/cosmos/ibc-go/v10/modules/apps/transfer/keeper"
ibctransfertypes "github.com/cosmos/ibc-go/v10/modules/apps/transfer/types"
ibc "github.com/cosmos/ibc-go/v10/modules/core"
ibcclienttypes "github.com/cosmos/ibc-go/v10/modules/core/02-client/types" //nolint:staticcheck
Expand Down Expand Up @@ -850,17 +850,21 @@ func NewChainApp(
app.IBCKeeper.ChannelKeeper, // Use ChannelKeeper as ICS4Wrapper
)

// Create Transfer Keepers : upgraded for ibc-go v10
// Create Transfer Keepers : upgraded for ibc-go v10.
// cosmos/evm v0.6.0 removed its custom x/ibc/transfer wrapper, so this now uses
// the standard ibc-go transfer keeper. ERC-20<>IBC conversion that the custom
// keeper used to perform (it took an Erc20Keeper arg) is now done by the
// erc20 IBC middleware wrapped around the transfer stack below.
app.TransferKeeper = ibctransferkeeper.NewKeeper(
appCodec,
runtime.NewKVStoreService(keys[ibctransfertypes.StoreKey]),
nil, // legacySubspace (no params subspace)
app.RatelimitKeeper, // ICS4Wrapper
//app.IBCFeeKeeper,
app.IBCKeeper.ChannelKeeper,
app.MsgServiceRouter(),
app.AccountKeeper,
app.BankKeeper,
app.Erc20Keeper,
authtypes.NewModuleAddress(govtypes.ModuleName).String(),
)

Expand Down Expand Up @@ -961,6 +965,10 @@ func NewChainApp(
// Create Transfer Stack
var transferStack porttypes.IBCModule
transferStack = transfer.NewIBCModule(app.TransferKeeper)
// ERC-20 middleware converts IBC vouchers to/from ERC-20 tokens. In cosmos/evm
// v0.6.0 this replaced the ERC-20 conversion that the removed custom
// x/ibc/transfer keeper performed in its OnRecvPacket/msg-server override.
transferStack = erc20.NewIBCMiddleware(app.Erc20Keeper, transferStack)
// callbacks wraps the transfer stack as its base app, and uses PacketForwardKeeper as the ICS4Wrapper
// i.e. packet-forward-middleware is higher on the stack and sits between callbacks and the ibc channel keeper
// Since this is the lowest level middleware of the transfer stack, it should be the first entrypoint for transfer keeper's
Expand Down
3 changes: 2 additions & 1 deletion app/precompiles.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
slashingprecompile "github.com/cosmos/evm/precompiles/slashing"
stakingprecompile "github.com/cosmos/evm/precompiles/staking"
erc20Keeper "github.com/cosmos/evm/x/erc20/keeper"
transferkeeper "github.com/cosmos/evm/x/ibc/transfer/keeper"
transferkeeper "github.com/cosmos/ibc-go/v10/modules/apps/transfer/keeper"
channelkeeper "github.com/cosmos/ibc-go/v10/modules/core/04-channel/keeper"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core/vm"
Expand Down Expand Up @@ -113,6 +113,7 @@ func NewAvailableStaticPrecompiles(
stakingKeeper,
transferKeeper,
channelKeeper,
erc20Kpr,
)

bankPrecompile := bankprecompile.NewPrecompile(bankKeeper, erc20Kpr)
Expand Down
16 changes: 8 additions & 8 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ replace (
cosmossdk.io/x/upgrade => cosmossdk.io/x/upgrade v0.1.4
github.com/CosmWasm/wasmd => github.com/CosmWasm/wasmd v0.55.0 // Keep v0.55.0
github.com/cosmos/cosmos-sdk => github.com/cosmos/cosmos-sdk v0.50.10 // Use stable v0.50.10
github.com/cosmos/evm => github.com/pushchain/evm v1.0.0-rc2.0.20260616081105-96231e7a76c0
github.com/cosmos/evm => github.com/pushchain/evm v1.0.0-rc2.0.20260627105801-6c22ba0b1e9e
github.com/ethereum/go-ethereum => github.com/cosmos/go-ethereum v0.0.0-20250806193535-2fc7571efa91
github.com/spf13/viper => github.com/spf13/viper v1.17.0
github.com/strangelove-ventures/tokenfactory => github.com/strangelove-ventures/tokenfactory v0.50.7-wasmvm2
Expand Down Expand Up @@ -56,7 +56,7 @@ require (
cosmossdk.io/x/tx v1.2.0-alpha.1
cosmossdk.io/x/upgrade v0.2.0
github.com/CosmWasm/wasmd v0.51.0
github.com/cometbft/cometbft v0.38.19
github.com/cometbft/cometbft v0.38.21
github.com/cosmos/cosmos-db v1.1.3
github.com/cosmos/cosmos-proto v1.0.0-beta.5
github.com/cosmos/cosmos-sdk v0.54.0-alpha.0.0.20250611155041-9fa93c9afe32
Expand All @@ -79,7 +79,7 @@ require (
github.com/rs/zerolog v1.34.0
github.com/spf13/cast v1.10.0
github.com/spf13/cobra v1.10.1
github.com/spf13/viper v1.20.1
github.com/spf13/viper v1.21.0
github.com/strangelove-ventures/tokenfactory v0.50.7-wasmvm2
github.com/stretchr/testify v1.11.1
google.golang.org/genproto/googleapis/api v0.0.0-20250707201910-8d1bb00bc6a7
Expand Down Expand Up @@ -238,7 +238,7 @@ require (
github.com/cosmos/iavl v1.2.6 // indirect
github.com/cosmos/ibc-go/modules/light-clients/08-wasm/v10 v10.4.0
github.com/cosmos/ics23/go v0.11.0 // indirect
github.com/cosmos/ledger-cosmos-go v0.16.0 // indirect
github.com/cosmos/ledger-cosmos-go v1.0.0 // indirect
github.com/creachadair/atomicfile v0.3.7 // indirect
github.com/creachadair/tomledit v0.0.28 // indirect
github.com/danieljoos/wincred v1.2.1 // indirect
Expand Down Expand Up @@ -294,7 +294,7 @@ require (
github.com/hashicorp/yamux v0.1.2 // indirect
github.com/hdevalence/ed25519consensus v0.2.0 // indirect
github.com/holiman/bloomfilter/v2 v2.0.3 // indirect
github.com/holiman/uint256 v1.3.2 // indirect
github.com/holiman/uint256 v1.3.2
github.com/huandu/skiplist v1.2.1 // indirect
github.com/huin/goupnp v1.3.0 // indirect
github.com/iancoleman/orderedmap v0.3.0 // indirect
Expand Down Expand Up @@ -343,12 +343,12 @@ require (
github.com/rivo/uniseg v0.2.0 // indirect
github.com/rogpeppe/go-internal v1.14.1 // indirect
github.com/rs/cors v1.11.1 // indirect
github.com/sagikazarmark/locafero v0.9.0 // indirect
github.com/sagikazarmark/locafero v0.11.0 // indirect
github.com/sagikazarmark/slog-shim v0.1.0 // indirect
github.com/sasha-s/go-deadlock v0.3.5 // indirect
github.com/shirou/gopsutil v3.21.11+incompatible // indirect
github.com/sourcegraph/conc v0.3.0 // indirect
github.com/spf13/afero v1.14.0 // indirect
github.com/sourcegraph/conc v0.3.1-0.20240121214520-5f936abd7ae8 // indirect
github.com/spf13/afero v1.15.0 // indirect
github.com/spf13/pflag v1.0.10 // indirect
github.com/streamingfast/logging v0.0.0-20230608130331-f22c91403091 // indirect
github.com/stretchr/objx v0.5.2 // indirect
Expand Down
28 changes: 14 additions & 14 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -862,8 +862,8 @@ github.com/cockroachdb/redact v1.1.6/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZ
github.com/cockroachdb/tokenbucket v0.0.0-20250429170803-42689b6311bb h1:3bCgBvB8PbJVMX1ouCcSIxvsqKPYM7gs72o0zC76n9g=
github.com/cockroachdb/tokenbucket v0.0.0-20250429170803-42689b6311bb/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ=
github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI=
github.com/cometbft/cometbft v0.38.19 h1:vNdtCkvhuwUlrcLPAyigV7lQpmmo+tAq8CsB8gZjEYw=
github.com/cometbft/cometbft v0.38.19/go.mod h1:UCu8dlHqvkAsmAFmWDRWNZJPlu6ya2fTWZlDrWsivwo=
github.com/cometbft/cometbft v0.38.21 h1:qcIJSH9LiwU5s6ZgKR5eRbsLNucbubfraDs5bzgjtOI=
github.com/cometbft/cometbft v0.38.21/go.mod h1:UCu8dlHqvkAsmAFmWDRWNZJPlu6ya2fTWZlDrWsivwo=
github.com/cometbft/cometbft-db v1.0.4 h1:cezb8yx/ZWcF124wqUtAFjAuDksS1y1yXedvtprUFxs=
github.com/cometbft/cometbft-db v1.0.4/go.mod h1:M+BtHAGU2XLrpUxo3Nn1nOCcnVCiLM9yx5OuT0u5SCA=
github.com/consensys/gnark-crypto v0.18.0 h1:vIye/FqI50VeAr0B3dx+YjeIvmc3LWz4yEfbWBpTUf0=
Expand Down Expand Up @@ -915,8 +915,8 @@ github.com/cosmos/ics23/go v0.11.0 h1:jk5skjT0TqX5e5QJbEnwXIS2yI2vnmLOgpQPeM5Rtn
github.com/cosmos/ics23/go v0.11.0/go.mod h1:A8OjxPE67hHST4Icw94hOxxFEJMBG031xIGF/JHNIY0=
github.com/cosmos/keyring v1.2.0 h1:8C1lBP9xhImmIabyXW4c3vFjjLiBdGCmfLUfeZlV1Yo=
github.com/cosmos/keyring v1.2.0/go.mod h1:fc+wB5KTk9wQ9sDx0kFXB3A0MaeGHM9AwRStKOQ5vOA=
github.com/cosmos/ledger-cosmos-go v0.16.0 h1:YKlWPG9NnGZIEUb2bEfZ6zhON1CHlNTg0QKRRGcNEd0=
github.com/cosmos/ledger-cosmos-go v0.16.0/go.mod h1:WrM2xEa8koYoH2DgeIuZXNarF7FGuZl3mrIOnp3Dp0o=
github.com/cosmos/ledger-cosmos-go v1.0.0 h1:jNKW89nPf0vR0EkjHG8Zz16h6p3zqwYEOxlHArwgYtw=
github.com/cosmos/ledger-cosmos-go v1.0.0/go.mod h1:mGaw2wDOf+Z6SfRJsMGxU9DIrBa4du0MAiPlpPhLAOE=
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.6 h1:XJtiaUW6dEEqVuZiMTn1ldk455QWwEIsMIJlo5vtkx0=
Expand Down Expand Up @@ -1765,8 +1765,8 @@ github.com/prysmaticlabs/gohashtree v0.0.4-beta.0.20240624100937-73632381301b h1
github.com/prysmaticlabs/gohashtree v0.0.4-beta.0.20240624100937-73632381301b/go.mod h1:HRuvtXLZ4WkaB1MItToVH2e8ZwKwZPY5/Rcby+CvvLY=
github.com/prysmaticlabs/prysm/v5 v5.3.0 h1:7Lr8ndapBTZg00YE+MgujN6+yvJR6Bdfn28ZDSJ00II=
github.com/prysmaticlabs/prysm/v5 v5.3.0/go.mod h1:r1KhlduqDMIGZ1GhR5pjZ2Ko8Q89noTDYTRoPKwf1+c=
github.com/pushchain/evm v1.0.0-rc2.0.20260616081105-96231e7a76c0 h1:y4oaq20SC2hFSg2/AyLc4iSLu9i6z/mCgyKcsrVyVhg=
github.com/pushchain/evm v1.0.0-rc2.0.20260616081105-96231e7a76c0/go.mod h1:BjKknQX/cnH/v/i2AgtfsJY4g/gihm9n6ilXk2SExUo=
github.com/pushchain/evm v1.0.0-rc2.0.20260627105801-6c22ba0b1e9e h1:KL2DPaFKZ7t7SkXnFQ/V5QEjvPE45Il5AyQvoVWFoMI=
github.com/pushchain/evm v1.0.0-rc2.0.20260627105801-6c22ba0b1e9e/go.mod h1:QuenX5DgRhWeYdIg0J/p65cyS/ntpgnzpZOIajZ/SHk=
github.com/quic-go/qpack v0.4.0 h1:Cr9BXA1sQS2SmDUWjSofMPNKmvF6IiIfDRmgU0w1ZCo=
github.com/quic-go/qpack v0.4.0/go.mod h1:UZVnYIfi5GRk+zI9UMaCPsmZ2xKJP7XBUvVyT1Knj9A=
github.com/quic-go/qtls-go1-20 v0.3.4 h1:MfFAPULvst4yoMgY9QmtpYmfij/em7O8UUi+bNVm7Cg=
Expand Down Expand Up @@ -1809,8 +1809,8 @@ github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQD
github.com/ruudk/golang-pdf417 v0.0.0-20181029194003-1af4ab5afa58/go.mod h1:6lfFZQK844Gfx8o5WFuvpxWRwnSoipWe/p622j1v06w=
github.com/ruudk/golang-pdf417 v0.0.0-20201230142125-a7e3863a1245/go.mod h1:pQAZKsJ8yyVxGRWYNEm9oFB8ieLgKFnamEyDmSA0BRk=
github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
github.com/sagikazarmark/locafero v0.9.0 h1:GbgQGNtTrEmddYDSAH9QLRyfAHY12md+8YFTqyMTC9k=
github.com/sagikazarmark/locafero v0.9.0/go.mod h1:UBUyz37V+EdMS3hDF3QWIiVr/2dPrx49OMO0Bn0hJqk=
github.com/sagikazarmark/locafero v0.11.0 h1:1iurJgmM9G3PA/I+wWYIOw/5SyBtxapeHDcg+AAIFXc=
github.com/sagikazarmark/locafero v0.11.0/go.mod h1:nVIGvgyzw595SUSUE6tvCp3YYTeHs15MvlmU87WwIik=
github.com/sagikazarmark/slog-shim v0.1.0 h1:diDBnUNK9N/354PgrxMywXnAwEr1QZcOr6gto+ugjYE=
github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ=
github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E=
Expand Down Expand Up @@ -1859,17 +1859,17 @@ github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9
github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
github.com/sony/gobreaker v0.4.1/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJOjmxWY=
github.com/sourcegraph/annotate v0.0.0-20160123013949-f4cad6c6324d/go.mod h1:UdhH50NIW0fCiwBSr0co2m7BnFLdv4fQTgdqdJTHFeE=
github.com/sourcegraph/conc v0.3.0 h1:OQTbbt6P72L20UqAkXXuLOj79LfEanQ+YQFNpLA9ySo=
github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0=
github.com/sourcegraph/conc v0.3.1-0.20240121214520-5f936abd7ae8 h1:+jumHNA0Wrelhe64i8F6HNlS8pkoyMv5sreGx2Ry5Rw=
github.com/sourcegraph/conc v0.3.1-0.20240121214520-5f936abd7ae8/go.mod h1:3n1Cwaq1E1/1lhQhtRK2ts/ZwZEhjcQeJQ1RuC6Q/8U=
github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e/go.mod h1:HuIsMU8RRBOtsCgI77wP899iHVBQpCmg4ErYMZB+2IA=
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
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.3.3/go.mod h1:5KUK8ByomD5Ti5Artl0RtHeI5pTF7MIDuXL3yY520V4=
github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
github.com/spf13/afero v1.9.2/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y=
github.com/spf13/afero v1.14.0 h1:9tH6MapGnn/j0eb0yIXiLjERO8RB6xIVZRDCX7PtqWA=
github.com/spf13/afero v1.14.0/go.mod h1:acJQ8t0ohCGuMN3O+Pv0V0hgMxNYDlvdk+VTfyZmbYo=
github.com/spf13/afero v1.15.0 h1:b/YBCLWAJdFWJTN9cLhiXXcD7mzKn9Dm86dNnfyQw1I=
github.com/spf13/afero v1.15.0/go.mod h1:NC2ByUVxtQs4b3sIUphxK0NioZnmxgyCrfzeuq8lxMg=
github.com/spf13/cast v1.10.0 h1:h2x0u2shc1QuLHfxi+cTJvs30+ZAHOGRic8uyGTDWxY=
github.com/spf13/cast v1.10.0/go.mod h1:jNfB8QC9IA6ZuY2ZjDp0KtFO2LZZlg4S/7bzP6qqeHo=
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
Expand Down Expand Up @@ -2061,8 +2061,8 @@ go.uber.org/zap v1.27.0 h1:aJMhYGrd5QSmlpLMr2MftRKl7t8J8PTZPA732ud/XR8=
go.uber.org/zap v1.27.0/go.mod h1:GB2qFLM7cTU87MWRP2mPIjqfIDnGu+VIO4V/SdhGo2E=
go.yaml.in/yaml/v2 v2.4.2 h1:DzmwEr2rDGHl7lsFgAHxmNz/1NlQ7xLIrlN2h5d1eGI=
go.yaml.in/yaml/v2 v2.4.2/go.mod h1:081UH+NErpNdqlCXm3TtEran0rJZGxAYx9hb/ELlsPU=
go.yaml.in/yaml/v3 v3.0.3 h1:bXOww4E/J3f66rav3pX3m8w6jDE4knZjGOw8b5Y6iNE=
go.yaml.in/yaml/v3 v3.0.3/go.mod h1:tBHosrYAkRZjRAOREWbDnBXUf08JOwYq++0QNwQiWzI=
go.yaml.in/yaml/v3 v3.0.4 h1:tfq32ie2Jv2UxXFdLJdh3jXuOzWiL1fo0bu/FbuKpbc=
go.yaml.in/yaml/v3 v3.0.4/go.mod h1:DhzuOOF2ATzADvBadXxruRBLzYTpT36CKvDb3+aBEFg=
go4.org v0.0.0-20180809161055-417644f6feb5/go.mod h1:MkTOUMDaeVYJUOUsaDXIhWPZYa1yOyC1qaOBpL57BhE=
golang.org/x/arch v0.17.0 h1:4O3dfLzd+lQewptAHqjewQZQDyEdejz3VwgeYwkZneU=
golang.org/x/arch v0.17.0/go.mod h1:bdwinDaKcfZUGpH09BB7ZmOfhalA8lQdzl62l8gGWsk=
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -468,10 +468,12 @@ func TestInboundCEAGasAndPayload(t *testing.T) {
// Check that PRC20 was deposited into the UEA (recipient)
res, err := chainApp.EVMKeeper.CallEVM(
ctx,
chainApp.EVMKeeper.NewStateDB(ctx),
prc20ABI,
ueModuleAccAddress,
prc20Address,
false,
false,
nil,
"balanceOf",
ueaAddrHex,
Expand All @@ -497,7 +499,7 @@ func TestInboundCEAGasAndPayload(t *testing.T) {
chainApp.UregistryKeeper.AddChainConfig(ctx, &uregistrytypes.ChainConfig{
Chain: "eip155:97",
VmType: uregistrytypes.VmType_EVM,
PublicRpcUrl: "https://data-seed-prebsc-1-s1.binance.org:8545",
PublicRpcUrl: "https://data-seed-prebsc-1-s1.binance.org:8545",
GatewayAddress: "0x0000000000000000000000000000000000000000",
BlockConfirmation: &uregistrytypes.BlockConfirmation{
FastInbound: 5,
Expand Down
14 changes: 9 additions & 5 deletions test/integration/uexecutor/inbound_cea_payload_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ func setupInboundCEAPayloadTest(t *testing.T, numVals int) (*app.ChainApp, sdk.C
chainApp, ctx, _, validators := utils.SetAppWithMultipleValidators(t, numVals)

chainConfigTest := uregistrytypes.ChainConfig{
Chain: "eip155:11155111",
VmType: uregistrytypes.VmType_EVM,
PublicRpcUrl: "https://sepolia.drpc.org",
Chain: "eip155:11155111",
VmType: uregistrytypes.VmType_EVM,
PublicRpcUrl: "https://sepolia.drpc.org",
GatewayAddress: "0x28E0F09bE2321c1420Dc60Ee146aACbD68B335Fe",
BlockConfirmation: &uregistrytypes.BlockConfirmation{
FastInbound: 5,
Expand Down Expand Up @@ -227,10 +227,12 @@ func TestInboundCEAFundsAndPayload(t *testing.T) {
// Check that PRC20 was deposited into the UEA (recipient)
res, err := chainApp.EVMKeeper.CallEVM(
ctx,
chainApp.EVMKeeper.NewStateDB(ctx),
prc20ABI,
ueModuleAccAddress,
prc20Address,
false,
false,
nil,
"balanceOf",
ueaAddrHex,
Expand Down Expand Up @@ -597,7 +599,7 @@ func TestInboundCEAFundsAndPayload(t *testing.T) {
ceaInbound := &uexecutortypes.Inbound{
SourceChain: "eip155:11155111",
TxHash: "0xcea07",
Sender: personBSender, // person B — no UEA
Sender: personBSender, // person B — no UEA
Recipient: ueaAddrHex.String(), // person A's UEA
Amount: "1000000",
AssetAddr: usdcAddress.String(),
Expand Down Expand Up @@ -633,10 +635,12 @@ func TestInboundCEAFundsAndPayload(t *testing.T) {
// Confirm the PRC20 balance landed at the explicitly passed recipient (person A's UEA)
res, err := chainApp.EVMKeeper.CallEVM(
ctx,
chainApp.EVMKeeper.NewStateDB(ctx),
prc20ABI,
ueModuleAccAddress,
prc20Address,
false,
false,
nil,
"balanceOf",
ueaAddrHex,
Expand Down Expand Up @@ -726,7 +730,7 @@ func TestInboundCEAFundsAndPayload(t *testing.T) {
chainApp.UregistryKeeper.AddChainConfig(ctx, &uregistrytypes.ChainConfig{
Chain: "eip155:97",
VmType: uregistrytypes.VmType_EVM,
PublicRpcUrl: "https://data-seed-prebsc-1-s1.binance.org:8545",
PublicRpcUrl: "https://data-seed-prebsc-1-s1.binance.org:8545",
GatewayAddress: "0x0000000000000000000000000000000000000000",
BlockConfirmation: &uregistrytypes.BlockConfirmation{
FastInbound: 5,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -239,10 +239,12 @@ func TestInboundCEASmartContractRecipient(t *testing.T) {

res, err := chainApp.EVMKeeper.CallEVM(
ctx,
chainApp.EVMKeeper.NewStateDB(ctx),
prc20ABI,
ueModuleAccAddress,
prc20Address,
false,
false,
nil,
"balanceOf",
contractAddr,
Expand Down Expand Up @@ -455,7 +457,7 @@ func TestInboundCEASmartContractRecipient(t *testing.T) {
ueModuleAccAddress, _ := chainApp.UexecutorKeeper.GetUeModuleAddress(ctx)

res, err := chainApp.EVMKeeper.CallEVM(
ctx, prc20ABI, ueModuleAccAddress, prc20Address, false, nil, "balanceOf", recipientAddr,
ctx, chainApp.EVMKeeper.NewStateDB(ctx), prc20ABI, ueModuleAccAddress, prc20Address, false, false, nil, "balanceOf", recipientAddr,
)
require.NoError(t, err)
balances, err := prc20ABI.Unpack("balanceOf", res.Ret)
Expand Down
6 changes: 3 additions & 3 deletions test/integration/uexecutor/inbound_solana_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ func TestSolanaInboundFunds(t *testing.T) {
recipient := common.HexToAddress(inbound.Recipient)

// Check initial balance is 0
res, err := app.EVMKeeper.CallEVM(ctx, prc20ABI, ueModuleAccAddress, prc20Address, false, nil, "balanceOf", recipient)
res, err := app.EVMKeeper.CallEVM(ctx, app.EVMKeeper.NewStateDB(ctx), prc20ABI, ueModuleAccAddress, prc20Address, false, false, nil, "balanceOf", recipient)
require.NoError(t, err)
balances, _ := prc20ABI.Unpack("balanceOf", res.Ret)
require.Equal(t, int64(0), balances[0].(*big.Int).Int64())
Expand All @@ -156,7 +156,7 @@ func TestSolanaInboundFunds(t *testing.T) {
require.False(t, isPending)

// PRC20 balance should equal inbound amount
res, err = app.EVMKeeper.CallEVM(ctx, prc20ABI, ueModuleAccAddress, prc20Address, false, nil, "balanceOf", recipient)
res, err = app.EVMKeeper.CallEVM(ctx, app.EVMKeeper.NewStateDB(ctx), prc20ABI, ueModuleAccAddress, prc20Address, false, false, nil, "balanceOf", recipient)
require.NoError(t, err)
balances, _ = prc20ABI.Unpack("balanceOf", res.Ret)
expected := new(big.Int)
Expand All @@ -179,7 +179,7 @@ func TestSolanaInboundFunds(t *testing.T) {
voteToQuorum(t, ctx, app, vals, coreVals, &inbound2)

// Balance should be 2x
res, err := app.EVMKeeper.CallEVM(ctx, prc20ABI, ueModuleAccAddress, prc20Address, false, nil, "balanceOf", recipient)
res, err := app.EVMKeeper.CallEVM(ctx, app.EVMKeeper.NewStateDB(ctx), prc20ABI, ueModuleAccAddress, prc20Address, false, false, nil, "balanceOf", recipient)
require.NoError(t, err)
balances, _ := prc20ABI.Unpack("balanceOf", res.Ret)
expected := new(big.Int)
Expand Down
Loading
Loading