Skip to content

miniproto.connection.sender.PendingRequest

miniproto.connection.sender.PendingRequest

Section titled “miniproto.connection.sender.PendingRequest”
PendingRequest(body: bytes | object, content_related: bool, future: asyncio.Future[object], retry_safe: bool = False, attempts: int = 0, transport: Transport | None = None, aliases: set[int] = set(), quick_ack: bool = False, quick_ack_callback: Callable[[QuickAckReceipt], None] | None = None, quick_ack_received: bool = False, quick_ack_waiters: list[QuickAckWaiter] = list(), expected_pong_ping_id: int | None = None) -> None

Internal state retained for one unresolved request and its resend aliases.

Parameters:

  • body (bytes | object) – Original encoded or serializable request body.
  • content_related (bool) – Whether MTProto sequence allocation marks it as content.
  • future (Future[object]) – Future completed with the RPC result or terminal exception.
  • retry_safe (bool) – Whether transport loss may resend this request automatically.
  • attempts (int) – Number of encrypted send attempts already made.
  • transport (Transport | None) – Transport used for the latest attempt.
  • aliases (set[int]) – Message IDs that currently map to this request after retries.
  • quick_ack (bool) – Whether the latest attempts request transport-level quick ACKs.
  • quick_ack_callback (Callable[[QuickAckReceipt], None] | None) – Optional synchronous callback for the first receipt.
  • quick_ack_received (bool) – Whether a non-stale receipt was already delivered.
  • quick_ack_waiters (list[QuickAckWaiter]) – Registered receipt correlations awaiting removal.
  • expected_pong_ping_id (int | None) – Ping identifier that a correlated Pong must echo, or None when this is not a ping request.