Just fix the following code:
|
def estimator_fn(estimator_params={}): # pylint: disable=dangerous-default-value |
|
from sklearn.linear_model import SGDRegressor |
|
|
|
return SGDRegressor(random_state=42, **estimator_params) |
to:
def estimator_fn(estimator_params=None):
from sklearn.linear_model import SGDRegressor
return SGDRegressor(random_state=42, **(estimator_params or {}))
{} is mutable and should not use as a default value for a function argument.
Just fix the following code:
mlflow/tests/pipelines/test_train_step.py
Lines 137 to 140 in fa96efe
to:
{}is mutable and should not use as a default value for a function argument.