code: def __init__(self, max_calls_before_reconnect, **kwargs):
      super().__init__(**kwargs)
      self._max_calls_before_reconnect = max_calls_before_reconnect
  
imports: import mongomock
  import pymongo
  import pymongo.errors
label_desc: Use image node_id 1 to create a new ReconnectingCollection object from inherited base classes: FailingCollection with example: obj = ReconnectingCollection(max_calls_before_reconnect)