Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
tsachiherman committed Jan 29, 2025
1 parent 0f01c2d commit 7e6e941
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion x/dsmr/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ var (
type ChainState interface {
GetNetworkParams() (networdID uint32, subnetID, chainID ids.ID)
GetSignatureParams(ctx context.Context) (validators warp.CanonicalValidatorSet, quorumNum uint64, quorumDen uint64, err error)
GetValidatorSet(ctx context.Context) (map[ids.NodeID]*snowValidators.GetValidatorOutput, error)
GetLatestValidatorSet(ctx context.Context) (map[ids.NodeID]*snowValidators.GetValidatorOutput, error)
}

type Validator struct {
Expand Down
2 changes: 1 addition & 1 deletion x/dsmr/node_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1559,6 +1559,6 @@ func (t *testChainState) GetSignatureParams(ctx context.Context) (warp.Canonical
return canonicalValidators, t.quorumNum, t.quorumDen, err
}

func (t *testChainState) GetValidatorSet(context.Context) (map[ids.NodeID]*validators.GetValidatorOutput, error) {
func (t *testChainState) GetLatestValidatorSet(context.Context) (map[ids.NodeID]*validators.GetValidatorOutput, error) {
return t.getValidatorSet(), nil
}
2 changes: 1 addition & 1 deletion x/dsmr/storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ func (c ChunkVerifier[T]) Verify(chunk Chunk[T]) error {
}

// check if the producer was expected to produce this chunk.
validatorSet, err := c.chainState.GetValidatorSet(context.TODO())
validatorSet, err := c.chainState.GetLatestValidatorSet(context.TODO())
if err != nil {
return fmt.Errorf("%w: failed to retrieve validator set while verifying chunk", err)
}
Expand Down

0 comments on commit 7e6e941

Please sign in to comment.