lit26 / finvizfinance

Finviz analysis python library.

Home Page:https://finvizfinance.readthedocs.io/en/latest/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

QST: Hello Li - I'm getting an error 'An error occurred: 'NoneType' object has no attribute 'findAll' when running the script below. Is there an update to the library that can help me fix it please?

kahlijah opened this issue · comments

Question about finvizfinance

#High level stock data
try:
foverview = Overview()
filters_dict = {'Country':'USA'}
foverview.set_filter(filters_dict=filters_dict)
df = foverview.screener_view()
df=df.rename(columns = {'Ticker\n\n':'Ticker'})
df['P/E'] = df['P/E'].apply(pd.to_numeric,errors='coerce')
df=df.rename(columns = {'Ticker':'symbol'})
except Exception as e:
print(f"An error occurred: {e}")

I think you are using the older version. The latest version is 0.14.7. Can you check the version of the package? The latest bs4 switch findAll to find_all. The package also update this.

Thank you very much as always, Tianning!! Much appreciated!