code: def settimeout(self, timeout):
          
          self.sock_opt.timeout = timeout
          if self.sock:
              self.sock.settimeout(timeout)
docs: Set the timeout to the websocket.
  
          timeout: timeout time(second).