A powerful financial data module used for pulling data from Yahoo Finance. This module can pull fundamental and technical data for stocks, indexes, currencies, cryptos, ETFs, Mutual Funds, U.S. Treasuries, and commodity futures.
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 595, in get_financial_stmts
data = self._run_financial_stmt(statement_type, report_num, reformat)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 585, in _run_financial_stmt
raw_data = self.get_stock_data(statement_type, report_name=report_name)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 476, in get_stock_data
dict_ent = self._create_dict_ent(self.ticker, statement_type, tech_type, report_name, hist_obj)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 402, in _create_dict_ent
re_data = self._scrape_data(YAHOO_URL, tech_type, statement_type)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 167, in _scrape_data
stores = data["context"]["dispatcher"]["stores"]["QuoteSummaryStore"]
TypeError: string indices must be integers
Hi, I use this more than a year. Until now everything worked fine, though, since some days I have troubles ---even on the examples given:
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 595, in get_financial_stmts data = self._run_financial_stmt(statement_type, report_num, reformat) File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 585, in _run_financial_stmt raw_data = self.get_stock_data(statement_type, report_name=report_name) File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 476, in get_stock_data dict_ent = self._create_dict_ent(self.ticker, statement_type, tech_type, report_name, hist_obj) File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 402, in _create_dict_ent re_data = self._scrape_data(YAHOO_URL, tech_type, statement_type) File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/yahoofinancials/init.py", line 167, in _scrape_data stores = data["context"]["dispatcher"]["stores"]["QuoteSummaryStore"] TypeError: string indices must be integers