Merge pull request #3519 from freqtrade/fix/trades_download_older
dl-trades should also support increasing download span
This commit is contained in:
@@ -270,6 +270,11 @@ def _download_trades_history(exchange: Exchange,
|
||||
# DEFAULT_TRADES_COLUMNS: 0 -> timestamp
|
||||
# DEFAULT_TRADES_COLUMNS: 1 -> id
|
||||
|
||||
if trades and since < trades[0][0]:
|
||||
# since is before the first trade
|
||||
logger.info(f"Start earlier than available data. Redownloading trades for {pair}...")
|
||||
trades = []
|
||||
|
||||
from_id = trades[-1][1] if trades else None
|
||||
if trades and since < trades[-1][0]:
|
||||
# Reset since to the last available point
|
||||
|
Reference in New Issue
Block a user