diff --git a/freqtrade/freqtradebot.py b/freqtrade/freqtradebot.py index d9a15f56a..5425e8736 100644 --- a/freqtrade/freqtradebot.py +++ b/freqtrade/freqtradebot.py @@ -700,7 +700,7 @@ class FreqtradeBot(object): logger.debug('Handling stoploss on exchange %s ...', trade) order = self.exchange.get_order(trade.stoploss_order_id, trade.pair) if order['status'] == 'closed': - trade.sell_reason = SellType.STOPLOSS_ON_EXCHNAGE.value + trade.sell_reason = SellType.STOPLOSS_ON_EXCHANGE.value trade.update(order) result = True else: diff --git a/freqtrade/strategy/interface.py b/freqtrade/strategy/interface.py index 1073f8028..141dd996c 100644 --- a/freqtrade/strategy/interface.py +++ b/freqtrade/strategy/interface.py @@ -33,7 +33,7 @@ class SellType(Enum): """ ROI = "roi" STOP_LOSS = "stop_loss" - STOPLOSS_ON_EXCHNAGE = "stoploss_on_exchange" + STOPLOSS_ON_EXCHANGE = "stoploss_on_exchange" TRAILING_STOP_LOSS = "trailing_stop_loss" SELL_SIGNAL = "sell_signal" FORCE_SELL = "force_sell" diff --git a/freqtrade/tests/test_freqtradebot.py b/freqtrade/tests/test_freqtradebot.py index b6b42d1da..131d7df99 100644 --- a/freqtrade/tests/test_freqtradebot.py +++ b/freqtrade/tests/test_freqtradebot.py @@ -1685,7 +1685,7 @@ def test_may_execute_sell_after_stoploss_on_exchange_hit(default_conf, assert trade.stoploss_order_id is None assert trade.is_open is False print(trade.sell_reason) - assert trade.sell_reason == SellType.STOPLOSS_ON_EXCHNAGE.value + assert trade.sell_reason == SellType.STOPLOSS_ON_EXCHANGE.value assert rpc_mock.call_count == 1