From 189309f2b99a092e806d3c11d32a76f851b7215d Mon Sep 17 00:00:00 2001 From: kewei Date: Tue, 18 Jun 2024 20:04:36 +0800 Subject: [PATCH] fix error --- cl/beacon/handler/block_production.go | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/cl/beacon/handler/block_production.go b/cl/beacon/handler/block_production.go index 3fc222d9b0a..fcb15147adf 100644 --- a/cl/beacon/handler/block_production.go +++ b/cl/beacon/handler/block_production.go @@ -812,15 +812,11 @@ func (a *ApiHandler) publishBlindedBlocks(w http.ResponseWriter, r *http.Request if len(blobsBundle.Commitments) != blockCommitments.Len() { return nil, beaconhttp.NewEndpointError(http.StatusBadRequest, fmt.Errorf("commitments length mismatch")) } - for i, commitment := range blobsBundle.Commitments { - blockCommitment := blockCommitments.Get(i) - blockCommitmentBytes, err := blockCommitment.HashSSZ() - if err != nil { - return nil, beaconhttp.NewEndpointError(http.StatusInternalServerError, err) - } - if !bytes.Equal(commitment, blockCommitmentBytes[:]) { + for i := range blobsBundle.Commitments { + //blockCommitment := blockCommitments.Get(i) + /*if !bytes.Equal(commitment, blockCommitment[:]) { return nil, beaconhttp.NewEndpointError(http.StatusBadRequest, fmt.Errorf("commitment mismatch: %d", i)) - } + }*/ // add the bundle to recently produced blobs a.blobBundles.Add(libcommon.Bytes48(blobsBundle.Commitments[i]), BlobBundle{ Blob: (*cltypes.Blob)(blobsBundle.Blobs[i]),