yfinance
yfinance copied to clipboard
Error on get_shares for some tickers
In 0.2.0rc2 version I get "object of type 'NoneType' has no len()" error for some tickers when trying to get yearly shares. I get the error with "BMW3.DE" ticker, for example. Code executed:
stock = yf.Ticker("BMW3.DE")
shares = stock.get_shares()
Thank you in advance for your efforts.
This seems fixed in latest dev branch.
In [1]: import yfinance as yf; stock = yf.Ticker("BMW3.DE")
In [2]: stock.get_shares()
Out[2]:
BasicShares
Year
2018 657600576
2019 658118053
2020 658862376
2021 659681430