From d6055440d57c1cf075fd188504678190f5ba8540 Mon Sep 17 00:00:00 2001 From: Hugo Date: Sun, 13 Jan 2019 21:55:07 +0200 Subject: [PATCH] Drop support for EOL Python 3.4 --- .appveyor.yml | 2 -- .travis.yml | 3 --- Tests/test_image_access.py | 6 ++---- docs/installation.rst | 10 ++++++---- mp_compile.py | 6 +++--- setup.py | 7 +++---- tox.ini | 2 +- winbuild/config.py | 19 ------------------- 8 files changed, 15 insertions(+), 40 deletions(-) diff --git a/.appveyor.yml b/.appveyor.yml index da8c1708b..0cf10597a 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -25,8 +25,6 @@ environment: - PYTHON: C:/Python36-x64 - PYTHON: C:/Python35 - PYTHON: C:/Python35-x64 - - PYTHON: C:/Python34 - - PYTHON: C:/Python34-x64 - PYTHON: C:/msys64/mingw32 EXECUTABLE: bin/python3 PIP_DIR: bin diff --git a/.travis.yml b/.travis.yml index b0fcea755..85bb87862 100644 --- a/.travis.yml +++ b/.travis.yml @@ -47,9 +47,6 @@ matrix: name: "3.5 Trusty PYTHONOPTIMIZE=2" dist: trusty env: PYTHONOPTIMIZE=2 - - python: '3.4' - name: "3.4 Trusty" - dist: trusty - env: DOCKER="alpine" DOCKER_TAG="master" - env: DOCKER="arch" DOCKER_TAG="master" # contains PyQt5 - env: DOCKER="ubuntu-trusty-x86" DOCKER_TAG="master" diff --git a/Tests/test_image_access.py b/Tests/test_image_access.py index 481ec5935..7384c685d 100644 --- a/Tests/test_image_access.py +++ b/Tests/test_image_access.py @@ -310,10 +310,8 @@ class TestCffi(AccessTest): class TestEmbeddable(unittest.TestCase): @unittest.skipIf(not sys.platform.startswith('win32') or - sys.version_info[:2] == (3, 4) or - on_appveyor(), # failing on appveyor when run from - # subprocess, not from shell - "requires Python 2.7 or >=3.5 for Windows") + on_appveyor(), + "Failing on AppVeyor when run from subprocess, not from shell") def test_embeddable(self): import subprocess import ctypes diff --git a/docs/installation.rst b/docs/installation.rst index 8cfb8af57..93d017a8c 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -26,7 +26,9 @@ Notes +--------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+ |Pillow 5.0.x - 5.1.x| | | | Yes | | | Yes | Yes | Yes | | +--------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+ -|Pillow >= 5.2.0 | | | | Yes | | | Yes | Yes | Yes | Yes | +|Pillow 5.2.x - 5.5.x| | | | Yes | | | Yes | Yes | Yes | Yes | ++--------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+ +|Pillow >= 6.0.0 | | | | Yes | | | | Yes | Yes | Yes | +--------------------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+ Basic Installation @@ -394,16 +396,16 @@ These platforms are built and tested for every change. +----------------------------------+-------------------------------+-----------------------+ | Fedora 29 | 2.7 |x86-64 | +----------------------------------+-------------------------------+-----------------------+ -| Mac OS X 10.10 Yosemite* | 2.7, 3.4, 3.5, 3.6, 3.7 |x86-64 | +| Mac OS X 10.10 Yosemite* | 2.7, 3.5, 3.6, 3.7 |x86-64 | +----------------------------------+-------------------------------+-----------------------+ | Ubuntu Linux 16.04 LTS | 2.7, 3.5, 3.6, 3.7, |x86-64 | | | PyPy, PyPy3 | | +----------------------------------+-------------------------------+-----------------------+ -| Ubuntu Linux 14.04 LTS | 2.7, 3.4, 3.5, 3.6 |x86-64 | +| Ubuntu Linux 14.04 LTS | 2.7, 3.5, 3.6 |x86-64 | | +-------------------------------+-----------------------+ | | 2.7 |x86 | +----------------------------------+-------------------------------+-----------------------+ -| Windows Server 2012 R2 | 2.7, 3.4, 3.5, 3.6, 3.7 |x86, x86-64 | +| Windows Server 2012 R2 | 2.7, 3.5, 3.6, 3.7 |x86, x86-64 | | +-------------------------------+-----------------------+ | | PyPy, 3.7/MinGW |x86 | +----------------------------------+-------------------------------+-----------------------+ diff --git a/mp_compile.py b/mp_compile.py index 2d5287d77..f50210ba5 100644 --- a/mp_compile.py +++ b/mp_compile.py @@ -1,6 +1,6 @@ # A monkey patch of the base distutils.ccompiler to use parallel builds # Tested on 2.7, looks to be identical to 3.3. -# Only applied on Python < 3.5 because otherwise, it conflicts with Python's +# Only applied on Python 2.7 because otherwise, it conflicts with Python's # own newly-added support for parallel builds. from __future__ import print_function @@ -79,6 +79,6 @@ def install(): "%s processes" % MAX_PROCS) -# We monkeypatch only versions earlier than 3.5 -if sys.version_info < (3, 5): +# We monkeypatch Python 2.7 +if sys.version_info.major < 3: install() diff --git a/setup.py b/setup.py index 806c9b46b..5d8159a12 100755 --- a/setup.py +++ b/setup.py @@ -265,8 +265,8 @@ class pil_build_ext(build_ext): if self.debug: global DEBUG DEBUG = True - if sys.version_info >= (3, 5) and not self.parallel: - # For Python < 3.5, we monkeypatch distutils to have parallel + if sys.version_info.major >= 3 and not self.parallel: + # For Python 2.7, we monkeypatch distutils to have parallel # builds. If --parallel (or -j) wasn't specified, we want to # reproduce the same behavior as before, that is, auto-detect the # number of jobs. @@ -774,14 +774,13 @@ try: "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy", ], - python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*", + python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*", cmdclass={"build_ext": pil_build_ext}, ext_modules=[Extension("PIL._imaging", ["_imaging.c"])], include_package_data=True, diff --git a/tox.ini b/tox.ini index 3ae11eea0..0baa44f87 100644 --- a/tox.ini +++ b/tox.ini @@ -4,7 +4,7 @@ # and then run "tox" from this directory. [tox] -envlist = py27, py34, py35, py36, py37 +envlist = py27, py35, py36, py37 [testenv] commands = diff --git a/winbuild/config.py b/winbuild/config.py index 380cb718f..da6f7855b 100644 --- a/winbuild/config.py +++ b/winbuild/config.py @@ -5,7 +5,6 @@ PILLOW_DEPENDS_DIR = 'C:\\pillow-depends\\' pythons = {'27': {'compiler': 7, 'vc': 2008}, 'pypy2': {'compiler': 7, 'vc': 2008}, - '34': {'compiler': 7.1, 'vc': 2010}, '35': {'compiler': 7.1, 'vc': 2015}, '36': {'compiler': 7.1, 'vc': 2015}, '37': {'compiler': 7.1, 'vc': 2015}} @@ -104,24 +103,6 @@ compilers = { } }, 7.1: { - 2010: { - 64: { - 'env_version': 'v7.1', - 'vc_version': '2010', - 'env_flags': '/x64 /vista', - 'inc_dir': 'msvcr10-x64', - 'platform': 'x64', - 'webp_platform': 'x64', - }, - 32: { - 'env_version': 'v7.1', - 'vc_version': '2010', - 'env_flags': '/x86 /vista', - 'inc_dir': 'msvcr10-x32', - 'platform': 'Win32', - 'webp_platform': 'x86', - } - }, 2015: { 64: { 'env_version': 'v7.1',