From e87c4460bfa61bc104874baa16c3534fce28ac22 Mon Sep 17 00:00:00 2001 From: Martin Arrivets Date: Thu, 10 Oct 2024 15:04:54 +0200 Subject: [PATCH] feat: add fields to cometbft header --- baseapp/abci.go | 8 +++++++- go.mod | 2 +- go.sum | 4 ++-- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/baseapp/abci.go b/baseapp/abci.go index 600ad36e7e69..973b10cece99 100644 --- a/baseapp/abci.go +++ b/baseapp/abci.go @@ -723,7 +723,13 @@ func (app *BaseApp) internalFinalizeBlock(ctx context.Context, req *abci.Request Time: req.Time, ProposerAddress: req.ProposerAddress, NextValidatorsHash: req.NextValidatorsHash, - AppHash: app.LastCommitID().Hash, + AppHash: req.AppHash, + ValidatorsHash: req.ValidatorsHash, + ConsensusHash: req.ConsensusHash, + DataHash: req.DataHash, + EvidenceHash: req.EvidenceHash, + LastCommitHash: req.LastCommitHash, + LastResultsHash: req.LastResultsHash, LastBlockId: cmtproto.BlockID{ Hash: req.LastBlockHash, PartSetHeader: cmtproto.PartSetHeader{ diff --git a/go.mod b/go.mod index 6fa07191e338..374492608ecc 100644 --- a/go.mod +++ b/go.mod @@ -208,7 +208,7 @@ replace ( // use cosmos fork of keyring github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 - github.com/cometbft/cometbft => github.com/InjectiveLabs/cometbft v0.38.11-inj-3 + github.com/cometbft/cometbft => github.com/InjectiveLabs/cometbft v0.38.11-inj-4 // dgrijalva/jwt-go is deprecated and doesn't receive security updates. // TODO: remove it: https://github.com/cosmos/cosmos-sdk/issues/13134 github.com/dgrijalva/jwt-go => github.com/golang-jwt/jwt/v4 v4.4.2 diff --git a/go.sum b/go.sum index 176f88a55578..80306dd36f7a 100644 --- a/go.sum +++ b/go.sum @@ -45,8 +45,8 @@ github.com/DataDog/sketches-go v1.4.2 h1:gppNudE9d19cQ98RYABOetxIhpTCl4m7CnbRZjv github.com/DataDog/sketches-go v1.4.2/go.mod h1:xJIXldczJyyjnbDop7ZZcLxJdV3+7Kra7H1KMgpgkLk= github.com/DataDog/zstd v1.5.5 h1:oWf5W7GtOLgp6bciQYDmhHHjdhYkALu6S/5Ni9ZgSvQ= github.com/DataDog/zstd v1.5.5/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= -github.com/InjectiveLabs/cometbft v0.38.11-inj-3 h1:82i3DrztJxVs1R45wVTUKZ5+8g+HT5KPexu6mB92jaE= -github.com/InjectiveLabs/cometbft v0.38.11-inj-3/go.mod h1:WreBJKC7CtZ9cNsb5p6uNpfCBwNWDu+risVb58GTLfY= +github.com/InjectiveLabs/cometbft v0.38.11-inj-4 h1:WBL3gGcPEYscqpIH+r1IkytmMhoLt247JtO71AlZ/iQ= +github.com/InjectiveLabs/cometbft v0.38.11-inj-4/go.mod h1:WreBJKC7CtZ9cNsb5p6uNpfCBwNWDu+risVb58GTLfY= github.com/InjectiveLabs/cosmos-sdk/store v1.1.1-0.20240522173845-46ef88f66790 h1:F4FYZR9rLg9igzxitFdLU5s7ZU9XS0wUB7DbkBOVXc8= github.com/InjectiveLabs/cosmos-sdk/store v1.1.1-0.20240522173845-46ef88f66790/go.mod h1:ZW4eIE98wivInyQyhxU2nHqEielc/iZAcr41qNyWSrw= github.com/InjectiveLabs/metrics v0.0.10 h1:BoOwXnCtRRIPmq06jcI20pXZYE758eusaCI5jDOoN4U=