fix bug in async download script

This commit is contained in:
Matthias 2018-08-18 21:08:59 +02:00
parent d556f669b0
commit d722c12109
1 changed files with 2 additions and 0 deletions

View File

@ -404,6 +404,8 @@ class Exchange(object):
for tick in tickers:
if tick[0] == pair:
data.extend(tick[1])
# Sort data again after extending the result - above calls return in "async order" order
data = sorted(data, key=lambda x: x[0])
logger.info("downloaded %s with length %s.", pair, len(data))
return data