From e53d97f4ed045138daa5e6229cc566f5dc745a29 Mon Sep 17 00:00:00 2001 From: Jon Crall Date: Thu, 1 Aug 2024 13:55:55 -0400 Subject: [PATCH] Drop support for Python 3.6 and 3.7 (#161) --- .circleci/config.yml | 32 ----------------- .github/workflows/tests.yml | 38 ++++---------------- CHANGELOG.md | 4 +++ README.rst | 2 +- appveyor.yml | 71 ------------------------------------- pyproject.toml | 4 +-- requirements/jupyter.txt | 20 +++-------- requirements/optional.txt | 2 +- requirements/tests.txt | 7 ++-- setup.py | 30 ++++++++++------ 10 files changed, 41 insertions(+), 169 deletions(-) delete mode 100644 appveyor.yml mode change 100755 => 100644 setup.py diff --git a/.circleci/config.yml b/.circleci/config.yml index 436d47df..6f808451 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -38,12 +38,6 @@ workflows: - test_full/cp38-38-linux: filters: <<: *__ignore_release__ - - test_full/cp37-37m-linux: - filters: - <<: *__ignore_release__ - - test_full/cp36-36m-linux: - filters: - <<: *__ignore_release__ - test_minimal/cp3_10-3_10-linux: filters: @@ -54,12 +48,6 @@ workflows: - test_minimal/cp38-38-linux: filters: <<: *__ignore_release__ - - test_minimal/cp37-37m-linux: - filters: - <<: *__ignore_release__ - - test_minimal/cp36-36m-linux: - filters: - <<: *__ignore_release__ - test_minimal/pypy3: filters: @@ -199,16 +187,6 @@ jobs: <<: *test_full_template docker: - image: cimg/python:3.8 - - test_full/cp37-37m-linux: - <<: *test_full_template - docker: - - image: cimg/python:3.7 - - test_full/cp36-36m-linux: - <<: *test_full_template - docker: - - image: cimg/python:3.6 # ------------ test_minimal/cp3_10-3_10-linux: @@ -226,16 +204,6 @@ jobs: docker: - image: cimg/python:3.8 - test_minimal/cp37-37m-linux: - <<: *test_minimal_template - docker: - - image: cimg/python:3.7 - - test_minimal/cp36-36m-linux: - <<: *test_minimal_template - docker: - - image: cimg/python:3.6 - # --- pypy ---- test_minimal/pypy3: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d7a73a1e..c150a24b 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -157,15 +157,15 @@ jobs: # Xcookie generates an explicit list of environments that will be used # for testing instead of using the more concise matrix notation. include: - - python-version: '3.6' + - python-version: '3.8' install-extras: tests-strict,runtime-strict - os: ubuntu-20.04 + os: ubuntu-latest arch: auto - - python-version: '3.6' + - python-version: '3.8' install-extras: tests-strict,runtime-strict - os: macos-13 + os: macOS-latest arch: auto - - python-version: '3.6' + - python-version: '3.8' install-extras: tests-strict,runtime-strict os: windows-latest arch: auto @@ -189,14 +189,6 @@ jobs: install-extras: tests os: windows-latest arch: auto - - python-version: '3.6' - install-extras: tests,optional - os: ubuntu-20.04 - arch: auto - - python-version: '3.7' - install-extras: tests,optional - os: ubuntu-latest - arch: auto - python-version: '3.8' install-extras: tests,optional os: ubuntu-latest @@ -221,14 +213,6 @@ jobs: install-extras: tests,optional os: ubuntu-latest arch: auto - - python-version: '3.6' - install-extras: tests,optional - os: macos-13 - arch: auto - - python-version: '3.7' - install-extras: tests,optional - os: macos-13 - arch: auto - python-version: '3.8' install-extras: tests,optional os: macOS-latest @@ -253,14 +237,6 @@ jobs: install-extras: tests,optional os: macOS-latest arch: auto - - python-version: '3.6' - install-extras: tests,optional - os: windows-latest - arch: auto - - python-version: '3.7' - install-extras: tests,optional - os: windows-latest - arch: auto - python-version: '3.8' install-extras: tests,optional os: windows-latest @@ -378,8 +354,8 @@ jobs: runs-on: ubuntu-latest if: github.event_name == 'push' && ! startsWith(github.event.ref, 'refs/tags') && ! startsWith(github.event.ref, 'refs/heads/release') needs: - - build_purepy_wheels - build_and_test_sdist + - build_purepy_wheels steps: - name: Checkout source uses: actions/checkout@v4.1.1 @@ -452,8 +428,8 @@ jobs: runs-on: ubuntu-latest if: github.event_name == 'push' && (startsWith(github.event.ref, 'refs/tags') || startsWith(github.event.ref, 'refs/heads/release')) needs: - - build_purepy_wheels - build_and_test_sdist + - build_purepy_wheels steps: - name: Checkout source uses: actions/checkout@v4.1.1 diff --git a/CHANGELOG.md b/CHANGELOG.md index a8b51077..fceee5ae 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,10 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm ## Version 1.2.0 - Unreleased +### Removed +* Dropped 3.6 and 3.7 support. Now supporting 3.6+ Use xdoctest<=1.1.6 for 3.6 or 3.7 support. + + ## Version 1.1.6 - Released 2024-08-01 ### Fixed diff --git a/README.rst b/README.rst index bb93a4a5..ea0abbfd 100644 --- a/README.rst +++ b/README.rst @@ -84,7 +84,7 @@ Installation: from pypi ^^^^^^^^^^^^^^^^^^^^^^^ Xdoctest is distributed on pypi as a universal wheel and can be pip installed on -Python 3.6+ (Python 2.7 and 3.4 / 3.5 support was removed in Version 1.1.0). +Python 3.8+ (Python 2.7 and 3.4 / 3.5 support was removed in Version 1.1.0, 3.6 / 3.7 support was removed in Version 1.2.0). Installations are tested on CPython and PyPy implementations. :: diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index fb58ed22..00000000 --- a/appveyor.yml +++ /dev/null @@ -1,71 +0,0 @@ -# Notes: Rolling Builds AKA Autocancel redundant builds -# https://www.appveyor.com/docs/build-configuration/#rolling-builds -# https://ci.appveyor.com/project/Erotemic/xdoctest/settings - -image: -- Visual Studio 2015 - -environment: - - matrix: - - # For Python versions available on Appveyor, see - # http://www.appveyor.com/docs/installed-software#python - # The list here is complete (excluding Python 2.6, which - # isn't covered by this document) at the time of writing. - - - PYTHON: "C:/Python37-x64" - ARCH_BITS: "64" - - - PYTHON: "C:/Python36-x64" - ARCH_BITS: "64" - - - PYTHON: "C:\\Python36" - ARCH_BITS: "32" - - - PYTHON: "C:\\Python37" - ARCH_BITS: "32" - -install: - # We need wheel installed to build wheels - - set PYTHONIOENCODING=utf-8 - - "%PYTHON%\\python.exe -m pip install colorama==0.4.1" - #- "%PYTHON%\\python.exe -m pip install attrs==19.1.0" - #- "%PYTHON%\\python.exe -m pip install pytest==4.1.0" - - "%PYTHON%\\python.exe -m pip install wheel" - - "%PYTHON%\\python.exe -m pip install -r requirements/runtime.txt" - - "%PYTHON%\\python.exe -m pip install -r requirements/tests.txt" - #- "%PYTHON%\\python.exe setup.py develop" - - "%PYTHON%\\python.exe -m pip install ." - -build: off - -test_script: - # Put your test command here. - # If you don't need to build C extensions on 64-bit Python 3.3 or 3.4, - # you can remove "build.cmd" from the front of the command, as it's - # only needed to support those cases. - # Note that you must use the environment variable %PYTHON% to refer to - # the interpreter you're using - Appveyor does not do anything special - # to put the Python version you want to use on PATH. - - set PYTHONIOENCODING=utf-8 - #- "%PYTHON%\\python.exe -m pip install pytest-cov==2.8.1" - - "%PYTHON%\\python.exe -m xdoctest xdoctest" - - "%PYTHON%\\python.exe -m pytest -s --xdoctest-verbose=3" - -after_test: - # This step builds your wheels. - # Again, you only need build.cmd if you're building C extensions for - # 64-bit Python 3.3/3.4. And you need to use %PYTHON% to get the correct - # interpreter - #- "build.cmd %PYTHON%\\python.exe setup.py bdist_wheel" - -artifacts: - # bdist_wheel puts your built wheel in the dist directory - #- path: dist\* - -#on_success: -# You can use this step to upload your artifacts to a public website. -# See Appveyor's documentation for more details. Or you can simply -# access your wheels from the Appveyor "artifacts" tab for your build. - diff --git a/pyproject.toml b/pyproject.toml index f55dd0cd..81d6eef4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -11,7 +11,7 @@ mod_name = "xdoctest" repo_name = "xdoctest" rel_mod_parent_dpath = "./src" os = [ "all", "win", "linux", "osx",] -min_python = '3.6' +min_python = '3.8' author = "Jon Crall" author_email = "erotemic@gmail.com" description = "A rewrite of the builtin doctest module" @@ -30,8 +30,6 @@ classifiers = [ "License :: OSI Approved :: Apache Software License", # Supported Python versions "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.6", - "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", diff --git a/requirements/jupyter.txt b/requirements/jupyter.txt index d29a3fcc..ecaa6d69 100644 --- a/requirements/jupyter.txt +++ b/requirements/jupyter.txt @@ -1,4 +1,3 @@ -# See ~/local/tools/supported_python_versions_pip.py for helper script # xdev availpkg jupyter_client # xdev availpkg nbconvert # xdev availpkg jupyter_core @@ -16,27 +15,21 @@ nbconvert>=6.0.0; python_version < '3.7.0' and python_version >= '3.6.0' and pl jinja2>=3.0.0 ; python_version >= '3.6' and platform_python_implementation != "PyPy" # Python 3.6+ -jupyter_client>=7.0.0 ; python_version >= '3.6.1' # Python 3.6.1+ -jupyter_client>=6.1.5 ; python_version < '3.6.1' and python_version >= '3.6' # Python 3.6 +jupyter_client>=7.0.0 -IPython>=7.23.1 ; python_version >= '3.7' # Python 3.7+ -IPython>=7.10.0 ; python_version < '3.7' and python_version >= '3.6' # Python 3.6 +IPython>=7.23.1 # Requires psutil? Breaking on pypy windows? ipykernel>=6.11.0 ; python_version < '4.0' and python_version >= '3.12' and (platform_system!="Windows" or platform_python_implementation != "PyPy") # Python 3.12+ ipykernel>=6.0.0 ; python_version < '3.12' and python_version >= '3.7' and (platform_system!="Windows" or platform_python_implementation != "PyPy") # Python 3.7-3.11 -ipykernel>=5.2.0 ; python_version < '3.7' and python_version >= '3.6' and (platform_system!="Windows" or platform_python_implementation != "PyPy") # Python 3.6 # For IPython-kernel debugpy>=1.6.0 ; python_version >= '3.10' # Python 3.10+ debugpy>=1.3.0 ; python_version < '3.10' and python_version >= '3.9' # Python 3.9 debugpy>=1.0.0 ; python_version < '3.9' and python_version >= '3.8' # Python 3.8 -debugpy>=1.0.0 ; python_version < '3.8' and python_version >= '3.7' # Python 3.7 -debugpy>=1.0.0 ; python_version < '3.7' and python_version >= '3.6' # Python 3.6 - # Needed for 3.10 tests # Needed for earlier versions of nbconvert @@ -44,15 +37,12 @@ ipython_genutils >= 0.2.0 ; python_version >= '3.6' and platform_python_impleme # For IPython -jedi>=0.16 ; python_version >= '3.6' # Python 3.6+ - - -attrs>=19.2.0 ; python_version >= '3.6' # Python 3.6+ +jedi>=0.16 +attrs>=19.2.0 # For jupyter-client -jupyter_core >= 4.7.0 ; python_version >= '3.6' # Python 3.6+ - +jupyter_core >= 4.7.0 # For jupyter-core # pywin32>=1.0; platform_system=="Windows" and python_version >= '3.6' and platform_python_implementation != "PyPy" diff --git a/requirements/optional.txt b/requirements/optional.txt index 5b16eb58..34754b36 100644 --- a/requirements/optional.txt +++ b/requirements/optional.txt @@ -3,5 +3,5 @@ pyflakes >= 2.2.0 -# python ~/local/tools/supported_python_versions_pip.py tomli +# xdev availpkg tomli tomli>=0.2.0 ; python_version < '3.11.0' and python_version >= '3.6' # Python 3.6+ diff --git a/requirements/tests.txt b/requirements/tests.txt index fa89e1b0..14ebd483 100644 --- a/requirements/tests.txt +++ b/requirements/tests.txt @@ -2,12 +2,9 @@ # TODO: determine what the actual minimum and maximum acceptable versions of # pytest (that are also compatible with xdoctest) are for each legacy python # major.minor version. -# See ~/local/tools/supported_python_versions_pip.py for helper script +# See xdev availpkg for helper script pytest >= 6.2.5 ; python_version >= '3.10.0' # Python 3.10+ pytest >= 4.6.0 ; python_version < '3.10.0' and python_version >= '3.7.0' # Python 3.7-3.9 -pytest >= 4.6.0 ; python_version < '3.7.0' and python_version >= '3.6.0' # Python 3.6 -pytest-cov >= 3.0.0 ; python_version >= '3.6.0' # Python 3.6+ - -typing >= 3.7.4;python_version <= '3.4' +pytest-cov >= 3.0.0 ; python_version >= '3.6.0' # Python 3.6+ diff --git a/setup.py b/setup.py old mode 100755 new mode 100644 index 446ae62b..e9c0f587 --- a/setup.py +++ b/setup.py @@ -207,8 +207,15 @@ def gen_packages_items(): ) setupkw["extras_require"] = { "all": parse_requirements("requirements.txt", versions="loose"), + "runtime": parse_requirements("requirements/runtime.txt", versions="loose"), "tests": parse_requirements("requirements/tests.txt", versions="loose"), "optional": parse_requirements("requirements/optional.txt", versions="loose"), + "colors": parse_requirements("requirements/colors.txt", versions="loose"), + "docs": parse_requirements("requirements/docs.txt", versions="loose"), + "jupyter": parse_requirements("requirements/jupyter.txt", versions="loose"), + "tests-binary": parse_requirements( + "requirements/tests-binary.txt", versions="loose" + ), "all-strict": parse_requirements("requirements.txt", versions="strict"), "runtime-strict": parse_requirements( "requirements/runtime.txt", versions="strict" @@ -217,12 +224,17 @@ def gen_packages_items(): "optional-strict": parse_requirements( "requirements/optional.txt", versions="strict" ), - 'tests-binary': parse_requirements('requirements/tests-binary.txt'), - 'tests-binary-strict': parse_requirements('requirements/tests-binary.txt', versions='strict'), - 'colors': parse_requirements('requirements/colors.txt'), - 'jupyter': parse_requirements('requirements/jupyter.txt'), + "colors-strict": parse_requirements( + "requirements/colors.txt", versions="strict" + ), + "docs-strict": parse_requirements("requirements/docs.txt", versions="strict"), + "jupyter-strict": parse_requirements( + "requirements/jupyter.txt", versions="strict" + ), + "tests-binary-strict": parse_requirements( + "requirements/tests-binary.txt", versions="strict" + ), } - setupkw["name"] = NAME setupkw["version"] = VERSION setupkw["author"] = "Jon Crall" @@ -233,18 +245,16 @@ def gen_packages_items(): setupkw["long_description_content_type"] = "text/x-rst" setupkw["license"] = "Apache 2" setupkw["packages"] = find_packages("./src") - setupkw["python_requires"] = ">=3.6" + setupkw["python_requires"] = ">=3.8" setupkw["classifiers"] = [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Developers", "Topic :: Software Development :: Libraries :: Python Modules", - "Topic :: Software Development :: Testing", "Topic :: Utilities", - "Framework :: Pytest", "License :: OSI Approved :: Apache Software License", + "Topic :: Software Development :: Testing", + "Framework :: Pytest", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.6", - "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10",