Skip to content

Commit

Permalink
Do not broadcast the parent_block_hash but use it as parameter to the EL
Browse files Browse the repository at this point in the history
  • Loading branch information
potuz committed Aug 26, 2023
1 parent 05022af commit 83da883
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion specs/_features/epbs/beacon-chain.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@ class InclusionListSummaryEntry(Container):
```python
class InclusionListSummary(Container)
proposer_index: ValidatorIndex
parent_block_hash: Hash32
summary: List[InclusionListSummaryEntry, MAX_TRANSACTIONS_PER_INCLUSION_LIST]
```

Expand Down Expand Up @@ -335,6 +334,7 @@ def process_epoch(state: BeaconState) -> None:
@dataclass
class NewInclusionListRequest(object):
inclusion_list: InclusionList
parent_block_hash: Hash32
```

#### Engine APIs
Expand Down
7 changes: 2 additions & 5 deletions specs/_features/epbs/fork-choice.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,6 @@ def verify_inclusion_list(state: BeaconState, block: BeaconBlock, inclusion_list
proposer = state.validators[proposer_index]
assert bls.Verify(proposer.pubkey, signing_root, signed_summary.signature)

# Check that the parent_hash corresponds to the state's last execution payload header
parent_hash = signed_summary.message.parent_block_hash
assert parent_hash == state.latest_execution_payload_header.block_hash

# TODO: These checks will also be performed by the EL surely so we can probably remove them from here.
# Check the summary and transaction list lengths
summary = signed_summary.message.summary
Expand All @@ -49,7 +45,8 @@ def verify_inclusion_list(state: BeaconState, block: BeaconBlock, inclusion_list
assert total_gas_limit <= MAX_GAS_PER_INCLUSION_LIST

# Check that the inclusion list is valid
return execution_engine.notify_new_inclusion_list(inclusion_list)
return execution_engine.notify_new_inclusion_list(NewInclusionListRequest(
inclusion_list=inclusion_list, parent_block_hash = state.latest_execution_payload_header.block_hash ))
```

### `is_inclusion_list_available`
Expand Down

0 comments on commit 83da883

Please sign in to comment.