Fix build_spec and typo

This commit is contained in:
Hsiao-Wei Wang 2019-08-07 19:29:24 +08:00
parent cb92aa91dd
commit 095cfe6633
No known key found for this signature in database
GPG Key ID: 95B070122902DEA4
2 changed files with 2 additions and 3 deletions

View File

@ -37,7 +37,7 @@ from eth2spec.utils.bls import (
from eth2spec.utils.hash_function import hash
'''
PHASE1_IMPORTS = '''from typing import (
Any, Dict, Optional, Set, Sequence, MutableSequence, Tuple,
Any, Dict, Optional, Set, Sequence, MutableSequence, Tuple, Union,
)
from dataclasses import (

View File

@ -535,7 +535,6 @@ def shard_block_transition(state: ShardState,
state.total_bytes += len(block.core.data)
assert block.core.total_bytes == state.total_bytes
# Update in-state block header
state.most_recent_block_core = ShardBlockCore(
slot=block.core.slot,
@ -599,7 +598,7 @@ def is_valid_beacon_attestation(shard: Shard,
blocks.append(ShardBlockHeader(ShardBlockCore(
slot=slot,
state_root=shard_blocks_or_state_roots[slot],
total_bytes=state.total_bytes
total_bytes=pre_state.total_bytes
), ShardBlockSignatures()))
assert candidate.data.crosslink.data_root == compute_crosslink_data_root(blocks)