yfinance icon indicating copy to clipboard operation
yfinance copied to clipboard

earnings not working properly

Open Timobaaij opened this issue 3 years ago • 4 comments

Just tried to call earnings dataframe for ticker: JAV2.F

The data is clearly on the Yahoo Finance website but the function returns an empty DF with the wrong columns.

image

image

Can you please tell me how to fix this? Anyone else experiencing this problem?

Timobaaij avatar Jan 29 '22 10:01 Timobaaij

BTW it is not a stand alone problem - there are more tickers where I experience this.

Timobaaij avatar Jan 29 '22 11:01 Timobaaij

I have had a quick look and it seems that utils.get_json('https://finance.yahoo.com/quote/JAV2.F/financials') queries yahoo finance and gets an html without any earning data in: _json.loads(json_str)['context']['dispatcher']['stores']['QuoteSummaryStore'] (utils.py line 108)

there might be more information in: _json.loads(json_str)['context']['dispatcher']['stores']['QuoteTimeSeriesStore']['timeSeries'] (utils.py line 112) but not exactly what you're looking for.

To sum up, the issue comes from the data fetched from yahoo instead of yfinance package.

ProgrammingDao avatar Jan 30 '22 13:01 ProgrammingDao

Yes, it is probably not there... the earnings function is not working but you can find the data in de financials function under "total revenue".

There are many issues reported for this I found! Thanks for the quick response and for looking into it!

Timobaaij avatar Jan 31 '22 10:01 Timobaaij

Correct financials are now available in pre-release version 0.2.0rc4.

ValueRaider avatar Dec 15 '22 16:12 ValueRaider