vroland / epdiy

EPDiy is a driver board for affordable e-Paper (or E-ink) displays.
https://vroland.github.io/epdiy-hardware/
GNU Lesser General Public License v3.0
1.25k stars 178 forks source link

Fix imageconvert #271

Closed martinberlin closed 5 months ago

martinberlin commented 6 months ago

Running: python imgconvert.py is returning an error

Because it seems ANTIALIAS is not anymore a valid attribute in Pillow python module.

Traceback (most recent call last): File "/home/martin/Documents/github/epdiy/scripts/imgconvert.py", line 20, in im.thumbnail((args.max_width, args.max_height), Image.ANTIALIAS) AttributeError: module 'PIL.Image' has no attribute 'ANTIALIAS'

Proposed solution found here:

ANTIALIAS was removed in Pillow 10.0.0 (after being deprecated through many previous versions). Now you need to use PIL.Image.LANCZOS or PIL.Image.Resampling.LANCZOS.

martinberlin commented 5 months ago

Hello @vroland Can you please review this one line update? Then we can merge so the new developers trying the image convert do not get this error. Thanks!