ellmetha / django-machina

A Django forum engine for building powerful community driven websites.
https://django-machina.readthedocs.org
BSD 3-Clause "New" or "Revised" License
589 stars 126 forks source link

module 'PIL.Image' has no attribute 'ANTIALIAS' with dependency pillow >= 10.0.0 #308

Closed barsch closed 11 months ago

barsch commented 11 months ago

Image.ANTIALIAS has been removed in Pillow 10.0.0 and needs to replaced with Image.LANCZOS or Image.Resampling.LANCZOS

see https://pillow.readthedocs.io/en/stable/releasenotes/10.0.0.html#constants

It is currently used here: https://github.com/ellmetha/django-machina/blob/6586d2608bbffc31911ea6f9a15c570580116238/machina/models/fields.py#L266

Alsaheem commented 11 months ago

Hi @barsch were you able to find a way around this ?

Alsaheem commented 11 months ago

For now , the following works Uninstall pillow 10.0.1 pip uninstall Pillow

Install Pillow 9.5.0 pip install Pillow==9.5.0

BoPeng commented 11 months ago

@ellmetha Could you please merge https://github.com/ellmetha/django-machina/pull/311 and create a new minor release of django-machina?

ellmetha commented 11 months ago

The new 1.3.1 minor release is available. Thanks for the PR @BoPeng!