JECSand / yahoofinancials

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.
https://pypi.python.org/pypi/yahoofinancials
MIT License
899 stars 214 forks source link

ImportError: cannot import name 'YahooFinancials' #38

Closed pinkylynn closed 4 years ago

pinkylynn commented 4 years ago

I have been importing values from YahooFinancials via from yahoofinancials import YahooFinancials. Up until today, when this error showed up - ImportError: cannot import name 'YahooFinancials'. Not sure if there's any updates being done on the backend thats causing this error? Thanks!

JECSand commented 4 years ago

Hi pinkylynn,

Given the potential severity of this reported issue, I went ahead and tried to replicate it on a fresh install and was unable to do so.

Can you attempt to reinstall using pip? Also what version of python are you using?

Lastly can anyone else confirm this is an issue?

Thanks!

JECSand commented 4 years ago

Closing this issue now since it has been over a month since I've heard from OP in addition to me not being been able to replicate the reported issue.

Crispiro commented 4 years ago

I'll just add my 2 pence for anyone else who came across this. I had this issue, upon numerous installations using either pip or python -m, I then realised I had named my project file yahoofinancials.py as well.

Upon changing my project file's name to something less dumb than the name of the library i was learning to use, I had no error importing the module. So make sure your .py file name is unique and unlikely to cause issues.

Thank you, JECSand for this library - keep up the good work.