Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Deprecate checkdep_ps_distiller. #14046

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

Merged
merged 1 commit into from
May 25, 2019

Conversation

anntzer
Copy link
Contributor

@anntzer anntzer commented Apr 26, 2019

We may as well move it to the corresponding rc validator and always
validate when assigning to that rcParam, not just at import time.

PR Summary

PR Checklist

  • Has Pytest style unit tests
  • Code is Flake 8 compliant
  • New features are documented, with examples if plot related
  • Documentation is sphinx and numpydoc compliant
  • Added an entry to doc/users/next_whats_new/ if major new feature (follow instructions in README.rst there)
  • Documented in doc/api/api_changes.rst if API changed in a backward-incompatible way

We may as well move it to the corresponding rc validator and always
validate when assigning to that rcParam, not just at import time.
@anntzer anntzer added this to the v3.2.0 milestone Apr 26, 2019
@@ -534,11 +537,22 @@ def update_savefig_format(value):
def validate_ps_distiller(s):
if isinstance(s, str):
s = s.lower()
if s in ('none', None):
if s in ('none', None, 'false', False):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(these values are treated the same)

Deprecations
````````````

``matplotlib.checkdep_ps_distiller`` is deprecated.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is it deprecated? Is it useless, or is there an alternative to use instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is useless and undocumented.
Well of course you could be trying to use this to figure out whether a ps distiller that happens to match the ones that matplotlib supports is installed. In which case they can now just try to assign to rcParams["ps.usedistiller"] and see whether the setter complains. But frankly I just don't think it's a realistic use case and adding this to the changelog is essentially noise, I would say.

@efiring efiring merged commit e2bec3f into matplotlib:master May 25, 2019
@anntzer anntzer deleted the checkdep_ps_distiller branch May 26, 2019 05:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants