From fb3a6e2ce81adb453e277218a5314dee1b4662f7 Mon Sep 17 00:00:00 2001 From: Sam Germain Date: Fri, 11 Feb 2022 00:43:45 -0600 Subject: [PATCH] added liquidation_buffer to constants.py --- freqtrade/constants.py | 1 + freqtrade/exchange/exchange.py | 4 ---- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/freqtrade/constants.py b/freqtrade/constants.py index f5dae9473..7e3f4374c 100644 --- a/freqtrade/constants.py +++ b/freqtrade/constants.py @@ -156,6 +156,7 @@ CONF_SCHEMA = { 'ignore_buying_expired_candle_after': {'type': 'number'}, 'trading_mode': {'type': 'string', 'enum': TRADING_MODES}, 'margin_mode': {'type': 'string', 'enum': MARGIN_MODES}, + 'liquidation_buffer': {'type': 'number', 'minimum': 0.0, 'maximum': 0.99}, 'backtest_breakdown': { 'type': 'array', 'items': {'type': 'string', 'enum': BACKTEST_BREAKDOWNS} diff --git a/freqtrade/exchange/exchange.py b/freqtrade/exchange/exchange.py index a5fc85f03..acd0e3ea0 100644 --- a/freqtrade/exchange/exchange.py +++ b/freqtrade/exchange/exchange.py @@ -143,10 +143,6 @@ class Exchange: else None ) self.liquidation_buffer = config.get('liquidation_buffer', 0.05) - if self.liquidation_buffer < 0.0: - raise OperationalException('Cannot have a negative liquidation_buffer') - if self.liquidation_buffer > 0.99: - raise OperationalException('Liquidation_buffer must be below 0.99') # Initialize ccxt objects ccxt_config = self._ccxt_config