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

Revert #23417 (Consistently set label on axis with units)#25278

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 7 commits intomatplotlib:mainfromksunden:revert_23417
Feb 22, 2023

Conversation

ksunden
Copy link
Member

@ksundenksunden commentedFeb 21, 2023
edited
Loading

  • Revert "Fix logic line break"
  • Revert "Improve unit axis label test"
  • Revert "Make have_units_and_converter private"
  • Revert "Update units_rectangle baseline image"
  • Revert "Fix unit info setting axis label"
  • Revert "Add test for axis label when units set"

PR Summary

PR#23417 caused problems for downstream libraries which provide unit converters.

The most prominent example is pandas, as discussed in depth in#25219 (edit: fixed linked discussion issue).
While there are other solutions that solve the narrow case, it was determined there that the pragmatic answer was to revert and sort out the details as a follow up.

PR Checklist

Documentation and Tests

  • Has pytest style unit tests (andpytest passes)
  • Documentation is sphinx and numpydoc compliant (the docs shouldbuild without error).
  • New plotting related features are documented with examples.

Release Notes

  • New features are marked with a.. versionadded:: directive in the docstring and documented indoc/users/next_whats_new/
  • API changes are marked with a.. versionchanged:: directive in the docstring and documented indoc/api/next_api_changes/
  • Release notes conform with instructions innext_whats_new/README.rst ornext_api_changes/README.rst

dstansby
dstansby previously requested changesFeb 21, 2023
Copy link
Member

@dstansbydstansby left a comment

Choose a reason for hiding this comment

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

Happy to revert (sorry for breaking!), but I think at the same time we should put in a test that breaks before this PR was reverted, and passes afterwards, so we don't accidentally break things in the future.

@dstansbydstansby dismissed theirstale reviewFebruary 21, 2023 22:33

Don't have time to review the test now, but I'll remove my change request, thanks for adding a test!

@ksunden
Copy link
MemberAuthor

Test added, it is a little bit apocryphal, as I don't really expect such things to be done with built in converters, but rather than introducing test-only subclasses, it still gets at the mechanism that I think is at the heart of the issue in#25219, that if a valid converter is applied to anAxis, it should not get overridden when further changes (such as xlim) are applied to the axes (which otherwise work with that converter), which is what was happening to Pandas' converters (though with the more drastic change to string categoricals as their date converters accept strings, which ours do not).

@ksundenksunden added this to thev3.7.1 milestoneFeb 22, 2023
@tacaswelltacaswell merged commiteeef80f intomatplotlib:mainFeb 22, 2023
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull requestFeb 22, 2023
ksunden added a commit that referenced this pull requestFeb 23, 2023
…278-on-v3.7.xBackport PR#25278 on branch v3.7.x (Revert#23417 (Consistently set label on axis with units))
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@tacaswelltacaswelltacaswell approved these changes

@jklymakjklymakjklymak approved these changes

@dstansbydstansbydstansby left review comments

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
v3.7.1
Development

Successfully merging this pull request may close these issues.

4 participants
@ksunden@tacaswell@jklymak@dstansby

[8]ページ先頭

©2009-2025 Movatter.jp