Update state Beacon APIs to Capella (#11708)

* proto

(cherry picked from commit 24f45e021061782ab4d6c101a95368310aad67b6)

* implementation

(cherry picked from commit bbfa22c2053e8176fc004b13ba9c8d62cc3bd352)

# Conflicts:
#	beacon-chain/rpc/apimiddleware/structs.go

* fix compilation error

Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
This commit is contained in:
Radosław Kapka 2022-12-06 01:36:23 +01:00 committed by GitHub
parent 51d35f36f0
commit 7dc966bb3b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
15 changed files with 1062 additions and 141 deletions

View File

@ -548,7 +548,7 @@ func TestProcessWithdrawals(t *testing.T) {
}
checkPostState := func(t *testing.T, expected control, st state.BeaconState) {
l, err := st.LastWithdrawalValidatorIndex()
l, err := st.NextWithdrawalValidatorIndex()
require.NoError(t, err)
require.Equal(t, expected.NextWithdrawalValidatorIndex, l)

View File

@ -95,7 +95,7 @@ func TestUpgradeToCapella(t *testing.T) {
require.NoError(t, err)
require.Equal(t, uint64(0), nwi)
lwvi, err := mSt.LastWithdrawalValidatorIndex()
lwvi, err := mSt.NextWithdrawalValidatorIndex()
require.NoError(t, err)
require.Equal(t, types.ValidatorIndex(0), lwvi)
}

View File

@ -567,6 +567,11 @@ type bellatrixStateResponseJson struct {
Data *BeaconStateBellatrixJson `json:"data"`
}
type capellaStateResponseJson struct {
Version string `json:"version"`
Data *BeaconStateCapellaJson `json:"data"`
}
func serializeV2State(response interface{}) (apimiddleware.RunDefault, []byte, apimiddleware.ErrorJson) {
respContainer, ok := response.(*BeaconStateV2ResponseJson)
if !ok {
@ -590,6 +595,11 @@ func serializeV2State(response interface{}) (apimiddleware.RunDefault, []byte, a
Version: respContainer.Version,
Data: respContainer.Data.BellatrixState,
}
case strings.EqualFold(respContainer.Version, strings.ToLower(ethpbv2.Version_CAPELLA.String())):
actualRespContainer = &capellaStateResponseJson{
Version: respContainer.Version,
Data: respContainer.Data.CapellaState,
}
default:
return false, nil, apimiddleware.InternalServerError(fmt.Errorf("unsupported state version '%s'", respContainer.Version))
}

View File

@ -949,6 +949,21 @@ func TestSerializeV2State(t *testing.T) {
require.NoError(t, json.Unmarshal(j, &bellatrixStateResponseJson{}))
})
t.Run("Capella", func(t *testing.T) {
response := &BeaconStateV2ResponseJson{
Version: ethpbv2.Version_CAPELLA.String(),
Data: &BeaconStateContainerV2Json{
Phase0State: nil,
CapellaState: &BeaconStateCapellaJson{},
},
}
runDefault, j, errJson := serializeV2State(response)
require.Equal(t, nil, errJson)
require.Equal(t, apimiddleware.RunDefault(false), runDefault)
require.NotNil(t, j)
require.NoError(t, json.Unmarshal(j, &capellaStateResponseJson{}))
})
t.Run("incorrect response type", func(t *testing.T) {
runDefault, j, errJson := serializeV2State(&types.Empty{})
require.Equal(t, apimiddleware.RunDefault(false), runDefault)

View File

@ -762,10 +762,41 @@ type BeaconStateBellatrixJson struct {
LatestExecutionPayloadHeader *ExecutionPayloadHeaderJson `json:"latest_execution_payload_header"`
}
type BeaconStateCapellaJson struct {
GenesisTime string `json:"genesis_time"`
GenesisValidatorsRoot string `json:"genesis_validators_root" hex:"true"`
Slot string `json:"slot"`
Fork *ForkJson `json:"fork"`
LatestBlockHeader *BeaconBlockHeaderJson `json:"latest_block_header"`
BlockRoots []string `json:"block_roots" hex:"true"`
StateRoots []string `json:"state_roots" hex:"true"`
HistoricalRoots []string `json:"historical_roots" hex:"true"`
Eth1Data *Eth1DataJson `json:"eth1_data"`
Eth1DataVotes []*Eth1DataJson `json:"eth1_data_votes"`
Eth1DepositIndex string `json:"eth1_deposit_index"`
Validators []*ValidatorJson `json:"validators"`
Balances []string `json:"balances"`
RandaoMixes []string `json:"randao_mixes" hex:"true"`
Slashings []string `json:"slashings"`
PreviousEpochParticipation EpochParticipation `json:"previous_epoch_participation"`
CurrentEpochParticipation EpochParticipation `json:"current_epoch_participation"`
JustificationBits string `json:"justification_bits" hex:"true"`
PreviousJustifiedCheckpoint *CheckpointJson `json:"previous_justified_checkpoint"`
CurrentJustifiedCheckpoint *CheckpointJson `json:"current_justified_checkpoint"`
FinalizedCheckpoint *CheckpointJson `json:"finalized_checkpoint"`
InactivityScores []string `json:"inactivity_scores"`
CurrentSyncCommittee *SyncCommitteeJson `json:"current_sync_committee"`
NextSyncCommittee *SyncCommitteeJson `json:"next_sync_committee"`
LatestExecutionPayloadHeader *ExecutionPayloadHeaderCapellaJson `json:"latest_execution_payload_header"`
NextWithdrawalIndex string `json:"next_withdrawal_index"`
NextWithdrawalValidatorIndex string `json:"next_withdrawal_validator_index"`
}
type BeaconStateContainerV2Json struct {
Phase0State *BeaconStateJson `json:"phase0_state"`
AltairState *BeaconStateAltairJson `json:"altair_state"`
BellatrixState *BeaconStateBellatrixJson `json:"bellatrix_state"`
CapellaState *BeaconStateCapellaJson `json:"capella_state"`
}
type ForkJson struct {

View File

@ -83,6 +83,18 @@ func (ds *Server) GetBeaconStateV2(ctx context.Context, req *ethpbv2.BeaconState
},
ExecutionOptimistic: isOptimistic,
}, nil
case version.Capella:
protoState, err := migration.BeaconStateCapellaToProto(beaconSt)
if err != nil {
return nil, status.Errorf(codes.Internal, "Could not convert state to proto: %v", err)
}
return &ethpbv2.BeaconStateResponseV2{
Version: ethpbv2.Version_CAPELLA,
Data: &ethpbv2.BeaconStateContainer{
State: &ethpbv2.BeaconStateContainer_CapellaState{CapellaState: protoState},
},
ExecutionOptimistic: isOptimistic,
}, nil
default:
return nil, status.Error(codes.Internal, "Unsupported state version")
}
@ -110,6 +122,8 @@ func (ds *Server) GetBeaconStateSSZV2(ctx context.Context, req *ethpbv2.BeaconSt
ver = ethpbv2.Version_ALTAIR
case version.Bellatrix:
ver = ethpbv2.Version_BELLATRIX
case version.Capella:
ver = ethpbv2.Version_CAPELLA
default:
return nil, status.Error(codes.Internal, "Unsupported state version")
}

View File

@ -76,6 +76,23 @@ func TestGetBeaconStateV2(t *testing.T) {
assert.NotNil(t, resp)
assert.Equal(t, ethpbv2.Version_BELLATRIX, resp.Version)
})
t.Run("Capella", func(t *testing.T) {
fakeState, _ := util.DeterministicGenesisStateCapella(t, 1)
server := &Server{
StateFetcher: &testutil.MockFetcher{
BeaconState: fakeState,
},
HeadFetcher: &blockchainmock.ChainService{},
OptimisticModeFetcher: &blockchainmock.ChainService{},
BeaconDB: db,
}
resp, err := server.GetBeaconStateV2(context.Background(), &ethpbv2.BeaconStateRequestV2{
StateId: make([]byte, 0),
})
require.NoError(t, err)
assert.NotNil(t, resp)
assert.Equal(t, ethpbv2.Version_CAPELLA, resp.Version)
})
t.Run("execution optimistic", func(t *testing.T) {
parentRoot := [32]byte{'a'}
blk := util.NewBeaconBlock()
@ -182,6 +199,25 @@ func TestGetBeaconStateSSZV2(t *testing.T) {
assert.DeepEqual(t, sszState, resp.Data)
assert.Equal(t, ethpbv2.Version_BELLATRIX, resp.Version)
})
t.Run("Capella", func(t *testing.T) {
fakeState, _ := util.DeterministicGenesisStateCapella(t, 1)
sszState, err := fakeState.MarshalSSZ()
require.NoError(t, err)
server := &Server{
StateFetcher: &testutil.MockFetcher{
BeaconState: fakeState,
},
}
resp, err := server.GetBeaconStateSSZV2(context.Background(), &ethpbv2.BeaconStateRequestV2{
StateId: make([]byte, 0),
})
require.NoError(t, err)
assert.NotNil(t, resp)
assert.DeepEqual(t, sszState, resp.Data)
assert.Equal(t, ethpbv2.Version_CAPELLA, resp.Version)
})
}
func TestListForkChoiceHeadsV2(t *testing.T) {

View File

@ -170,7 +170,7 @@ type ReadOnlyAttestations interface {
// ReadOnlyWithdrawals defines a struct which only has read access to withdrawal methods.
type ReadOnlyWithdrawals interface {
ExpectedWithdrawals() ([]*enginev1.Withdrawal, error)
LastWithdrawalValidatorIndex() (types.ValidatorIndex, error)
NextWithdrawalValidatorIndex() (types.ValidatorIndex, error)
NextWithdrawalIndex() (uint64, error)
}

View File

@ -24,11 +24,11 @@ func (b *BeaconState) NextWithdrawalIndex() (uint64, error) {
return b.nextWithdrawalIndex, nil
}
// NextPartialWithdrawalValidatorIndex returns the index of the validator which is
// next in line for a partial withdrawal.
func (b *BeaconState) LastWithdrawalValidatorIndex() (types.ValidatorIndex, error) {
// NextWithdrawalValidatorIndex returns the index of the validator which is
// next in line for a withdrawal.
func (b *BeaconState) NextWithdrawalValidatorIndex() (types.ValidatorIndex, error) {
if b.version < version.Capella {
return 0, errNotSupported("LastWithdrawalValidatorIndex", b.version)
return 0, errNotSupported("NextWithdrawalValidatorIndex", b.version)
}
b.lock.RLock()

View File

@ -29,14 +29,14 @@ func TestNextWithdrawalIndex(t *testing.T) {
func TestLastWithdrawalValidatorIndex(t *testing.T) {
t.Run("ok", func(t *testing.T) {
s := BeaconState{version: version.Capella, nextWithdrawalValidatorIndex: 123}
i, err := s.LastWithdrawalValidatorIndex()
i, err := s.NextWithdrawalValidatorIndex()
require.NoError(t, err)
assert.Equal(t, types.ValidatorIndex(123), i)
})
t.Run("version before Capella not supported", func(t *testing.T) {
s := BeaconState{version: version.Bellatrix}
_, err := s.LastWithdrawalValidatorIndex()
assert.ErrorContains(t, "LastWithdrawalValidatorIndex is not supported", err)
_, err := s.NextWithdrawalValidatorIndex()
assert.ErrorContains(t, "NextWithdrawalValidatorIndex is not supported", err)
})
}

View File

@ -70,7 +70,7 @@ func (f FieldIndex) String(_ int) string {
case NextWithdrawalIndex:
return "NextWithdrawalIndex"
case NextWithdrawalValidatorIndex:
return "LastWithdrawalValidatorIndex"
return "NextWithdrawalValidatorIndex"
default:
return ""
}

View File

@ -496,6 +496,261 @@ func (x *BeaconStateBellatrix) GetLatestExecutionPayloadHeader() *v11.ExecutionP
return nil
}
type BeaconStateCapella struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
GenesisTime uint64 `protobuf:"varint,1001,opt,name=genesis_time,json=genesisTime,proto3" json:"genesis_time,omitempty"`
GenesisValidatorsRoot []byte `protobuf:"bytes,1002,opt,name=genesis_validators_root,json=genesisValidatorsRoot,proto3" json:"genesis_validators_root,omitempty" ssz-size:"32"`
Slot github_com_prysmaticlabs_prysm_v3_consensus_types_primitives.Slot `protobuf:"varint,1003,opt,name=slot,proto3" json:"slot,omitempty" cast-type:"github.com/prysmaticlabs/prysm/v3/consensus-types/primitives.Slot"`
Fork *v1.Fork `protobuf:"bytes,1004,opt,name=fork,proto3" json:"fork,omitempty"`
LatestBlockHeader *v1.BeaconBlockHeader `protobuf:"bytes,2001,opt,name=latest_block_header,json=latestBlockHeader,proto3" json:"latest_block_header,omitempty"`
BlockRoots [][]byte `protobuf:"bytes,2002,rep,name=block_roots,json=blockRoots,proto3" json:"block_roots,omitempty" ssz-size:"8192,32"`
StateRoots [][]byte `protobuf:"bytes,2003,rep,name=state_roots,json=stateRoots,proto3" json:"state_roots,omitempty" ssz-size:"8192,32"`
HistoricalRoots [][]byte `protobuf:"bytes,2004,rep,name=historical_roots,json=historicalRoots,proto3" json:"historical_roots,omitempty" ssz-max:"16777216" ssz-size:"?,32"`
Eth1Data *v1.Eth1Data `protobuf:"bytes,3001,opt,name=eth1_data,json=eth1Data,proto3" json:"eth1_data,omitempty"`
Eth1DataVotes []*v1.Eth1Data `protobuf:"bytes,3002,rep,name=eth1_data_votes,json=eth1DataVotes,proto3" json:"eth1_data_votes,omitempty" ssz-max:"2048"`
Eth1DepositIndex uint64 `protobuf:"varint,3003,opt,name=eth1_deposit_index,json=eth1DepositIndex,proto3" json:"eth1_deposit_index,omitempty"`
Validators []*v1.Validator `protobuf:"bytes,4001,rep,name=validators,proto3" json:"validators,omitempty" ssz-max:"1099511627776"`
Balances []uint64 `protobuf:"varint,4002,rep,packed,name=balances,proto3" json:"balances,omitempty" ssz-max:"1099511627776"`
RandaoMixes [][]byte `protobuf:"bytes,5001,rep,name=randao_mixes,json=randaoMixes,proto3" json:"randao_mixes,omitempty" ssz-size:"65536,32"`
Slashings []uint64 `protobuf:"varint,6001,rep,packed,name=slashings,proto3" json:"slashings,omitempty" ssz-size:"8192"`
PreviousEpochParticipation []byte `protobuf:"bytes,7001,opt,name=previous_epoch_participation,json=previousEpochParticipation,proto3" json:"previous_epoch_participation,omitempty" ssz-max:"1099511627776"`
CurrentEpochParticipation []byte `protobuf:"bytes,7002,opt,name=current_epoch_participation,json=currentEpochParticipation,proto3" json:"current_epoch_participation,omitempty" ssz-max:"1099511627776"`
JustificationBits github_com_prysmaticlabs_go_bitfield.Bitvector4 `protobuf:"bytes,8001,opt,name=justification_bits,json=justificationBits,proto3" json:"justification_bits,omitempty" cast-type:"github.com/prysmaticlabs/go-bitfield.Bitvector4" ssz-size:"1"`
PreviousJustifiedCheckpoint *v1.Checkpoint `protobuf:"bytes,8002,opt,name=previous_justified_checkpoint,json=previousJustifiedCheckpoint,proto3" json:"previous_justified_checkpoint,omitempty"`
CurrentJustifiedCheckpoint *v1.Checkpoint `protobuf:"bytes,8003,opt,name=current_justified_checkpoint,json=currentJustifiedCheckpoint,proto3" json:"current_justified_checkpoint,omitempty"`
FinalizedCheckpoint *v1.Checkpoint `protobuf:"bytes,8004,opt,name=finalized_checkpoint,json=finalizedCheckpoint,proto3" json:"finalized_checkpoint,omitempty"`
InactivityScores []uint64 `protobuf:"varint,9001,rep,packed,name=inactivity_scores,json=inactivityScores,proto3" json:"inactivity_scores,omitempty" ssz-max:"1099511627776"`
CurrentSyncCommittee *SyncCommittee `protobuf:"bytes,9002,opt,name=current_sync_committee,json=currentSyncCommittee,proto3" json:"current_sync_committee,omitempty"`
NextSyncCommittee *SyncCommittee `protobuf:"bytes,9003,opt,name=next_sync_committee,json=nextSyncCommittee,proto3" json:"next_sync_committee,omitempty"`
LatestExecutionPayloadHeader *v11.ExecutionPayloadHeaderCapella `protobuf:"bytes,10001,opt,name=latest_execution_payload_header,json=latestExecutionPayloadHeader,proto3" json:"latest_execution_payload_header,omitempty"`
NextWithdrawalIndex uint64 `protobuf:"varint,11001,opt,name=next_withdrawal_index,json=nextWithdrawalIndex,proto3" json:"next_withdrawal_index,omitempty"`
NextWithdrawalValidatorIndex github_com_prysmaticlabs_prysm_v3_consensus_types_primitives.ValidatorIndex `protobuf:"varint,11002,opt,name=next_withdrawal_validator_index,json=nextWithdrawalValidatorIndex,proto3" json:"next_withdrawal_validator_index,omitempty" cast-type:"github.com/prysmaticlabs/prysm/v3/consensus-types/primitives.ValidatorIndex"`
}
func (x *BeaconStateCapella) Reset() {
*x = BeaconStateCapella{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *BeaconStateCapella) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*BeaconStateCapella) ProtoMessage() {}
func (x *BeaconStateCapella) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use BeaconStateCapella.ProtoReflect.Descriptor instead.
func (*BeaconStateCapella) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{2}
}
func (x *BeaconStateCapella) GetGenesisTime() uint64 {
if x != nil {
return x.GenesisTime
}
return 0
}
func (x *BeaconStateCapella) GetGenesisValidatorsRoot() []byte {
if x != nil {
return x.GenesisValidatorsRoot
}
return nil
}
func (x *BeaconStateCapella) GetSlot() github_com_prysmaticlabs_prysm_v3_consensus_types_primitives.Slot {
if x != nil {
return x.Slot
}
return github_com_prysmaticlabs_prysm_v3_consensus_types_primitives.Slot(0)
}
func (x *BeaconStateCapella) GetFork() *v1.Fork {
if x != nil {
return x.Fork
}
return nil
}
func (x *BeaconStateCapella) GetLatestBlockHeader() *v1.BeaconBlockHeader {
if x != nil {
return x.LatestBlockHeader
}
return nil
}
func (x *BeaconStateCapella) GetBlockRoots() [][]byte {
if x != nil {
return x.BlockRoots
}
return nil
}
func (x *BeaconStateCapella) GetStateRoots() [][]byte {
if x != nil {
return x.StateRoots
}
return nil
}
func (x *BeaconStateCapella) GetHistoricalRoots() [][]byte {
if x != nil {
return x.HistoricalRoots
}
return nil
}
func (x *BeaconStateCapella) GetEth1Data() *v1.Eth1Data {
if x != nil {
return x.Eth1Data
}
return nil
}
func (x *BeaconStateCapella) GetEth1DataVotes() []*v1.Eth1Data {
if x != nil {
return x.Eth1DataVotes
}
return nil
}
func (x *BeaconStateCapella) GetEth1DepositIndex() uint64 {
if x != nil {
return x.Eth1DepositIndex
}
return 0
}
func (x *BeaconStateCapella) GetValidators() []*v1.Validator {
if x != nil {
return x.Validators
}
return nil
}
func (x *BeaconStateCapella) GetBalances() []uint64 {
if x != nil {
return x.Balances
}
return nil
}
func (x *BeaconStateCapella) GetRandaoMixes() [][]byte {
if x != nil {
return x.RandaoMixes
}
return nil
}
func (x *BeaconStateCapella) GetSlashings() []uint64 {
if x != nil {
return x.Slashings
}
return nil
}
func (x *BeaconStateCapella) GetPreviousEpochParticipation() []byte {
if x != nil {
return x.PreviousEpochParticipation
}
return nil
}
func (x *BeaconStateCapella) GetCurrentEpochParticipation() []byte {
if x != nil {
return x.CurrentEpochParticipation
}
return nil
}
func (x *BeaconStateCapella) GetJustificationBits() github_com_prysmaticlabs_go_bitfield.Bitvector4 {
if x != nil {
return x.JustificationBits
}
return github_com_prysmaticlabs_go_bitfield.Bitvector4(nil)
}
func (x *BeaconStateCapella) GetPreviousJustifiedCheckpoint() *v1.Checkpoint {
if x != nil {
return x.PreviousJustifiedCheckpoint
}
return nil
}
func (x *BeaconStateCapella) GetCurrentJustifiedCheckpoint() *v1.Checkpoint {
if x != nil {
return x.CurrentJustifiedCheckpoint
}
return nil
}
func (x *BeaconStateCapella) GetFinalizedCheckpoint() *v1.Checkpoint {
if x != nil {
return x.FinalizedCheckpoint
}
return nil
}
func (x *BeaconStateCapella) GetInactivityScores() []uint64 {
if x != nil {
return x.InactivityScores
}
return nil
}
func (x *BeaconStateCapella) GetCurrentSyncCommittee() *SyncCommittee {
if x != nil {
return x.CurrentSyncCommittee
}
return nil
}
func (x *BeaconStateCapella) GetNextSyncCommittee() *SyncCommittee {
if x != nil {
return x.NextSyncCommittee
}
return nil
}
func (x *BeaconStateCapella) GetLatestExecutionPayloadHeader() *v11.ExecutionPayloadHeaderCapella {
if x != nil {
return x.LatestExecutionPayloadHeader
}
return nil
}
func (x *BeaconStateCapella) GetNextWithdrawalIndex() uint64 {
if x != nil {
return x.NextWithdrawalIndex
}
return 0
}
func (x *BeaconStateCapella) GetNextWithdrawalValidatorIndex() github_com_prysmaticlabs_prysm_v3_consensus_types_primitives.ValidatorIndex {
if x != nil {
return x.NextWithdrawalValidatorIndex
}
return github_com_prysmaticlabs_prysm_v3_consensus_types_primitives.ValidatorIndex(0)
}
type BeaconStateRequestV2 struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
@ -507,7 +762,7 @@ type BeaconStateRequestV2 struct {
func (x *BeaconStateRequestV2) Reset() {
*x = BeaconStateRequestV2{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[2]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -520,7 +775,7 @@ func (x *BeaconStateRequestV2) String() string {
func (*BeaconStateRequestV2) ProtoMessage() {}
func (x *BeaconStateRequestV2) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[2]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -533,7 +788,7 @@ func (x *BeaconStateRequestV2) ProtoReflect() protoreflect.Message {
// Deprecated: Use BeaconStateRequestV2.ProtoReflect.Descriptor instead.
func (*BeaconStateRequestV2) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{2}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{3}
}
func (x *BeaconStateRequestV2) GetStateId() []byte {
@ -556,7 +811,7 @@ type BeaconStateResponseV2 struct {
func (x *BeaconStateResponseV2) Reset() {
*x = BeaconStateResponseV2{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[3]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -569,7 +824,7 @@ func (x *BeaconStateResponseV2) String() string {
func (*BeaconStateResponseV2) ProtoMessage() {}
func (x *BeaconStateResponseV2) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[3]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -582,7 +837,7 @@ func (x *BeaconStateResponseV2) ProtoReflect() protoreflect.Message {
// Deprecated: Use BeaconStateResponseV2.ProtoReflect.Descriptor instead.
func (*BeaconStateResponseV2) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{3}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{4}
}
func (x *BeaconStateResponseV2) GetVersion() Version {
@ -618,7 +873,7 @@ type BeaconStateSSZResponseV2 struct {
func (x *BeaconStateSSZResponseV2) Reset() {
*x = BeaconStateSSZResponseV2{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[4]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -631,7 +886,7 @@ func (x *BeaconStateSSZResponseV2) String() string {
func (*BeaconStateSSZResponseV2) ProtoMessage() {}
func (x *BeaconStateSSZResponseV2) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[4]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -644,7 +899,7 @@ func (x *BeaconStateSSZResponseV2) ProtoReflect() protoreflect.Message {
// Deprecated: Use BeaconStateSSZResponseV2.ProtoReflect.Descriptor instead.
func (*BeaconStateSSZResponseV2) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{4}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{5}
}
func (x *BeaconStateSSZResponseV2) GetVersion() Version {
@ -667,16 +922,18 @@ type BeaconStateContainer struct {
unknownFields protoimpl.UnknownFields
// Types that are assignable to State:
//
// *BeaconStateContainer_Phase0State
// *BeaconStateContainer_AltairState
// *BeaconStateContainer_BellatrixState
// *BeaconStateContainer_CapellaState
State isBeaconStateContainer_State `protobuf_oneof:"state"`
}
func (x *BeaconStateContainer) Reset() {
*x = BeaconStateContainer{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[5]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -689,7 +946,7 @@ func (x *BeaconStateContainer) String() string {
func (*BeaconStateContainer) ProtoMessage() {}
func (x *BeaconStateContainer) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[5]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[6]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -702,7 +959,7 @@ func (x *BeaconStateContainer) ProtoReflect() protoreflect.Message {
// Deprecated: Use BeaconStateContainer.ProtoReflect.Descriptor instead.
func (*BeaconStateContainer) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{5}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{6}
}
func (m *BeaconStateContainer) GetState() isBeaconStateContainer_State {
@ -733,6 +990,13 @@ func (x *BeaconStateContainer) GetBellatrixState() *BeaconStateBellatrix {
return nil
}
func (x *BeaconStateContainer) GetCapellaState() *BeaconStateCapella {
if x, ok := x.GetState().(*BeaconStateContainer_CapellaState); ok {
return x.CapellaState
}
return nil
}
type isBeaconStateContainer_State interface {
isBeaconStateContainer_State()
}
@ -749,12 +1013,18 @@ type BeaconStateContainer_BellatrixState struct {
BellatrixState *BeaconStateBellatrix `protobuf:"bytes,3,opt,name=bellatrix_state,json=bellatrixState,proto3,oneof"`
}
type BeaconStateContainer_CapellaState struct {
CapellaState *BeaconStateCapella `protobuf:"bytes,4,opt,name=capella_state,json=capellaState,proto3,oneof"`
}
func (*BeaconStateContainer_Phase0State) isBeaconStateContainer_State() {}
func (*BeaconStateContainer_AltairState) isBeaconStateContainer_State() {}
func (*BeaconStateContainer_BellatrixState) isBeaconStateContainer_State() {}
func (*BeaconStateContainer_CapellaState) isBeaconStateContainer_State() {}
type ForkChoiceHeadsResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
@ -766,7 +1036,7 @@ type ForkChoiceHeadsResponse struct {
func (x *ForkChoiceHeadsResponse) Reset() {
*x = ForkChoiceHeadsResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[6]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -779,7 +1049,7 @@ func (x *ForkChoiceHeadsResponse) String() string {
func (*ForkChoiceHeadsResponse) ProtoMessage() {}
func (x *ForkChoiceHeadsResponse) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[6]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[7]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -792,7 +1062,7 @@ func (x *ForkChoiceHeadsResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use ForkChoiceHeadsResponse.ProtoReflect.Descriptor instead.
func (*ForkChoiceHeadsResponse) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{6}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{7}
}
func (x *ForkChoiceHeadsResponse) GetData() []*ForkChoiceHead {
@ -815,7 +1085,7 @@ type ForkChoiceHead struct {
func (x *ForkChoiceHead) Reset() {
*x = ForkChoiceHead{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[7]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -828,7 +1098,7 @@ func (x *ForkChoiceHead) String() string {
func (*ForkChoiceHead) ProtoMessage() {}
func (x *ForkChoiceHead) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[7]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[8]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -841,7 +1111,7 @@ func (x *ForkChoiceHead) ProtoReflect() protoreflect.Message {
// Deprecated: Use ForkChoiceHead.ProtoReflect.Descriptor instead.
func (*ForkChoiceHead) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{7}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{8}
}
func (x *ForkChoiceHead) GetRoot() []byte {
@ -877,7 +1147,7 @@ type RandaoRequest struct {
func (x *RandaoRequest) Reset() {
*x = RandaoRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[8]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[9]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -890,7 +1160,7 @@ func (x *RandaoRequest) String() string {
func (*RandaoRequest) ProtoMessage() {}
func (x *RandaoRequest) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[8]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[9]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -903,7 +1173,7 @@ func (x *RandaoRequest) ProtoReflect() protoreflect.Message {
// Deprecated: Use RandaoRequest.ProtoReflect.Descriptor instead.
func (*RandaoRequest) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{8}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{9}
}
func (x *RandaoRequest) GetStateId() []byte {
@ -932,7 +1202,7 @@ type RandaoResponse struct {
func (x *RandaoResponse) Reset() {
*x = RandaoResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[9]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[10]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -945,7 +1215,7 @@ func (x *RandaoResponse) String() string {
func (*RandaoResponse) ProtoMessage() {}
func (x *RandaoResponse) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[9]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[10]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -958,7 +1228,7 @@ func (x *RandaoResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use RandaoResponse.ProtoReflect.Descriptor instead.
func (*RandaoResponse) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{9}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{10}
}
func (x *RandaoResponse) GetData() *RandaoResponse_Randao {
@ -986,7 +1256,7 @@ type RandaoResponse_Randao struct {
func (x *RandaoResponse_Randao) Reset() {
*x = RandaoResponse_Randao{}
if protoimpl.UnsafeEnabled {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[10]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[11]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -999,7 +1269,7 @@ func (x *RandaoResponse_Randao) String() string {
func (*RandaoResponse_Randao) ProtoMessage() {}
func (x *RandaoResponse_Randao) ProtoReflect() protoreflect.Message {
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[10]
mi := &file_proto_eth_v2_beacon_state_proto_msgTypes[11]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -1012,7 +1282,7 @@ func (x *RandaoResponse_Randao) ProtoReflect() protoreflect.Message {
// Deprecated: Use RandaoResponse_Randao.ProtoReflect.Descriptor instead.
func (*RandaoResponse_Randao) Descriptor() ([]byte, []int) {
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{9, 0}
return file_proto_eth_v2_beacon_state_proto_rawDescGZIP(), []int{10, 0}
}
func (x *RandaoResponse_Randao) GetRandao() []byte {
@ -1262,43 +1532,174 @@ var file_proto_eth_v2_beacon_state_proto_rawDesc = []byte{
0x65, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61,
0x79, 0x6c, 0x6f, 0x61, 0x64, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x1c, 0x6c, 0x61, 0x74,
0x65, 0x73, 0x74, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61, 0x79, 0x6c,
0x6f, 0x61, 0x64, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x22, 0x31, 0x0a, 0x14, 0x42, 0x65, 0x61,
0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x56,
0x32, 0x12, 0x19, 0x0a, 0x08, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20,
0x01, 0x28, 0x0c, 0x52, 0x07, 0x73, 0x74, 0x61, 0x74, 0x65, 0x49, 0x64, 0x22, 0xb9, 0x01, 0x0a,
0x15, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70,
0x6f, 0x6e, 0x73, 0x65, 0x56, 0x32, 0x12, 0x32, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f,
0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65,
0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f,
0x6e, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x39, 0x0a, 0x04, 0x64, 0x61,
0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72,
0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x65, 0x61, 0x63, 0x6f,
0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x52,
0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x31, 0x0a, 0x14, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69,
0x6f, 0x6e, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x73, 0x74, 0x69, 0x63, 0x18, 0x03, 0x20,
0x01, 0x28, 0x08, 0x52, 0x13, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x4f, 0x70,
0x74, 0x69, 0x6d, 0x69, 0x73, 0x74, 0x69, 0x63, 0x22, 0x62, 0x0a, 0x18, 0x42, 0x65, 0x61, 0x63,
0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x53, 0x53, 0x5a, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
0x73, 0x65, 0x56, 0x32, 0x12, 0x32, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18,
0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d,
0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52,
0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61,
0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0xf7, 0x01, 0x0a,
0x14, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74,
0x61, 0x69, 0x6e, 0x65, 0x72, 0x12, 0x41, 0x0a, 0x0c, 0x70, 0x68, 0x61, 0x73, 0x65, 0x30, 0x5f,
0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x65, 0x74,
0x6f, 0x61, 0x64, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x22, 0xe1, 0x0f, 0x0a, 0x12, 0x42, 0x65,
0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x43, 0x61, 0x70, 0x65, 0x6c, 0x6c, 0x61,
0x12, 0x22, 0x0a, 0x0c, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x5f, 0x74, 0x69, 0x6d, 0x65,
0x18, 0xe9, 0x07, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73,
0x54, 0x69, 0x6d, 0x65, 0x12, 0x3f, 0x0a, 0x17, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x5f,
0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18,
0xea, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x06, 0x8a, 0xb5, 0x18, 0x02, 0x33, 0x32, 0x52, 0x15,
0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72,
0x73, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x5a, 0x0a, 0x04, 0x73, 0x6c, 0x6f, 0x74, 0x18, 0xeb, 0x07,
0x20, 0x01, 0x28, 0x04, 0x42, 0x45, 0x82, 0xb5, 0x18, 0x41, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62,
0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x61, 0x74, 0x69, 0x63, 0x6c, 0x61,
0x62, 0x73, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x33, 0x2f, 0x63, 0x6f, 0x6e, 0x73,
0x65, 0x6e, 0x73, 0x75, 0x73, 0x2d, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d,
0x69, 0x74, 0x69, 0x76, 0x65, 0x73, 0x2e, 0x53, 0x6c, 0x6f, 0x74, 0x52, 0x04, 0x73, 0x6c, 0x6f,
0x74, 0x12, 0x2a, 0x0a, 0x04, 0x66, 0x6f, 0x72, 0x6b, 0x18, 0xec, 0x07, 0x20, 0x01, 0x28, 0x0b,
0x32, 0x15, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e,
0x76, 0x31, 0x2e, 0x46, 0x6f, 0x72, 0x6b, 0x52, 0x04, 0x66, 0x6f, 0x72, 0x6b, 0x12, 0x53, 0x0a,
0x13, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x65,
0x61, 0x64, 0x65, 0x72, 0x18, 0xd1, 0x0f, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x65, 0x74,
0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x65,
0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x48, 0x00, 0x52, 0x0b, 0x70, 0x68, 0x61,
0x73, 0x65, 0x30, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x41, 0x0a, 0x0c, 0x61, 0x6c, 0x74, 0x61,
0x69, 0x72, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c,
0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32,
0x2e, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x48, 0x00, 0x52, 0x0b,
0x61, 0x6c, 0x74, 0x61, 0x69, 0x72, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x50, 0x0a, 0x0f, 0x62,
0x65, 0x6c, 0x6c, 0x61, 0x74, 0x72, 0x69, 0x78, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x03,
0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e,
0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61,
0x74, 0x65, 0x42, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x72, 0x69, 0x78, 0x48, 0x00, 0x52, 0x0e, 0x62,
0x65, 0x6c, 0x6c, 0x61, 0x74, 0x72, 0x69, 0x78, 0x53, 0x74, 0x61, 0x74, 0x65, 0x42, 0x07, 0x0a,
0x61, 0x63, 0x6f, 0x6e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52,
0x11, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x65, 0x61, 0x64,
0x65, 0x72, 0x12, 0x2d, 0x0a, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x72, 0x6f, 0x6f, 0x74,
0x73, 0x18, 0xd2, 0x0f, 0x20, 0x03, 0x28, 0x0c, 0x42, 0x0b, 0x8a, 0xb5, 0x18, 0x07, 0x38, 0x31,
0x39, 0x32, 0x2c, 0x33, 0x32, 0x52, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x6f, 0x6f, 0x74,
0x73, 0x12, 0x2d, 0x0a, 0x0b, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x73,
0x18, 0xd3, 0x0f, 0x20, 0x03, 0x28, 0x0c, 0x42, 0x0b, 0x8a, 0xb5, 0x18, 0x07, 0x38, 0x31, 0x39,
0x32, 0x2c, 0x33, 0x32, 0x52, 0x0a, 0x73, 0x74, 0x61, 0x74, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x73,
0x12, 0x40, 0x0a, 0x10, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c, 0x5f, 0x72,
0x6f, 0x6f, 0x74, 0x73, 0x18, 0xd4, 0x0f, 0x20, 0x03, 0x28, 0x0c, 0x42, 0x14, 0x8a, 0xb5, 0x18,
0x04, 0x3f, 0x2c, 0x33, 0x32, 0x92, 0xb5, 0x18, 0x08, 0x31, 0x36, 0x37, 0x37, 0x37, 0x32, 0x31,
0x36, 0x52, 0x0f, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c, 0x52, 0x6f, 0x6f,
0x74, 0x73, 0x12, 0x37, 0x0a, 0x09, 0x65, 0x74, 0x68, 0x31, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18,
0xb9, 0x17, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75,
0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x74, 0x68, 0x31, 0x44, 0x61, 0x74,
0x61, 0x52, 0x08, 0x65, 0x74, 0x68, 0x31, 0x44, 0x61, 0x74, 0x61, 0x12, 0x4c, 0x0a, 0x0f, 0x65,
0x74, 0x68, 0x31, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x76, 0x6f, 0x74, 0x65, 0x73, 0x18, 0xba,
0x17, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d,
0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x74, 0x68, 0x31, 0x44, 0x61, 0x74, 0x61,
0x42, 0x08, 0x92, 0xb5, 0x18, 0x04, 0x32, 0x30, 0x34, 0x38, 0x52, 0x0d, 0x65, 0x74, 0x68, 0x31,
0x44, 0x61, 0x74, 0x61, 0x56, 0x6f, 0x74, 0x65, 0x73, 0x12, 0x2d, 0x0a, 0x12, 0x65, 0x74, 0x68,
0x31, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18,
0xbb, 0x17, 0x20, 0x01, 0x28, 0x04, 0x52, 0x10, 0x65, 0x74, 0x68, 0x31, 0x44, 0x65, 0x70, 0x6f,
0x73, 0x69, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x4e, 0x0a, 0x0a, 0x76, 0x61, 0x6c, 0x69,
0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0xa1, 0x1f, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e,
0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x2e,
0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x42, 0x11, 0x92, 0xb5, 0x18, 0x0d, 0x31,
0x30, 0x39, 0x39, 0x35, 0x31, 0x31, 0x36, 0x32, 0x37, 0x37, 0x37, 0x36, 0x52, 0x0a, 0x76, 0x61,
0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x12, 0x2e, 0x0a, 0x08, 0x62, 0x61, 0x6c, 0x61,
0x6e, 0x63, 0x65, 0x73, 0x18, 0xa2, 0x1f, 0x20, 0x03, 0x28, 0x04, 0x42, 0x11, 0x92, 0xb5, 0x18,
0x0d, 0x31, 0x30, 0x39, 0x39, 0x35, 0x31, 0x31, 0x36, 0x32, 0x37, 0x37, 0x37, 0x36, 0x52, 0x08,
0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x30, 0x0a, 0x0c, 0x72, 0x61, 0x6e, 0x64,
0x61, 0x6f, 0x5f, 0x6d, 0x69, 0x78, 0x65, 0x73, 0x18, 0x89, 0x27, 0x20, 0x03, 0x28, 0x0c, 0x42,
0x0c, 0x8a, 0xb5, 0x18, 0x08, 0x36, 0x35, 0x35, 0x33, 0x36, 0x2c, 0x33, 0x32, 0x52, 0x0b, 0x72,
0x61, 0x6e, 0x64, 0x61, 0x6f, 0x4d, 0x69, 0x78, 0x65, 0x73, 0x12, 0x27, 0x0a, 0x09, 0x73, 0x6c,
0x61, 0x73, 0x68, 0x69, 0x6e, 0x67, 0x73, 0x18, 0xf1, 0x2e, 0x20, 0x03, 0x28, 0x04, 0x42, 0x08,
0x8a, 0xb5, 0x18, 0x04, 0x38, 0x31, 0x39, 0x32, 0x52, 0x09, 0x73, 0x6c, 0x61, 0x73, 0x68, 0x69,
0x6e, 0x67, 0x73, 0x12, 0x54, 0x0a, 0x1c, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x5f,
0x65, 0x70, 0x6f, 0x63, 0x68, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74,
0x69, 0x6f, 0x6e, 0x18, 0xd9, 0x36, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x11, 0x92, 0xb5, 0x18, 0x0d,
0x31, 0x30, 0x39, 0x39, 0x35, 0x31, 0x31, 0x36, 0x32, 0x37, 0x37, 0x37, 0x36, 0x52, 0x1a, 0x70,
0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x45, 0x70, 0x6f, 0x63, 0x68, 0x50, 0x61, 0x72, 0x74,
0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x52, 0x0a, 0x1b, 0x63, 0x75, 0x72,
0x72, 0x65, 0x6e, 0x74, 0x5f, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x69,
0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xda, 0x36, 0x20, 0x01, 0x28, 0x0c, 0x42,
0x11, 0x92, 0xb5, 0x18, 0x0d, 0x31, 0x30, 0x39, 0x39, 0x35, 0x31, 0x31, 0x36, 0x32, 0x37, 0x37,
0x37, 0x36, 0x52, 0x19, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x45, 0x70, 0x6f, 0x63, 0x68,
0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x68, 0x0a,
0x12, 0x6a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x62,
0x69, 0x74, 0x73, 0x18, 0xc1, 0x3e, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x38, 0x8a, 0xb5, 0x18, 0x01,
0x31, 0x82, 0xb5, 0x18, 0x2f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
0x70, 0x72, 0x79, 0x73, 0x6d, 0x61, 0x74, 0x69, 0x63, 0x6c, 0x61, 0x62, 0x73, 0x2f, 0x67, 0x6f,
0x2d, 0x62, 0x69, 0x74, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x2e, 0x42, 0x69, 0x74, 0x76, 0x65, 0x63,
0x74, 0x6f, 0x72, 0x34, 0x52, 0x11, 0x6a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74,
0x69, 0x6f, 0x6e, 0x42, 0x69, 0x74, 0x73, 0x12, 0x60, 0x0a, 0x1d, 0x70, 0x72, 0x65, 0x76, 0x69,
0x6f, 0x75, 0x73, 0x5f, 0x6a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x65, 0x64, 0x5f, 0x63, 0x68,
0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0xc2, 0x3e, 0x20, 0x01, 0x28, 0x0b, 0x32,
0x1b, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76,
0x31, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x52, 0x1b, 0x70, 0x72,
0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x4a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x65, 0x64, 0x43,
0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x5e, 0x0a, 0x1c, 0x63, 0x75, 0x72,
0x72, 0x65, 0x6e, 0x74, 0x5f, 0x6a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x65, 0x64, 0x5f, 0x63,
0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0xc3, 0x3e, 0x20, 0x01, 0x28, 0x0b,
0x32, 0x1b, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e,
0x76, 0x31, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x52, 0x1a, 0x63,
0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x4a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x65, 0x64, 0x43,
0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x4f, 0x0a, 0x14, 0x66, 0x69, 0x6e,
0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x5f, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e,
0x74, 0x18, 0xc4, 0x3e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72,
0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b,
0x70, 0x6f, 0x69, 0x6e, 0x74, 0x52, 0x13, 0x66, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64,
0x43, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x3f, 0x0a, 0x11, 0x69, 0x6e,
0x61, 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79, 0x5f, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x73, 0x18,
0xa9, 0x46, 0x20, 0x03, 0x28, 0x04, 0x42, 0x11, 0x92, 0xb5, 0x18, 0x0d, 0x31, 0x30, 0x39, 0x39,
0x35, 0x31, 0x31, 0x36, 0x32, 0x37, 0x37, 0x37, 0x36, 0x52, 0x10, 0x69, 0x6e, 0x61, 0x63, 0x74,
0x69, 0x76, 0x69, 0x74, 0x79, 0x53, 0x63, 0x6f, 0x72, 0x65, 0x73, 0x12, 0x55, 0x0a, 0x16, 0x63,
0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x73, 0x79, 0x6e, 0x63, 0x5f, 0x63, 0x6f, 0x6d, 0x6d,
0x69, 0x74, 0x74, 0x65, 0x65, 0x18, 0xaa, 0x46, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x65,
0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x53,
0x79, 0x6e, 0x63, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x74, 0x65, 0x65, 0x52, 0x14, 0x63, 0x75,
0x72, 0x72, 0x65, 0x6e, 0x74, 0x53, 0x79, 0x6e, 0x63, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x74,
0x65, 0x65, 0x12, 0x4f, 0x0a, 0x13, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x73, 0x79, 0x6e, 0x63, 0x5f,
0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x74, 0x65, 0x65, 0x18, 0xab, 0x46, 0x20, 0x01, 0x28, 0x0b,
0x32, 0x1e, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e,
0x76, 0x32, 0x2e, 0x53, 0x79, 0x6e, 0x63, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x74, 0x65, 0x65,
0x52, 0x11, 0x6e, 0x65, 0x78, 0x74, 0x53, 0x79, 0x6e, 0x63, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74,
0x74, 0x65, 0x65, 0x12, 0x79, 0x0a, 0x1f, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x65, 0x78,
0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x5f,
0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x91, 0x4e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x31, 0x2e,
0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x2e,
0x76, 0x31, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61, 0x79, 0x6c,
0x6f, 0x61, 0x64, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x43, 0x61, 0x70, 0x65, 0x6c, 0x6c, 0x61,
0x52, 0x1c, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f,
0x6e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x33,
0x0a, 0x15, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61,
0x6c, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0xf9, 0x55, 0x20, 0x01, 0x28, 0x04, 0x52, 0x13,
0x6e, 0x65, 0x78, 0x74, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x49, 0x6e,
0x64, 0x65, 0x78, 0x12, 0x97, 0x01, 0x0a, 0x1f, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x77, 0x69, 0x74,
0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f,
0x72, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0xfa, 0x55, 0x20, 0x01, 0x28, 0x04, 0x42, 0x4f,
0x82, 0xb5, 0x18, 0x4b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x70,
0x72, 0x79, 0x73, 0x6d, 0x61, 0x74, 0x69, 0x63, 0x6c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72, 0x79,
0x73, 0x6d, 0x2f, 0x76, 0x33, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2d,
0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65, 0x73,
0x2e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x52,
0x1c, 0x6e, 0x65, 0x78, 0x74, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x56,
0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x31, 0x0a,
0x14, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75,
0x65, 0x73, 0x74, 0x56, 0x32, 0x12, 0x19, 0x0a, 0x08, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x69,
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x73, 0x74, 0x61, 0x74, 0x65, 0x49, 0x64,
0x22, 0xb9, 0x01, 0x0a, 0x15, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65,
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x32, 0x12, 0x32, 0x0a, 0x07, 0x76, 0x65,
0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x65, 0x74,
0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x56, 0x65,
0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x39,
0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x65,
0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x42,
0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69,
0x6e, 0x65, 0x72, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x31, 0x0a, 0x14, 0x65, 0x78, 0x65,
0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x73, 0x74, 0x69,
0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x13, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69,
0x6f, 0x6e, 0x4f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x73, 0x74, 0x69, 0x63, 0x22, 0x62, 0x0a, 0x18,
0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x53, 0x53, 0x5a, 0x52, 0x65,
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x32, 0x12, 0x32, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73,
0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x65, 0x74, 0x68, 0x65,
0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x56, 0x65, 0x72, 0x73,
0x69, 0x6f, 0x6e, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04,
0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61,
0x22, 0xc3, 0x02, 0x0a, 0x14, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65,
0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x12, 0x41, 0x0a, 0x0c, 0x70, 0x68, 0x61,
0x73, 0x65, 0x30, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32,
0x1c, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76,
0x31, 0x2e, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x48, 0x00, 0x52,
0x0b, 0x70, 0x68, 0x61, 0x73, 0x65, 0x30, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x41, 0x0a, 0x0c,
0x61, 0x6c, 0x74, 0x61, 0x69, 0x72, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x02, 0x20, 0x01,
0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74,
0x68, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65,
0x48, 0x00, 0x52, 0x0b, 0x61, 0x6c, 0x74, 0x61, 0x69, 0x72, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12,
0x50, 0x0a, 0x0f, 0x62, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x72, 0x69, 0x78, 0x5f, 0x73, 0x74, 0x61,
0x74, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72,
0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x65, 0x61, 0x63, 0x6f,
0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x42, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x72, 0x69, 0x78, 0x48,
0x00, 0x52, 0x0e, 0x62, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x72, 0x69, 0x78, 0x53, 0x74, 0x61, 0x74,
0x65, 0x12, 0x4a, 0x0a, 0x0d, 0x63, 0x61, 0x70, 0x65, 0x6c, 0x6c, 0x61, 0x5f, 0x73, 0x74, 0x61,
0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72,
0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x65, 0x61, 0x63, 0x6f,
0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x43, 0x61, 0x70, 0x65, 0x6c, 0x6c, 0x61, 0x48, 0x00, 0x52,
0x0c, 0x63, 0x61, 0x70, 0x65, 0x6c, 0x6c, 0x61, 0x53, 0x74, 0x61, 0x74, 0x65, 0x42, 0x07, 0x0a,
0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x22, 0x4e, 0x0a, 0x17, 0x46, 0x6f, 0x72, 0x6b, 0x43, 0x68,
0x6f, 0x69, 0x63, 0x65, 0x48, 0x65, 0x61, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
0x65, 0x12, 0x33, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32,
@ -1360,64 +1761,78 @@ func file_proto_eth_v2_beacon_state_proto_rawDescGZIP() []byte {
return file_proto_eth_v2_beacon_state_proto_rawDescData
}
var file_proto_eth_v2_beacon_state_proto_msgTypes = make([]protoimpl.MessageInfo, 11)
var file_proto_eth_v2_beacon_state_proto_msgTypes = make([]protoimpl.MessageInfo, 12)
var file_proto_eth_v2_beacon_state_proto_goTypes = []interface{}{
(*BeaconState)(nil), // 0: ethereum.eth.v2.BeaconState
(*BeaconStateBellatrix)(nil), // 1: ethereum.eth.v2.BeaconStateBellatrix
(*BeaconStateRequestV2)(nil), // 2: ethereum.eth.v2.BeaconStateRequestV2
(*BeaconStateResponseV2)(nil), // 3: ethereum.eth.v2.BeaconStateResponseV2
(*BeaconStateSSZResponseV2)(nil), // 4: ethereum.eth.v2.BeaconStateSSZResponseV2
(*BeaconStateContainer)(nil), // 5: ethereum.eth.v2.BeaconStateContainer
(*ForkChoiceHeadsResponse)(nil), // 6: ethereum.eth.v2.ForkChoiceHeadsResponse
(*ForkChoiceHead)(nil), // 7: ethereum.eth.v2.ForkChoiceHead
(*RandaoRequest)(nil), // 8: ethereum.eth.v2.RandaoRequest
(*RandaoResponse)(nil), // 9: ethereum.eth.v2.RandaoResponse
(*RandaoResponse_Randao)(nil), // 10: ethereum.eth.v2.RandaoResponse.Randao
(*v1.Fork)(nil), // 11: ethereum.eth.v1.Fork
(*v1.BeaconBlockHeader)(nil), // 12: ethereum.eth.v1.BeaconBlockHeader
(*v1.Eth1Data)(nil), // 13: ethereum.eth.v1.Eth1Data
(*v1.Validator)(nil), // 14: ethereum.eth.v1.Validator
(*v1.Checkpoint)(nil), // 15: ethereum.eth.v1.Checkpoint
(*SyncCommittee)(nil), // 16: ethereum.eth.v2.SyncCommittee
(*v11.ExecutionPayloadHeader)(nil), // 17: ethereum.engine.v1.ExecutionPayloadHeader
(Version)(0), // 18: ethereum.eth.v2.Version
(*v1.BeaconState)(nil), // 19: ethereum.eth.v1.BeaconState
(*BeaconState)(nil), // 0: ethereum.eth.v2.BeaconState
(*BeaconStateBellatrix)(nil), // 1: ethereum.eth.v2.BeaconStateBellatrix
(*BeaconStateCapella)(nil), // 2: ethereum.eth.v2.BeaconStateCapella
(*BeaconStateRequestV2)(nil), // 3: ethereum.eth.v2.BeaconStateRequestV2
(*BeaconStateResponseV2)(nil), // 4: ethereum.eth.v2.BeaconStateResponseV2
(*BeaconStateSSZResponseV2)(nil), // 5: ethereum.eth.v2.BeaconStateSSZResponseV2
(*BeaconStateContainer)(nil), // 6: ethereum.eth.v2.BeaconStateContainer
(*ForkChoiceHeadsResponse)(nil), // 7: ethereum.eth.v2.ForkChoiceHeadsResponse
(*ForkChoiceHead)(nil), // 8: ethereum.eth.v2.ForkChoiceHead
(*RandaoRequest)(nil), // 9: ethereum.eth.v2.RandaoRequest
(*RandaoResponse)(nil), // 10: ethereum.eth.v2.RandaoResponse
(*RandaoResponse_Randao)(nil), // 11: ethereum.eth.v2.RandaoResponse.Randao
(*v1.Fork)(nil), // 12: ethereum.eth.v1.Fork
(*v1.BeaconBlockHeader)(nil), // 13: ethereum.eth.v1.BeaconBlockHeader
(*v1.Eth1Data)(nil), // 14: ethereum.eth.v1.Eth1Data
(*v1.Validator)(nil), // 15: ethereum.eth.v1.Validator
(*v1.Checkpoint)(nil), // 16: ethereum.eth.v1.Checkpoint
(*SyncCommittee)(nil), // 17: ethereum.eth.v2.SyncCommittee
(*v11.ExecutionPayloadHeader)(nil), // 18: ethereum.engine.v1.ExecutionPayloadHeader
(*v11.ExecutionPayloadHeaderCapella)(nil), // 19: ethereum.engine.v1.ExecutionPayloadHeaderCapella
(Version)(0), // 20: ethereum.eth.v2.Version
(*v1.BeaconState)(nil), // 21: ethereum.eth.v1.BeaconState
}
var file_proto_eth_v2_beacon_state_proto_depIdxs = []int32{
11, // 0: ethereum.eth.v2.BeaconState.fork:type_name -> ethereum.eth.v1.Fork
12, // 1: ethereum.eth.v2.BeaconState.latest_block_header:type_name -> ethereum.eth.v1.BeaconBlockHeader
13, // 2: ethereum.eth.v2.BeaconState.eth1_data:type_name -> ethereum.eth.v1.Eth1Data
13, // 3: ethereum.eth.v2.BeaconState.eth1_data_votes:type_name -> ethereum.eth.v1.Eth1Data
14, // 4: ethereum.eth.v2.BeaconState.validators:type_name -> ethereum.eth.v1.Validator
15, // 5: ethereum.eth.v2.BeaconState.previous_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
15, // 6: ethereum.eth.v2.BeaconState.current_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
15, // 7: ethereum.eth.v2.BeaconState.finalized_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
16, // 8: ethereum.eth.v2.BeaconState.current_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
16, // 9: ethereum.eth.v2.BeaconState.next_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
11, // 10: ethereum.eth.v2.BeaconStateBellatrix.fork:type_name -> ethereum.eth.v1.Fork
12, // 11: ethereum.eth.v2.BeaconStateBellatrix.latest_block_header:type_name -> ethereum.eth.v1.BeaconBlockHeader
13, // 12: ethereum.eth.v2.BeaconStateBellatrix.eth1_data:type_name -> ethereum.eth.v1.Eth1Data
13, // 13: ethereum.eth.v2.BeaconStateBellatrix.eth1_data_votes:type_name -> ethereum.eth.v1.Eth1Data
14, // 14: ethereum.eth.v2.BeaconStateBellatrix.validators:type_name -> ethereum.eth.v1.Validator
15, // 15: ethereum.eth.v2.BeaconStateBellatrix.previous_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
15, // 16: ethereum.eth.v2.BeaconStateBellatrix.current_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
15, // 17: ethereum.eth.v2.BeaconStateBellatrix.finalized_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
16, // 18: ethereum.eth.v2.BeaconStateBellatrix.current_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
16, // 19: ethereum.eth.v2.BeaconStateBellatrix.next_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
17, // 20: ethereum.eth.v2.BeaconStateBellatrix.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeader
18, // 21: ethereum.eth.v2.BeaconStateResponseV2.version:type_name -> ethereum.eth.v2.Version
5, // 22: ethereum.eth.v2.BeaconStateResponseV2.data:type_name -> ethereum.eth.v2.BeaconStateContainer
18, // 23: ethereum.eth.v2.BeaconStateSSZResponseV2.version:type_name -> ethereum.eth.v2.Version
19, // 24: ethereum.eth.v2.BeaconStateContainer.phase0_state:type_name -> ethereum.eth.v1.BeaconState
0, // 25: ethereum.eth.v2.BeaconStateContainer.altair_state:type_name -> ethereum.eth.v2.BeaconState
1, // 26: ethereum.eth.v2.BeaconStateContainer.bellatrix_state:type_name -> ethereum.eth.v2.BeaconStateBellatrix
7, // 27: ethereum.eth.v2.ForkChoiceHeadsResponse.data:type_name -> ethereum.eth.v2.ForkChoiceHead
10, // 28: ethereum.eth.v2.RandaoResponse.data:type_name -> ethereum.eth.v2.RandaoResponse.Randao
29, // [29:29] is the sub-list for method output_type
29, // [29:29] is the sub-list for method input_type
29, // [29:29] is the sub-list for extension type_name
29, // [29:29] is the sub-list for extension extendee
0, // [0:29] is the sub-list for field type_name
12, // 0: ethereum.eth.v2.BeaconState.fork:type_name -> ethereum.eth.v1.Fork
13, // 1: ethereum.eth.v2.BeaconState.latest_block_header:type_name -> ethereum.eth.v1.BeaconBlockHeader
14, // 2: ethereum.eth.v2.BeaconState.eth1_data:type_name -> ethereum.eth.v1.Eth1Data
14, // 3: ethereum.eth.v2.BeaconState.eth1_data_votes:type_name -> ethereum.eth.v1.Eth1Data
15, // 4: ethereum.eth.v2.BeaconState.validators:type_name -> ethereum.eth.v1.Validator
16, // 5: ethereum.eth.v2.BeaconState.previous_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
16, // 6: ethereum.eth.v2.BeaconState.current_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
16, // 7: ethereum.eth.v2.BeaconState.finalized_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
17, // 8: ethereum.eth.v2.BeaconState.current_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
17, // 9: ethereum.eth.v2.BeaconState.next_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
12, // 10: ethereum.eth.v2.BeaconStateBellatrix.fork:type_name -> ethereum.eth.v1.Fork
13, // 11: ethereum.eth.v2.BeaconStateBellatrix.latest_block_header:type_name -> ethereum.eth.v1.BeaconBlockHeader
14, // 12: ethereum.eth.v2.BeaconStateBellatrix.eth1_data:type_name -> ethereum.eth.v1.Eth1Data
14, // 13: ethereum.eth.v2.BeaconStateBellatrix.eth1_data_votes:type_name -> ethereum.eth.v1.Eth1Data
15, // 14: ethereum.eth.v2.BeaconStateBellatrix.validators:type_name -> ethereum.eth.v1.Validator
16, // 15: ethereum.eth.v2.BeaconStateBellatrix.previous_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
16, // 16: ethereum.eth.v2.BeaconStateBellatrix.current_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
16, // 17: ethereum.eth.v2.BeaconStateBellatrix.finalized_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
17, // 18: ethereum.eth.v2.BeaconStateBellatrix.current_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
17, // 19: ethereum.eth.v2.BeaconStateBellatrix.next_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
18, // 20: ethereum.eth.v2.BeaconStateBellatrix.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeader
12, // 21: ethereum.eth.v2.BeaconStateCapella.fork:type_name -> ethereum.eth.v1.Fork
13, // 22: ethereum.eth.v2.BeaconStateCapella.latest_block_header:type_name -> ethereum.eth.v1.BeaconBlockHeader
14, // 23: ethereum.eth.v2.BeaconStateCapella.eth1_data:type_name -> ethereum.eth.v1.Eth1Data
14, // 24: ethereum.eth.v2.BeaconStateCapella.eth1_data_votes:type_name -> ethereum.eth.v1.Eth1Data
15, // 25: ethereum.eth.v2.BeaconStateCapella.validators:type_name -> ethereum.eth.v1.Validator
16, // 26: ethereum.eth.v2.BeaconStateCapella.previous_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
16, // 27: ethereum.eth.v2.BeaconStateCapella.current_justified_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
16, // 28: ethereum.eth.v2.BeaconStateCapella.finalized_checkpoint:type_name -> ethereum.eth.v1.Checkpoint
17, // 29: ethereum.eth.v2.BeaconStateCapella.current_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
17, // 30: ethereum.eth.v2.BeaconStateCapella.next_sync_committee:type_name -> ethereum.eth.v2.SyncCommittee
19, // 31: ethereum.eth.v2.BeaconStateCapella.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderCapella
20, // 32: ethereum.eth.v2.BeaconStateResponseV2.version:type_name -> ethereum.eth.v2.Version
6, // 33: ethereum.eth.v2.BeaconStateResponseV2.data:type_name -> ethereum.eth.v2.BeaconStateContainer
20, // 34: ethereum.eth.v2.BeaconStateSSZResponseV2.version:type_name -> ethereum.eth.v2.Version
21, // 35: ethereum.eth.v2.BeaconStateContainer.phase0_state:type_name -> ethereum.eth.v1.BeaconState
0, // 36: ethereum.eth.v2.BeaconStateContainer.altair_state:type_name -> ethereum.eth.v2.BeaconState
1, // 37: ethereum.eth.v2.BeaconStateContainer.bellatrix_state:type_name -> ethereum.eth.v2.BeaconStateBellatrix
2, // 38: ethereum.eth.v2.BeaconStateContainer.capella_state:type_name -> ethereum.eth.v2.BeaconStateCapella
8, // 39: ethereum.eth.v2.ForkChoiceHeadsResponse.data:type_name -> ethereum.eth.v2.ForkChoiceHead
11, // 40: ethereum.eth.v2.RandaoResponse.data:type_name -> ethereum.eth.v2.RandaoResponse.Randao
41, // [41:41] is the sub-list for method output_type
41, // [41:41] is the sub-list for method input_type
41, // [41:41] is the sub-list for extension type_name
41, // [41:41] is the sub-list for extension extendee
0, // [0:41] is the sub-list for field type_name
}
func init() { file_proto_eth_v2_beacon_state_proto_init() }
@ -1453,7 +1868,7 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*BeaconStateRequestV2); i {
switch v := v.(*BeaconStateCapella); i {
case 0:
return &v.state
case 1:
@ -1465,7 +1880,7 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*BeaconStateResponseV2); i {
switch v := v.(*BeaconStateRequestV2); i {
case 0:
return &v.state
case 1:
@ -1477,7 +1892,7 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*BeaconStateSSZResponseV2); i {
switch v := v.(*BeaconStateResponseV2); i {
case 0:
return &v.state
case 1:
@ -1489,7 +1904,7 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*BeaconStateContainer); i {
switch v := v.(*BeaconStateSSZResponseV2); i {
case 0:
return &v.state
case 1:
@ -1501,7 +1916,7 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*ForkChoiceHeadsResponse); i {
switch v := v.(*BeaconStateContainer); i {
case 0:
return &v.state
case 1:
@ -1513,7 +1928,7 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*ForkChoiceHead); i {
switch v := v.(*ForkChoiceHeadsResponse); i {
case 0:
return &v.state
case 1:
@ -1525,7 +1940,7 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*RandaoRequest); i {
switch v := v.(*ForkChoiceHead); i {
case 0:
return &v.state
case 1:
@ -1537,7 +1952,7 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*RandaoResponse); i {
switch v := v.(*RandaoRequest); i {
case 0:
return &v.state
case 1:
@ -1549,6 +1964,18 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*RandaoResponse); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*RandaoResponse_Randao); i {
case 0:
return &v.state
@ -1561,19 +1988,20 @@ func file_proto_eth_v2_beacon_state_proto_init() {
}
}
}
file_proto_eth_v2_beacon_state_proto_msgTypes[5].OneofWrappers = []interface{}{
file_proto_eth_v2_beacon_state_proto_msgTypes[6].OneofWrappers = []interface{}{
(*BeaconStateContainer_Phase0State)(nil),
(*BeaconStateContainer_AltairState)(nil),
(*BeaconStateContainer_BellatrixState)(nil),
(*BeaconStateContainer_CapellaState)(nil),
}
file_proto_eth_v2_beacon_state_proto_msgTypes[8].OneofWrappers = []interface{}{}
file_proto_eth_v2_beacon_state_proto_msgTypes[9].OneofWrappers = []interface{}{}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_proto_eth_v2_beacon_state_proto_rawDesc,
NumEnums: 0,
NumMessages: 11,
NumMessages: 12,
NumExtensions: 0,
NumServices: 0,
},

View File

@ -121,7 +121,59 @@ message BeaconStateBellatrix {
SyncCommittee next_sync_committee = 9003; // [New in Altair]
// Bellatrix fields [10001-11000]
engine.v1.ExecutionPayloadHeader latest_execution_payload_header = 10001; // [New in Bellatrix]
engine.v1.ExecutionPayloadHeader latest_execution_payload_header = 10001; // [New in Bellatrix]
}
message BeaconStateCapella {
// Versioning [1001-2000]
uint64 genesis_time = 1001;
bytes genesis_validators_root = 1002 [(ethereum.eth.ext.ssz_size) = "32"];
uint64 slot = 1003 [(ethereum.eth.ext.cast_type) = "github.com/prysmaticlabs/prysm/v3/consensus-types/primitives.Slot"];
v1.Fork fork = 1004;
// History [2001-3000]
v1.BeaconBlockHeader latest_block_header = 2001;
repeated bytes block_roots = 2002 [(ethereum.eth.ext.ssz_size) = "block_roots.size"];
repeated bytes state_roots = 2003 [(ethereum.eth.ext.ssz_size) = "state_roots.size"];
repeated bytes historical_roots = 2004 [(ethereum.eth.ext.ssz_size) = "?,32", (ethereum.eth.ext.ssz_max) = "16777216"];
// Eth1 [3001-4000]
v1.Eth1Data eth1_data = 3001;
repeated v1.Eth1Data eth1_data_votes = 3002 [(ethereum.eth.ext.ssz_max) = "eth1_data_votes.size"];
uint64 eth1_deposit_index = 3003;
// Registry [4001-5000]
repeated v1.Validator validators = 4001 [(ethereum.eth.ext.ssz_max) = "1099511627776"];
repeated uint64 balances = 4002 [(ethereum.eth.ext.ssz_max) = "1099511627776"];
// Randomness [5001-6000]
repeated bytes randao_mixes = 5001 [(ethereum.eth.ext.ssz_size) = "randao_mixes.size"];
// Slashings [6001-7000]
repeated uint64 slashings = 6001 [(ethereum.eth.ext.ssz_size) = "slashings.size"];
// Participation [7001-8000]
bytes previous_epoch_participation = 7001 [(ethereum.eth.ext.ssz_max) = "1099511627776"];
bytes current_epoch_participation = 7002 [(ethereum.eth.ext.ssz_max) = "1099511627776"];
// Finality [8001-9000]
// Spec type [4]Bitvector which means this would be a fixed size of 4 bits.
bytes justification_bits = 8001 [(ethereum.eth.ext.ssz_size) = "1", (ethereum.eth.ext.cast_type) = "github.com/prysmaticlabs/go-bitfield.Bitvector4"];
v1.Checkpoint previous_justified_checkpoint = 8002;
v1.Checkpoint current_justified_checkpoint = 8003;
v1.Checkpoint finalized_checkpoint = 8004;
// Altair fields [9001-10000]
repeated uint64 inactivity_scores = 9001 [(ethereum.eth.ext.ssz_max) = "1099511627776"];
SyncCommittee current_sync_committee = 9002; // [New in Altair]
SyncCommittee next_sync_committee = 9003; // [New in Altair]
// Bellatrix fields [10001-11000]
ethereum.engine.v1.ExecutionPayloadHeaderCapella latest_execution_payload_header = 10001; // [New in Bellatrix]
// Capella fields [11001-12000]
uint64 next_withdrawal_index = 11001; // [New in Capella]
uint64 next_withdrawal_validator_index = 11002 [(ethereum.eth.ext.cast_type) = "github.com/prysmaticlabs/prysm/v3/consensus-types/primitives.ValidatorIndex"]; // [New in Capella]
}
message BeaconStateRequestV2 {
@ -146,6 +198,7 @@ message BeaconStateContainer {
v1.BeaconState phase0_state = 1;
BeaconState altair_state = 2;
BeaconStateBellatrix bellatrix_state = 3;
BeaconStateCapella capella_state = 4;
}
}

View File

@ -528,6 +528,155 @@ func BeaconStateBellatrixToProto(st state.BeaconState) (*ethpbv2.BeaconStateBell
return result, nil
}
// BeaconStateCapellaToProto converts a state.BeaconState object to its protobuf equivalent.
func BeaconStateCapellaToProto(st state.BeaconState) (*ethpbv2.BeaconStateCapella, error) {
sourceFork := st.Fork()
sourceLatestBlockHeader := st.LatestBlockHeader()
sourceEth1Data := st.Eth1Data()
sourceEth1DataVotes := st.Eth1DataVotes()
sourceValidators := st.Validators()
sourceJustificationBits := st.JustificationBits()
sourcePrevJustifiedCheckpoint := st.PreviousJustifiedCheckpoint()
sourceCurrJustifiedCheckpoint := st.CurrentJustifiedCheckpoint()
sourceFinalizedCheckpoint := st.FinalizedCheckpoint()
resultEth1DataVotes := make([]*ethpbv1.Eth1Data, len(sourceEth1DataVotes))
for i, vote := range sourceEth1DataVotes {
resultEth1DataVotes[i] = &ethpbv1.Eth1Data{
DepositRoot: bytesutil.SafeCopyBytes(vote.DepositRoot),
DepositCount: vote.DepositCount,
BlockHash: bytesutil.SafeCopyBytes(vote.BlockHash),
}
}
resultValidators := make([]*ethpbv1.Validator, len(sourceValidators))
for i, validator := range sourceValidators {
resultValidators[i] = &ethpbv1.Validator{
Pubkey: bytesutil.SafeCopyBytes(validator.PublicKey),
WithdrawalCredentials: bytesutil.SafeCopyBytes(validator.WithdrawalCredentials),
EffectiveBalance: validator.EffectiveBalance,
Slashed: validator.Slashed,
ActivationEligibilityEpoch: validator.ActivationEligibilityEpoch,
ActivationEpoch: validator.ActivationEpoch,
ExitEpoch: validator.ExitEpoch,
WithdrawableEpoch: validator.WithdrawableEpoch,
}
}
sourcePrevEpochParticipation, err := st.PreviousEpochParticipation()
if err != nil {
return nil, errors.Wrap(err, "could not get previous epoch participation")
}
sourceCurrEpochParticipation, err := st.CurrentEpochParticipation()
if err != nil {
return nil, errors.Wrap(err, "could not get current epoch participation")
}
sourceInactivityScores, err := st.InactivityScores()
if err != nil {
return nil, errors.Wrap(err, "could not get inactivity scores")
}
sourceCurrSyncCommittee, err := st.CurrentSyncCommittee()
if err != nil {
return nil, errors.Wrap(err, "could not get current sync committee")
}
sourceNextSyncCommittee, err := st.NextSyncCommittee()
if err != nil {
return nil, errors.Wrap(err, "could not get next sync committee")
}
executionPayloadHeaderInterface, err := st.LatestExecutionPayloadHeader()
if err != nil {
return nil, errors.Wrap(err, "could not get latest execution payload header")
}
sourceLatestExecutionPayloadHeader, ok := executionPayloadHeaderInterface.Proto().(*enginev1.ExecutionPayloadHeaderCapella)
if !ok {
return nil, errors.New("execution payload header has incorrect type")
}
sourceNextWithdrawalIndex, err := st.NextWithdrawalIndex()
if err != nil {
return nil, errors.Wrap(err, "could not get next withdrawal index")
}
sourceNextWithdrawalValIndex, err := st.NextWithdrawalValidatorIndex()
if err != nil {
return nil, errors.Wrap(err, "could not get next withdrawal validator index")
}
result := &ethpbv2.BeaconStateCapella{
GenesisTime: st.GenesisTime(),
GenesisValidatorsRoot: bytesutil.SafeCopyBytes(st.GenesisValidatorsRoot()),
Slot: st.Slot(),
Fork: &ethpbv1.Fork{
PreviousVersion: bytesutil.SafeCopyBytes(sourceFork.PreviousVersion),
CurrentVersion: bytesutil.SafeCopyBytes(sourceFork.CurrentVersion),
Epoch: sourceFork.Epoch,
},
LatestBlockHeader: &ethpbv1.BeaconBlockHeader{
Slot: sourceLatestBlockHeader.Slot,
ProposerIndex: sourceLatestBlockHeader.ProposerIndex,
ParentRoot: bytesutil.SafeCopyBytes(sourceLatestBlockHeader.ParentRoot),
StateRoot: bytesutil.SafeCopyBytes(sourceLatestBlockHeader.StateRoot),
BodyRoot: bytesutil.SafeCopyBytes(sourceLatestBlockHeader.BodyRoot),
},
BlockRoots: bytesutil.SafeCopy2dBytes(st.BlockRoots()),
StateRoots: bytesutil.SafeCopy2dBytes(st.StateRoots()),
HistoricalRoots: bytesutil.SafeCopy2dBytes(st.HistoricalRoots()),
Eth1Data: &ethpbv1.Eth1Data{
DepositRoot: bytesutil.SafeCopyBytes(sourceEth1Data.DepositRoot),
DepositCount: sourceEth1Data.DepositCount,
BlockHash: bytesutil.SafeCopyBytes(sourceEth1Data.BlockHash),
},
Eth1DataVotes: resultEth1DataVotes,
Eth1DepositIndex: st.Eth1DepositIndex(),
Validators: resultValidators,
Balances: st.Balances(),
RandaoMixes: bytesutil.SafeCopy2dBytes(st.RandaoMixes()),
Slashings: st.Slashings(),
PreviousEpochParticipation: bytesutil.SafeCopyBytes(sourcePrevEpochParticipation),
CurrentEpochParticipation: bytesutil.SafeCopyBytes(sourceCurrEpochParticipation),
JustificationBits: bytesutil.SafeCopyBytes(sourceJustificationBits),
PreviousJustifiedCheckpoint: &ethpbv1.Checkpoint{
Epoch: sourcePrevJustifiedCheckpoint.Epoch,
Root: bytesutil.SafeCopyBytes(sourcePrevJustifiedCheckpoint.Root),
},
CurrentJustifiedCheckpoint: &ethpbv1.Checkpoint{
Epoch: sourceCurrJustifiedCheckpoint.Epoch,
Root: bytesutil.SafeCopyBytes(sourceCurrJustifiedCheckpoint.Root),
},
FinalizedCheckpoint: &ethpbv1.Checkpoint{
Epoch: sourceFinalizedCheckpoint.Epoch,
Root: bytesutil.SafeCopyBytes(sourceFinalizedCheckpoint.Root),
},
InactivityScores: sourceInactivityScores,
CurrentSyncCommittee: &ethpbv2.SyncCommittee{
Pubkeys: bytesutil.SafeCopy2dBytes(sourceCurrSyncCommittee.Pubkeys),
AggregatePubkey: bytesutil.SafeCopyBytes(sourceCurrSyncCommittee.AggregatePubkey),
},
NextSyncCommittee: &ethpbv2.SyncCommittee{
Pubkeys: bytesutil.SafeCopy2dBytes(sourceNextSyncCommittee.Pubkeys),
AggregatePubkey: bytesutil.SafeCopyBytes(sourceNextSyncCommittee.AggregatePubkey),
},
LatestExecutionPayloadHeader: &enginev1.ExecutionPayloadHeaderCapella{
ParentHash: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.ParentHash),
FeeRecipient: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.FeeRecipient),
StateRoot: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.StateRoot),
ReceiptsRoot: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.ReceiptsRoot),
LogsBloom: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.LogsBloom),
PrevRandao: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.PrevRandao),
BlockNumber: sourceLatestExecutionPayloadHeader.BlockNumber,
GasLimit: sourceLatestExecutionPayloadHeader.GasLimit,
GasUsed: sourceLatestExecutionPayloadHeader.GasUsed,
Timestamp: sourceLatestExecutionPayloadHeader.Timestamp,
ExtraData: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.ExtraData),
BaseFeePerGas: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.BaseFeePerGas),
BlockHash: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.BlockHash),
TransactionsRoot: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.TransactionsRoot),
WithdrawalsRoot: bytesutil.SafeCopyBytes(sourceLatestExecutionPayloadHeader.WithdrawalsRoot),
},
NextWithdrawalIndex: sourceNextWithdrawalIndex,
NextWithdrawalValidatorIndex: sourceNextWithdrawalValIndex,
}
return result, nil
}
func V1Alpha1SignedContributionAndProofToV2(alphaContribution *ethpbalpha.SignedContributionAndProof) *ethpbv2.SignedContributionAndProof {
result := &ethpbv2.SignedContributionAndProof{
Message: &ethpbv2.ContributionAndProof{

View File

@ -575,3 +575,188 @@ func TestBeaconStateBellatrixToProto(t *testing.T) {
assert.DeepEqual(t, bytesutil.PadTo([]byte("blockhash"), 32), resultLatestExecutionPayloadHeader.BlockHash)
assert.DeepEqual(t, bytesutil.PadTo([]byte("transactionsroot"), 32), resultLatestExecutionPayloadHeader.TransactionsRoot)
}
func TestBeaconStateCapellaToProto(t *testing.T) {
source, err := util.NewBeaconStateCapella(util.FillRootsNaturalOptCapella, func(state *ethpbalpha.BeaconStateCapella) error {
state.GenesisTime = 1
state.GenesisValidatorsRoot = bytesutil.PadTo([]byte("genesisvalidatorsroot"), 32)
state.Slot = 2
state.Fork = &ethpbalpha.Fork{
PreviousVersion: bytesutil.PadTo([]byte("123"), 4),
CurrentVersion: bytesutil.PadTo([]byte("456"), 4),
Epoch: 3,
}
state.LatestBlockHeader = &ethpbalpha.BeaconBlockHeader{
Slot: 4,
ProposerIndex: 5,
ParentRoot: bytesutil.PadTo([]byte("lbhparentroot"), 32),
StateRoot: bytesutil.PadTo([]byte("lbhstateroot"), 32),
BodyRoot: bytesutil.PadTo([]byte("lbhbodyroot"), 32),
}
state.BlockRoots = [][]byte{bytesutil.PadTo([]byte("blockroots"), 32)}
state.StateRoots = [][]byte{bytesutil.PadTo([]byte("stateroots"), 32)}
state.HistoricalRoots = [][]byte{bytesutil.PadTo([]byte("historicalroots"), 32)}
state.Eth1Data = &ethpbalpha.Eth1Data{
DepositRoot: bytesutil.PadTo([]byte("e1ddepositroot"), 32),
DepositCount: 6,
BlockHash: bytesutil.PadTo([]byte("e1dblockhash"), 32),
}
state.Eth1DataVotes = []*ethpbalpha.Eth1Data{{
DepositRoot: bytesutil.PadTo([]byte("e1dvdepositroot"), 32),
DepositCount: 7,
BlockHash: bytesutil.PadTo([]byte("e1dvblockhash"), 32),
}}
state.Eth1DepositIndex = 8
state.Validators = []*ethpbalpha.Validator{{
PublicKey: bytesutil.PadTo([]byte("publickey"), 48),
WithdrawalCredentials: bytesutil.PadTo([]byte("withdrawalcredentials"), 32),
EffectiveBalance: 9,
Slashed: true,
ActivationEligibilityEpoch: 10,
ActivationEpoch: 11,
ExitEpoch: 12,
WithdrawableEpoch: 13,
}}
state.Balances = []uint64{14}
state.RandaoMixes = [][]byte{bytesutil.PadTo([]byte("randaomixes"), 32)}
state.Slashings = []uint64{15}
state.JustificationBits = bitfield.Bitvector4{1}
state.PreviousJustifiedCheckpoint = &ethpbalpha.Checkpoint{
Epoch: 30,
Root: bytesutil.PadTo([]byte("pjcroot"), 32),
}
state.CurrentJustifiedCheckpoint = &ethpbalpha.Checkpoint{
Epoch: 31,
Root: bytesutil.PadTo([]byte("cjcroot"), 32),
}
state.FinalizedCheckpoint = &ethpbalpha.Checkpoint{
Epoch: 32,
Root: bytesutil.PadTo([]byte("fcroot"), 32),
}
state.PreviousEpochParticipation = []byte("previousepochparticipation")
state.CurrentEpochParticipation = []byte("currentepochparticipation")
state.InactivityScores = []uint64{1, 2, 3}
state.CurrentSyncCommittee = &ethpbalpha.SyncCommittee{
Pubkeys: [][]byte{bytesutil.PadTo([]byte("cscpubkeys"), 48)},
AggregatePubkey: bytesutil.PadTo([]byte("cscaggregatepubkey"), 48),
}
state.NextSyncCommittee = &ethpbalpha.SyncCommittee{
Pubkeys: [][]byte{bytesutil.PadTo([]byte("nscpubkeys"), 48)},
AggregatePubkey: bytesutil.PadTo([]byte("nscaggregatepubkey"), 48),
}
state.LatestExecutionPayloadHeader = &enginev1.ExecutionPayloadHeaderCapella{
ParentHash: bytesutil.PadTo([]byte("parenthash"), 32),
FeeRecipient: bytesutil.PadTo([]byte("feerecipient"), 20),
StateRoot: bytesutil.PadTo([]byte("stateroot"), 32),
ReceiptsRoot: bytesutil.PadTo([]byte("receiptroot"), 32),
LogsBloom: bytesutil.PadTo([]byte("logsbloom"), 256),
PrevRandao: bytesutil.PadTo([]byte("prevrandao"), 32),
BlockNumber: 123,
GasLimit: 456,
GasUsed: 789,
Timestamp: 012,
ExtraData: []byte("extradata"),
BaseFeePerGas: bytesutil.PadTo([]byte("basefeepergas"), 32),
BlockHash: bytesutil.PadTo([]byte("blockhash"), 32),
TransactionsRoot: bytesutil.PadTo([]byte("transactionsroot"), 32),
WithdrawalsRoot: bytesutil.PadTo([]byte("withdrawalsroot"), 32),
}
state.NextWithdrawalIndex = 123
state.NextWithdrawalValidatorIndex = 123
return nil
})
require.NoError(t, err)
result, err := BeaconStateCapellaToProto(source)
require.NoError(t, err)
require.NotNil(t, result)
assert.Equal(t, uint64(1), result.GenesisTime)
assert.DeepEqual(t, bytesutil.PadTo([]byte("genesisvalidatorsroot"), 32), result.GenesisValidatorsRoot)
assert.Equal(t, types.Slot(2), result.Slot)
resultFork := result.Fork
require.NotNil(t, resultFork)
assert.DeepEqual(t, bytesutil.PadTo([]byte("123"), 4), resultFork.PreviousVersion)
assert.DeepEqual(t, bytesutil.PadTo([]byte("456"), 4), resultFork.CurrentVersion)
assert.Equal(t, types.Epoch(3), resultFork.Epoch)
resultLatestBlockHeader := result.LatestBlockHeader
require.NotNil(t, resultLatestBlockHeader)
assert.Equal(t, types.Slot(4), resultLatestBlockHeader.Slot)
assert.Equal(t, types.ValidatorIndex(5), resultLatestBlockHeader.ProposerIndex)
assert.DeepEqual(t, bytesutil.PadTo([]byte("lbhparentroot"), 32), resultLatestBlockHeader.ParentRoot)
assert.DeepEqual(t, bytesutil.PadTo([]byte("lbhstateroot"), 32), resultLatestBlockHeader.StateRoot)
assert.DeepEqual(t, bytesutil.PadTo([]byte("lbhbodyroot"), 32), resultLatestBlockHeader.BodyRoot)
assert.Equal(t, 8192, len(result.BlockRoots))
assert.DeepEqual(t, bytesutil.PadTo([]byte("blockroots"), 32), result.BlockRoots[0])
assert.Equal(t, 8192, len(result.StateRoots))
assert.DeepEqual(t, bytesutil.PadTo([]byte("stateroots"), 32), result.StateRoots[0])
assert.Equal(t, 1, len(result.HistoricalRoots))
assert.DeepEqual(t, bytesutil.PadTo([]byte("historicalroots"), 32), result.HistoricalRoots[0])
resultEth1Data := result.Eth1Data
require.NotNil(t, resultEth1Data)
assert.DeepEqual(t, bytesutil.PadTo([]byte("e1ddepositroot"), 32), resultEth1Data.DepositRoot)
assert.Equal(t, uint64(6), resultEth1Data.DepositCount)
assert.DeepEqual(t, bytesutil.PadTo([]byte("e1dblockhash"), 32), resultEth1Data.BlockHash)
require.Equal(t, 1, len(result.Eth1DataVotes))
resultEth1DataVote := result.Eth1DataVotes[0]
require.NotNil(t, resultEth1DataVote)
assert.DeepEqual(t, bytesutil.PadTo([]byte("e1dvdepositroot"), 32), resultEth1DataVote.DepositRoot)
assert.Equal(t, uint64(7), resultEth1DataVote.DepositCount)
assert.DeepEqual(t, bytesutil.PadTo([]byte("e1dvblockhash"), 32), resultEth1DataVote.BlockHash)
assert.Equal(t, uint64(8), result.Eth1DepositIndex)
require.Equal(t, 1, len(result.Validators))
resultValidator := result.Validators[0]
require.NotNil(t, resultValidator)
assert.DeepEqual(t, bytesutil.PadTo([]byte("publickey"), 48), resultValidator.Pubkey)
assert.DeepEqual(t, bytesutil.PadTo([]byte("withdrawalcredentials"), 32), resultValidator.WithdrawalCredentials)
assert.Equal(t, uint64(9), resultValidator.EffectiveBalance)
assert.Equal(t, true, resultValidator.Slashed)
assert.Equal(t, types.Epoch(10), resultValidator.ActivationEligibilityEpoch)
assert.Equal(t, types.Epoch(11), resultValidator.ActivationEpoch)
assert.Equal(t, types.Epoch(12), resultValidator.ExitEpoch)
assert.Equal(t, types.Epoch(13), resultValidator.WithdrawableEpoch)
assert.DeepEqual(t, []uint64{14}, result.Balances)
assert.Equal(t, 65536, len(result.RandaoMixes))
assert.DeepEqual(t, bytesutil.PadTo([]byte("randaomixes"), 32), result.RandaoMixes[0])
assert.DeepEqual(t, []uint64{15}, result.Slashings)
assert.DeepEqual(t, bitfield.Bitvector4{1}, result.JustificationBits)
resultPrevJustifiedCheckpoint := result.PreviousJustifiedCheckpoint
require.NotNil(t, resultPrevJustifiedCheckpoint)
assert.Equal(t, types.Epoch(30), resultPrevJustifiedCheckpoint.Epoch)
assert.DeepEqual(t, bytesutil.PadTo([]byte("pjcroot"), 32), resultPrevJustifiedCheckpoint.Root)
resultCurrJustifiedCheckpoint := result.CurrentJustifiedCheckpoint
require.NotNil(t, resultCurrJustifiedCheckpoint)
assert.Equal(t, types.Epoch(31), resultCurrJustifiedCheckpoint.Epoch)
assert.DeepEqual(t, bytesutil.PadTo([]byte("cjcroot"), 32), resultCurrJustifiedCheckpoint.Root)
resultFinalizedCheckpoint := result.FinalizedCheckpoint
require.NotNil(t, resultFinalizedCheckpoint)
assert.Equal(t, types.Epoch(32), resultFinalizedCheckpoint.Epoch)
assert.DeepEqual(t, bytesutil.PadTo([]byte("fcroot"), 32), resultFinalizedCheckpoint.Root)
assert.DeepEqual(t, []byte("previousepochparticipation"), result.PreviousEpochParticipation)
assert.DeepEqual(t, []byte("currentepochparticipation"), result.CurrentEpochParticipation)
assert.DeepEqual(t, []uint64{1, 2, 3}, result.InactivityScores)
require.NotNil(t, result.CurrentSyncCommittee)
assert.DeepEqual(t, [][]byte{bytesutil.PadTo([]byte("cscpubkeys"), 48)}, result.CurrentSyncCommittee.Pubkeys)
assert.DeepEqual(t, bytesutil.PadTo([]byte("cscaggregatepubkey"), 48), result.CurrentSyncCommittee.AggregatePubkey)
require.NotNil(t, result.NextSyncCommittee)
assert.DeepEqual(t, [][]byte{bytesutil.PadTo([]byte("nscpubkeys"), 48)}, result.NextSyncCommittee.Pubkeys)
assert.DeepEqual(t, bytesutil.PadTo([]byte("nscaggregatepubkey"), 48), result.NextSyncCommittee.AggregatePubkey)
resultLatestExecutionPayloadHeader := result.LatestExecutionPayloadHeader
require.NotNil(t, resultLatestExecutionPayloadHeader)
assert.DeepEqual(t, bytesutil.PadTo([]byte("parenthash"), 32), resultLatestExecutionPayloadHeader.ParentHash)
assert.DeepEqual(t, bytesutil.PadTo([]byte("feerecipient"), 20), resultLatestExecutionPayloadHeader.FeeRecipient)
assert.DeepEqual(t, bytesutil.PadTo([]byte("stateroot"), 32), resultLatestExecutionPayloadHeader.StateRoot)
assert.DeepEqual(t, bytesutil.PadTo([]byte("receiptroot"), 32), resultLatestExecutionPayloadHeader.ReceiptsRoot)
assert.DeepEqual(t, bytesutil.PadTo([]byte("logsbloom"), 256), resultLatestExecutionPayloadHeader.LogsBloom)
assert.DeepEqual(t, bytesutil.PadTo([]byte("prevrandao"), 32), resultLatestExecutionPayloadHeader.PrevRandao)
assert.Equal(t, uint64(123), resultLatestExecutionPayloadHeader.BlockNumber)
assert.Equal(t, uint64(456), resultLatestExecutionPayloadHeader.GasLimit)
assert.Equal(t, uint64(789), resultLatestExecutionPayloadHeader.GasUsed)
assert.Equal(t, uint64(012), resultLatestExecutionPayloadHeader.Timestamp)
assert.DeepEqual(t, []byte("extradata"), resultLatestExecutionPayloadHeader.ExtraData)
assert.DeepEqual(t, bytesutil.PadTo([]byte("basefeepergas"), 32), resultLatestExecutionPayloadHeader.BaseFeePerGas)
assert.DeepEqual(t, bytesutil.PadTo([]byte("blockhash"), 32), resultLatestExecutionPayloadHeader.BlockHash)
assert.DeepEqual(t, bytesutil.PadTo([]byte("transactionsroot"), 32), resultLatestExecutionPayloadHeader.TransactionsRoot)
assert.DeepEqual(t, bytesutil.PadTo([]byte("withdrawalsroot"), 32), resultLatestExecutionPayloadHeader.WithdrawalsRoot)
assert.Equal(t, uint64(123), result.NextWithdrawalIndex)
assert.Equal(t, types.ValidatorIndex(123), result.NextWithdrawalValidatorIndex)
}