pub fn handle_sync_failure(
state: &mut NeighborSyncState,
failed_peer: &PeerId,
cooldown: Duration,
) -> Option<PeerId>Expand description
Handle a failed sync attempt: remove peer from snapshot and try to fill the vacated slot.
Rule 3: Remove unreachable peer from pending sync state, attempt to fill
by using the same priority-first scan as select_sync_batch. Applies the
same cooldown filtering to avoid selecting a peer that was recently synced.