Fixed Clippy Complaints & Some Failing Tests (#3791)

* Fixed Clippy Complaints & Some Failing Tests
* Update Dockerfile to Rust-1.65
* EF test file renamed
* Touch up comments based on feedback
This commit is contained in:
ethDreamer
2022-12-13 10:50:24 -06:00
committed by GitHub
parent 173a0abab4
commit b1c33361ea
15 changed files with 79 additions and 49 deletions

View File

@@ -2205,8 +2205,10 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
.verify_and_observe(bls_to_execution_change, &wall_clock_state, &self.spec)?)
}
// TODO: remove this whole block once withdrawals-processing is removed
#[cfg(not(feature = "withdrawals-processing"))]
{
#[allow(clippy::drop_non_drop)]
drop(bls_to_execution_change);
Ok(ObservationOutcome::AlreadyKnown)
}
@@ -4342,17 +4344,17 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
// Might implement caching here in the future..
let prepare_state = self
.state_at_slot(prepare_slot, StateSkipConfig::WithoutStateRoots)
.or_else(|e| {
.map_err(|e| {
error!(self.log, "State advance for withdrawals failed"; "error" => ?e);
Err(e)
e
})?;
Some(get_expected_withdrawals(&prepare_state, &self.spec))
}
}
.transpose()
.or_else(|e| {
.map_err(|e| {
error!(self.log, "Error preparing beacon proposer"; "error" => ?e);
Err(e)
e
})
.map(|withdrawals_opt| withdrawals_opt.map(|w| w.into()))
.map_err(Error::PrepareProposerFailed)?;