From 37a4f02266de0512dbd4de65d6c6efd0c8ca2d0d Mon Sep 17 00:00:00 2001 From: Tilman Date: Tue, 31 Oct 2017 18:12:53 +0100 Subject: [PATCH] piplayer3.py production version --- code/piplayer3.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/piplayer3.py b/code/piplayer3.py index e9f42ce..2a88e45 100644 --- a/code/piplayer3.py +++ b/code/piplayer3.py @@ -171,8 +171,8 @@ try: logging.info("Trying to connect to the server...") response = requests.post(MOPIDY_RPC_URL, data='{"jsonrpc": "2.0", "id": 1, "method": "core.tracklist.clear"}', timeout=REQUEST_TIMEOUT) except: - logging.debug("Connection refused by the server, wait 5 seconds") - time.sleep(5) + logging.debug("Timeout while connecting to the server") + time.sleep(1) continue play_sound(SOUND_OK)