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

Appearance settings

FIX: reset to original DPI in getstate #23476

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 1 commit into from
Jul 22, 2022

Conversation

tacaswell
Copy link
Member

PR Summary

There is a bit of extra caution in extracting the original DPI
just in case there is a canvas class that does something very funny
and the _orignial_dpi attribute does not get set (it is set to the Figure
instance in the CanvasBase init, not in the Figure init).

closes #23471

PR Checklist

Tests and Styling

  • Has pytest style unit tests (and pytest passes).
  • Is Flake 8 compliant (install flake8-docstrings and run flake8 --docstring-convention=all).

There is a bit of extra caution in extracting the original DPI
just in case there is a canvas class that does something very funny
and the `_orignial_dpi` attribute does not get set (it is set to the `Figure`
instance in the `CanvasBase` init, not in the `Figure` init).

closes matplotlib#23471
@tacaswell tacaswell added this to the v3.5.3 milestone Jul 22, 2022
@QuLogic QuLogic merged commit 3301248 into matplotlib:main Jul 22, 2022
@lumberbot-app
Copy link

lumberbot-app bot commented Jul 22, 2022

Owee, I'm MrMeeseeks, Look at me.

There seem to be a conflict, please backport manually. Here are approximate instructions:

  1. Checkout backport branch and update it.
git checkout v3.5.x
git pull
  1. Cherry pick the first parent branch of the this PR on top of the older branch:
git cherry-pick -x -m1 330124862b46dc003ff3e38427efcc9000b9d7ab
  1. You will likely have some merge/cherry-pick conflict here, fix them and commit:
git commit -am 'Backport PR #23476: FIX: reset to original DPI in getstate'
  1. Push to a named branch:
git push YOURFORK v3.5.x:auto-backport-of-pr-23476-on-v3.5.x
  1. Create a PR against branch v3.5.x, I would have named this PR:

"Backport PR #23476 on branch v3.5.x (FIX: reset to original DPI in getstate)"

And apply the correct labels and milestones.

Congratulations — you did some good work! Hopefully your backport PR will be tested by the continuous integration and merged soon!

Remember to remove the Still Needs Manual Backport label once the PR gets merged.

If these instructions are inaccurate, feel free to suggest an improvement.

@tacaswell tacaswell deleted the fix/unpickle_dpi branch July 22, 2022 21:42
tacaswell pushed a commit to tacaswell/matplotlib that referenced this pull request Jul 22, 2022
Merge pull request matplotlib#23476 from tacaswell/fix/unpickle_dpi

FIX: reset to original DPI in getstate
(cherry picked from commit 3301248)
QuLogic added a commit that referenced this pull request Jul 22, 2022
…-v3.5.x

Backport PR #23476: FIX: reset to original DPI in getstate
@greglucas greglucas mentioned this pull request Jun 16, 2023
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: DPI of a figure is doubled after unpickling on M1 Mac
3 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.