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

Deprecate rcParams["datapath"] in favor of mpl.get_data_path().#16722

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
tacaswell merged 4 commits intomatplotlib:v3.2.xfromanntzer:deprecate-rcdatapath-32
Mar 17, 2020

Conversation

anntzer
Copy link
Contributor

The rcParam cannot be meaningfully set by the end user from their
matplotlibrc or Python code.

(This is a manual backport to 3.2.x of#16417; see discussion there.)

PR Summary

PR Checklist

  • Has Pytest style unit tests
  • Code isFlake 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

The rcParam cannot be meaningfully set by the end user from theirmatplotlibrc or Python code.(This is a manual backport to 3.2.x.)
@anntzeranntzer added the Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions. labelMar 10, 2020
@anntzeranntzer added this to thev3.2.1 milestoneMar 10, 2020
@anntzer
Copy link
ContributorAuthor

@tacaswell I don't think this will help if the user directly assigns to rcParams["datapath"]?

@tacaswell
Copy link
Member

It will not, but I thought the OP was loading it from a file? The other option is to add a flag tosuppress checking the rcParams so it works no matter what.

@anntzer
Copy link
ContributorAuthor

OK, I guess your solution works for that case...

Copy link
Member

@QuLogicQuLogic left a comment

Choose a reason for hiding this comment

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

AFAICT, this correctly raises the deprecation warning and sets the path, but I have a couple questions.

Closesmatplotlib#16678This does a bit of jiggery-pokery to respect the datapath set inthe users matplotlibrc.   This is going to have an expediteddeprecation cycle as we don't think end-users should be setting thisrcparam.
@tacaswelltacaswellforce-pushed thedeprecate-rcdatapath-32 branch from5f62526 toecd95c4CompareMarch 16, 2020 22:28
Co-Authored-By: Elliott Sales de Andrade <quantum.analyst@gmail.com>
@tacaswell
Copy link
Member

So this fixes the thing we broke for the OP but does not fully restore the functionality.

I am 👍 on this being good enough, but open to the argument we should fully restore the rcparam functionality.

@anntzer
Copy link
ContributorAuthor

@tacaswell's patch looks fine to me.

Copy link
Member

@tacaswelltacaswell left a comment

Choose a reason for hiding this comment

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

despite my having written a bunch of this.

@tacaswelltacaswell merged commit4897c4d intomatplotlib:v3.2.xMar 17, 2020
@anntzeranntzer deleted the deprecate-rcdatapath-32 branchMarch 17, 2020 19:00
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@tacaswelltacaswelltacaswell approved these changes

@QuLogicQuLogicQuLogic approved these changes

Assignees
No one assigned
Labels
Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions.
Projects
None yet
Milestone
v3.2.1
Development

Successfully merging this pull request may close these issues.

3 participants
@anntzer@tacaswell@QuLogic

[8]ページ先頭

©2009-2025 Movatter.jp