Thanks to visit codestin.com
Credit goes to github.com

Skip to content

FIX: re-order unit conversion and mask array coercion #19876

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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 7, 2021

Conversation

tacaswell
Copy link
Member

PR Summary

Fix for #19871 but still needs tests.

I am hesitant to register the pandas converters because the test should still be useful to us even if pandas changes to returning arrays and because making sure we de-register the pandas handlers on failure is a bit fiddly.

This probably also fixes some latent bugs where the safe_masked_invalid was up-converting to an array too soon.

PR Checklist

  • Has pytest style unit tests (and pytest passes).
  • Is Flake 8 compliant (run flake8 on changed files to check).
  • Conforms to Matplotlib style conventions (install flake8-docstrings and run flake8 --docstring-convention=all).

@tacaswell tacaswell added this to the v3.4.2 milestone Apr 6, 2021
@dstansby
Copy link
Member

dstansby commented Apr 7, 2021

Would it be sensible to ask pandas to add a test for this too (with their converters)?

Copy link
Member

@jklymak jklymak left a comment

Choose a reason for hiding this comment

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

This seems fine. I don't know that we should be obliged to test panda's converters, and frankly I think their converters are obsoleted by recent improvements in the matplotlib datetime code. But if this change fixes them for now, thats great.

@tacaswell
Copy link
Member Author

sorry, Elliott and I talked about how to test this yesterday and then I did not get to it yet.

@tacaswell tacaswell marked this pull request as ready for review May 6, 2021 22:32
@tacaswell tacaswell force-pushed the fix_pandas_pcolor_regression branch from 4b1b9d8 to 0618a81 Compare May 6, 2021 23:06
@tacaswell tacaswell force-pushed the fix_pandas_pcolor_regression branch from 0618a81 to 4f23d61 Compare May 6, 2021 23:15
@QuLogic QuLogic merged commit a71c8ae into matplotlib:master May 7, 2021
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request May 7, 2021
QuLogic added a commit that referenced this pull request May 7, 2021
…876-on-v3.4.x

Backport PR #19876 on branch v3.4.x (FIX: re-order unit conversion and mask array coercion)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants