From 45109c45e004ff9c654142bf3a29c3bd80342a7c Mon Sep 17 00:00:00 2001 From: Alexander Bezobchuk Date: Wed, 4 Dec 2019 11:56:24 -0500 Subject: [PATCH] Bump SDK Commit (#207) Update against SDK's latest changeset. --- app/app.go | 14 +++++++++----- cli_test/cli_test.go | 2 -- go.mod | 2 +- go.sum | 11 ++--------- 4 files changed, 12 insertions(+), 17 deletions(-) diff --git a/app/app.go b/app/app.go index 39ae844965..9c71e41849 100644 --- a/app/app.go +++ b/app/app.go @@ -109,7 +109,7 @@ type GaiaApp struct { crisisKeeper crisis.Keeper paramsKeeper params.Keeper upgradeKeeper upgrade.Keeper - evidenceKeeper *evidence.Keeper + evidenceKeeper evidence.Keeper // the module manager mm *module.Manager @@ -173,12 +173,16 @@ func NewGaiaApp( app.upgradeKeeper = upgrade.NewKeeper(keys[upgrade.StoreKey], app.cdc) // create evidence keeper with evidence router - app.evidenceKeeper = evidence.NewKeeper( + evidenceKeeper := evidence.NewKeeper( app.cdc, keys[evidence.StoreKey], evidenceSubspace, evidence.DefaultCodespace, + &stakingKeeper, app.slashingKeeper, ) evidenceRouter := evidence.NewRouter() - // TODO: Register evidence routes. - app.evidenceKeeper.SetRouter(evidenceRouter) + + // TODO: register evidence routes + evidenceKeeper.SetRouter(evidenceRouter) + + app.evidenceKeeper = *evidenceKeeper // register the proposal types govRouter := gov.NewRouter() @@ -211,7 +215,7 @@ func NewGaiaApp( slashing.NewAppModule(app.slashingKeeper, app.stakingKeeper), staking.NewAppModule(app.stakingKeeper, app.accountKeeper, app.supplyKeeper), upgrade.NewAppModule(app.upgradeKeeper), - evidence.NewAppModule(*app.evidenceKeeper), + evidence.NewAppModule(app.evidenceKeeper), ) // During begin block slashing happens after distr.BeginBlocker so that diff --git a/cli_test/cli_test.go b/cli_test/cli_test.go index eb14217a3f..9ef156a145 100644 --- a/cli_test/cli_test.go +++ b/cli_test/cli_test.go @@ -12,7 +12,6 @@ import ( "path/filepath" "strings" "testing" - "time" "github.com/tendermint/tendermint/crypto/ed25519" tmtypes "github.com/tendermint/tendermint/types" @@ -1291,7 +1290,6 @@ func TestSlashingGetParams(t *testing.T) { defer proc.Stop(false) params := f.QuerySlashingParams() - require.Equal(t, time.Duration(120000000000), params.MaxEvidenceAge) require.Equal(t, int64(100), params.SignedBlocksWindow) require.Equal(t, sdk.NewDecWithPrec(5, 1), params.MinSignedPerWindow) diff --git a/go.mod b/go.mod index 2e6d93c22e..69887ba486 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.13 require ( github.com/btcsuite/btcd v0.0.0-20190807005414-4063feeff79a // indirect - github.com/cosmos/cosmos-sdk v0.34.4-0.20191130143208-b9cb3e105dba + github.com/cosmos/cosmos-sdk v0.34.4-0.20191204151802-202cb9be0bc3 github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d // indirect github.com/golang/mock v1.3.1 // indirect github.com/onsi/ginkgo v1.8.0 // indirect diff --git a/go.sum b/go.sum index 67866b1e60..b3005eda52 100644 --- a/go.sum +++ b/go.sum @@ -41,8 +41,8 @@ github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8Nz github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= -github.com/cosmos/cosmos-sdk v0.34.4-0.20191130143208-b9cb3e105dba h1:S9ojH+R2yp+m2yDpUz+6fmP1vUknYWNM9eOge1IAYL4= -github.com/cosmos/cosmos-sdk v0.34.4-0.20191130143208-b9cb3e105dba/go.mod h1:tA4b40PRtoZdit2w1o29YYdrCfuAVEpD7bRz9JDo43M= +github.com/cosmos/cosmos-sdk v0.34.4-0.20191204151802-202cb9be0bc3 h1:8kzgZVydSDaSbK2BbvR+D9ccrMN/VmV7WVvIEYjvMJo= +github.com/cosmos/cosmos-sdk v0.34.4-0.20191204151802-202cb9be0bc3/go.mod h1:JWuSAxZmMgNmNsZBCTuFfMHeeAAJZDxTnAKrQeSJOdk= github.com/cosmos/go-bip39 v0.0.0-20180618194314-52158e4697b8/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d h1:49RLWk1j44Xu4fjHb6JFYmeUnDORVwHNkDxaQ0ctCVU= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= @@ -91,7 +91,6 @@ github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+ github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= -github.com/gogo/protobuf v1.3.0/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.1 h1:DqDEcV5aeaTmdFBePNpYsp3FlcVH/2ISVVM9Qf8PSls= github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58= @@ -251,8 +250,6 @@ github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.0.0/go.mod h1:A8kyI5cUJhb8N+3pkfONlcEcZbueH6nhAm0Fq7SrnBM= github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= -github.com/spf13/viper v1.4.0 h1:yXHLWeravcrgGyFSyCgdYpXQ9dR9c/WED3pg1RhxqEU= -github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE= github.com/spf13/viper v1.5.0 h1:GpsTwfsQ27oS/Aha/6d1oD7tpKIqWnOA6tgOX9HHkt4= github.com/spf13/viper v1.5.0/go.mod h1:AkYRkVJF8TkSG/xet6PzXX+l39KhhXa2pdqVSxnTcn4= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= @@ -279,8 +276,6 @@ github.com/tendermint/go-amino v0.15.1/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoM github.com/tendermint/iavl v0.12.4 h1:hd1woxUGISKkfUWBA4mmmTwOua6PQZTJM/F0FDrmMV8= github.com/tendermint/iavl v0.12.4/go.mod h1:8LHakzt8/0G3/I8FUU0ReNx98S/EP6eyPJkAUvEXT/o= github.com/tendermint/tendermint v0.32.1/go.mod h1:jmPDAKuNkev9793/ivn/fTBnfpA9mGBww8MPRNPNxnU= -github.com/tendermint/tendermint v0.32.7 h1:Szu5Fm1L3pvn3t4uQxPAcP+7ndZEQKgLie/yokM56rU= -github.com/tendermint/tendermint v0.32.7/go.mod h1:D2+A3pNjY+Po72X0mTfaXorFhiVI8dh/Zg640FGyGtE= github.com/tendermint/tendermint v0.32.8 h1:eOaLJGRi5x/Rb23fiVsxq9c5fZ/6O5QplExlGjNPDVI= github.com/tendermint/tendermint v0.32.8/go.mod h1:5/B1XZjNYtVBso8o1l/Eg4A0Mhu42lDcmftoQl95j/E= github.com/tendermint/tm-db v0.1.1/go.mod h1:0cPKWu2Mou3IlxecH+MEUSYc1Ch537alLe6CpFrKzgw= @@ -368,8 +363,6 @@ google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZi google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= google.golang.org/grpc v1.22.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.23.1 h1:q4XQuHFC6I28BKZpo6IYyb3mNO+l7lSOxRuYTCiDfXk= -google.golang.org/grpc v1.23.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= google.golang.org/grpc v1.25.1 h1:wdKvqQk7IttEw92GoRyKG2IDrUIpgpj6H6m81yfeMW0= google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=