Check for empty whitelist moved to _process()

This commit is contained in:
hroff-1902 2019-04-01 21:36:53 +03:00
parent 34b40500c3
commit ab0e657d77

View File

@ -79,8 +79,6 @@ class FreqtradeBot(object):
self.config.get('edge', {}).get('enabled', False) else None self.config.get('edge', {}).get('enabled', False) else None
self.active_pair_whitelist: List[str] = self.config['exchange']['pair_whitelist'] self.active_pair_whitelist: List[str] = self.config['exchange']['pair_whitelist']
if not self.active_pair_whitelist:
raise DependencyException('Whitelist is empty.')
self._init_modules() self._init_modules()
@ -198,6 +196,9 @@ class FreqtradeBot(object):
# Refresh whitelist # Refresh whitelist
self.pairlists.refresh_pairlist() self.pairlists.refresh_pairlist()
self.active_pair_whitelist = self.pairlists.whitelist self.active_pair_whitelist = self.pairlists.whitelist
if not self.active_pair_whitelist:
logger.warning('Whitelist is empty.')
return False
# Calculating Edge positioning # Calculating Edge positioning
if self.edge: if self.edge: