code: def send(self, data):
          
          while not self.stopped():
              try:
                  self.ws.send(data)
                  return
              except websocket.WebSocketConnectionClosedException:
                  # config.LOGGER.debug('WebSocket closed, retrying send.') # TODO(investigate infinite loop)
                  time.sleep(0.1)
docs: This method keeps trying to send a message relying on the run method
          to reopen the websocket in case it was closed.