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

Skip to content

FIX: don't fail on first show if animation already exhausted #17810

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
Aug 6, 2021

Conversation

tacaswell
Copy link
Member

PR Summary

If _init_draw() fails, assume the animation is dead, but do not fail.

closes #17770

I am not sure this is actually the best fix. On one hand, this is elides the problem, but does so by ignoring the problem. There is some poor interaction going on here between the ways access the data sources and how we try to "peek" at the first frame if we are not passed an init function.

PR Checklist

  • Has Pytest style unit tests
  • Code is Flake 8 compliant

@tacaswell tacaswell added this to the v3.4.0 milestone Jul 1, 2020
@QuLogic QuLogic modified the milestones: v3.4.0, v3.5.0 Jan 22, 2021
@tacaswell tacaswell force-pushed the fix_exhausted_animations branch from 65d1a19 to 288d438 Compare August 5, 2021 18:46
@tacaswell tacaswell marked this pull request as ready for review August 5, 2021 18:46
If we need to get the first frame in `_init_draw()` (because the user did not
pass an initialization function) fails, warn instead of raising.

closes matplotlib#17770
@tacaswell tacaswell force-pushed the fix_exhausted_animations branch from 288d438 to 5471db1 Compare August 6, 2021 16:27
@QuLogic QuLogic merged commit 9a7329c into matplotlib:master Aug 6, 2021
@tacaswell tacaswell deleted the fix_exhausted_animations branch August 6, 2021 23:21
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.

animation.save and fig.savefig interfere with each other and raise StopIteration
5 participants