diff options
author | jcass <john.cass77@gmail.com> | 2016-01-12 18:24:18 +0200 |
---|---|---|
committer | jcass <john.cass77@gmail.com> | 2016-01-12 18:24:18 +0200 |
commit | 473872dc0e3ffbcad5dfe4fec69e41755c47c549 (patch) | |
tree | a85607c9b18f909a7431712477ded8c6b718f8e4 /pandora | |
parent | 296c91c836ad41a5130711bcd6f30117a4c48265 (diff) | |
download | pydora-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.py | 2 |
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)) |