Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MNT]: Remove axis parameter from scales #29349

Open
timhoffm opened this issue Dec 19, 2024 · 0 comments
Open

[MNT]: Remove axis parameter from scales #29349

timhoffm opened this issue Dec 19, 2024 · 0 comments

Comments

@timhoffm
Copy link
Member

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:

  1. Make scale_factory work with scales have or have not an initial axis parameter. Either by try-except with/without this parameter or by introspecting the signature.
  2. Introspect scale classes passed to register_scale and warn if they still have the axis argument.
  3. Make all our scales work with/without the axis parameter by adding a suitable decorator to their init functions.

Otherwise, we can simplify the transition.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant