From 657b002a8197b2a949ac423f7207a379db5bd787 Mon Sep 17 00:00:00 2001 From: Matthias Date: Sun, 13 Dec 2020 10:59:29 +0100 Subject: [PATCH] Explicitly check for False in fetch_ticker --- freqtrade/exchange/exchange.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/freqtrade/exchange/exchange.py b/freqtrade/exchange/exchange.py index 611ce4abd..7f763610c 100644 --- a/freqtrade/exchange/exchange.py +++ b/freqtrade/exchange/exchange.py @@ -658,7 +658,8 @@ class Exchange: @retrier def fetch_ticker(self, pair: str) -> dict: try: - if pair not in self._api.markets or not self._api.markets[pair].get('active'): + if (pair not in self._api.markets or + self._api.markets[pair].get('active', False) is False): raise ExchangeError(f"Pair {pair} not available") data = self._api.fetch_ticker(pair) return data