aboutsummaryrefslogtreecommitdiff
path: root/pandora
diff options
context:
space:
mode:
authorjcass <john.cass77@gmail.com>2016-01-12 18:24:18 +0200
committerjcass <john.cass77@gmail.com>2016-01-12 18:24:18 +0200
commit473872dc0e3ffbcad5dfe4fec69e41755c47c549 (patch)
treea85607c9b18f909a7431712477ded8c6b718f8e4 /pandora
parent296c91c836ad41a5130711bcd6f30117a4c48265 (diff)
downloadpydora-473872dc0e3ffbcad5dfe4fec69e41755c47c549.tar.bz2
pydora-473872dc0e3ffbcad5dfe4fec69e41755c47c549.tar.xz
pydora-473872dc0e3ffbcad5dfe4fec69e41755c47c549.zip
Fix to ensure InvalidAuthToken exceptions result in re-authentication and retry.
Diffstat (limited to 'pandora')
-rw-r--r--pandora/transport.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pandora/transport.py b/pandora/transport.py
index bba1608..cdd1699 100644
--- a/pandora/transport.py
+++ b/pandora/transport.py
@@ -50,7 +50,7 @@ def retries(max_tries, exceptions=(Exception,)):
50 # Don't retry for PandoraExceptions - unlikely that result 50 # Don't retry for PandoraExceptions - unlikely that result
51 # will change for same set of input parameters. 51 # will change for same set of input parameters.
52 if isinstance(e, PandoraException): 52 if isinstance(e, PandoraException):
53 break 53 raise
54 if retries_left > 0: 54 if retries_left > 0:
55 time.sleep(delay_exponential( 55 time.sleep(delay_exponential(
56 0.5, 2, max_tries - retries_left)) 56 0.5, 2, max_tries - retries_left))