From a87d6ea3ab6b198a8bffbcb3e0765575523afe7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Wed, 7 Oct 2020 14:56:11 +0200 Subject: [PATCH] baseapp: fix err message and use valid default consensus params values (#7471) * update err msg and add passing default in simapp * fix default Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- baseapp/params.go | 2 +- simapp/test_helpers.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/baseapp/params.go b/baseapp/params.go index f7d8d1c0a1c7..7b3ec6ff7d23 100644 --- a/baseapp/params.go +++ b/baseapp/params.go @@ -64,7 +64,7 @@ func ValidateEvidenceParams(i interface{}) error { } if v.MaxNum <= 0 { - return fmt.Errorf("evidence maximum number of evidence must be positive: %v", v.MaxAgeDuration) + return fmt.Errorf("evidence maximum number of evidence must be positive: %v", v.MaxNum) } return nil diff --git a/simapp/test_helpers.go b/simapp/test_helpers.go index 31fed4c9964b..136fde760e42 100644 --- a/simapp/test_helpers.go +++ b/simapp/test_helpers.go @@ -38,6 +38,7 @@ var DefaultConsensusParams = &abci.ConsensusParams{ Evidence: &tmproto.EvidenceParams{ MaxAgeNumBlocks: 302400, MaxAgeDuration: 504 * time.Hour, // 3 weeks is the max duration + MaxNum: 50, }, Validator: &tmproto.ValidatorParams{ PubKeyTypes: []string{