From fc569694e9960d91dad8ed82b7d546b6b96b1c46 Mon Sep 17 00:00:00 2001 From: Willem Melching Date: Thu, 17 Jun 2021 19:20:41 +0200 Subject: [PATCH] Athena: increase timeouts (#21316) * fix typo in thread name * bump send/upload timeout to 30 seconds --- selfdrive/athena/athenad.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/selfdrive/athena/athenad.py b/selfdrive/athena/athenad.py index 1659b692..99e5998c 100755 --- a/selfdrive/athena/athenad.py +++ b/selfdrive/athena/athenad.py @@ -54,7 +54,7 @@ def handle_long_poll(ws): threads = [ threading.Thread(target=ws_recv, args=(ws, end_event), name='ws_recv'), - threading.Thread(target=ws_send, args=(ws, end_event), name='wc_send'), + threading.Thread(target=ws_send, args=(ws, end_event), name='ws_send'), threading.Thread(target=upload_handler, args=(end_event,), name='upload_handler'), threading.Thread(target=log_handler, args=(end_event,), name='log_handler'), ] + [ @@ -116,7 +116,7 @@ def _do_upload(upload_item): return requests.put(upload_item.url, data=f, headers={**upload_item.headers, 'Content-Length': str(size)}, - timeout=10) + timeout=30) # security: user should be able to request any message from their car @@ -479,8 +479,7 @@ def main(): ws = create_connection(ws_uri, cookie="jwt=" + api.get_token(), enable_multithread=True, - timeout=1.0) - ws.settimeout(1) + timeout=30.0) cloudlog.event("athenad.main.connected_ws", ws_uri=ws_uri) manage_tokens(api)