From d097cb7c225a98f5556cf4b8041008973e4c7323 Mon Sep 17 00:00:00 2001 From: realiti4 Date: Tue, 6 Apr 2021 18:30:16 +0300 Subject: [PATCH] bitmex api bug fix --- setup.py | 2 +- tradingfeatures/apis/bitmex/quote.py | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/setup.py b/setup.py index 7814b53..e58db89 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ setup( name="tradingfeatures", - version="0.5.6", + version="0.6.0", author="Onur Cetinkol", author_email="realiti44@gmail.com", description="A useful tool to download market history from popular exchanges.", diff --git a/tradingfeatures/apis/bitmex/quote.py b/tradingfeatures/apis/bitmex/quote.py index c633763..fdbda94 100644 --- a/tradingfeatures/apis/bitmex/quote.py +++ b/tradingfeatures/apis/bitmex/quote.py @@ -25,12 +25,14 @@ def get(self, query=None, start=None, end=None, *args, **kwargs): *args, **kwargs ) - def get_hist(self, convert_funds=False, *args, **kwargs): - self._start_check(self.address, kwargs['symbol']) + def get_hist(self, symbol=None, convert_funds=False, *args, **kwargs): + symbol = symbol or 'btcusd' + self._start_check(self.address, symbol=symbol) # columns = ['bidSize', 'bidPrice', 'askPrice', 'askSize'] if columns is None else columns df = apiBase.get_hist( self, + symbol=symbol, # columns=columns, # interval='8h', *args, **kwargs