I was using tradehull properley. so for some historical data I try to use DhanHQ Api, but I was unable to access the same. Then Dhan customer care told me to update to DhanHQ-py : v2.1.0. I did, Then I can’t access tradehull api. Below error
G:\advanced algo\Supertrend>py “1.7 strategy .py”
Codebase Version 3
-----Logged into Dhan-----
dhanhq.init() takes 2 positional arguments but 3 were given
‘Tradehull’ object has no attribute ‘response’
Traceback (most recent call last):
File “C:\Users\meetj\AppData\Local\Programs\Python\Python312\Lib\site-packages\Dhan_Tradehull\Dhan_Tradehull.py”, line 74, in get_login
self.Dhan = dhanhq(self.ClientCode, self.token_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: dhanhq.init() takes 2 positional arguments but 3 were given
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File “C:\Users\meetj\AppData\Local\Programs\Python\Python312\Lib\site-packages\Dhan_Tradehull\Dhan_Tradehull.py”, line 52, in init
self.get_login(ClientCode,token_id)
File “C:\Users\meetj\AppData\Local\Programs\Python\Python312\Lib\site-packages\Dhan_Tradehull\Dhan_Tradehull.py”, line 80, in get_login
print(self.response)
^^^^^^^^^^^^^
AttributeError: ‘Tradehull’ object has no attribute ‘response’
Error at Gettting balance as ‘Tradehull’ object has no attribute ‘Dhan’
Error at Gettting balance as ‘Tradehull’ object has no attribute ‘Dhan’
Starting live strategy loop. Press Ctrl+C to stop.
Exception in Getting OHLC data as ‘Tradehull’ object has no attribute ‘instrument_df’
Exception in Getting OHLC data as ‘Tradehull’ object has no attribute ‘instrument_df’
Insufficient data to compute indicators, retrying…
Interrupted by user. Performing final save…
Saved final orderbook to Live_Trades.xlsx
Strategy finished.
G:\advanced algo\Supertrend>