Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

DOC: fix deprecation warnings in examples#23867

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
oscargus merged 1 commit intomatplotlib:mainfromStefRe:DOC/depr_examples
Sep 11, 2022

Conversation

StefRe
Copy link
Contributor

PR Summary

  • The dist attribute was deprecated in Matplotlib 3.6 and will be removed two minor releases later.
  • Passing the loc parameter ofinit() positionally is deprecated since Matplotlib 3.6; the parameter will become keyword-only two minor releases later.
  • Passing the radius parameter ofinit() positionally is deprecated since Matplotlib 3.6; the parameter will become keyword-only two minor releases later.
  • Passing the closed parameter ofinit() positionally is deprecated since Matplotlib 3.6; the parameter will become keyword-only two minor releases later.
  • Auto-removal of grids by pcolor() and pcolormesh() is deprecated since 3.5 and will be removed two minor releases later; please call grid(False) first.

(#23855 was for the tutorials, this is for the examples, sorry - I didn't notice it first that there were deprecations in the examples too)

PR Checklist

Tests and Styling

  • [N/A] Has pytest style unit tests (andpytest passes).
  • IsFlake 8 compliant (installflake8-docstrings and runflake8 --docstring-convention=all).

Documentation

  • [N/A] New features are documented, with examples if plot related.
  • [N/A] New features have an entry indoc/users/next_whats_new/ (follow instructions in README.rst there).
  • [N/A] API changes documented indoc/api/next_api_changes/ (follow instructions in README.rst there).
  • Documentation is sphinx and numpydoc compliant (the docs shouldbuild without error).

- The dist attribute was deprecated in Matplotlib 3.6 and will be  removed two minor releases later.- Passing the loc parameter of __init__() positionally is deprecated  since Matplotlib 3.6; the parameter will become keyword-only two  minor releases later.- Passing the radius parameter of __init__() positionally is deprecated  since Matplotlib 3.6; the parameter will become keyword-only two  minor releases later.- Passing the closed parameter of __init__() positionally is deprecated  since Matplotlib 3.6; the parameter will become keyword-only two  minor releases later.- Auto-removal of grids by pcolor() and pcolormesh() is deprecated  since 3.5 and will be removed two minor releases later; please call  grid(False) first.
@StefReStefRe changed the titleDOC: fix deprecations in examplesDOC: fix deprecation warnings in examplesSep 11, 2022
@oscargus
Copy link
Member

Thanks!

Do you have any input on the related issue#23866 ? That is, did you somehow enable the deprecation warnings or did you use a more manual approach?

@oscargusoscargus added this to thev3.6.0 milestoneSep 11, 2022
@StefRe
Copy link
ContributorAuthor

Actually I came across this by chance: I was checking in which tutorials and examples the output needs to be captured (for#23796 (comment)). To do so I "grepped" the rst file created by sphinx gallery for.. rst-class:: sphx-glr-script-out. This yielded the deprecation warnings too :). So yes - it's a manual process.

@StefRe
Copy link
ContributorAuthor

judging by

# Unless we catch the warning explicitly somewhere, a warning should cause the
# docs build to fail. This is especially useful for getting rid of deprecated
# usage in the gallery.
warnings.filterwarnings('error',append=True)

warnings should make the docs build fail, but they don't do so for some reason. Maybe this is due to theappend=True if sphinx gallery also controls warnings with the defaultappend value ofFalse? (I didn't check this, just a guess)

@oscargus
Copy link
Member

OK!

I have added a step that will at least list examples and tutorials with deprecation warnings in#23868 so that will help a bit.

Thanks for sorting this out!

StefRe reacted with thumbs up emoji

@oscargusoscargus merged commit06660ef intomatplotlib:mainSep 11, 2022
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull requestSep 11, 2022
oscargus added a commit that referenced this pull requestSep 11, 2022
…867-on-v3.6.xBackport PR#23867 on branch v3.6.x (DOC: fix deprecation warnings in examples)
@StefReStefRe deleted the DOC/depr_examples branchSeptember 11, 2022 15:02
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@oscargusoscargusoscargus approved these changes

Assignees
No one assigned
Projects
None yet
Milestone
v3.6.0
Development

Successfully merging this pull request may close these issues.

2 participants
@StefRe@oscargus

[8]ページ先頭

©2009-2025 Movatter.jp