diff --git a/block/block.go b/block/block.go index 78d8255f9..2785d7719 100644 --- a/block/block.go +++ b/block/block.go @@ -59,10 +59,7 @@ func (m *Manager) applyBlock(block *types.Block, commit *types.Commit, blockMeta } // Get the validator changes from the app - validators, err := m.Executor.NextValSetFromResponses(m.State, responses, block) - if err != nil { - return fmt.Errorf("update state from responses: %w", err) - } + validators := m.State.NextValidators.Copy() // TODO: this will be changed when supporting multiple sequencers from the hub dbBatch, err = m.Store.SaveValidators(block.Header.Height, validators, dbBatch) if err != nil { diff --git a/block/executor_test.go b/block/executor_test.go index e4eca2f55..fe675aa98 100644 --- a/block/executor_test.go +++ b/block/executor_test.go @@ -232,8 +232,7 @@ func TestApplyBlock(t *testing.T) { resp, err = executor.ExecuteBlock(state, block) require.NoError(err) require.NotNil(resp) - vals, err := executor.NextValSetFromResponses(state, resp, block) - require.NoError(err) + vals := state.NextValidators.Copy() // TODO: this will be changed when supporting multiple sequencers from the hub _, _, err = executor.Commit(state, block, resp) require.NoError(err) executor.UpdateStateAfterCommit(state, resp, appHash, block.Header.Height, vals) diff --git a/block/state.go b/block/state.go index 35ca63c3d..5fa53260c 100644 --- a/block/state.go +++ b/block/state.go @@ -104,13 +104,6 @@ func (e *Executor) UpdateMempoolAfterInitChain(s *types.State) { e.mempool.SetPostCheckFn(mempool.PostCheckMaxGas(s.ConsensusParams.Block.MaxGas)) } -// NextValSetFromResponses updates state based on the ABCIResponses. -func (e *Executor) NextValSetFromResponses(state *types.State, resp *tmstate.ABCIResponses, block *types.Block) (*tmtypes.ValidatorSet, error) { - // Dymint ignores any setValidator responses from the app, as it is manages the validator set based on the settlement consensus - // TODO: this will be changed when supporting multiple sequencers from the hub - return state.NextValidators.Copy(), nil -} - // Update state from Commit response func (e *Executor) UpdateStateAfterCommit(s *types.State, resp *tmstate.ABCIResponses, appHash []byte, height uint64, valSet *tmtypes.ValidatorSet) { copy(s.AppHash[:], appHash[:])