mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-12 10:16:17 +03:00
Merge branch 'master' into rm-2.7
This commit is contained in:
commit
40133cfc74
|
@ -13,6 +13,7 @@ environment:
|
||||||
TEST_OPTIONS:
|
TEST_OPTIONS:
|
||||||
DEPLOY: YES
|
DEPLOY: YES
|
||||||
matrix:
|
matrix:
|
||||||
|
- PYTHON: C:\Python38rc1-x64
|
||||||
- PYTHON: C:/Python37
|
- PYTHON: C:/Python37
|
||||||
- PYTHON: C:/Python37-x64
|
- PYTHON: C:/Python37-x64
|
||||||
- PYTHON: C:/Python36
|
- PYTHON: C:/Python36
|
||||||
|
@ -28,7 +29,6 @@ environment:
|
||||||
EXECUTABLE: bin/pypy.exe
|
EXECUTABLE: bin/pypy.exe
|
||||||
PIP_DIR: bin
|
PIP_DIR: bin
|
||||||
VENV: YES
|
VENV: YES
|
||||||
- PYTHON: C:\Python38rc1-x64
|
|
||||||
|
|
||||||
|
|
||||||
install:
|
install:
|
||||||
|
|
2
.github/FUNDING.yml
vendored
2
.github/FUNDING.yml
vendored
|
@ -1 +1 @@
|
||||||
tidelift: pypi/pillow
|
tidelift: "pypi/Pillow"
|
||||||
|
|
2
.github/workflows/macos-install.sh
vendored
2
.github/workflows/macos-install.sh
vendored
|
@ -2,8 +2,6 @@
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
sudo installer -pkg /Library/Developer/CommandLineTools/Packages/macOS_SDK_headers_for_macOS_10.14.pkg -target /
|
|
||||||
|
|
||||||
brew install libtiff libjpeg webp little-cms2
|
brew install libtiff libjpeg webp little-cms2
|
||||||
|
|
||||||
PYTHONOPTIMIZE=0 pip install cffi
|
PYTHONOPTIMIZE=0 pip install cffi
|
||||||
|
|
18
.github/workflows/test-windows.yml
vendored
18
.github/workflows/test-windows.yml
vendored
|
@ -58,6 +58,7 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
"%pythonLocation%\python.exe" -m pip install wheel pytest pytest-cov
|
"%pythonLocation%\python.exe" -m pip install wheel pytest pytest-cov
|
||||||
pip install codecov
|
pip install codecov
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Fetch dependencies
|
- name: Fetch dependencies
|
||||||
run: |
|
run: |
|
||||||
|
@ -96,6 +97,7 @@ jobs:
|
||||||
copy /Y /B j*.h %INCLIB%
|
copy /Y /B j*.h %INCLIB%
|
||||||
copy /Y /B *.lib %INCLIB%
|
copy /Y /B *.lib %INCLIB%
|
||||||
copy /Y /B *.exe %INCLIB%
|
copy /Y /B *.exe %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build dependencies / libjpeg-turbo
|
- name: Build dependencies / libjpeg-turbo
|
||||||
run: |
|
run: |
|
||||||
|
@ -114,6 +116,7 @@ jobs:
|
||||||
copy /Y /B jpeg-static.lib %INCLIB%\libjpeg.lib
|
copy /Y /B jpeg-static.lib %INCLIB%\libjpeg.lib
|
||||||
copy /Y /B cjpeg-static.exe %INCLIB%\cjpeg.exe
|
copy /Y /B cjpeg-static.exe %INCLIB%\cjpeg.exe
|
||||||
copy /Y /B djpeg-static.exe %INCLIB%\djpeg.exe
|
copy /Y /B djpeg-static.exe %INCLIB%\djpeg.exe
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build dependencies / zlib
|
- name: Build dependencies / zlib
|
||||||
run: |
|
run: |
|
||||||
|
@ -128,6 +131,7 @@ jobs:
|
||||||
copy /Y /B z*.h %INCLIB%
|
copy /Y /B z*.h %INCLIB%
|
||||||
copy /Y /B *.lib %INCLIB%
|
copy /Y /B *.lib %INCLIB%
|
||||||
copy /Y /B zlib.lib %INCLIB%\z.lib
|
copy /Y /B zlib.lib %INCLIB%\z.lib
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build dependencies / LibTIFF
|
- name: Build dependencies / LibTIFF
|
||||||
run: |
|
run: |
|
||||||
|
@ -143,6 +147,7 @@ jobs:
|
||||||
copy /Y /B libtiff\tiff*.h %INCLIB%
|
copy /Y /B libtiff\tiff*.h %INCLIB%
|
||||||
copy /Y /B libtiff\*.dll %INCLIB%
|
copy /Y /B libtiff\*.dll %INCLIB%
|
||||||
copy /Y /B libtiff\*.lib %INCLIB%
|
copy /Y /B libtiff\*.lib %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build dependencies / WebP
|
- name: Build dependencies / WebP
|
||||||
run: |
|
run: |
|
||||||
|
@ -157,6 +162,7 @@ jobs:
|
||||||
mkdir %INCLIB%\webp
|
mkdir %INCLIB%\webp
|
||||||
copy /Y /B src\webp\*.h %INCLIB%\webp
|
copy /Y /B src\webp\*.h %INCLIB%\webp
|
||||||
copy /Y /B output\release-static\${{ matrix.architecture }}\lib\* %INCLIB%
|
copy /Y /B output\release-static\${{ matrix.architecture }}\lib\* %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build dependencies / FreeType
|
- name: Build dependencies / FreeType
|
||||||
run: |
|
run: |
|
||||||
|
@ -176,6 +182,7 @@ jobs:
|
||||||
%MSBUILD% builds\windows\vc2010\freetype.sln /t:Build /p:Configuration="Release Static" /p:Platform=${{ matrix.platform-msbuild }} /m
|
%MSBUILD% builds\windows\vc2010\freetype.sln /t:Build /p:Configuration="Release Static" /p:Platform=${{ matrix.platform-msbuild }} /m
|
||||||
xcopy /Y /E /Q include %INCLIB%
|
xcopy /Y /E /Q include %INCLIB%
|
||||||
copy /Y /B "objs\${{ matrix.platform-msbuild }}\Release Static\freetype.lib" %INCLIB%
|
copy /Y /B "objs\${{ matrix.platform-msbuild }}\Release Static\freetype.lib" %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build dependencies / LCMS2
|
- name: Build dependencies / LCMS2
|
||||||
run: |
|
run: |
|
||||||
|
@ -193,6 +200,7 @@ jobs:
|
||||||
%MSBUILD% Projects\VC2015\lcms2.sln /t:Clean;lcms2_static /p:Configuration="Release" /p:Platform=${{ matrix.platform-msbuild }} /m
|
%MSBUILD% Projects\VC2015\lcms2.sln /t:Clean;lcms2_static /p:Configuration="Release" /p:Platform=${{ matrix.platform-msbuild }} /m
|
||||||
xcopy /Y /E /Q include %INCLIB%
|
xcopy /Y /E /Q include %INCLIB%
|
||||||
copy /Y /B Lib\MS\*.lib %INCLIB%
|
copy /Y /B Lib\MS\*.lib %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build dependencies / OpenJPEG
|
- name: Build dependencies / OpenJPEG
|
||||||
run: |
|
run: |
|
||||||
|
@ -211,6 +219,7 @@ jobs:
|
||||||
mkdir %INCLIB%\openjpeg-2.3.1
|
mkdir %INCLIB%\openjpeg-2.3.1
|
||||||
copy /Y /B src\lib\openjp2\*.h %INCLIB%\openjpeg-2.3.1
|
copy /Y /B src\lib\openjp2\*.h %INCLIB%\openjpeg-2.3.1
|
||||||
copy /Y /B bin\*.lib %INCLIB%
|
copy /Y /B bin\*.lib %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
# GPL licensed; skip if building wheels
|
# GPL licensed; skip if building wheels
|
||||||
- name: Build dependencies / libimagequant
|
- name: Build dependencies / libimagequant
|
||||||
|
@ -233,6 +242,7 @@ jobs:
|
||||||
nmake -nologo -f Makefile
|
nmake -nologo -f Makefile
|
||||||
copy /Y /B *.h %INCLIB%
|
copy /Y /B *.h %INCLIB%
|
||||||
copy /Y /B *.lib %INCLIB%
|
copy /Y /B *.lib %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
# for Raqm
|
# for Raqm
|
||||||
- name: Build dependencies / HarfBuzz
|
- name: Build dependencies / HarfBuzz
|
||||||
|
@ -253,6 +263,7 @@ jobs:
|
||||||
nmake -nologo -f Makefile harfbuzz
|
nmake -nologo -f Makefile harfbuzz
|
||||||
copy /Y /B src\*.h %INCLIB%
|
copy /Y /B src\*.h %INCLIB%
|
||||||
copy /Y /B *.lib %INCLIB%
|
copy /Y /B *.lib %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
# for Raqm
|
# for Raqm
|
||||||
- name: Build dependencies / FriBidi
|
- name: Build dependencies / FriBidi
|
||||||
|
@ -272,6 +283,7 @@ jobs:
|
||||||
nmake -nologo -f Makefile fribidi
|
nmake -nologo -f Makefile fribidi
|
||||||
copy /Y /B lib\*.h %INCLIB%
|
copy /Y /B lib\*.h %INCLIB%
|
||||||
copy /Y /B *.lib %INCLIB%
|
copy /Y /B *.lib %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
# failing with PyPy3
|
# failing with PyPy3
|
||||||
- name: Build dependencies / Raqm
|
- name: Build dependencies / Raqm
|
||||||
|
@ -293,6 +305,7 @@ jobs:
|
||||||
nmake -nologo -f Makefile libraqm
|
nmake -nologo -f Makefile libraqm
|
||||||
copy /Y /B src\*.h %INCLIB%
|
copy /Y /B src\*.h %INCLIB%
|
||||||
copy /Y /B libraqm.dll %INCLIB%
|
copy /Y /B libraqm.dll %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build dependencies / ghostscript
|
- name: Build dependencies / ghostscript
|
||||||
run: |
|
run: |
|
||||||
|
@ -308,6 +321,7 @@ jobs:
|
||||||
nmake -nologo -f psi\msvc.mak
|
nmake -nologo -f psi\msvc.mak
|
||||||
rem Add bin to PATH variable: Copy to INCLIB, then add INCLIB to PATH in Test step.
|
rem Add bin to PATH variable: Copy to INCLIB, then add INCLIB to PATH in Test step.
|
||||||
copy /Y /B bin\* %INCLIB%
|
copy /Y /B bin\* %INCLIB%
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build Pillow
|
- name: Build Pillow
|
||||||
run: |
|
run: |
|
||||||
|
@ -323,6 +337,7 @@ jobs:
|
||||||
rem Add GhostScript and Raqm binaries (copied to INCLIB) to PATH.
|
rem Add GhostScript and Raqm binaries (copied to INCLIB) to PATH.
|
||||||
path %INCLIB%;%PATH%
|
path %INCLIB%;%PATH%
|
||||||
%PYTHON%\python.exe selftest.py --installed
|
%PYTHON%\python.exe selftest.py --installed
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Test Pillow
|
- name: Test Pillow
|
||||||
run: |
|
run: |
|
||||||
|
@ -332,9 +347,11 @@ jobs:
|
||||||
path %INCLIB%;%PATH%
|
path %INCLIB%;%PATH%
|
||||||
cd /D %GITHUB_WORKSPACE%
|
cd /D %GITHUB_WORKSPACE%
|
||||||
%PYTHON%\python.exe -m pytest -vx --cov PIL --cov-report term --cov-report xml Tests
|
%PYTHON%\python.exe -m pytest -vx --cov PIL --cov-report term --cov-report xml Tests
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Upload coverage
|
- name: Upload coverage
|
||||||
run: 'codecov --file "%GITHUB_WORKSPACE%\coverage.xml" --name "%pythonLocation%"'
|
run: 'codecov --file "%GITHUB_WORKSPACE%\coverage.xml" --name "%pythonLocation%"'
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- name: Build wheel
|
- name: Build wheel
|
||||||
id: wheel
|
id: wheel
|
||||||
|
@ -351,6 +368,7 @@ jobs:
|
||||||
set INCLUDE=%INCLIB%;%GITHUB_WORKSPACE%\depends\tcl86\include;%INCLUDE%
|
set INCLUDE=%INCLIB%;%GITHUB_WORKSPACE%\depends\tcl86\include;%INCLUDE%
|
||||||
call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" ${{ matrix.platform-vcvars }} 8.1
|
call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" ${{ matrix.platform-vcvars }} 8.1
|
||||||
%PYTHON%\python.exe setup.py bdist_wheel
|
%PYTHON%\python.exe setup.py bdist_wheel
|
||||||
|
shell: cmd
|
||||||
|
|
||||||
- uses: actions/upload-artifact@v1
|
- uses: actions/upload-artifact@v1
|
||||||
if: "github.event_name == 'push' && !contains(matrix.python-version, 'pypy')"
|
if: "github.event_name == 'push' && !contains(matrix.python-version, 'pypy')"
|
||||||
|
|
|
@ -18,6 +18,9 @@ matrix:
|
||||||
env: LINT="true"
|
env: LINT="true"
|
||||||
- python: "pypy3"
|
- python: "pypy3"
|
||||||
name: "PyPy3 Xenial"
|
name: "PyPy3 Xenial"
|
||||||
|
- python: "3.8"
|
||||||
|
name: "3.8 Xenial"
|
||||||
|
services: xvfb
|
||||||
- python: '3.7'
|
- python: '3.7'
|
||||||
name: "3.7 Xenial"
|
name: "3.7 Xenial"
|
||||||
services: xvfb
|
services: xvfb
|
||||||
|
@ -29,9 +32,6 @@ matrix:
|
||||||
name: "3.5 Xenial PYTHONOPTIMIZE=2"
|
name: "3.5 Xenial PYTHONOPTIMIZE=2"
|
||||||
env: PYTHONOPTIMIZE=2
|
env: PYTHONOPTIMIZE=2
|
||||||
services: xvfb
|
services: xvfb
|
||||||
- python: "3.8-dev"
|
|
||||||
name: "3.8-dev Xenial"
|
|
||||||
services: xvfb
|
|
||||||
- env: DOCKER="alpine" DOCKER_TAG="master"
|
- env: DOCKER="alpine" DOCKER_TAG="master"
|
||||||
- env: DOCKER="arch" DOCKER_TAG="master" # contains PyQt5
|
- env: DOCKER="arch" DOCKER_TAG="master" # contains PyQt5
|
||||||
- env: DOCKER="ubuntu-16.04-xenial-amd64" DOCKER_TAG="master"
|
- env: DOCKER="ubuntu-16.04-xenial-amd64" DOCKER_TAG="master"
|
||||||
|
|
|
@ -3,5 +3,8 @@
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
coverage erase
|
coverage erase
|
||||||
|
if [ $(uname) == "Darwin" ]; then
|
||||||
|
export CPPFLAGS="-I/usr/local/miniconda/include";
|
||||||
|
fi
|
||||||
make clean
|
make clean
|
||||||
make install-coverage
|
make install-coverage
|
||||||
|
|
|
@ -20,11 +20,17 @@ Changelog (Pillow)
|
||||||
- Changed default frombuffer raw decoder args #1730
|
- Changed default frombuffer raw decoder args #1730
|
||||||
[radarhere]
|
[radarhere]
|
||||||
|
|
||||||
6.2.0 (2019-10-01)
|
6.2.1 (2019-10-21)
|
||||||
------------------
|
------------------
|
||||||
|
|
||||||
- This is the last Pillow release to support Python 2.7 #3642
|
- This is the last Pillow release to support Python 2.7 #3642
|
||||||
|
|
||||||
|
- Add support for Python 3.8 #4141
|
||||||
|
[hugovk]
|
||||||
|
|
||||||
|
6.2.0 (2019-10-01)
|
||||||
|
------------------
|
||||||
|
|
||||||
- Catch buffer overruns #4104
|
- Catch buffer overruns #4104
|
||||||
[radarhere]
|
[radarhere]
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@ Pillow is the friendly PIL fork by `Alex Clark and Contributors <https://github.
|
||||||
* - docs
|
* - docs
|
||||||
- |docs|
|
- |docs|
|
||||||
* - tests
|
* - tests
|
||||||
- |linux| |macos| |windows| |gha_lint| |gha_docker| |coverage|
|
- |linux| |macos| |windows| |gha_lint| |gha| |gha_windows| |gha_docker| |coverage|
|
||||||
* - package
|
* - package
|
||||||
- |zenodo| |tidelift| |version| |downloads|
|
- |zenodo| |tidelift| |version| |downloads|
|
||||||
* - social
|
* - social
|
||||||
|
@ -66,6 +66,12 @@ To report a security vulnerability, please follow the procedure described in the
|
||||||
.. |gha_docker| image:: https://github.com/python-pillow/Pillow/workflows/Test%20Docker/badge.svg
|
.. |gha_docker| image:: https://github.com/python-pillow/Pillow/workflows/Test%20Docker/badge.svg
|
||||||
:alt: GitHub Actions build status (Test Docker)
|
:alt: GitHub Actions build status (Test Docker)
|
||||||
|
|
||||||
|
.. |gha| image:: https://github.com/python-pillow/Pillow/workflows/Test/badge.svg
|
||||||
|
:alt: GitHub Actions build status (Test Linux and macOS)
|
||||||
|
|
||||||
|
.. |gha_windows| image:: https://github.com/python-pillow/Pillow/workflows/Test%20Windows/badge.svg
|
||||||
|
:alt: GitHub Actions build status (Test Windows)
|
||||||
|
|
||||||
.. |coverage| image:: https://codecov.io/gh/python-pillow/Pillow/branch/master/graph/badge.svg
|
.. |coverage| image:: https://codecov.io/gh/python-pillow/Pillow/branch/master/graph/badge.svg
|
||||||
:target: https://codecov.io/gh/python-pillow/Pillow
|
:target: https://codecov.io/gh/python-pillow/Pillow
|
||||||
:alt: Code coverage
|
:alt: Code coverage
|
||||||
|
|
|
@ -51,6 +51,7 @@ Released as needed for security, installation or critical bug fixes.
|
||||||
make sdist
|
make sdist
|
||||||
```
|
```
|
||||||
* [ ] Create [binary distributions](https://github.com/python-pillow/Pillow/blob/master/RELEASING.md#binary-distributions)
|
* [ ] Create [binary distributions](https://github.com/python-pillow/Pillow/blob/master/RELEASING.md#binary-distributions)
|
||||||
|
* [ ] Upload all binaries and source distributions e.g. `twine upload dist/Pillow-5.2.1*`
|
||||||
* [ ] Create a [new release on GitHub](https://github.com/python-pillow/Pillow/releases/new)
|
* [ ] Create a [new release on GitHub](https://github.com/python-pillow/Pillow/releases/new)
|
||||||
|
|
||||||
## Embargoed Release
|
## Embargoed Release
|
||||||
|
|
|
@ -51,29 +51,11 @@ def convert_to_comparable(a, b):
|
||||||
|
|
||||||
|
|
||||||
class PillowTestCase(unittest.TestCase):
|
class PillowTestCase(unittest.TestCase):
|
||||||
def __init__(self, *args, **kwargs):
|
|
||||||
unittest.TestCase.__init__(self, *args, **kwargs)
|
|
||||||
# holds last result object passed to run method:
|
|
||||||
self.currentResult = None
|
|
||||||
|
|
||||||
def run(self, result=None):
|
|
||||||
self.currentResult = result # remember result for use later
|
|
||||||
unittest.TestCase.run(self, result) # call superclass run method
|
|
||||||
|
|
||||||
def delete_tempfile(self, path):
|
def delete_tempfile(self, path):
|
||||||
try:
|
try:
|
||||||
ok = self.currentResult.wasSuccessful()
|
os.remove(path)
|
||||||
except AttributeError: # for pytest
|
except OSError:
|
||||||
ok = True
|
pass # report?
|
||||||
|
|
||||||
if ok:
|
|
||||||
# only clean out tempfiles if test passed
|
|
||||||
try:
|
|
||||||
os.remove(path)
|
|
||||||
except OSError:
|
|
||||||
pass # report?
|
|
||||||
else:
|
|
||||||
print("=== orphaned temp file: %s" % path)
|
|
||||||
|
|
||||||
def assert_deep_equal(self, a, b, msg=None):
|
def assert_deep_equal(self, a, b, msg=None):
|
||||||
try:
|
try:
|
||||||
|
|
|
@ -25,7 +25,7 @@ class PillowQtTestCase:
|
||||||
|
|
||||||
class PillowQPixmapTestCase(PillowQtTestCase):
|
class PillowQPixmapTestCase(PillowQtTestCase):
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
PillowQtTestCase.setUp(self)
|
super().setUp()
|
||||||
try:
|
try:
|
||||||
if ImageQt.qt_version == "5":
|
if ImageQt.qt_version == "5":
|
||||||
from PyQt5.QtGui import QGuiApplication
|
from PyQt5.QtGui import QGuiApplication
|
||||||
|
@ -37,7 +37,7 @@ class PillowQPixmapTestCase(PillowQtTestCase):
|
||||||
self.app = QGuiApplication([])
|
self.app = QGuiApplication([])
|
||||||
|
|
||||||
def tearDown(self):
|
def tearDown(self):
|
||||||
PillowQtTestCase.tearDown(self)
|
super().tearDown()
|
||||||
self.app.quit()
|
self.app.quit()
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -15,23 +15,25 @@ Notes
|
||||||
|
|
||||||
.. note:: Pillow is supported on the following Python versions
|
.. note:: Pillow is supported on the following Python versions
|
||||||
|
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|**Python** |**2.4**|**2.5**|**2.6**|**2.7**|**3.2**|**3.3**|**3.4**|**3.5**|**3.6**|**3.7**|
|
|**Python** |**2.4**|**2.5**|**2.6**|**2.7**|**3.2**|**3.3**|**3.4**|**3.5**|**3.6**|**3.7**|**3.8**|
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|Pillow < 2.0.0 | Yes | Yes | Yes | Yes | | | | | | |
|
|Pillow < 2 | Yes | Yes | Yes | Yes | | | | | | | |
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|Pillow 2.x - 3.x | | | Yes | Yes | Yes | Yes | Yes | Yes | | |
|
|Pillow 2 - 3 | | | Yes | Yes | Yes | Yes | Yes | Yes | | | |
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|Pillow 4.x | | | | Yes | | Yes | Yes | Yes | Yes | |
|
|Pillow 4 | | | | Yes | | Yes | Yes | Yes | Yes | | |
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|Pillow 5.0.x - 5.1.x | | | | Yes | | | Yes | Yes | Yes | |
|
|Pillow 5.0 - 5.1 | | | | Yes | | | Yes | Yes | Yes | | |
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|Pillow 5.2.x - 5.4.x | | | | Yes | | | Yes | Yes | Yes | Yes |
|
|Pillow 5.2 - 5.4 | | | | Yes | | | Yes | Yes | Yes | Yes | |
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|Pillow 6.x | | | | Yes | | | | Yes | Yes | Yes |
|
|Pillow 6.0 - 6.2.0 | | | | Yes | | | | Yes | Yes | Yes | |
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|Pillow >= 7.0.0 | | | | | | | | Yes | Yes | Yes |
|
|Pillow 6.2.1 | | | | Yes | | | | Yes | Yes | Yes | Yes |
|
||||||
+---------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|
|Pillow >= 7 | | | | | | | | Yes | Yes | Yes | Yes |
|
||||||
|
+-------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
|
||||||
|
|
||||||
Basic Installation
|
Basic Installation
|
||||||
------------------
|
------------------
|
||||||
|
@ -402,12 +404,12 @@ These platforms are built and tested for every change.
|
||||||
+----------------------------------+-------------------------------+-----------------------+
|
+----------------------------------+-------------------------------+-----------------------+
|
||||||
| Fedora 30 | 2.7, 3.7 |x86-64 |
|
| Fedora 30 | 2.7, 3.7 |x86-64 |
|
||||||
+----------------------------------+-------------------------------+-----------------------+
|
+----------------------------------+-------------------------------+-----------------------+
|
||||||
| macOS 10.13 High Sierra* | 2.7, 3.5, 3.6, 3.7 |x86-64 |
|
| macOS 10.13 High Sierra* | 2.7, 3.5, 3.6, 3.7, 3.8 |x86-64 |
|
||||||
+----------------------------------+-------------------------------+-----------------------+
|
+----------------------------------+-------------------------------+-----------------------+
|
||||||
| Ubuntu Linux 16.04 LTS | 2.7, 3.5, 3.6, 3.7, |x86-64 |
|
| Ubuntu Linux 16.04 LTS | 2.7, 3.5, 3.6, 3.7, 3.8, |x86-64 |
|
||||||
| | PyPy, PyPy3 | |
|
| | PyPy, PyPy3 | |
|
||||||
+----------------------------------+-------------------------------+-----------------------+
|
+----------------------------------+-------------------------------+-----------------------+
|
||||||
| Windows Server 2012 R2 | 2.7, 3.5, 3.6, 3.7 |x86, x86-64 |
|
| Windows Server 2012 R2 | 2.7, 3.5, 3.6, 3.7, 3.8 |x86, x86-64 |
|
||||||
| +-------------------------------+-----------------------+
|
| +-------------------------------+-----------------------+
|
||||||
| | PyPy, 3.7/MinGW |x86 |
|
| | PyPy, 3.7/MinGW |x86 |
|
||||||
+----------------------------------+-------------------------------+-----------------------+
|
+----------------------------------+-------------------------------+-----------------------+
|
||||||
|
|
|
@ -62,14 +62,6 @@ shared instance of ``Image.Exif``.
|
||||||
Deprecations
|
Deprecations
|
||||||
^^^^^^^^^^^^
|
^^^^^^^^^^^^
|
||||||
|
|
||||||
Python 2.7
|
|
||||||
~~~~~~~~~~
|
|
||||||
|
|
||||||
Python 2.7 reaches end-of-life on 2020-01-01.
|
|
||||||
|
|
||||||
Pillow 7.0.0 will be released on 2020-01-01 and will drop support for Python
|
|
||||||
2.7, making Pillow 6.2.x the last release series to support Python 2.
|
|
||||||
|
|
||||||
Image.frombuffer
|
Image.frombuffer
|
||||||
~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
|
26
docs/releasenotes/6.2.1.rst
Normal file
26
docs/releasenotes/6.2.1.rst
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
6.2.1
|
||||||
|
-----
|
||||||
|
|
||||||
|
API Changes
|
||||||
|
===========
|
||||||
|
|
||||||
|
Deprecations
|
||||||
|
^^^^^^^^^^^^
|
||||||
|
|
||||||
|
Python 2.7
|
||||||
|
~~~~~~~~~~
|
||||||
|
|
||||||
|
Python 2.7 reaches end-of-life on 2020-01-01.
|
||||||
|
|
||||||
|
Pillow 7.0.0 will be released on 2020-01-01 and will drop support for Python
|
||||||
|
2.7, making Pillow 6.2.x the last release series to support Python 2.
|
||||||
|
|
||||||
|
Other Changes
|
||||||
|
=============
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Support added for Python 3.8
|
||||||
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
Pillow 6.2.1 supports Python 3.8.
|
|
@ -6,6 +6,7 @@ Release Notes
|
||||||
.. toctree::
|
.. toctree::
|
||||||
:maxdepth: 2
|
:maxdepth: 2
|
||||||
|
|
||||||
|
6.2.1
|
||||||
6.2.0
|
6.2.0
|
||||||
6.1.0
|
6.1.0
|
||||||
6.0.0
|
6.0.0
|
||||||
|
|
3
setup.py
3
setup.py
|
@ -19,7 +19,7 @@ from distutils.command.build_ext import build_ext
|
||||||
|
|
||||||
from setuptools import Extension, setup
|
from setuptools import Extension, setup
|
||||||
|
|
||||||
if sys.platform == "win32" and sys.version_info >= (3, 8):
|
if sys.platform == "win32" and sys.version_info >= (3, 9):
|
||||||
warnings.warn(
|
warnings.warn(
|
||||||
"Pillow does not yet support Python {}.{} and does not yet provide "
|
"Pillow does not yet support Python {}.{} and does not yet provide "
|
||||||
"prebuilt Windows binaries. We do not recommend building from "
|
"prebuilt Windows binaries. We do not recommend building from "
|
||||||
|
@ -862,6 +862,7 @@ try:
|
||||||
"Programming Language :: Python :: 3.5",
|
"Programming Language :: Python :: 3.5",
|
||||||
"Programming Language :: Python :: 3.6",
|
"Programming Language :: Python :: 3.6",
|
||||||
"Programming Language :: Python :: 3.7",
|
"Programming Language :: Python :: 3.7",
|
||||||
|
"Programming Language :: Python :: 3.8",
|
||||||
"Programming Language :: Python :: 3 :: Only",
|
"Programming Language :: Python :: 3 :: Only",
|
||||||
"Programming Language :: Python :: Implementation :: CPython",
|
"Programming Language :: Python :: Implementation :: CPython",
|
||||||
"Programming Language :: Python :: Implementation :: PyPy",
|
"Programming Language :: Python :: Implementation :: PyPy",
|
||||||
|
|
|
@ -84,8 +84,7 @@ def bdf_char(f):
|
||||||
|
|
||||||
class BdfFontFile(FontFile.FontFile):
|
class BdfFontFile(FontFile.FontFile):
|
||||||
def __init__(self, fp):
|
def __init__(self, fp):
|
||||||
|
super().__init__()
|
||||||
FontFile.FontFile.__init__(self)
|
|
||||||
|
|
||||||
s = fp.readline()
|
s = fp.readline()
|
||||||
if s[:13] != b"STARTFONT 2.1":
|
if s[:13] != b"STARTFONT 2.1":
|
||||||
|
|
|
@ -78,7 +78,7 @@ class ImageFile(Image.Image):
|
||||||
"Base class for image file format handlers."
|
"Base class for image file format handlers."
|
||||||
|
|
||||||
def __init__(self, fp=None, filename=None):
|
def __init__(self, fp=None, filename=None):
|
||||||
Image.Image.__init__(self)
|
super().__init__()
|
||||||
|
|
||||||
self._min_frame = 0
|
self._min_frame = 0
|
||||||
|
|
||||||
|
|
|
@ -173,8 +173,7 @@ if qt_is_installed:
|
||||||
# buffer, so this buffer has to hang on for the life of the image.
|
# buffer, so this buffer has to hang on for the life of the image.
|
||||||
# Fixes https://github.com/python-pillow/Pillow/issues/1370
|
# Fixes https://github.com/python-pillow/Pillow/issues/1370
|
||||||
self.__data = im_data["data"]
|
self.__data = im_data["data"]
|
||||||
QImage.__init__(
|
super().__init__(
|
||||||
self,
|
|
||||||
self.__data,
|
self.__data,
|
||||||
im_data["im"].size[0],
|
im_data["im"].size[0],
|
||||||
im_data["im"].size[1],
|
im_data["im"].size[1],
|
||||||
|
|
|
@ -290,7 +290,7 @@ def _show(image, title):
|
||||||
self.image = BitmapImage(im, foreground="white", master=master)
|
self.image = BitmapImage(im, foreground="white", master=master)
|
||||||
else:
|
else:
|
||||||
self.image = PhotoImage(im, master=master)
|
self.image = PhotoImage(im, master=master)
|
||||||
tkinter.Label.__init__(self, master, image=self.image, bg="black", bd=0)
|
super().__init__(master, image=self.image, bg="black", bd=0)
|
||||||
|
|
||||||
if not tkinter._default_root:
|
if not tkinter._default_root:
|
||||||
raise OSError("tkinter not initialized")
|
raise OSError("tkinter not initialized")
|
||||||
|
|
|
@ -224,7 +224,7 @@ class ImageWindow(Window):
|
||||||
image = Dib(image)
|
image = Dib(image)
|
||||||
self.image = image
|
self.image = image
|
||||||
width, height = image.size
|
width, height = image.size
|
||||||
Window.__init__(self, title, width=width, height=height)
|
super().__init__(title, width=width, height=height)
|
||||||
|
|
||||||
def ui_handle_repair(self, dc, x0, y0, x1, y1):
|
def ui_handle_repair(self, dc, x0, y0, x1, y1):
|
||||||
self.image.draw(dc, (x0, y0, x1, y1))
|
self.image.draw(dc, (x0, y0, x1, y1))
|
||||||
|
|
|
@ -62,7 +62,7 @@ class PcfFontFile(FontFile.FontFile):
|
||||||
if magic != PCF_MAGIC:
|
if magic != PCF_MAGIC:
|
||||||
raise SyntaxError("not a PCF file")
|
raise SyntaxError("not a PCF file")
|
||||||
|
|
||||||
FontFile.FontFile.__init__(self)
|
super().__init__()
|
||||||
|
|
||||||
count = l32(fp.read(4))
|
count = l32(fp.read(4))
|
||||||
self.toc = {}
|
self.toc = {}
|
||||||
|
|
|
@ -292,8 +292,7 @@ class PngInfo:
|
||||||
|
|
||||||
class PngStream(ChunkStream):
|
class PngStream(ChunkStream):
|
||||||
def __init__(self, fp):
|
def __init__(self, fp):
|
||||||
|
super().__init__(fp)
|
||||||
ChunkStream.__init__(self, fp)
|
|
||||||
|
|
||||||
# local copies of Image attributes
|
# local copies of Image attributes
|
||||||
self.im_info = {}
|
self.im_info = {}
|
||||||
|
|
|
@ -54,7 +54,7 @@ class TarIO(ContainerIO.ContainerIO):
|
||||||
self.fh.seek((size + 511) & (~511), io.SEEK_CUR)
|
self.fh.seek((size + 511) & (~511), io.SEEK_CUR)
|
||||||
|
|
||||||
# Open region
|
# Open region
|
||||||
ContainerIO.ContainerIO.__init__(self, self.fh, self.fh.tell(), size)
|
super().__init__(self.fh, self.fh.tell(), size)
|
||||||
|
|
||||||
# Context manager support
|
# Context manager support
|
||||||
def __enter__(self):
|
def __enter__(self):
|
||||||
|
|
|
@ -884,7 +884,7 @@ class ImageFileDirectory_v1(ImageFileDirectory_v2):
|
||||||
"""
|
"""
|
||||||
|
|
||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
ImageFileDirectory_v2.__init__(self, *args, **kwargs)
|
super().__init__(*args, **kwargs)
|
||||||
self._legacy_api = True
|
self._legacy_api = True
|
||||||
|
|
||||||
tags = property(lambda self: self._tags_v1)
|
tags = property(lambda self: self._tags_v1)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user