Fix APNG info after seeking backwards more than twice by esoma · Pull Request #7701 · python-pillow/Pillow

@esoma

@esoma

…g to the first frame multiple times.

@hugovk

Please could you add a test for this?

@radarhere radarhere changed the title (7700) Fix info for first frame of apng images getting clobbered when seeking to the first frame multiple times. Fix info for first frame of apng images getting clobbered when seeking to the first frame multiple times

Jan 7, 2024

@esoma

…o the first frame multiple times.

@esoma

@hugovk
Added the test and checked it against main to ensure it produces the issue. If ya'll have any preferences on the naming of the test or if you want a full explanation of the issue in the test just let me know.

I'm guessing the codecov failure is because the github actions aren't approved to run and the appveyor builds don't emit coverage in the src directory.

@radarhere

I approved the GitHub Actions run and CodeCov is no longer failing.

hugovk

Comment on lines +694 to +696

def test_apng_issue_7700():
# https://github.com/python-pillow/Pillow/issues/7700
with Image.open("Tests/images/apng/issue_7700.png") as im:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please could you give the test and image more descriptive names than issue_7700?

@esoma

@esoma

@esoma

Is an occasional segfault in testing a known issue? I'm guessing the reason for the failing action is not related to this PR.

@nulano

Someone has triggered it to re-run so I can't see which job failed, but yes, the PyPy jobs occasionally segfault while collecting tests.

@radarhere

radarhere

@radarhere radarhere changed the title Fix info for first frame of apng images getting clobbered when seeking to the first frame multiple times Fix PNG info after seeking backwards more than twice

Jan 9, 2024

@radarhere radarhere changed the title Fix PNG info after seeking backwards more than twice Fix APNG info after seeking backwards more than twice

Jan 9, 2024

@esoma @radarhere

Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>

radarhere

hugovk

@radarhere radarhere added the Bug

Any unexpected behavior, until confirmed feature.

label

Jan 10, 2024

@esoma

@hugovk