Skip to content

Commit

Permalink
Updates for 1.4.0-beta1
Browse files Browse the repository at this point in the history
  • Loading branch information
mcdee committed Aug 1, 2023
1 parent c80eae9 commit ae55399
Show file tree
Hide file tree
Showing 23 changed files with 342 additions and 342 deletions.
32 changes: 16 additions & 16 deletions api/v1/deneb/blindedbeaconblock_test.go

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions api/v1/deneb/blindedbeaconblockbody_test.go

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions api/v1/deneb/blindedblockcontents_test.go

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions api/v1/deneb/blockcontents_test.go

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions api/v1/deneb/signedblindedbeaconblock_test.go

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions api/v1/deneb/signedblindedblockcontents_test.go

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions api/v1/deneb/signedblockcontents_test.go

Large diffs are not rendered by default.

32 changes: 16 additions & 16 deletions spec/deneb/beaconblock_test.go

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion spec/deneb/beaconblockbody.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ type BeaconBlockBody struct {
SyncAggregate *altair.SyncAggregate
ExecutionPayload *ExecutionPayload
BLSToExecutionChanges []*capella.SignedBLSToExecutionChange `ssz-max:"16"`
BlobKzgCommitments []KzgCommitment `ssz-max:"6" ssz-size:"?,48"`
BlobKzgCommitments []KzgCommitment `ssz-max:"4096" ssz-size:"?,48"`
}

// String returns a string version of the structure.
Expand Down
12 changes: 6 additions & 6 deletions spec/deneb/beaconblockbody_ssz.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

72 changes: 36 additions & 36 deletions spec/deneb/beaconblockbody_test.go

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions spec/deneb/beaconstate_test.go

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions spec/deneb/executionpayload.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ type ExecutionPayload struct {
BlockHash phase0.Hash32 `ssz-size:"32"`
Transactions []bellatrix.Transaction `ssz-max:"1048576,1073741824" ssz-size:"?,?"`
Withdrawals []*capella.Withdrawal `ssz-max:"16"`
DataGasUsed uint64
ExcessDataGas uint64
BlobGasUsed uint64
ExcessBlobGas uint64
}

// String returns a string version of the structure.
Expand Down
20 changes: 10 additions & 10 deletions spec/deneb/executionpayload_json.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ type executionPayloadJSON struct {
BlockHash phase0.Hash32 `json:"block_hash"`
Transactions []string `json:"transactions"`
Withdrawals []*capella.Withdrawal `json:"withdrawals"`
DataGasUsed string `json:"data_gas_used"`
ExcessDataGas string `json:"excess_data_gas"`
BlobGasUsed string `json:"blob_gas_used"`
ExcessBlobGas string `json:"excess_blob_gas"`
}

// MarshalJSON implements json.Marshaler.
Expand Down Expand Up @@ -77,8 +77,8 @@ func (e *ExecutionPayload) MarshalJSON() ([]byte, error) {
BlockHash: e.BlockHash,
Transactions: transactions,
Withdrawals: e.Withdrawals,
DataGasUsed: fmt.Sprintf("%d", e.DataGasUsed),
ExcessDataGas: fmt.Sprintf("%d", e.ExcessDataGas),
BlobGasUsed: fmt.Sprintf("%d", e.BlobGasUsed),
ExcessBlobGas: fmt.Sprintf("%d", e.ExcessBlobGas),
})
}

Expand Down Expand Up @@ -222,17 +222,17 @@ func (e *ExecutionPayload) UnmarshalJSON(input []byte) error {
return errors.Wrap(err, "withdrawals")
}

tmpUint, err = strconv.ParseUint(string(bytes.Trim(raw["data_gas_used"], `"`)), 10, 64)
tmpUint, err = strconv.ParseUint(string(bytes.Trim(raw["blob_gas_used"], `"`)), 10, 64)
if err != nil {
return errors.Wrap(err, "data_gas_used")
return errors.Wrap(err, "blob_gas_used")
}
e.DataGasUsed = tmpUint
e.BlobGasUsed = tmpUint

tmpUint, err = strconv.ParseUint(string(bytes.Trim(raw["excess_data_gas"], `"`)), 10, 64)
tmpUint, err = strconv.ParseUint(string(bytes.Trim(raw["excess_blob_gas"], `"`)), 10, 64)
if err != nil {
return errors.Wrap(err, "excess_data_gas")
return errors.Wrap(err, "excess_blob_gas")
}
e.ExcessDataGas = tmpUint
e.ExcessBlobGas = tmpUint

