class_docstr: A threadsafe helper class to hold ProducerBatches that haven't been ack'd yet
class_docstr_tok: ["A","threadsafe","helper","class","to","hold","ProducerBatches","that","have","n't","been","ack","'d","yet"]
code: def remove(self, batch):
      with self._lock:
          return self._incomplete.remove(batch)
  
imports: from __future__ import absolute_import
  import collections
  import copy
  import logging
  import threading
  import time
  import kafka.errors
  from kafka.producer.buffer import SimpleBufferPool
  from kafka.producer.future import FutureRecordMetadata, FutureProduceResult
  from kafka.record.memory_records import MemoryRecordsBuilder
  from kafka.structs import TopicPartition
label_desc: Use image node_id 3 for calling the IncompleteProducerBatches obj's underlying member method code with example usage: obj.remove(batch) and returns: self