2020-02-16 12:20:11 +00:00
|
|
|
""" FTX exchange subclass """
|
|
|
|
import logging
|
2020-06-02 18:29:48 +00:00
|
|
|
from typing import Any, Dict
|
2020-02-16 12:20:11 +00:00
|
|
|
|
|
|
|
from freqtrade.exchange import Exchange
|
|
|
|
|
|
|
|
logger = logging.getLogger(__name__)
|
|
|
|
|
|
|
|
|
|
|
|
class Ftx(Exchange):
|
|
|
|
|
|
|
|
_ft_has: Dict = {
|
|
|
|
"ohlcv_candle_limit": 1500,
|
|
|
|
}
|
2020-06-02 18:29:48 +00:00
|
|
|
|
|
|
|
def market_is_tradable(self, market: Dict[str, Any]) -> bool:
|
|
|
|
"""
|
|
|
|
Check if the market symbol is tradable by Freqtrade.
|
2020-06-02 18:30:31 +00:00
|
|
|
Default checks + check if pair is spot pair (no futures trading yet).
|
2020-06-02 18:29:48 +00:00
|
|
|
"""
|
|
|
|
parent_check = super().market_is_tradable(market)
|
|
|
|
|
|
|
|
return (parent_check and
|
|
|
|
market.get('spot', False) is True)
|