yfinance-cache
yfinance-cache copied to clipboard
KeyError when getting data for stocks listed on the BSE (Bombay Stock Exchange)
KeyError when getting data for stocks listed on the BSE (Bombay Stock Exchange)
>>> stock = yf.Ticker("500182.BO")
>>> data = stock.history(period="1mo",interval="1d")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/ishan/Desktop/etreco/venv/lib/python3.12/site-packages/yfinance_cache/yfc_ticker.py", line 94, in history
yfct.SetExchangeTzName(exchange, tz_name)
File "/home/ishan/Desktop/etreco/venv/lib/python3.12/site-packages/yfinance_cache/yfc_time.py", line 36, in SetExchangeTzName
exchange_lock = yfcd.exchange_locks[exchange]
~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
KeyError: 'YHD'