Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
ChangeLog
---------

0.2.3
~~~~~

Release date: 2023/11/28

- Fix the compatibility issue with Flask ``3.x``.


0.2.2
~~~~~

Expand Down
6 changes: 3 additions & 3 deletions flask_avatars/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@

from uuid import uuid4

import PIL
from PIL import Image
from flask import current_app, Blueprint, url_for, Markup
from flask import current_app, Blueprint, url_for
from markupsafe import Markup
from .identicon import Identicon # noqa


Expand Down Expand Up @@ -283,7 +283,7 @@ def resize_avatar(self, img, base_width):
"""
w_percent = (base_width / float(img.size[0]))
h_size = int((float(img.size[1]) * float(w_percent)))
img = img.resize((base_width, h_size), PIL.Image.ANTIALIAS)
img = img.resize((base_width, h_size), Image.BICUBIC)
return img

def save_avatar(self, image):
Expand Down
16 changes: 7 additions & 9 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@

setup(
name='Flask-Avatars',
version='0.2.2',
version='0.2.3',
description='All avatar generators in one place.',
url='https://github.com/greyli/flask-avatars',
url='https://github.com/helloflask/flask-avatars',
license='MIT',
author='Grey Li',
author_email='withlihui@gmail.com',
Expand All @@ -44,14 +44,12 @@
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3 :: Only',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
]
Expand Down