mirror of
https://github.com/freqtrade/freqtrade.git
synced 2026-02-10 08:10:34 +00:00
Refactor validExchangesType to separate types package
This commit is contained in:
@@ -11,7 +11,7 @@ from ccxt import (DECIMAL_PLACES, ROUND, ROUND_DOWN, ROUND_UP, SIGNIFICANT_DIGIT
|
||||
|
||||
from freqtrade.exchange.common import (BAD_EXCHANGES, EXCHANGE_HAS_OPTIONAL, EXCHANGE_HAS_REQUIRED,
|
||||
SUPPORTED_EXCHANGES)
|
||||
from freqtrade.exchange.types import ValidExchangesType
|
||||
from freqtrade.types import ValidExchangesType
|
||||
from freqtrade.util import FtPrecise
|
||||
from freqtrade.util.datetime_helpers import dt_from_ts, dt_ts
|
||||
|
||||
|
||||
@@ -27,14 +27,5 @@ class OrderBook(TypedDict):
|
||||
Tickers = Dict[str, Ticker]
|
||||
|
||||
|
||||
# Used for list-exchanges
|
||||
class ValidExchangesType(TypedDict):
|
||||
name: str
|
||||
valid: bool
|
||||
supported: bool
|
||||
comment: str
|
||||
trade_modes: List[str]
|
||||
|
||||
|
||||
# pair, timeframe, candleType, OHLCV, drop last?,
|
||||
OHLCVResponse = Tuple[str, str, CandleType, List, bool]
|
||||
|
||||
1
freqtrade/types/__init__.py
Normal file
1
freqtrade/types/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from freqtrade.types.valid_exchanges_type import ValidExchangesType # noqa: F401
|
||||
10
freqtrade/types/valid_exchanges_type.py
Normal file
10
freqtrade/types/valid_exchanges_type.py
Normal file
@@ -0,0 +1,10 @@
|
||||
# Used for list-exchanges
|
||||
from typing import List, TypedDict
|
||||
|
||||
|
||||
class ValidExchangesType(TypedDict):
|
||||
name: str
|
||||
valid: bool
|
||||
supported: bool
|
||||
comment: str
|
||||
trade_modes: List[str]
|
||||
Reference in New Issue
Block a user