Closed Rapid1898-code closed 1 year ago
@Rapid1898-code If you maintain this software for clients, you should really know how to read Python. yf.Ticker.info
triggers a fetch that ultimately fails to decrypt.
Hello - i don´t understand what is wrong with checking if there is some result with:
if data.info == None:
Is this in any way wrong handling?
And why is it outputting an error with "yfinance failed to decrypt Yahoo data response"?
info
isn't a variable. It's a property function, see the source code.
It behaves like a variable, and to initialise it requires decrypting data returned by Yahoo. That is failing, clearly. #1407
So to correct way is to allways use a try and except logic when accessing data from info. Do i understand this correct?
No. If decryption is failing, go outside for a walk because there's nothing you can do.
Hello - i still not get it - I have the situation that i read several tickers - ticker by ticker (eg. 100 tickers) And sometimes as described i get this error after 10 tickers or so.
But with a workaround it seems to work - So i make a try and except and when i get this exception i wait for eg. 5 seconds and then try it again. Most of the time after this 5 seconds access to info works fine.
So it seems for me that there is something i can do. (or it would be a very short walk...)
Interesting, I thought decryption had 100% broken for everyone. Certainly has for me. But it's ultimately your decision what to do when yfinance
can't decrypt Yahoo's data.
so you mean generally there is sometimes no way to get data from yfinance you think?
Read #1407
Hello - when i run the folklowing code:
I get (earlier or later) the following error message -
Why is that - and why is it happening in the line with this statement:
if data.info == None:
Is there anything i can do for preventing such errors?