code: def __init__(self, wsClient, maxInactivity, responseTimeout):
      assert maxInactivity > 0
      assert responseTimeout > 0
      self.__callback = None
      self.__wsClient = wsClient
      self.__activityTimeout = maxInactivity
      self.__responseTimeout = responseTimeout
      self.__lastSeen = None
      self.__kaSent = None
  
imports: import json
  import time
  import threading
  import six
  from ws4py.client import tornadoclient
  import tornado
  import pyalgotrade.logger
label_desc: Use image node_id 1 to create a new KeepAliveMgr object from inherited base classes: object with example: obj = KeepAliveMgr(wsClient, maxInactivity, responseTimeout)