mirror of
https://github.com/sigp/lighthouse.git
synced 2026-06-16 18:28:42 +00:00
fix tests
This commit is contained in:
@@ -880,8 +880,11 @@ pub fn process_deposit_requests_pre_gloas<E: EthSpec>(
|
||||
spec: &ChainSpec,
|
||||
) -> Result<(), BlockProcessingError> {
|
||||
for request in deposit_requests {
|
||||
// Set deposit receipt start index
|
||||
if state.deposit_requests_start_index()? == spec.unset_deposit_requests_start_index {
|
||||
// Set deposit receipt start index if pre-Fulu.
|
||||
// Support for the former Eth1 bridge deposit mechanism was removed in Fulu.
|
||||
if !state.fork_name_unchecked().fulu_enabled()
|
||||
&& state.deposit_requests_start_index()? == spec.unset_deposit_requests_start_index
|
||||
{
|
||||
*state.deposit_requests_start_index_mut()? = request.index
|
||||
}
|
||||
let slot = state.slot();
|
||||
|
||||
@@ -1104,14 +1104,10 @@ impl PendingDepositsContext {
|
||||
|
||||
let pending_deposits = state.pending_deposits()?;
|
||||
|
||||
// Support for the former Eth1 bridge deposit mechanism was removed in Fulu (spec PR #4704),
|
||||
// so the gate that withholds deposit requests until bridge deposits are applied only runs
|
||||
// pre-Fulu.
|
||||
let apply_eth1_bridge_gate = !state.fork_name_unchecked().fulu_enabled();
|
||||
|
||||
for deposit in pending_deposits.iter() {
|
||||
// Do not process deposit requests if the Eth1 bridge deposits are not yet applied.
|
||||
if apply_eth1_bridge_gate
|
||||
// Do not process deposit requests if pre-Fulu and the Eth1 bridge deposits are not yet applied.
|
||||
// Support for the former Eth1 bridge deposit mechanism was removed in Fulu.
|
||||
if !state.fork_name_unchecked().fulu_enabled()
|
||||
&& deposit.slot > spec.genesis_slot
|
||||
&& state.eth1_deposit_index() < state.deposit_requests_start_index()?
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user