Skip to content

Commit

Permalink
feat(mimicry): return errro when sidecar is missing
Browse files Browse the repository at this point in the history
  • Loading branch information
Savid committed Mar 12, 2024
1 parent 9d57084 commit 4a14067
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/mimicry/p2p/execution/event_transaction.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethpandaops/xatu/pkg/proto/xatu"
"github.com/jellydator/ttlcache/v3"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
"google.golang.org/protobuf/types/known/timestamppb"
"google.golang.org/protobuf/types/known/wrapperspb"
Expand Down Expand Up @@ -112,7 +113,7 @@ func (p *Peer) getTransactionData(ctx context.Context, event *types.Transaction,
sidecarsEmptySize += ethereum.CountConsecutiveEmptyBytes(sidecars, 4)
}
} else {
p.log.WithField("versioned hash", event.Hash().String()).WithField("transaction", event.Hash().String()).Warn("no sidecars found for a type 3 transaction")
return nil, errors.Errorf("no sidecars found for a type 3 transaction %s", event.Hash().String())
}

extra.BlobSidecarsSize = fmt.Sprint(sidecarsSize)
Expand Down

0 comments on commit 4a14067

Please sign in to comment.