refactor: improve punctuation handling on bad exchanges
This commit is contained in:
@@ -51,10 +51,12 @@ def check_exchange(config: Config, check_for_bad: bool = True) -> bool:
|
|||||||
if not valid:
|
if not valid:
|
||||||
if check_for_bad:
|
if check_for_bad:
|
||||||
raise OperationalException(
|
raise OperationalException(
|
||||||
f'Exchange "{exchange}" will not work with Freqtrade. Reason: {reason}'
|
f'Exchange "{exchange}" will not work with Freqtrade. Reason: {reason}.'
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
logger.warning(f'Exchange "{exchange}" will not work with Freqtrade. Reason: {reason}')
|
logger.warning(
|
||||||
|
f'Exchange "{exchange}" will not work with Freqtrade. Reason: {reason}.'
|
||||||
|
)
|
||||||
|
|
||||||
if MAP_EXCHANGE_CHILDCLASS.get(exchange, exchange) in SUPPORTED_EXCHANGES:
|
if MAP_EXCHANGE_CHILDCLASS.get(exchange, exchange) in SUPPORTED_EXCHANGES:
|
||||||
logger.info(
|
logger.info(
|
||||||
|
|||||||
@@ -36,12 +36,12 @@ API_RETRY_COUNT = 4
|
|||||||
API_FETCH_ORDER_RETRY_COUNT = 5
|
API_FETCH_ORDER_RETRY_COUNT = 5
|
||||||
|
|
||||||
BAD_EXCHANGES = {
|
BAD_EXCHANGES = {
|
||||||
"bitmex": "Various reasons.",
|
"bitmex": "Various reasons",
|
||||||
"probit": "Requires additional, regular calls to `signIn()`.",
|
"probit": "Requires additional, regular calls to `signIn()`",
|
||||||
"poloniex": "Does not provide fetch_order endpoint to fetch both open and closed orders.",
|
"poloniex": "Does not provide fetch_order endpoint to fetch both open and closed orders",
|
||||||
"kucoinfutures": "Unsupported futures exchange.",
|
"kucoinfutures": "Unsupported futures exchange",
|
||||||
"poloniexfutures": "Unsupported futures exchange.",
|
"poloniexfutures": "Unsupported futures exchange",
|
||||||
"binancecoinm": "Unsupported futures exchange.",
|
"binancecoinm": "Unsupported futures exchange",
|
||||||
}
|
}
|
||||||
|
|
||||||
MAP_EXCHANGE_CHILDCLASS = {
|
MAP_EXCHANGE_CHILDCLASS = {
|
||||||
|
|||||||
Reference in New Issue
Block a user