Improve handling of kraken dataconvert

This commit is contained in:
Matthias
2023-09-24 20:10:27 +02:00
parent 2e430519e3
commit 1e8814b43e
2 changed files with 2 additions and 1 deletions

View File

@@ -136,6 +136,7 @@ def convert_trades_format(config: Config, convert_from: str, convert_to: str, er
)
from freqtrade.data.converter.trade_converter_kraken import import_kraken_trades_from_csv
import_kraken_trades_from_csv(config, convert_to)
return
from freqtrade.data.history.idatahandler import get_datahandler
src = get_datahandler(config['datadir'], convert_from)

View File

@@ -30,13 +30,13 @@ def import_kraken_trades_from_csv(config: Config, convert_to: str):
exchange = ExchangeResolver.load_exchange(config, validate=False)
# iterate through directories in this directory
data_symbols = {p.stem for p in tradesdir.rglob('*.csv')}
print(data_symbols)
# create pair/filename mapping
markets = {
(m['symbol'], m['altname']) for m in exchange.markets.values()
if m.get('altname') in data_symbols
}
logger.info(f"Found csv files for {', '.join(data_symbols)}")
for pair, name in markets:
dfs = []