Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
FIX: do not replace the Axes._children list object#24677
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
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Each Artist keeps a reference to `Axes._children.remove` as`art._remove_method`. If we replace the `_children` instance on the Axes witha different list instance the Artists will not be updated and their removemethod will refer to the wrong list. This will cause subsequent failures onthe next draw because on remove we reset the `art.axes` and `art.figure` toNone.xrefhttps://discourse.matplotlib.org/t/host-subplot-and-artist-remove/23374
Owee, I'm MrMeeseeks, Look at me. There seem to be a conflict, please backport manually. Here are approximate instructions:
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 If these instructions are inaccurate, feel free tosuggest an improvement. |
…list objectManual backport due to conflicts, which were just additional tests inmain frommatplotlib#23861, so simply removed these.
Backport PR#24677 on branch v3.6.x (FIX: do not replace the Axes._children list object)
PR Summary
Each Artist keeps a reference to
Axes._children.remove
asart._remove_method
. If we replace the_children
instance on the Axes with a different list instance the Artists will not be updated and their remove method will refer to the wrong list. This will cause subsequent failures on the next draw because on remove we reset theart.axes
andart.figure
to None.xrefhttps://discourse.matplotlib.org/t/host-subplot-and-artist-remove/23374
PR Checklist
Documentation and Tests
pytest
passes)