from _typeshed import Incomplete
from enum import IntEnum

log: Incomplete

class FinalState(IntEnum):
    ABORTED = 0
    FAILED = 1
    SUCCEEDED = 2

class ProducerBatch:
    max_record_size: int
    created: Incomplete
    drained: Incomplete
    attempts: int
    last_attempt: Incomplete
    last_append: Incomplete
    records: Incomplete
    topic_partition: Incomplete
    produce_future: Incomplete
    def __init__(self, tp, records, now=None) -> None: ...
    @property
    def final_state(self): ...
    @property
    def record_count(self): ...
    @property
    def producer_id(self): ...
    @property
    def producer_epoch(self): ...
    @property
    def has_sequence(self): ...
    def try_append(self, timestamp_ms, key, value, headers, now=None): ...
    def abort(self, exception): ...
    def complete(self, base_offset, log_append_time): ...
    def complete_exceptionally(self, top_level_exception, record_exceptions_fn): ...
    def done(self, base_offset=None, timestamp_ms=None, top_level_exception=None, record_exceptions_fn=None): ...
    def has_reached_delivery_timeout(self, delivery_timeout_ms, now=None): ...
    def in_retry(self): ...
    def retry(self, now=None) -> None: ...
    @property
    def is_done(self): ...
    def __lt__(self, other): ...
