Skip to content

Don't hide exceptions in FontManager.addfont. #15937

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
Dec 17, 2019

Conversation

anntzer
Copy link
Contributor

@anntzer anntzer commented Dec 14, 2019

We only need to hide them when constructing the default fontManager
instance (because we don't want a single bad font in the system to
prevent Matplotlib from importing, but if the end user manually calls
addfont, errors should not pass silently).

Release critical as addfont is a new API in 3.2 (#15068).

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

@anntzer anntzer added Release critical For bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions. topic: text/fonts labels Dec 14, 2019
@anntzer anntzer added this to the v3.2.0 milestone Dec 14, 2019
Copy link
Member

@timhoffm timhoffm left a comment

Choose a reason for hiding this comment

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

Modulo some wording.

We only need to hide them when constructing the default fontManager
instance (because we don't want a single bad font in the system to
prevent Matplotlib from importing, but if the end user manually calls
addfont, errors should not pass silently).

Release critical as addfont is a new API in 3.2.
@tacaswell tacaswell merged commit 621f298 into matplotlib:master Dec 17, 2019
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Dec 17, 2019
@anntzer anntzer deleted the addfont-exception branch December 17, 2019 17:54
timhoffm added a commit that referenced this pull request Dec 17, 2019
…937-on-v3.2.x

Backport PR #15937 on branch v3.2.x (Don't hide exceptions in FontManager.addfont.)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Release critical For bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions. topic: text/fonts
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants