diff --git a/mesa/visualization/UserParam.py b/mesa/visualization/UserParam.py index a7290d8017f..3e391e7ad44 100644 --- a/mesa/visualization/UserParam.py +++ b/mesa/visualization/UserParam.py @@ -1,4 +1,6 @@ from numbers import Number +from warnings import warn + NUMBER = "number" CHECKBOX = "checkbox" @@ -65,6 +67,13 @@ def __init__( choices=None, description=None, ): + + warn( + "UserSettableParameter is deprecated in favor of UserParam objects " + "such as Slider, Checkbox, Choice, StaticText, NumberInput. " + "See the examples folder for how to use them. " + "UserSettableParameter will be removed in the next major release." + ) if choices is None: choices = list() if param_type not in self.TYPES: diff --git a/tests/test_usersettableparam.py b/tests/test_usersettableparam.py index d576803c43e..6dc52774438 100644 --- a/tests/test_usersettableparam.py +++ b/tests/test_usersettableparam.py @@ -5,7 +5,7 @@ Checkbox, Choice, StaticText, - NumberInput + NumberInput, )