Fix flake8 error in fiat_convert

This commit is contained in:
A. Schueler 2021-05-17 12:05:25 +02:00
parent a0921ec753
commit 8842e0d161

View File

@ -54,7 +54,8 @@ class CryptoToFiatConverter:
self._cryptomap = {x['symbol']: x['id'] for x in coinlistings} self._cryptomap = {x['symbol']: x['id'] for x in coinlistings}
except RequestException as request_exception: except RequestException as request_exception:
if "429" in str(request_exception): if "429" in str(request_exception):
logger.warning("Too many requests for Coingecko API, backing off and trying again later.") logger.warning(
"Too many requests for Coingecko API, backing off and trying again later.")
# Set backoff timestamp to 60 seconds in the future # Set backoff timestamp to 60 seconds in the future
self._backoff = datetime.datetime.now().timestamp() + 60 self._backoff = datetime.datetime.now().timestamp() + 60
except (Exception) as exception: except (Exception) as exception: