async fn fetch_blocks(
        &self,
        ctx: &ctx::Ctx,
        queue: &mut storage::PayloadQueue,
    ) -> ctx::Result<()> {
        const MAX_CONCURRENT_REQUESTS: usize = 30;
        let mut next = queue.next();
        scope::run!(ctx, |ctx, s| async {
            let (send, mut recv) = ctx::channel::bounded(MAX_CONCURRENT_REQUESTS);
            s.spawn::<()>(async {
                let send = send;
                loop {
                    wait_for_main_node_block(ctx, &self.sync_state, |main| main >= next).await?;
                    send.send(ctx, s.spawn(self.fetch_block(ctx, next))).await?;
                    next = next.next();
                }
            });
            loop {
                let block = recv.recv(ctx).await?.join(ctx).await?;
                queue.send(block).await.context("queue.send()")?;
            }
        })
        .await
    }
Fetches blocks starting with `queue.next()`.
core/node/consensus/src/en.rs