Skip to main content

claim_fallback

Function claim_fallback 

Source
pub(crate) async fn claim_fallback(
    block_id: &str,
    reason: &str,
    boundary_uuid: Option<&str>,
    event_at_ms: Option<i64>,
) -> bool
Expand description

Whether the frontend’s hidden-reinjection fallback should deliver this event (true) or stand down because the SessionStart hook delivered it (false). Waits out a hook delivery still in flight for up to PENDING_WAIT, then lets the fallback deliver, so a hook that died part-way never leaves the agent without its memory. With a boundary_uuid, only the block whose CLI compacted can deliver. With event_at_ms (a fresh session’s time), the hook’s delivery for that session counts however late the claim comes.