referrerpolicy=no-referrer-when-downgrade

check_relay_parent_session

Function check_relay_parent_session 

Source
pub async fn check_relay_parent_session(
    sender: &mut impl SubsystemSender<RuntimeApiMessage>,
    query_at: Hash,
    session_index: SessionIndex,
    relay_parent: Hash,
) -> CheckRelayParentSessionResult
Expand description

Check whether a relay parent is valid in a given session.

Works for all blocks within the max_relay_parent_session_age window, including the block being queried at (the “self” case where query_at == relay_parent). The ancestor_relay_parent_info runtime API only works for ancestors (a block is not in its own AllowedRelayParents). This utility handles the self case by verifying the session directly via session_index_for_child.