return nil
}
24 changes: 12 additions & 12 deletions spec/deneb/executionpayload_ssz.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

160 changes: 80 additions & 80 deletions spec/deneb/executionpayload_test.go

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions spec/deneb/executionpayload_yaml.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ type executionPayloadYAML struct {
BlockHash string `yaml:"block_hash"`
Transactions []string `yaml:"transactions"`
Withdrawals []*capella.Withdrawal `yaml:"withdrawals"`
DataGasUsed uint64 `yaml:"data_gas_used"`
ExcessDataGas uint64 `yaml:"excess_data_gas"`
BlobGasUsed uint64 `yaml:"blob_gas_used"`
ExcessBlobGas uint64 `yaml:"excess_blob_gas"`
}

// MarshalYAML implements yaml.Marshaler.
Expand Down Expand Up @@ -72,8 +72,8 @@ func (e *ExecutionPayload) MarshalYAML() ([]byte, error) {
BlockHash: fmt.Sprintf("%#x", e.BlockHash),
Transactions: transactions,
Withdrawals: e.Withdrawals,
DataGasUsed: e.DataGasUsed,
ExcessDataGas: e.ExcessDataGas,
BlobGasUsed: e.BlobGasUsed,
ExcessBlobGas: e.ExcessBlobGas,
}, yaml.Flow(true))
if err != nil {
return nil, err
Expand Down
4 changes: 2 additions & 2 deletions spec/deneb/executionpayloadheader.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ type ExecutionPayloadHeader struct {
BlockHash phase0.Hash32 `ssz-size:"32"`
TransactionsRoot phase0.Root `ssz-size:"32"`
WithdrawalsRoot phase0.Root `ssz-size:"32"`
DataGasUsed uint64
ExcessDataGas uint64
BlobGasUsed uint64
ExcessBlobGas uint64
}

// String returns a string version of the structure.
Expand Down
20 changes: 10 additions & 10 deletions spec/deneb/executionpayloadheader_json.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ type executionPayloadHeaderJSON struct {
BlockHash phase0.Hash32 `json:"block_hash"`
TransactionsRoot phase0.Root `json:"transactions_root"`
WithdrawalsRoot phase0.Root `json:"withdrawals_root"`
DataGasUsed string `json:"data_gas_used"`
ExcessDataGas string `json:"excess_data_gas"`
BlobGasUsed string `json:"blob_gas_used"`
ExcessBlobGas string `json:"excess_blob_gas"`
}

// MarshalJSON implements json.Marshaler.
Expand All @@ -71,8 +71,8 @@ func (e *ExecutionPayloadHeader) MarshalJSON() ([]byte, error) {
BlockHash: e.BlockHash,
TransactionsRoot: e.TransactionsRoot,
WithdrawalsRoot: e.WithdrawalsRoot,
DataGasUsed: fmt.Sprintf("%d", e.DataGasUsed),
ExcessDataGas: fmt.Sprintf("%d", e.ExcessDataGas),
BlobGasUsed: fmt.Sprintf("%d", e.BlobGasUsed),
ExcessBlobGas: fmt.Sprintf("%d", e.ExcessBlobGas),
})
}

Expand Down Expand Up @@ -202,17 +202,17 @@ func (e *ExecutionPayloadHeader) UnmarshalJSON(input []byte) error {
return errors.Wrap(err, "withdrawals_root")
}

tmpUint, err = strconv.ParseUint(string(bytes.Trim(raw["data_gas_used"], `"`)), 10, 64)
tmpUint, err = strconv.ParseUint(string(bytes.Trim(raw["blob_gas_used"], `"`)), 10, 64)
if err != nil {
return errors.Wrap(err, "data_gas_used")
return errors.Wrap(err, "blob_gas_used")
}
e.DataGasUsed = tmpUint
e.BlobGasUsed = tmpUint

tmpUint, err = strconv.ParseUint(string(bytes.Trim(raw["excess_data_gas"], `"`)), 10, 64)
tmpUint, err = strconv.ParseUint(string(bytes.Trim(raw["excess_blob_gas"], `"`)), 10, 64)
if err != nil {
return errors.Wrap(err, "excess_data_gas")
return errors.Wrap(err, "excess_blob_gas")
}
e.ExcessDataGas = tmpUint
e.ExcessBlobGas = tmpUint

return nil
}
24 changes: 12 additions & 12 deletions spec/deneb/executionpayloadheader_ssz.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit ae55399

Please sign in to comment.