Skip to main content

run_storage_programs

Function run_storage_programs 

Source
pub async fn run_storage_programs<P: Provider<AnyNetwork>>(
    provider: &P,
    block: BlockId,
    programs: &[StorageProgram],
) -> Vec<StorageFetchResult<Bytes>> 
Expand description

Execute several StoragePrograms, batching programs with distinct targets into a single Multicall3-dispatched eth_call.

Programs that share a target address (each needs its own code override at that key) or that target the dispatcher address run as individual calls. Results are returned in input order, one per program.