-
-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Closed
Labels
Milestone
Description
Summary
For historic reasons, Scales take the axis as the first parameter. It's use is discouraged and none of our own scales actually use it at least since #12831.
To simplify our code, we should get rid of that parameter.
Proposed fix
Do we know whether
- downstream libraries add their own Scales via
register_scale()? - user will directly instantiate our own Scale classes?
If so we need the full deprecation machinery:
- Make
scale_factorywork with scales have or have not an initialaxisparameter. Either by try-except with/without this parameter or by introspecting the signature. - Introspect scale classes passed to
register_scaleand warn if they still have the axis argument. - Make all our scales work with/without the
axisparameter by adding a suitable decorator to their init functions. - Refactoring: Removing axis parameter from scales #29988
Otherwise, we can simplify the transition.
--
Edit: Both questions are yes, so we need the full deprecation mechanism.