Merge branch 'master' into eth1-deploy

This commit is contained in:
Paul Hauner
2019-11-27 12:48:46 +11:00
42 changed files with 2516 additions and 604 deletions

View File

@@ -360,7 +360,7 @@ fn eth1_block_hash_at_start_of_voting_period<T: EthSpec, S: Store>(
.map_err(|e| Error::UnableToGetPreviousStateRoot(e))?;
store
.get::<BeaconState<T>>(&prev_state_root)
.get_state::<T>(&prev_state_root, Some(slot))
.map_err(|e| Error::StoreError(e))?
.map(|state| state.eth1_data.block_hash)
.ok_or_else(|| Error::PreviousStateNotInDB(*prev_state_root))
@@ -746,7 +746,7 @@ mod test {
);
store
.put(
.put_state(
&state
.get_state_root(prev_state.slot)
.expect("should find state root"),
@@ -808,7 +808,7 @@ mod test {
);
store
.put(
.put_state(
&state
.get_state_root(Slot::new(0))
.expect("should find state root"),