def send_keep_alive(sock, interval=60): # 1 minute while True: try: sock.send(b'keep-alive') except Exception as e: print(f"Error sending keep-alive: {e}") time.sleep(interval)
We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.