fix transactions field in exec payload helper
This commit is contained in:
parent
470c6dcc6f
commit
ff3a82e0f3
|
@ -18,7 +18,7 @@ def build_empty_execution_payload(spec, state):
|
|||
timestamp=timestamp,
|
||||
receipt_root=b"no receipts here" + b"\x00"*16, # TODO: root of empty MPT may be better.
|
||||
logs_bloom=spec.ByteVector[spec.BYTES_PER_LOGS_BLOOM](), # TODO: zeroed logs bloom for empty logs ok?
|
||||
transactions_root=empty_txs,
|
||||
transactions=empty_txs,
|
||||
)
|
||||
# TODO: real RLP + block hash logic would be nice, requires RLP and keccak256 dependency however.
|
||||
payload.block_hash = spec.Hash32(spec.hash(payload.hash_tree_root() + b"FAKE RLP HASH"))
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
from eth2spec.test.helpers.constants import PHASE0, ALTAIR
|
||||
from eth2spec.test.helpers.execution_payload import build_empty_execution_payload
|
||||
from eth2spec.test.context import spec_state_test, expect_assertion_error, always_bls, with_all_phases_except
|
||||
|
||||
with_merge_and_later = with_all_phases_except([PHASE0, ALTAIR])
|
||||
|
@ -36,7 +37,7 @@ def test_success_first_payload(spec, state):
|
|||
assert not spec.is_transition_completed(state)
|
||||
|
||||
# TODO: execution payload
|
||||
execution_payload = spec.ExecutionPayload()
|
||||
execution_payload = build_empty_execution_payload(spec, state)
|
||||
|
||||
yield from run_execution_payload_processing(spec, state, execution_payload)
|
||||
|
||||
|
|
Loading…
Reference in New Issue