pmorissette / ffn

ffn - a financial function library for Python
pmorissette.github.io/ffn
MIT License
1.87k stars 282 forks source link

Removing Deprecated and Erroring Pandas_Datareader #237

Closed Gamrix closed 1 month ago

Gamrix commented 1 month ago

Describe the bug pandas_datareader throws an error because it depends on the distutils package that was removed in Python 3.12, and is otherwise deprecated.

I am happy to contribute a patch to remove pandas_datareader from the dependencies list, and update the repo to use the yfinance calls directly. I just want a go-ahead before doing the work. The repo already uses yfinance.pdr_override to patch out the function if the dependency is not there, but the file data.py still import pandas_datareader before calling that and therefore causing the crash.

To Reproduce

  1. Have a virtual Environment with Python 3.12 or higher
  2. import fft

Expected behavior No errors in Python

Desktop (please complete the following information):

timkpaine commented 1 month ago

Sounds good to me, thanks!