mirror of
https://github.com/freqtrade/freqtrade.git
synced 2025-12-16 21:01:14 +00:00
chore: fix init sequence to avoid risk of "unbound error"
This commit is contained in:
@@ -277,6 +277,11 @@ class Exchange:
|
|||||||
|
|
||||||
logger.info(f'Using Exchange "{self.name}"')
|
logger.info(f'Using Exchange "{self.name}"')
|
||||||
self.required_candle_call_count = 1
|
self.required_candle_call_count = 1
|
||||||
|
# Converts the interval provided in minutes in config to seconds
|
||||||
|
self.markets_refresh_interval: int = (
|
||||||
|
exchange_conf.get("markets_refresh_interval", 60) * 60 * 1000
|
||||||
|
)
|
||||||
|
|
||||||
if validate:
|
if validate:
|
||||||
# Initial markets load
|
# Initial markets load
|
||||||
self.reload_markets(True, load_leverage_tiers=False)
|
self.reload_markets(True, load_leverage_tiers=False)
|
||||||
@@ -286,11 +291,6 @@ class Exchange:
|
|||||||
self._startup_candle_count, config.get("timeframe", "")
|
self._startup_candle_count, config.get("timeframe", "")
|
||||||
)
|
)
|
||||||
|
|
||||||
# Converts the interval provided in minutes in config to seconds
|
|
||||||
self.markets_refresh_interval: int = (
|
|
||||||
exchange_conf.get("markets_refresh_interval", 60) * 60 * 1000
|
|
||||||
)
|
|
||||||
|
|
||||||
if self.trading_mode != TradingMode.SPOT and load_leverage_tiers:
|
if self.trading_mode != TradingMode.SPOT and load_leverage_tiers:
|
||||||
self.fill_leverage_tiers()
|
self.fill_leverage_tiers()
|
||||||
self.additional_exchange_init()
|
self.additional_exchange_init()
|
||||||
|
|||||||
Reference in New Issue
Block a user