Search code examples
pythondatabricksfacebook-prophet

Unable to install facebook prophet library in Databricks using Python


I installed the facebook prophet on Databricks and it was working fine till yesterday. I installed it using the following commands:

%pip install pystan==2.19.1.1
%pip install fbprophet

However, it is not working now. It gives me the following error:

Command 'pip install fbprophet' returned non-zero exit status 1.
python setup.py bdist_wheel did not run successfully
TypeError: object.__init__() takes exactly one argument (the instance to initialize)

Any thoughts?


Solution

  • I've had the exact same issue! it's been driving me nuts all day...

    I've just found out theres an issue with the version of holidays, and this needs to be reverted to 0.23

    Found existing installation: holidays 0.25

    If you install holidays first it should install fbprophet without issue, the same is also true for prophet.

    %pip install holidays==0.23
    %pip install pystan==2.19.1.1 fbprophet
    

    or if you need to uninstall holidays

    pip uninstall holidays -y
    

    then

    pip install holidays==0.23
    

    I hope this works for you