From 189b959d2e5f09660508482398414e2869c074ff Mon Sep 17 00:00:00 2001 From: Elvis Pranskevichus Date: Fri, 6 Aug 2021 18:19:23 -0700 Subject: [PATCH] Drop Python 3.5 support declaration, add Python 3.10 (#71) --- .github/workflows/tests.yml | 2 +- README.rst | 4 ++-- immutables/__init__.py | 5 +---- pyproject.toml | 6 ++++++ setup.py | 4 ++-- 5 files changed, 12 insertions(+), 9 deletions(-) create mode 100644 pyproject.toml diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 90bffc33d..b3316203b 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -14,7 +14,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - python-version: [3.6, 3.7, 3.8, 3.9, 3.10.0-beta.4] + python-version: [3.6, 3.7, 3.8, 3.9, 3.10.0-rc.1] os: [windows-latest, ubuntu-latest, macos-latest] arch: [x64, x86] exclude: diff --git a/README.rst b/README.rst index 4132bc07e..e14d3210f 100644 --- a/README.rst +++ b/README.rst @@ -12,7 +12,7 @@ An immutable mapping type for Python. The underlying datastructure is a Hash Array Mapped Trie (HAMT) used in Clojure, Scala, Haskell, and other functional languages. This implementation is used in CPython 3.7 in the ``contextvars`` -module (see `PEP 550 `_ and +module (see `PEP 550 `_ and `PEP 567 `_ for more details). Immutable mappings based on HAMT have O(log N) performance for both @@ -30,7 +30,7 @@ copy-on-write approach (the benchmark code is available Installation ------------ -``immutables`` requires Python 3.5+ and is available on PyPI:: +``immutables`` requires Python 3.6+ and is available on PyPI:: $ pip install immutables diff --git a/immutables/__init__.py b/immutables/__init__.py index fc7764b29..b8565b0c3 100644 --- a/immutables/__init__.py +++ b/immutables/__init__.py @@ -2,10 +2,7 @@ import sys -if sys.version_info >= (3, 5, 2): - from typing import TYPE_CHECKING -else: - from typing_extensions import TYPE_CHECKING +from typing import TYPE_CHECKING if TYPE_CHECKING: from ._map import Map diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 000000000..810162d8a --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,6 @@ +[project] +requires-python = ">=3.6" + +[build-system] +requires = ["setuptools>=42", "wheel"] +build-backend = "setuptools.build_meta" diff --git a/setup.py b/setup.py index b21c05afa..221313a14 100644 --- a/setup.py +++ b/setup.py @@ -65,16 +65,16 @@ version=VERSION, description='Immutable Collections', long_description=readme, - python_requires='>=3.5', + python_requires='>=3.6', classifiers=[ 'License :: OSI Approved :: Apache Software License', 'Intended Audience :: Developers', 'Programming Language :: Python :: 3 :: Only', - 'Programming Language :: Python :: 3.5', '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', 'Operating System :: POSIX', 'Operating System :: MacOS :: MacOS X', 'Operating System :: Microsoft :: Windows',