Reduce warnings when waiting for coingecko backoff
This commit is contained in:
parent
e4ca944597
commit
f8cdd6475c
@ -143,11 +143,14 @@ class CryptoToFiatConverter:
|
|||||||
if crypto_symbol == fiat_symbol:
|
if crypto_symbol == fiat_symbol:
|
||||||
return 1.0
|
return 1.0
|
||||||
|
|
||||||
if self._cryptomap == {} and self._backoff <= datetime.datetime.now().timestamp():
|
if self._cryptomap == {}:
|
||||||
|
if self._backoff <= datetime.datetime.now().timestamp():
|
||||||
self._load_cryptomap()
|
self._load_cryptomap()
|
||||||
# return 0.0 if we still dont have data to check, no reason to proceed
|
# return 0.0 if we still dont have data to check, no reason to proceed
|
||||||
if self._cryptomap == {}:
|
if self._cryptomap == {}:
|
||||||
return 0.0
|
return 0.0
|
||||||
|
else:
|
||||||
|
return 0.0
|
||||||
|
|
||||||
if crypto_symbol not in self._cryptomap:
|
if crypto_symbol not in self._cryptomap:
|
||||||
# return 0 for unsupported stake currencies (fiat-convert should not break the bot)
|
# return 0 for unsupported stake currencies (fiat-convert should not break the bot)
|
||||||
|
Loading…
Reference in New Issue
Block a user