Skip to content

Commit

Permalink
chore: update error with block height
Browse files Browse the repository at this point in the history
  • Loading branch information
RafilxTenfen committed Sep 17, 2024
1 parent a43b3f1 commit 94b8ff6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion clientcontroller/babylon.go
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ func (bc *BabylonController) QueryFinalityProviderVotingPower(fpPk *btcec.Public
blockHeight,
)
if err != nil {
return 0, fmt.Errorf("failed to query Finality Voting Power at Height: %w", err)
return 0, fmt.Errorf("failed to query Finality Voting Power at Height %d: %w", blockHeight, err)
}

return res.VotingPower, nil
Expand Down
2 changes: 1 addition & 1 deletion finality-provider/service/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ func (app *FinalityProviderApp) SyncFinalityProviderStatus() error {
if err != nil {
// if error occured then the finality-provider is not registered in the Babylon chain yet or
// there is nothing in the voting power table, so it should not start the fp.
allowedErr := fmt.Sprintf("failed to query Finality Voting Power at Height: rpc error: code = Unknown desc = %s: unknown request", bstypes.ErrVotingPowerTableNotUpdated.Wrapf("height: %d", latestBlock.Height).Error())
allowedErr := fmt.Sprintf("failed to query Finality Voting Power at Height %d: rpc error: code = Unknown desc = %s: unknown request", latestBlock.Height, bstypes.ErrVotingPowerTableNotUpdated.Wrapf("height: %d", latestBlock.Height).Error())
if !strings.EqualFold(err.Error(), allowedErr) {
// if nothing was updated in the voting power table, it should consider as zero VP to start to send pub random
continue
Expand Down

0 comments on commit 94b8ff6

Please sign in to comment.