From b96260283f25ca593385ba11379fb3a69f3a5115 Mon Sep 17 00:00:00 2001 From: Bryant Moscon Date: Sun, 20 Nov 2022 13:58:00 -0500 Subject: [PATCH] Fix coinbase symbol parsing --- cryptofeed/exchanges/coinbase.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cryptofeed/exchanges/coinbase.py b/cryptofeed/exchanges/coinbase.py index 2dee605c1..abb9e3851 100644 --- a/cryptofeed/exchanges/coinbase.py +++ b/cryptofeed/exchanges/coinbase.py @@ -47,7 +47,8 @@ def _parse_symbol_data(cls, data: list) -> Tuple[Dict, Dict]: info = defaultdict(dict) for entry in data: - sym = Symbol(entry['base_currency'], entry['quote_currency']) + base, quote = entry['id'].split("-") + sym = Symbol(base, quote) info['tick_size'][sym.normalized] = entry['quote_increment'] info['instrument_type'][sym.normalized] = sym.type ret[sym.normalized] = entry['id']