Added liq-formula to exchange classes
This commit is contained in:
parent
7ac73999f6
commit
265638bb05
@ -25,6 +25,7 @@ class Binance(Exchange):
|
|||||||
"l2_limit_range": [5, 10, 20, 50, 100, 500, 1000],
|
"l2_limit_range": [5, 10, 20, 50, 100, 500, 1000],
|
||||||
}
|
}
|
||||||
interest_mode: InterestMode = InterestMode.HOURSPERDAY
|
interest_mode: InterestMode = InterestMode.HOURSPERDAY
|
||||||
|
liq_formula: LiqFormula = LiqFormula.BINANCE
|
||||||
|
|
||||||
maintenance_margin_formula = LiqFormula.BINANCE
|
maintenance_margin_formula = LiqFormula.BINANCE
|
||||||
|
|
||||||
|
@ -71,6 +71,7 @@ class Exchange:
|
|||||||
_ft_has: Dict = {}
|
_ft_has: Dict = {}
|
||||||
liq_formula: LiqFormula
|
liq_formula: LiqFormula
|
||||||
interest_mode: InterestMode = InterestMode.NONE
|
interest_mode: InterestMode = InterestMode.NONE
|
||||||
|
liq_formula: LiqFormula = LiqFormula.NONE
|
||||||
|
|
||||||
def __init__(self, config: Dict[str, Any], validate: bool = True) -> None:
|
def __init__(self, config: Dict[str, Any], validate: bool = True) -> None:
|
||||||
"""
|
"""
|
||||||
|
@ -5,6 +5,7 @@ from typing import Any, Dict
|
|||||||
import ccxt
|
import ccxt
|
||||||
|
|
||||||
from freqtrade.enums import LiqFormula
|
from freqtrade.enums import LiqFormula
|
||||||
|
#from freqtrade.enums import InterestMode, LiqFormula
|
||||||
from freqtrade.exceptions import (DDosProtection, InsufficientFundsError, InvalidOrderException,
|
from freqtrade.exceptions import (DDosProtection, InsufficientFundsError, InvalidOrderException,
|
||||||
OperationalException, TemporaryError)
|
OperationalException, TemporaryError)
|
||||||
from freqtrade.exchange import Exchange
|
from freqtrade.exchange import Exchange
|
||||||
@ -21,8 +22,8 @@ class Ftx(Exchange):
|
|||||||
"stoploss_on_exchange": True,
|
"stoploss_on_exchange": True,
|
||||||
"ohlcv_candle_limit": 1500,
|
"ohlcv_candle_limit": 1500,
|
||||||
}
|
}
|
||||||
|
#interest_mode: InterestMode = InterestMode.HOURSPERDAY
|
||||||
maintenance_margin_formula = LiqFormula.FTX
|
liq_formula: LiqFormula = LiqFormula.FTX
|
||||||
|
|
||||||
def market_is_tradable(self, market: Dict[str, Any]) -> bool:
|
def market_is_tradable(self, market: Dict[str, Any]) -> bool:
|
||||||
"""
|
"""
|
||||||
|
@ -24,6 +24,7 @@ class Kraken(Exchange):
|
|||||||
"trades_pagination_arg": "since",
|
"trades_pagination_arg": "since",
|
||||||
}
|
}
|
||||||
interest_mode: InterestMode = InterestMode.HOURSPER4
|
interest_mode: InterestMode = InterestMode.HOURSPER4
|
||||||
|
liq_formula: LiqFormula = LiqFormula.KRAKEN
|
||||||
|
|
||||||
maintenance_margin_formula = LiqFormula.KRAKEN
|
maintenance_margin_formula = LiqFormula.KRAKEN
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user