diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index 4334720..cadd548 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -1,14 +1,14 @@ on: pull_request jobs: pre-commit: - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 steps: - name: Checkout uses: actions/checkout@v1 - - name: Setup python 3.6 + - name: Setup python 3.10 uses: actions/setup-python@v1 with: - python-version: 3.6 + python-version: 3.10.14 - name: Install pre-commit run: pip install pre-commit - name: Run pre-commit @@ -36,10 +36,10 @@ jobs: # - name: Run license finder # run: license_finder test: - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 strategy: matrix: - python-version: ['2.7.x', '3.6.x', '3.7.x', '3.8.x'] + python-version: ['3.10.x'] steps: - name: Checkout uses: actions/checkout@v1 diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 812f9f4..e242d86 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -8,14 +8,14 @@ on: jobs: build-and-publish-python-module: name: Build and publish python module to pypi - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 steps: - name: Checkout uses: actions/checkout@v1 - - name: Setup python 3.6 + - name: Setup python 3.10 uses: actions/setup-python@v1 with: - python-version: 3.6 + python-version: 3.10.14 - name: Add wheel dependency run: pip install wheel - name: Generate dist diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a94479a..f372f3f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -5,5 +5,5 @@ repos: hooks: - id: flake8 additional_dependencies: - - flake8==3.3.0 - - flake8-tidy-imports==1.0.6 + - flake8 + - flake8-tidy-imports diff --git a/CHANGELOG.md b/CHANGELOG.md index 9184041..c4d6105 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## 2.5.3 + +* upgrade to python3.10 + ## 2.2.0 * remove upper bound for dependency of cryptography diff --git a/Makefile b/Makefile index 5b42a39..8468914 100644 --- a/Makefile +++ b/Makefile @@ -5,4 +5,4 @@ test: test_unit test_unit: mkdir -p build - nosetests tests/unit + pytest tests/unit diff --git a/confidant_client/__init__.py b/confidant_client/__init__.py index 8b494d4..d73f90a 100644 --- a/confidant_client/__init__.py +++ b/confidant_client/__init__.py @@ -932,7 +932,7 @@ def get_certificate_from_csr(self, ca, csr, validity=120): try: response = self._execute_request( 'post', - '{0}/v1/certificates/{1}'.format( + '{0}/v1/certificates/{1}'.format( # noqa: F522 self.config['url'], ca, data={ diff --git a/requirements.txt b/requirements.txt index fe07950..7817b75 100644 --- a/requirements.txt +++ b/requirements.txt @@ -8,10 +8,9 @@ flake8==2.3.0 # Upstream url: https://pypi.python.org/pypi/coverage coverage==3.7.1 -# nose makes testing easier -# License: GNU Library or Lesser General Public License (LGPL) -# Upstream url: http://readthedocs.org/docs/nose -nose==1.3.3 +# License: MIT +# Upstream url: https://pypi.org/project/pytest/ +pytest # Mocking and Patching Library for Testing # License: BSD diff --git a/setup.py b/setup.py index 5926470..19702cb 100644 --- a/setup.py +++ b/setup.py @@ -18,7 +18,7 @@ setup( name="confidant-client", - version="2.5.2", + version="2.5.3", packages=find_packages(exclude=["test*"]), install_requires=[ # Boto3 is the Amazon Web Services (AWS) Software Development Kit (SDK) @@ -97,7 +97,6 @@ ], }, classifiers=[ - 'Programming Language :: Python :: 2.7', 'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3.3', 'Programming Language :: Python :: 3.4', @@ -105,5 +104,6 @@ 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.10', ], ) diff --git a/tests/unit/confidant_client/client_test.py b/tests/unit/confidant_client/client_test.py index 5884b92..2612e39 100644 --- a/tests/unit/confidant_client/client_test.py +++ b/tests/unit/confidant_client/client_test.py @@ -79,13 +79,13 @@ def test_validate_config(self): # invalid token version token_version=3 ) - assert(confidant_client.ConfidantClient( + assert (confidant_client.ConfidantClient( 'http://localhost/', 'alias/authnz-testing', {'from': 'test', 'to': 'test'}, token_version=1 )) - assert(confidant_client.ConfidantClient( + assert (confidant_client.ConfidantClient( 'http://localhost/', 'alias/authnz-testing', {'from': 'test', 'to': 'test', 'user_type': 'service'}