Skip to main content

spawn_pending_receive_scanner

Function spawn_pending_receive_scanner 

Source
pub(crate) fn spawn_pending_receive_scanner(
    btc_rpc: ServerBitcoinRpcMonitor,
    pks_hash: Hash,
    sender: Sender<PendingOutputs>,
    task_group: &TaskGroup,
)
Expand description

Maintains crate::Wallet::pending_outputs by scanning both the blocks just below the guardian’s local chain tip and its mempool.

This deliberately runs outside of consensus. Most of this window sits above the consensus block count precisely because the federation does not consider those blocks final yet, and each guardian sees a slightly different tip, so nothing derived here may ever influence consensus state. It exists only so clients can render peg-in progress rather than showing nothing for the hour it takes a deposit to become claimable.