8000 Prevent exception when running animation on Agg backend. by anntzer · Pull Request #13229 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content

Prevent exception when running animation on Agg backend. #13229

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
Jan 27, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions lib/matplotlib/animation.py
Original file line number Diff line number Diff line change
Expand Up @@ -1613,6 +1613,7 @@ def __init__(self, fig, func, frames=None, init_func=None, fargs=None,
else:
self._args = ()
self._func = func
self._init_func = init_func

# Amount of framedata to keep around for saving movies. This is only
# used if we don't know how many frames there will be: in the case
Expand Down Expand Up @@ -1644,7 +1645,7 @@ def __init__(self, fig, func, frames=None, init_func=None, fargs=None,
# As a workaround, convert save_count to a native python int.
self.save_count = int(self.save_count)

self._init_func = init_func
self._cache_frame_data = cache_frame_data

# Needs to be initialized so the draw functions work without checking
self._save_seq = []
Expand All @@ -1655,8 +1656,6 @@ def __init__(self, fig, func, frames=None, init_func=None, fargs=None,
# for a single frame from init, which is not what we want.
self._save_seq = []

self._cache_frame_data = cache_frame_data

def new_frame_seq(self):
# Use the generating function to generate a new frame sequence
return self._iter_gen()
Expand Down
0