pub(crate) async fn resolve_block_unchecked(
        &self,
        connection: &mut Connection<'_, Core>,
        block: api::BlockId,
    ) -> Result<Option<L2BlockNumber>, Web3Error> {
        self.start_info.ensure_not_pruned(block, connection).await?;
        match block {
            api::BlockId::Number(api::BlockNumber::Number(number)) => {
                Ok(u32::try_from(number).ok().map(L2BlockNumber))
            }
            api::BlockId::Number(api::BlockNumber::Earliest) => Ok(Some(L2BlockNumber(0))),
            _ => Ok(connection
                .blocks_web3_dal()
                .resolve_block_id(block)
                .await
                .map_err(DalError::generalize)?),
        }
    }
Resolves the specified block ID to a block number, which is **not** guaranteed to be present in the node storage.
Returns `None` if the block is known to not be present in the storage (e.g., it's a "finalized" block ID and no blocks
were finalized yet).

This method is more efficient than [`Self::resolve_block()`] (it doesn't query the storage if block ID maps to a known
block number), but is more difficult to reason about. You should use it only if the block number consumer correctly handles
non-existing blocks.
core/node/api_server/src/web3/state.rs