refactor! : bump comet to v1 (#19726)
Co-authored-by: yihuang <yi.codeplayer@gmail.com>
This commit is contained in:
@@ -6,8 +6,8 @@ import (
|
||||
"time"
|
||||
|
||||
abci "github.com/cometbft/cometbft/abci/types"
|
||||
cmtproto "github.com/cometbft/cometbft/api/cometbft/types/v1"
|
||||
cmtjson "github.com/cometbft/cometbft/libs/json"
|
||||
cmtproto "github.com/cometbft/cometbft/proto/tendermint/types"
|
||||
cmttypes "github.com/cometbft/cometbft/types"
|
||||
dbm "github.com/cosmos/cosmos-db"
|
||||
|
||||
@@ -114,7 +114,7 @@ func SetupAtGenesis(appConfig depinject.Config, extraOutputs ...interface{}) (*r
|
||||
|
||||
// NextBlock starts a new block.
|
||||
func NextBlock(app *runtime.App, ctx sdk.Context, jumpTime time.Duration) (sdk.Context, error) {
|
||||
_, err := app.FinalizeBlock(&abci.RequestFinalizeBlock{Height: ctx.BlockHeight(), Time: ctx.BlockTime()})
|
||||
_, err := app.FinalizeBlock(&abci.FinalizeBlockRequest{Height: ctx.BlockHeight(), Time: ctx.BlockTime()})
|
||||
if err != nil {
|
||||
return sdk.Context{}, err
|
||||
}
|
||||
@@ -188,7 +188,7 @@ func SetupWithConfiguration(appConfig depinject.Config, startupConfig StartupCon
|
||||
}
|
||||
|
||||
// init chain will set the validator set and initialize the genesis accounts
|
||||
_, err = app.InitChain(&abci.RequestInitChain{
|
||||
_, err = app.InitChain(&abci.InitChainRequest{
|
||||
Validators: []abci.ValidatorUpdate{},
|
||||
ConsensusParams: DefaultConsensusParams,
|
||||
AppStateBytes: stateBytes,
|
||||
@@ -199,7 +199,7 @@ func SetupWithConfiguration(appConfig depinject.Config, startupConfig StartupCon
|
||||
|
||||
// commit genesis changes
|
||||
if !startupConfig.AtGenesis {
|
||||
_, err = app.FinalizeBlock(&abci.RequestFinalizeBlock{
|
||||
_, err = app.FinalizeBlock(&abci.FinalizeBlockRequest{
|
||||
Height: app.LastBlockHeight() + 1,
|
||||
NextValidatorsHash: valSet.Hash(),
|
||||
})
|
||||
|
||||
@@ -126,7 +126,7 @@ func SignCheckDeliver(
|
||||
bz, err := txCfg.TxEncoder()(tx)
|
||||
require.NoError(t, err)
|
||||
|
||||
resBlock, err := app.FinalizeBlock(&types2.RequestFinalizeBlock{
|
||||
resBlock, err := app.FinalizeBlock(&types2.FinalizeBlockRequest{
|
||||
Height: header.Height,
|
||||
Txs: [][]byte{bz},
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user