[ERROR] seahub.avatar.templatetags.avatar_tags:62 avatar unsupported resampling filter

New installation of Server for generic Linux 6.2.4 64bit
In the profile, an error occurs when the avatar is added and the avatar is not added.
In the message log …/logs/seahub.log:
2018-01-22 09:03:39,550 [ERROR] seahub.avatar.templatetags.avatar_tags:62 avatar unsupported resampling filter

In the message log …/logs/seahub_django_request.log:
2018-01-22 09:03:28,570 [ERROR] django.request:256 handle_uncaught_exception Internal Server Error: /avatar/add/
Traceback (most recent call last):
File “/cloud/seafile-server-6.2.4/seahub/thirdpart/Django-1.8.18-py2.7.egg/django/core/handlers/base.py”, line 132, in get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File “/cloud/seafile-server-6.2.4/seahub/seahub/auth/decorators.py”, line 27, in _wrapped_view
return view_func(request, *args, **kwargs)
File “/cloud/seafile-server-6.2.4/seahub/seahub/avatar/views.py”, line 76, in add
avatar.avatar.save(image_file.name, image_file)
File “/cloud/seafile-server-6.2.4/seahub/thirdpart/Django-1.8.18-py2.7.egg/django/db/models/fields/files.py”, line 111, in save
self.instance.save()
File “/cloud/seafile-server-6.2.4/seahub/seahub/avatar/models.py”, line 151, in save
super(Avatar, self).save(*args, **kwargs)
File “/cloud/seafile-server-6.2.4/seahub/thirdpart/Django-1.8.18-py2.7.egg/django/db/models/base.py”, line 734, in save
force_update=force_update, update_fields=update_fields)
File “/cloud/seafile-server-6.2.4/seahub/thirdpart/Django-1.8.18-py2.7.egg/django/db/models/base.py”, line 771, in save_base
update_fields=update_fields, raw=raw, using=using)
File “/cloud/seafile-server-6.2.4/seahub/thirdpart/Django-1.8.18-py2.7.egg/django/dispatch/dispatcher.py”, line 189, in send
response = receiver(signal=self, sender=sender, **named)
File “/cloud/seafile-server-6.2.4/seahub/seahub/avatar/models.py”, line 174, in create_default_thumbnails
instance.create_thumbnail(size)
File “/cloud/seafile-server-6.2.4/seahub/seahub/avatar/models.py”, line 105, in create_thumbnail
image = image.resize((size, size), AVATAR_RESIZE_METHOD)
File “/usr/lib64/python2.7/site-packages/PIL/Image.py”, line 1338, in resize
raise ValueError(“unsupported resampling filter”)
ValueError: unsupported resampling filter

After selecting the image and pressing the Add button, the browser goes to the blank page https://My_domain/avatar/add/

What kind of pillow version you have?

pip 9.0.1 from /usr/lib/python2.7/site-packages (python 2.7)

That’s pip version I need pillow

pip list | grep "Pillow"
1 Like

DEPRECATION: The default format will switch to columns in the future. You can use --format=(legacy|columns) (or define a format=(legacy|columns) in your pip.conf under the [list] section) to disable this warning.
Pillow (5.0.0)

Can you try to install 4.3.0 version?

pip uninstall pillow
pip install pillow==4.3.0

This should work. And don’t forgot restart Seafile server and Seahub

1 Like

Pillow 5 does not work?
The Software should support default package versions of a system if it’s listed as supported/tested.
Otherwise there should be information about what version to use in the official manual. How are users supposed to know this otherwise?

pip doesn’t care about system. It just installed latest version, it’s not like classic Linux repositories. And I don’t know just trying PIL/image.py Is part of pillow and he has installed newer major version (4.x vs 5.x). And 4.3.0 working

Installing the correct version of Pillow has helped :blush:
But still had to reboot the server.

What does that mean? You mean you had to restart seahub and server too? Or what?

1 Like

Restarting the seahub did not help.
I had to restart the server completely.

It’s weird cause Pillow is Seahub dependecy, but it can be. Sometimes is better restart whole seafile :wink:

Thank you very much for your help :slight_smile:
Now I will configure it to work with LDAP.

They should really update those files regularly. It’s very annoying to have to fix these kind of things ever time the system has updates or we install a Seafile server upgrade.

for DerDanilo:
Friend, if you want guarantees, then use the PRO version.
Using free for my own purposes, I’m ready for some difficulties and lack of some functionality.
Despite this, the project developer team is very responsible and responsive people. They always help us.

@Tietatter, DerDanilo is one of most active people in community which trying to help people, provide more information and help to developers with finding Bugs(and helping them solve).

And I’m using Seafile CE since it was published, now have two servers with CE and one PRO and I can say you there’s no difference if we talking about information. Look at manual, Deployment for PRO saying, “install like CE and run this script”. So there are no information about dependecy versions in manual but in source are :slight_smile:

I’m work as developer so I don’t have problem look for it a research but if I don’t and use PRO this will be pain in a** for me :slight_smile:

2 Likes

No one did not want to offend :flushed:
But it seemed to me that DerDanilo rigidly commented on the work of the Seafile team :confused:

I know and I understand DerDanilo frustration. Cause we are trying to put some actual information together, but devs don’t want or don’t have time to collaborate with us. For example I did some pull-request into WebApi documentation in september 2017 and it still isn’t merged or published. So DerDanilo go and create comunity documentation. We know that it’s hard to create soft like this, but if there are people which are trying to help and are ignored it’s sad. A lot of informations aren’t said somewhere and we have to find out how to fix it for help people like you now. This Pillow dependency is for example my experience and it’s not written somewhere in doc. There are a lot of undocumented WebApi calls.

EDIT: OK stop messing this thread. Please mark my answer as solution, I will edit it to restart whole seafile server.

3 Likes