Skip to content

Remove 3.7-deprecated fontconfig api#27574

Closed
bawejahritik wants to merge 8 commits into
matplotlib:mainfrom
bawejahritik:my-feature
Closed

Remove 3.7-deprecated fontconfig api#27574
bawejahritik wants to merge 8 commits into
matplotlib:mainfrom
bawejahritik:my-feature

Conversation

@bawejahritik

@bawejahritik bawejahritik commented Dec 27, 2023

Copy link
Copy Markdown

PR summary

Removal of old and unused API that were marked as deprecated in 3.7 of Matplotlib and the corresponding test.
(issue #26865)

PR checklist

@dstansby dstansby left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks for the PR - I've left a request to update the test intsead of removing it. Otherwise looks 👍



def test_fontconfig_unknown_constant():
with pytest.warns(DeprecationWarning):

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Instead of deleting this test, could you change the warning check to an error check? That way we can make sure the error is raised as expected.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

For sure, I'll do that!

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I've added the test, please check

@dstansby dstansby left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks great! Could whoever merges this do a squash merge?

Comment thread lib/matplotlib/_fontconfig_pattern.py Outdated
@@ -1,7 +1,7 @@
import pytest

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Since pytest is a third party library, it was above the matplotlib import following the PEP8 style guide so ideally it should stay there.

@QuLogic QuLogic changed the title Remove 3.7-deprecated api Remove 3.7-deprecated fontconfig api Jan 3, 2024

@anntzer anntzer left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The correct fix is at #26884.

@ksunden

ksunden commented Jan 8, 2024

Copy link
Copy Markdown
Member

@bawejahritik Thanks for your interest, however we have merged the older pull request that included changes from related comments for this deprecation.

We hope to hear from you again!

@ksunden ksunden closed this Jan 8, 2024
@melissawm melissawm moved this from Waiting for author to Done in First Time Contributors Mar 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Development

Successfully merging this pull request may close these issues.

6 participants