From 9bb067e03d0f3bda702ccda87d22e8fec465d8a0 Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 23 Jan 2023 11:49:09 -0800 Subject: [PATCH 1/3] chore: freeze py311 depedencies for pyca and test in CI --- .github/workflows/ci_tests.yaml | 26 ++++++++++++++-- test/upstream-requirements-py311.txt | 20 +++++++++++++ test/upstream-requirements-py37.txt | 45 ++++++++++++++-------------- tox.ini | 19 +++++++++++- 4 files changed, 84 insertions(+), 26 deletions(-) create mode 100644 test/upstream-requirements-py311.txt diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 3e4f51c93..c909e3ccb 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -31,7 +31,9 @@ jobs: - 3.7 - 3.8 - 3.9 - - 3.x + - 3.10 + - 3.11 + - 3.x # Ideally, we would skip if 3.x is 3.11 architecture: - x64 - x86 @@ -61,7 +63,7 @@ jobs: env: TOXENV: ${{ matrix.category }} run: tox -- -vv - upstream-py3: + upstream-py37: runs-on: ubuntu-latest strategy: fail-fast: true @@ -81,3 +83,23 @@ jobs: env: TOXENV: ${{ matrix.category }} run: tox -- -vv + upstream-py311: + runs-on: ubuntu-latest + strategy: + fail-fast: true + matrix: + category: + - nocmk + - test-upstream-requirements-py311 + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + with: + python-version: 3.11 + - run: | + python -m pip install --upgrade pip + pip install --upgrade -r dev_requirements/ci-requirements.txt + - name: run test + env: + TOXENV: ${{ matrix.category }} + run: tox -- -vv diff --git a/test/upstream-requirements-py311.txt b/test/upstream-requirements-py311.txt new file mode 100644 index 000000000..e5e24f492 --- /dev/null +++ b/test/upstream-requirements-py311.txt @@ -0,0 +1,20 @@ +attrs==22.2.0 +boto3==1.26.54 +botocore==1.29.54 +cffi==1.15.1 +coverage==7.0.5 +cryptography==39.0.0 +iniconfig==2.0.0 +jmespath==1.0.1 +mock==4.0.3 +packaging==23.0 +pluggy==1.0.0 +pycparser==2.21 +pytest==7.2.0 +pytest-cov==3.0.0 +pytest-mock==3.6.1 +python-dateutil==2.8.2 +s3transfer==0.6.0 +six==1.16.0 +urllib3==1.26.14 +wrapt==1.14.1 diff --git a/test/upstream-requirements-py37.txt b/test/upstream-requirements-py37.txt index a4603ddf8..ecb05c22c 100644 --- a/test/upstream-requirements-py37.txt +++ b/test/upstream-requirements-py37.txt @@ -1,26 +1,25 @@ -attrs==21.2.0 -boto3==1.17.92 -botocore==1.20.92 -cffi==1.14.5 -coverage==5.5 -cryptography==3.4.7 -importlib-metadata==4.5.0 -iniconfig==1.1.1 -jmespath==0.10.0 +attrs==22.2.0 +boto3==1.26.54 +botocore==1.29.54 +cffi==1.15.1 +coverage==7.0.5 +cryptography==39.0.0 +exceptiongroup==1.1.0 +importlib-metadata==6.0.0 +iniconfig==2.0.0 +jmespath==1.0.1 mock==4.0.3 -packaging==20.9 -pluggy==0.13.1 -py==1.10.0 -pycparser==2.20 -pyparsing==2.4.7 -pytest==6.2.4 -pytest-cov==2.12.1 +packaging==23.0 +pluggy==1.0.0 +pycparser==2.21 +pytest==7.2.0 +pytest-cov==3.0.0 pytest-mock==3.6.1 -python-dateutil==2.8.1 -s3transfer==0.4.2 +python-dateutil==2.8.2 +s3transfer==0.6.0 six==1.16.0 -toml==0.10.2 -typing-extensions==3.10.0.0 -urllib3==1.26.5 -wrapt==1.12.1 -zipp==3.4.1 +tomli==2.0.1 +typing_extensions==4.4.0 +urllib3==1.26.14 +wrapt==1.14.1 +zipp==3.11.0 diff --git a/tox.ini b/tox.ini index 99a6dff73..48421de50 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,6 @@ [tox] envlist = - py{37,38,39,310}-{local,integ,accept,examples}, nocmk, + py{37,38,39,310,311}-{local,integ,accept,examples}, nocmk, bandit, doc8, readme, docs, {flake8,pylint}{,-tests,-examples}, isort-check, black-check, @@ -103,6 +103,15 @@ recreate = {[testenv:freeze-upstream-requirements-base]recreate} deps = {[testenv:freeze-upstream-requirements-base]deps} commands = {[testenv:freeze-upstream-requirements-base]commands} test/upstream-requirements-py37.txt +# Freeze for Python 3.11 +[testenv:freeze-upstream-requirements-py311] +basepython = python3.11 +sitepackages = {[testenv:freeze-upstream-requirements-base]sitepackages} +skip_install = {[testenv:freeze-upstream-requirements-base]skip_install} +recreate = {[testenv:freeze-upstream-requirements-base]recreate} +deps = {[testenv:freeze-upstream-requirements-base]deps} +commands = {[testenv:freeze-upstream-requirements-base]commands} test/upstream-requirements-py311.txt + # Test frozen upstream requirements [testenv:test-upstream-requirements-base] sitepackages = False @@ -117,6 +126,14 @@ sitepackages = {[testenv:test-upstream-requirements-base]sitepackages} recreate = {[testenv:test-upstream-requirements-base]recreate} commands = {[testenv:test-upstream-requirements-base]commands} +# Test frozen upstream requirements for Python 3.11 +[testenv:test-upstream-requirements-py311] +basepython = python3.11 +deps = -rtest/upstream-requirements-py311.txt +sitepackages = {[testenv:test-upstream-requirements-base]sitepackages} +recreate = {[testenv:test-upstream-requirements-base]recreate} +commands = {[testenv:test-upstream-requirements-base]commands} + # Linters [testenv:flake8] basepython = python3 From cbddce326c458b2035049885c85e0570d7bd028d Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 23 Jan 2023 11:56:46 -0800 Subject: [PATCH 2/3] fix: GitHub Action reads 3.11 as 3.1 --- .github/workflows/ci_tests.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index c909e3ccb..869766b63 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -32,7 +32,7 @@ jobs: - 3.8 - 3.9 - 3.10 - - 3.11 + - "3.11" - 3.x # Ideally, we would skip if 3.x is 3.11 architecture: - x64 @@ -95,7 +95,7 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-python@v4 with: - python-version: 3.11 + python-version: "3.11" - run: | python -m pip install --upgrade pip pip install --upgrade -r dev_requirements/ci-requirements.txt From 0c97f9141d8307f28416293c7559937660530e10 Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 23 Jan 2023 11:58:59 -0800 Subject: [PATCH 3/3] fix: GitHub Action reads 3.10 as 3.1 --- .github/workflows/ci_tests.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 869766b63..f537491fc 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -31,7 +31,7 @@ jobs: - 3.7 - 3.8 - 3.9 - - 3.10 + - "3.10" - "3.11" - 3.x # Ideally, we would skip if 3.x is 3.11 architecture: