From 5540a081f49a79786084c37d944def093cc26627 Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Fri, 8 Oct 2021 14:16:48 +0300 Subject: [PATCH 1/7] Add support for Python 3.10 --- .github/workflows/ci.yml | 4 ++-- setup.py | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 84496648..46536f7b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -10,7 +10,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [3.5, 3.6, 3.7, 3.8, 3.9] + python-version: ["3.5", "3.6", "3.7", "3.8", "3.9", "3.10"] steps: - uses: actions/checkout@v2 @@ -21,7 +21,7 @@ jobs: - name: Install test dependencies run: | python -m pip install --upgrade pip - pip install pytest + python -m pip install pytest - name: Test with pytest run: | pytest diff --git a/setup.py b/setup.py index 69ec098a..6d0d9203 100755 --- a/setup.py +++ b/setup.py @@ -62,6 +62,7 @@ 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: 3.9', + 'Programming Language :: Python :: 3.10', ], project_urls={ 'Documentation': 'https://certifiio.readthedocs.io/en/latest/', From 62315e68780081c850919a88eec5fe2d82cbad47 Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Fri, 8 Oct 2021 14:20:37 +0300 Subject: [PATCH 2/7] Remove Trove classifiers for dropped versions --- setup.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/setup.py b/setup.py index 6d0d9203..ee7fe8fc 100755 --- a/setup.py +++ b/setup.py @@ -55,8 +55,6 @@ 'Natural Language :: English', 'Programming Language :: Python', '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.7', From 0ecf2d01423e0cfdd186af91351776d9b1406c8e Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Fri, 8 Oct 2021 14:22:13 +0300 Subject: [PATCH 3/7] Remove redundant setup.cfg: no need for universal wheels for Python 3-only, setuptools and wheel auto-find LICENSE files --- setup.cfg | 5 ----- 1 file changed, 5 deletions(-) delete mode 100644 setup.cfg diff --git a/setup.cfg b/setup.cfg deleted file mode 100644 index ed8a958e..00000000 --- a/setup.cfg +++ /dev/null @@ -1,5 +0,0 @@ -[bdist_wheel] -universal = 1 - -[metadata] -license_file = LICENSE From b03946b788fa2d7a8010d346d485ffd8484a6401 Mon Sep 17 00:00:00 2001 From: Nirjas Jakilim Date: Wed, 21 Apr 2021 15:22:00 +0600 Subject: [PATCH 4/7] Added Required Python Version Added python_requires to specify the required python version for the library. --- setup.py | 1 + 1 file changed, 1 insertion(+) diff --git a/setup.py b/setup.py index ee7fe8fc..7b50ad0e 100755 --- a/setup.py +++ b/setup.py @@ -48,6 +48,7 @@ include_package_data=True, zip_safe=False, license='MPL-2.0', + python_requires=">=3.3", classifiers=[ 'Development Status :: 5 - Production/Stable', 'Intended Audience :: Developers', From 8c0ccb189b9407096232a05c07e54c593d3e270b Mon Sep 17 00:00:00 2001 From: Nirjas Jakilim Date: Wed, 21 Apr 2021 19:02:44 +0600 Subject: [PATCH 5/7] Updated required python version --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 7b50ad0e..56d171df 100755 --- a/setup.py +++ b/setup.py @@ -48,7 +48,7 @@ include_package_data=True, zip_safe=False, license='MPL-2.0', - python_requires=">=3.3", + python_requires=">=3.5", classifiers=[ 'Development Status :: 5 - Production/Stable', 'Intended Audience :: Developers', From fc3b13d85c484e17aac8f9f7eecf8b57d81a0fbf Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Fri, 8 Oct 2021 14:24:24 +0300 Subject: [PATCH 6/7] Drop support for EOL Python 3.5 --- .github/workflows/ci.yml | 2 +- setup.py | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 46536f7b..981e8b47 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -10,7 +10,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.5", "3.6", "3.7", "3.8", "3.9", "3.10"] + python-version: ["3.6", "3.7", "3.8", "3.9", "3.10"] steps: - uses: actions/checkout@v2 diff --git a/setup.py b/setup.py index 56d171df..c812c73b 100755 --- a/setup.py +++ b/setup.py @@ -48,7 +48,7 @@ include_package_data=True, zip_safe=False, license='MPL-2.0', - python_requires=">=3.5", + python_requires=">=3.6", classifiers=[ 'Development Status :: 5 - Production/Stable', 'Intended Audience :: Developers', @@ -56,7 +56,6 @@ 'Natural Language :: English', 'Programming Language :: Python', 'Programming Language :: Python :: 3', - 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', From 49f7dc59b47ca007decfc0779433e032747ce3be Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Fri, 8 Oct 2021 14:25:05 +0300 Subject: [PATCH 7/7] Upgrade Python syntax with pyupgrade --py36-plus --- certifi/core.py | 4 +--- certifi/tests/test_certify.py | 2 -- setup.py | 4 +--- 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/certifi/core.py b/certifi/core.py index 5d2b8cd3..bf4fef29 100644 --- a/certifi/core.py +++ b/certifi/core.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - """ certifi.py ~~~~~~~~~~ @@ -45,7 +43,7 @@ def where(): # so won't address issues with environments like PyOxidizer that don't set # __file__ on modules. def read_text(_module, _path, encoding="ascii"): - with open(where(), "r", encoding=encoding) as data: + with open(where(), encoding=encoding) as data: return data.read() # If we don't have importlib.resources, then we will just do the old logic diff --git a/certifi/tests/test_certify.py b/certifi/tests/test_certify.py index 7fb8c77f..122c7e04 100755 --- a/certifi/tests/test_certify.py +++ b/certifi/tests/test_certify.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - import os import unittest diff --git a/setup.py b/setup.py index c812c73b..1ab4db65 100755 --- a/setup.py +++ b/setup.py @@ -1,6 +1,4 @@ #!/usr/bin/env python -# -*- coding: utf-8 -*- -from __future__ import with_statement import re import os import sys @@ -18,7 +16,7 @@ version_regex = r'__version__ = ["\']([^"\']*)["\']' -with open('certifi/__init__.py', 'r') as f: +with open('certifi/__init__.py') as f: text = f.read() match = re.search(version_regex, text)