convert price to precision price before verifying stoploss adjustment

closes #6504
This commit is contained in:
Matthias
2022-03-08 19:35:30 +01:00
parent 17041b78fc
commit f2ed6165e9
2 changed files with 29 additions and 1 deletions

View File

@@ -907,7 +907,9 @@ class FreqtradeBot(LoggingMixin):
:param order: Current on exchange stoploss order
:return: None
"""
if self.exchange.stoploss_adjust(trade.stop_loss, order):
stoploss_norm = self.exchange.price_to_precision(trade.pair, trade.stop_loss)
if self.exchange.stoploss_adjust(stoploss_norm, order):
# we check if the update is necessary
update_beat = self.strategy.order_types.get('stoploss_on_exchange_interval', 60)
if (datetime.utcnow() - trade.stoploss_last_update).total_seconds() >= update_beat: