From 16146357b329a759654c302e391e304848adc951 Mon Sep 17 00:00:00 2001 From: axel Date: Tue, 3 Aug 2021 16:39:35 -0400 Subject: [PATCH] reuse buy_limit_requested as rate input for custom entry price --- freqtrade/freqtradebot.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/freqtrade/freqtradebot.py b/freqtrade/freqtradebot.py index 5b60c0ea3..ffe223899 100644 --- a/freqtrade/freqtradebot.py +++ b/freqtrade/freqtradebot.py @@ -481,11 +481,10 @@ class FreqtradeBot(LoggingMixin): # Calculate price buy_limit_requested = self.exchange.get_rate(pair, refresh=True, side="buy") if self.config.get('use_custom_entry_price', False): - buy_rate = self.exchange.get_rate(pair, refresh=True, side="buy") custom_entry_price = strategy_safe_wrapper(self.strategy.custom_entry_price, default_retval=stake_amount)( pair=pair, current_time=datetime.now(timezone.utc), - current_rate=buy_rate) + current_rate=buy_limit_requested) buy_limit_requested = custom_entry_price