diff --git a/app/protocol/flows/v5/blockrelay/ibd_with_headers_proof.go b/app/protocol/flows/v5/blockrelay/ibd_with_headers_proof.go index 2ad059a0e0..455b1c2dc5 100644 --- a/app/protocol/flows/v5/blockrelay/ibd_with_headers_proof.go +++ b/app/protocol/flows/v5/blockrelay/ibd_with_headers_proof.go @@ -286,7 +286,13 @@ func (flow *handleIBDFlow) processBlockWithTrustedData( } err := consensus.ValidateAndInsertBlockWithTrustedData(blockWithTrustedData, false) - return err + if err != nil { + if errors.As(err, &ruleerrors.RuleError{}) { + return protocolerrors.Wrapf(true, err, "failed validating block with trusted data") + } + return err + } + return nil } func (flow *handleIBDFlow) receiveBlockWithTrustedData() (*appmessage.MsgBlockWithTrustedDataV4, bool, error) {