[BUG]: Allow Custom Logger Configuration to Handle Prophet Dependency Warning #3957
Open
3 tasks done
Labels
bug
Something isn't working
pycaret version checks
I have checked that this issue has not already been reported here.
I have confirmed this bug exists on the latest version of pycaret.
I have confirmed this bug exists on the master branch of pycaret (pip install -U git+https://github.com/pycaret/pycaret.git@master).
Issue Description
Time Series setup allows the passing of a logger object to be passed, and all pycaret messages would be routed to that logger. However just importing the TSForecastingExperiment creates either warning or info messages about the dependancy on prophet and as it as at import time, it is not routed to the logger. This prevents me from creating my own logger to catch and handle the message in the way I want.
This can be problematic in scenarios where we want to control how warnings are logged and displayed, especially in production environments where we might want to suppress certain warnings or redirect them to specific logging channels.
Reproducible Example
Expected Behavior
I expect no logs and no logging file (logs.log) to be created
Actual Results
Installed Versions
PyCaret required dependencies:
pip: 24.0
setuptools: 69.2.0
pycaret: 3.3.0
IPython: 8.23.0
ipywidgets: 8.1.2
tqdm: 4.66.2
numpy: 1.26.4
pandas: 2.1.4
jinja2: 3.1.3
scipy: 1.11.4
joblib: 1.3.2
sklearn: 1.4.1.post1
pyod: 1.1.3
imblearn: 0.12.2
category_encoders: 2.6.3
lightgbm: 4.3.0
numba: 0.59.1
requests: 2.31.0
matplotlib: 3.7.5
scikitplot: 0.3.7
yellowbrick: 1.5
plotly: 5.20.0
plotly-resampler: Not installed
kaleido: 0.2.1
schemdraw: 0.15
statsmodels: 0.14.1
sktime: 0.26.0
tbats: 1.1.3
pmdarima: 2.0.4
psutil: 5.9.8
markupsafe: 2.1.5
pickle5: Not installed
cloudpickle: 3.0.0
deprecation: 2.1.0
xxhash: 3.4.1
wurlitzer: 3.0.3
PyCaret optional dependencies:
shap: Not installed
interpret: Not installed
umap: Not installed
ydata_profiling: Not installed
explainerdashboard: Not installed
autoviz: Not installed
fairlearn: Not installed
deepchecks: Not installed
xgboost: Not installed
catboost: Not installed
kmodes: Not installed
mlxtend: Not installed
statsforecast: Not installed
tune_sklearn: Not installed
ray: Not installed
hyperopt: Not installed
optuna: Not installed
skopt: Not installed
mlflow: Not installed
gradio: Not installed
fastapi: Not installed
uvicorn: Not installed
m2cgen: Not installed
evidently: Not installed
fugue: Not installed
streamlit: Not installed
prophet: Not installed
The text was updated successfully, but these errors were encountered: