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

FIX: deprecate qt4/5 rcparams#10351

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

Conversation

jklymak
Copy link
Member

PR Summary

#10282 deprecated rcparamsbackend.qt4 andbackend.qt5 but left the defaults active so the deprecation warning came on, even if the user did not have these rcparams in thematplotlibrc. This PR makes the defaultsNone, and adds a check forNone in the validator (that returns the old defaults). Hence the deprecation now only displays if these rcParams are still in thematplotlibrc.

PR Checklist

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

@jklymak
Copy link
MemberAuthor

Note thattutorials/introductory/usage.py is also now wrong.

# How do I select PyQt4 or PySide?

@jklymakjklymak added this to thev2.2 milestoneJan 30, 2018
@jklymakjklymak added the Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions. labelJan 30, 2018
@jklymak
Copy link
MemberAuthor

Milestoning as release critical if#10282 is going to stay in...

Copy link
Contributor

@anntzeranntzer left a comment

Choose a reason for hiding this comment

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

I think that's a much better way to do it indeed.

@efiring
Copy link
Member

Failures:

/home/travis/build/matplotlib/matplotlib/lib/matplotlib/rcsetup.py:274:10: E711 comparison to None should be 'if cond is None:'    if s == None:         ^/home/travis/build/matplotlib/matplotlib/lib/matplotlib/rcsetup.py:287:10: E711 comparison to None should be 'if cond is None:'    if s == None:         ^

@jklymakjklymakforce-pushed thefix-deprecate-qt45rcparams branch from047aa18 to17112e8CompareJanuary 30, 2018 21:10
@jklymak
Copy link
MemberAuthor

Sorry - shouldn't ask for reviews before I make sure the tests pass.

@jklymak
Copy link
MemberAuthor

@anntzer does this mean we can remove the somewhat complicated testing check? I left it in for now...

@anntzer
Copy link
Contributor

Probably the warnings suppression inmatplotlib/__init__ too.

@jklymak
Copy link
MemberAuthor

I didn't see what needs changing in__init__.py...

@jklymak
Copy link
MemberAuthor

I guess I wasn't saying we had to get rid of all the warning suppression. I don't quite understand what those two sections do. Feel free to push onto this PR, or open one and close thsi one.

@anntzer
Copy link
Contributor

Leaving them in is a bit redundant but not a critical problem I think.

@efiringefiring merged commit5a58d8d intomatplotlib:masterJan 31, 2018
@QuLogic
Copy link
Member

Isn't this still happening onthe Python 3.6 build? Sure is annoying when running pytest.

@jklymak
Copy link
MemberAuthor

I’m a little confused about pytest. Does it look at the local matplotlibrc? If so, if you still have that rcParams in your matplotlibrc you’ll get the warnings.

@QuLogic
Copy link
Member

Test setup callsrcdefaults, which re-applies all rcParams. I guess it takes the final result somehow instead ofNone.

@jklymak
Copy link
MemberAuthor

Ok well we should put the test logic back then I guess. I do t quite get why this is happening though.

@anntzer
Copy link
Contributor

Won't have much time to take care of this (or other prs) in the coming days. Will get back later, but if this is blocking a release feel free to revert the original deprecation (sorry for the sloppy patch).

@jklymakjklymak deleted the fix-deprecate-qt45rcparams branchFebruary 4, 2018 22:20
@jklymak
Copy link
MemberAuthor

OK,backend.qt4 andbackend.qt5 need to be added to_obsolete_set in__init__.py I think, though I'm a little confused about the differences between_obsolete_set and_deprecated_map.

@jklymakjklymak mentioned this pull requestFeb 4, 2018
6 tasks
@QuLogicQuLogic modified the milestones:needs sorting,v2.2.0Feb 12, 2018
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@efiringefiringefiring approved these changes

@anntzeranntzeranntzer 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
v2.2.0
Development

Successfully merging this pull request may close these issues.

4 participants
@jklymak@efiring@anntzer@QuLogic

[8]ページ先頭

©2009-2025 Movatter.jp