diff --git a/Makefile b/Makefile index bd76e81ee4..44ac61b048 100644 --- a/Makefile +++ b/Makefile @@ -8,7 +8,7 @@ export GO111MODULE=on GithubTop=github.com -Version=v0.18.11 +Version=v0.18.12 CosmosSDK=v0.39.2 Tendermint=v0.33.9 Iavl=v0.14.3 diff --git a/app/app.go b/app/app.go index 7e7e635bb0..43041b649e 100644 --- a/app/app.go +++ b/app/app.go @@ -416,6 +416,7 @@ func NewOKExChainApp( app.SetAnteHandler(ante.NewAnteHandler(app.AccountKeeper, app.EvmKeeper, app.SupplyKeeper, validateMsgHook(app.OrderKeeper))) app.SetEndBlocker(app.EndBlocker) app.SetGasRefundHandler(refund.NewGasRefundHandler(app.AccountKeeper, app.SupplyKeeper)) + app.SetAccHandler(NewAccHandler(app.AccountKeeper)) if loadLatest { err := app.LoadLatestVersion(app.keys[bam.MainStoreKey]) @@ -589,3 +590,11 @@ func validateMsgHook(orderKeeper order.Keeper) ante.ValidateMsgHandler { return nil } } + +func NewAccHandler(ak auth.AccountKeeper) sdk.AccHandler { + return func( + ctx sdk.Context, addr sdk.AccAddress, + ) uint64 { + return ak.GetAccount(ctx, addr).GetSequence() + } +} \ No newline at end of file diff --git a/go.mod b/go.mod index f10929ab42..200a76c6e7 100644 --- a/go.mod +++ b/go.mod @@ -56,7 +56,7 @@ require ( ) replace ( - github.com/cosmos/cosmos-sdk => github.com/okex/cosmos-sdk v0.39.3-0.20210727103206-6345fb1f29e8 + github.com/cosmos/cosmos-sdk => github.com/okex/cosmos-sdk v0.39.2-exchain9 github.com/tendermint/iavl => github.com/okex/iavl v0.14.3-exchain github.com/tendermint/tendermint => github.com/okex/tendermint v0.33.9-exchain6 ) diff --git a/go.sum b/go.sum index ed54db7b9b..769e67f944 100644 --- a/go.sum +++ b/go.sum @@ -499,8 +499,8 @@ github.com/nats-io/nkeys v0.1.3/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxzi github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= -github.com/okex/cosmos-sdk v0.39.3-0.20210727103206-6345fb1f29e8 h1:NrZgzvAloeUexA08O3Us75IqIa5CDr70Lk1wwPVo65w= -github.com/okex/cosmos-sdk v0.39.3-0.20210727103206-6345fb1f29e8/go.mod h1:IvlniaZoJAtzILHgcmnfaJ5S125TYJWfJvGqY9zSXb4= +github.com/okex/cosmos-sdk v0.39.2-exchain9 h1:KG7t/7zWSbfC9LzGJn0c6OMuhrx3TVx4pNt/UNbQQWA= +github.com/okex/cosmos-sdk v0.39.2-exchain9/go.mod h1:IvlniaZoJAtzILHgcmnfaJ5S125TYJWfJvGqY9zSXb4= github.com/okex/iavl v0.14.3-exchain h1:kwRIwpFD6B8mDDqoaxeUN3Pg2GW0Vr+sA+b86renWcA= github.com/okex/iavl v0.14.3-exchain/go.mod h1:vHLYxU/zuxBmxxr1v+5Vnd/JzcIsyK17n9P9RDubPVU= github.com/okex/tendermint v0.33.9-exchain6 h1:g2pinlQENrKwryRHwRCLOQygQ5Mq37vqxkEuAKcj72g=