djokeur / merlinator

Playlist editor for the Merlin children loudspeaker from La Chouette Radio (Bayard / Radio France)
MIT License
56 stars 11 forks source link

AttributeError: module 'PIL.Image' has no attribute 'ANTIALIAS' when importing playlist.bin #10

Open Sahaathyva opened 3 days ago

Sahaathyva commented 3 days ago

Bonjour / hi !

Lorsque je tente d'importer playlist.bin il ne se passe rien, la console py me renvoie l'erreur AttributeError: module 'PIL.Image' has no attribute 'ANTIALIAS'

Après une petite recherche il semblerait que 'ANTIALIAS' ait été déprécié depuis Pillow v10.0 ,cf https://stackoverflow.com/questions/76616042/attributeerror-module-pil-image-has-no-attribute-antialias

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.

Quel est le script qui utilise ANTIALIAS , le main_gui.py ?

When I try to import playlist.bin, nothing happens, and the py console returns the error:

AttributeError: module 'PIL.Image' has no attribute 'ANTIALIAS'

After a little research, it seems that 'ANTIALIAS' has been deprecated since Pillow v10.0 (https://stackoverflow.com/questions/76616042/attributeerror-module-pil-image-has-no-attribute-antialias). Now you need to use PIL.Image.LANCZOS or PIL.Image.Resampling.LANCZOS.

Which script uses ANTIALIAS, main_gui.py?

Si je trouve du temps je tente de débuguer

Sahaathyva commented 3 days ago

It works i will push a PR with the patched script

Sahaathyva commented 3 days ago

i won't as it is already waiting :

https://github.com/djokeur/merlinator/pull/9