Support Capella Blocks for Tool (#12402)

* fix it

* fix it
This commit is contained in:
Nishant Das 2023-05-15 17:59:02 +08:00 committed by GitHub
parent 3b9e974a45
commit 09e22538f9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,6 +4,7 @@ import (
"context"
"flag"
"fmt"
"math"
"time"
"github.com/prysmaticlabs/prysm/v4/config/params"
@ -25,7 +26,7 @@ func main() {
flag.Parse()
ctx := context.Background()
cc, err := grpc.DialContext(ctx, *beacon, grpc.WithInsecure())
cc, err := grpc.DialContext(ctx, *beacon, grpc.WithInsecure(), grpc.WithDefaultCallOptions(grpc.MaxCallRecvMsgSize(math.MaxInt64)))
if err != nil {
panic(err)
}
@ -82,6 +83,8 @@ func wrapBlock(b *v1alpha1.BeaconBlockContainer) interfaces.ReadOnlyBeaconBlock
wb, err = blocks.NewSignedBeaconBlock(bb.AltairBlock)
case *v1alpha1.BeaconBlockContainer_BellatrixBlock:
wb, err = blocks.NewSignedBeaconBlock(bb.BellatrixBlock)
case *v1alpha1.BeaconBlockContainer_CapellaBlock:
wb, err = blocks.NewSignedBeaconBlock(bb.CapellaBlock)
}
if err != nil {
panic("no block")