You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems to be that gif animations cannot be generated anymore because of empty list for ax_fig.lines[0].get_xdata().
Currently, I got the following error in the CI run.
UNEXPECTED EXCEPTION: IndexError('list index out of range')
Traceback (most recent call last):
File "/home/runner/work/useful-math-functions/useful-math-functions/.venv/lib/python3.10/site-packages/matplotlib/animation.py", line 224, in saving
yield self
File "/home/runner/work/useful-math-functions/useful-math-functions/.venv/lib/python3.10/site-packages/matplotlib/animation.py", line 1126, in save
writer.grab_frame(**savefig_kwargs)
File "/home/runner/work/useful-math-functions/useful-math-functions/.venv/lib/python3.10/site-packages/matplotlib/animation.py", line 499, in grab_frame
self._frame.append(im)
AttributeError: 'PillowWriter' object has no attribute '_frame'. Did you mean: '_frames'?
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/runner/.local/share/uv/python/cpython-3.10.16-linux-x86_64-gnu/lib/python3.10/doctest.py", line 1350, in __run
exec(compile(example.source, filename, "single",
File "<doctest umf.images.diagrams.ClassicPlot[30]>", line 1, in <module>
File "/home/runner/work/useful-math-functions/useful-math-functions/umf/images/diagrams.py", line 335, in plot_save_gif
anim.save(filename=fname, writer="imagemagick", dpi=settings.dpi, **kwargs)
File "/home/runner/work/useful-math-functions/useful-math-functions/.venv/lib/python3.10/site-packages/matplotlib/animation.py", line 1098, in save
with (writer.saving(self._fig, filename, dpi),
File "/home/runner/.local/share/uv/python/cpython-3.10.16-linux-x86_64-gnu/lib/python3.10/contextlib.py", line 153, in __exit__
self.gen.throw(typ, value, traceback)
File "/home/runner/work/useful-math-functions/useful-math-functions/.venv/lib/python3.10/site-packages/matplotlib/animation.py", line 226, in saving
self.finish()
File "/home/runner/work/useful-math-functions/useful-math-functions/.venv/lib/python3.10/site-packages/matplotlib/animation.py", line 506, in finish
self._frames[0].save(
IndexError: list index out of range
/home/runner/work/useful-math-functions/useful-math-functions/umf/images/diagrams.py:73: UnexpectedException
Bug summary
It seems to be that
gif
animations cannot be generated anymore because of empty list forax_fig.lines[0].get_xdata()
.Currently, I got the following error in the CI run.
See also:
https://github.com/matplotlib/matplotlib/blob/f39bf4d2585746fce3ba39decba62693c82f194e/lib/matplotlib/animation.py#L499C21-L499C35
Code for reproduction
Actual outcome
Expected outcome
Working like previously Anselmoo/useful-math-functions#71
So, I have tested both backend
poetry
anduv
, but it seems both are not working.Additional information
If
_frame
is changed to_frames
in local.venv
, it is working fine.Operating system
No response
Matplotlib Version
Matplotlib Backend
No response
Python version
No response
Jupyter version
No response
Installation
pip
The text was updated successfully, but these errors were encountered: