diff --git a/freqtrade/main.py b/freqtrade/main.py index c404d6c11..6f3854af2 100755 --- a/freqtrade/main.py +++ b/freqtrade/main.py @@ -48,7 +48,14 @@ def refresh_whitelist(whitelist: List[str]) -> List[str]: 'Ignoring %s from whitelist (reason: %s).', pair, status.get('Notice') or 'wallet is not active' ) - + # Wallet will be delisted soon (and cause a loss) + if "delisted" in status['Notice']: + sanitized_whitelist.remove(pair) + logger.info( + 'Ignoring %s from whitelist (reason: %s).', + pair, status.get('Notice') or 'wallet will be delisted soon' + ) + # We need to remove pairs that are unknown final_list = [x for x in sanitized_whitelist if x in known_pairs] return final_list