Sir i got this error when i want to login. I am novice in this. So help me to solve this

dhanhq api

D:\DHAN\NEW\3.1 Codebase Upgrade>pip show dhanhq
Name: dhanhq
Version: 2.0.2
Summary: The official Python client for communicating with the DhanHQ API
Home-page: https://dhanhq.co/
Author: Dhan
Author-email: dhan-oss@dhan.co
License: MIT LICENSE
Location: C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages
Requires: pandas, pyOpenSSL, requests, websockets
Required-by: Dhan_Tradehull

dhan-tradehull

D:\DHAN\NEW\3.1 Codebase Upgrade>pip show dhan-tradehull
Name: Dhan_Tradehull
Version: 3.0.6
Summary: A Dhan Codebase from TradeHull
Home-page: https://github.com/TradeHull/Dhan_Tradehull
Author: TradeHull
Author-email: contact.tradehull@gmail.com
License:
Location: C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages
Requires: dhanhq, mibian, numpy, pandas, pytz, requests
Required-by:

D:\DHAN\NEW\3.1 Codebase Upgrade>py "How to use updated codebase.py"
Codebase Version 2.8 : Solved - Strike Selection Issue
-----Logged into Dhan-----
This BOT Is Picking New File From Dhan
<urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1000)>
'Tradehull' object has no attribute 'response'
Traceback (most recent call last):
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\urllib\request.py", line 1344, in do_open
    h.request(req.get_method(), req.selector, req.data, headers,
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\http\client.py", line 1336, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\http\client.py", line 1382, in _send_request
    self.endheaders(body, encode_chunked=encode_chunked)
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\http\client.py", line 1331, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\http\client.py", line 1091, in _send_output
    self.send(msg)
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\http\client.py", line 1035, in send
    self.connect()
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\http\client.py", line 1477, in connect
    self.sock = self._context.wrap_socket(self.sock,
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\ssl.py", line 455, in wrap_socket
    return self.sslsocket_class._create(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\ssl.py", line 1041, in _create
    self.do_handshake()
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\ssl.py", line 1319, in do_handshake
    self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1000)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "D:\DHAN\NEW\3.1 Codebase Upgrade\Dhan_Tradehull_V2.py", line 80, in get_login
    self.instrument_df                                                                  = self.get_instrument_file()
                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\DHAN\NEW\3.1 Codebase Upgrade\Dhan_Tradehull_V2.py", line 112, in get_instrument_file
    instrument_df = pd.read_csv("https://images.dhan.co/api-data/api-scrip-master.csv", low_memory=False)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\parsers\readers.py", line 1026, in read_csv
    return _read(filepath_or_buffer, kwds)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\parsers\readers.py", line 620, in _read
    parser = TextFileReader(filepath_or_buffer, **kwds)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\parsers\readers.py", line 1620, in __init__
    self._engine = self._make_engine(f, self.engine)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\parsers\readers.py", line 1880, in _make_engine
    self.handles = get_handle(
                   ^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\common.py", line 728, in get_handle
    ioargs = _get_filepath_or_buffer(
             ^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\common.py", line 384, in _get_filepath_or_buffer
    with urlopen(req_info) as req:
         ^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\io\common.py", line 289, in urlopen
    return urllib.request.urlopen(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\urllib\request.py", line 215, in urlopen
    return opener.open(url, data, timeout)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\urllib\request.py", line 515, in open
    response = self._open(req, data)
               ^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\urllib\request.py", line 532, in _open
    result = self._call_chain(self.handle_open, protocol, protocol +
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\urllib\request.py", line 492, in _call_chain
    result = func(*args)
             ^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\urllib\request.py", line 1392, in https_open
    return self.do_open(http.client.HTTPSConnection, req,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\LENOVO\AppData\Local\Programs\Python\Python312\Lib\urllib\request.py", line 1347, in do_open
    raise URLError(err)
urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1000)>

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "D:\DHAN\NEW\3.1 Codebase Upgrade\Dhan_Tradehull_V2.py", line 53, in __init__
    self.get_login(ClientCode,token_id)
  File "D:\DHAN\NEW\3.1 Codebase Upgrade\Dhan_Tradehull_V2.py", line 85, in get_login
    print(self.response)
          ^^^^^^^^^^^^^
AttributeError: 'Tradehull' object has no attribute 'response'
Exception at calling ltp as 'Tradehull' object has no attribute 'instrument_df'
Traceback (most recent call last):
  File "D:\DHAN\NEW\3.1 Codebase Upgrade\How to use updated codebase.py", line 19, in <module>
    acc_ltp = all_ltp_data['ACC']
              ~~~~~~~~~~~~^^^^^^^
KeyError: 'ACC'

Hi @Tech_Geek ,

Welcome to madefortrade ,

Thanks for bringing this up. @Tradehull_Imran may be able to assist here