mirror of
https://github.com/sigp/lighthouse.git
synced 2026-06-29 19:04:27 +00:00
process withdrawals updates
This commit is contained in:
@@ -33,7 +33,7 @@ pub fn get_next_withdrawals<T: BeaconChainTypes>(
|
||||
}
|
||||
|
||||
match get_expected_withdrawals(&state, &chain.spec) {
|
||||
Ok(withdrawals) => Ok(withdrawals),
|
||||
Ok((withdrawals, _)) => Ok(withdrawals),
|
||||
Err(e) => Err(warp_utils::reject::custom_server_error(format!(
|
||||
"failed to get expected withdrawal: {:?}",
|
||||
e
|
||||
|
||||
@@ -610,6 +610,7 @@ pub async fn proposer_boost_re_org_test(
|
||||
assert_eq!(state_b.slot(), slot_b);
|
||||
let pre_advance_withdrawals = get_expected_withdrawals(&state_b, &harness.chain.spec)
|
||||
.unwrap()
|
||||
.0
|
||||
.to_vec();
|
||||
complete_state_advance(&mut state_b, None, slot_c, &harness.chain.spec).unwrap();
|
||||
|
||||
@@ -696,6 +697,7 @@ pub async fn proposer_boost_re_org_test(
|
||||
get_expected_withdrawals(&state_b, &harness.chain.spec)
|
||||
}
|
||||
.unwrap()
|
||||
.0
|
||||
.to_vec();
|
||||
let payload_attribs_withdrawals = payload_attribs.withdrawals().unwrap();
|
||||
assert_eq!(expected_withdrawals, *payload_attribs_withdrawals);
|
||||
|
||||
@@ -5448,7 +5448,9 @@ impl ApiTester {
|
||||
&self.chain.spec,
|
||||
);
|
||||
}
|
||||
let expected_withdrawals = get_expected_withdrawals(&state, &self.chain.spec).unwrap();
|
||||
let expected_withdrawals = get_expected_withdrawals(&state, &self.chain.spec)
|
||||
.unwrap()
|
||||
.0;
|
||||
|
||||
// fetch expected withdrawals from the client
|
||||
let result = self.client.get_expected_withdrawals(&state_id).await;
|
||||
|
||||
Reference in New Issue
Block a user