check for timeouts before exiting positions
This commit is contained in:
parent
270ac2e8c1
commit
7c47c6e3bd
@ -143,6 +143,10 @@ class FreqtradeBot:
|
|||||||
self.dataprovider.refresh(self._create_pair_whitelist(self.active_pair_whitelist),
|
self.dataprovider.refresh(self._create_pair_whitelist(self.active_pair_whitelist),
|
||||||
self.strategy.informative_pairs())
|
self.strategy.informative_pairs())
|
||||||
|
|
||||||
|
with self._sell_lock:
|
||||||
|
# Check and handle any timed out open orders
|
||||||
|
self.check_handle_timedout()
|
||||||
|
|
||||||
# Protect from collisions with forcesell.
|
# Protect from collisions with forcesell.
|
||||||
# Without this, freqtrade my try to recreate stoploss_on_exchange orders
|
# Without this, freqtrade my try to recreate stoploss_on_exchange orders
|
||||||
# while selling is in process, since telegram messages arrive in an different thread.
|
# while selling is in process, since telegram messages arrive in an different thread.
|
||||||
@ -154,8 +158,6 @@ class FreqtradeBot:
|
|||||||
if self.get_free_open_trades():
|
if self.get_free_open_trades():
|
||||||
self.enter_positions()
|
self.enter_positions()
|
||||||
|
|
||||||
# Check and handle any timed out open orders
|
|
||||||
self.check_handle_timedout()
|
|
||||||
Trade.session.flush()
|
Trade.session.flush()
|
||||||
|
|
||||||
def _refresh_whitelist(self, trades: List[Trade] = []) -> List[str]:
|
def _refresh_whitelist(self, trades: List[Trade] = []) -> List[str]:
|
||||||
|
Loading…
Reference in New Issue
Block a user