From 0dd70830a557da091305a55318a4da8ac87731a3 Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 15:31:08 -0700 Subject: [PATCH 1/9] feat: test Python 3.12 in CI --- .github/workflows/ci_static-analysis.yaml | 2 +- .github/workflows/ci_test-vector-handler.yaml | 3 +-- .github/workflows/ci_tests.yaml | 3 ++- buildspec.yml | 13 +++++++++ codebuild/py311/awses_local.yml | 27 +++++++++++++++++++ codebuild/py311/examples.yml | 24 +++++++++++++++++ codebuild/py311/integ.yml | 24 +++++++++++++++++ codebuild/py312/awses_local.yml | 27 +++++++++++++++++++ codebuild/py312/examples.yml | 24 +++++++++++++++++ codebuild/py312/integ.yml | 24 +++++++++++++++++ dev_requirements/ci-requirements.txt | 1 + tox.ini | 2 +- 12 files changed, 169 insertions(+), 5 deletions(-) create mode 100644 codebuild/py311/awses_local.yml create mode 100644 codebuild/py311/examples.yml create mode 100644 codebuild/py311/integ.yml create mode 100644 codebuild/py312/awses_local.yml create mode 100644 codebuild/py312/examples.yml create mode 100644 codebuild/py312/integ.yml diff --git a/.github/workflows/ci_static-analysis.yaml b/.github/workflows/ci_static-analysis.yaml index 0093ae9a9..1cfb70551 100644 --- a/.github/workflows/ci_static-analysis.yaml +++ b/.github/workflows/ci_static-analysis.yaml @@ -30,7 +30,7 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-python@v4 with: - python-version: 3.8 + python-version: 3.11 - run: | python -m pip install --upgrade pip pip install --upgrade -r dev_requirements/ci-requirements.txt diff --git a/.github/workflows/ci_test-vector-handler.yaml b/.github/workflows/ci_test-vector-handler.yaml index 81ad1fa09..4cfb6b5d7 100644 --- a/.github/workflows/ci_test-vector-handler.yaml +++ b/.github/workflows/ci_test-vector-handler.yaml @@ -21,7 +21,6 @@ jobs: - windows-latest - macos-latest python: - - 3.7 - 3.8 - 3.x architecture: @@ -73,7 +72,7 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-python@v4 with: - python-version: 3.9 + python-version: 3.11 - run: | python -m pip install --upgrade pip pip install --upgrade -r dev_requirements/ci-requirements.txt diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index f537491fc..9d491203c 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -33,7 +33,8 @@ jobs: - 3.9 - "3.10" - "3.11" - - 3.x # Ideally, we would skip if 3.x is 3.11 + - "3.12" + - 3.x architecture: - x64 - x86 diff --git a/buildspec.yml b/buildspec.yml index 2f2571f64..b8b797b99 100644 --- a/buildspec.yml +++ b/buildspec.yml @@ -30,7 +30,20 @@ batch: - identifier: py310_awses_latest buildspec: codebuild/py310/awses_local.yml + - identifier: py311_integ + buildspec: codebuild/py311/integ.yml + - identifier: py311_examples + buildspec: codebuild/py311/examples.yml + - identifier: py311_awses_latest + buildspec: codebuild/py311/awses_local.yml + - identifier: py312_integ + buildspec: codebuild/py312/integ.yml + - identifier: py312_examples + buildspec: codebuild/py312/examples.yml + - identifier: py312_awses_latest + buildspec: codebuild/py312/awses_local.yml + - identifier: code_coverage buildspec: codebuild/coverage/coverage.yml diff --git a/codebuild/py311/awses_local.yml b/codebuild/py311/awses_local.yml new file mode 100644 index 000000000..fa153ea61 --- /dev/null +++ b/codebuild/py311/awses_local.yml @@ -0,0 +1,27 @@ +version: 0.2 + +env: + variables: + TOXENV: "py311-awses_local" + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID: >- + arn:aws:kms:us-west-2:658956600833:key/b3537ef1-d8dc-4780-9f5a-55776cbb2f7f + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID_2: >- + arn:aws:kms:eu-central-1:658956600833:key/75414c93-5285-4b57-99c9-30c1cf0a22c2 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_1: >- + arn:aws:kms:us-west-2:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_2: >- + arn:aws:kms:us-east-1:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + AWS_ENCRYPTION_SDK_PYTHON_DECRYPT_ORACLE_API_DEPLOYMENT_ID: "xi1mwx3ttb" + AWS_ENCRYPTION_SDK_PYTHON_DECRYPT_ORACLE_REGION: "us-west-2" + +phases: + install: + runtime-versions: + python: latest + build: + commands: + - pyenv install 3.11.0 + - pyenv local 3.11.0 + - pip install "tox < 4.0" + - cd test_vector_handlers + - tox diff --git a/codebuild/py311/examples.yml b/codebuild/py311/examples.yml new file mode 100644 index 000000000..8c33bd81e --- /dev/null +++ b/codebuild/py311/examples.yml @@ -0,0 +1,24 @@ +version: 0.2 + +env: + variables: + TOXENV: "py311-examples" + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID: >- + arn:aws:kms:us-west-2:658956600833:key/b3537ef1-d8dc-4780-9f5a-55776cbb2f7f + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID_2: >- + arn:aws:kms:eu-central-1:658956600833:key/75414c93-5285-4b57-99c9-30c1cf0a22c2 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_1: >- + arn:aws:kms:us-west-2:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_2: >- + arn:aws:kms:us-east-1:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + +phases: + install: + runtime-versions: + python: latest + build: + commands: + - pyenv install 3.11.0 + - pyenv local 3.11.0 + - pip install "tox < 4.0" + - tox diff --git a/codebuild/py311/integ.yml b/codebuild/py311/integ.yml new file mode 100644 index 000000000..9629e1db9 --- /dev/null +++ b/codebuild/py311/integ.yml @@ -0,0 +1,24 @@ +version: 0.2 + +env: + variables: + TOXENV: "py311-integ" + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID: >- + arn:aws:kms:us-west-2:658956600833:key/b3537ef1-d8dc-4780-9f5a-55776cbb2f7f + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID_2: >- + arn:aws:kms:eu-central-1:658956600833:key/75414c93-5285-4b57-99c9-30c1cf0a22c2 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_1: >- + arn:aws:kms:us-west-2:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_2: >- + arn:aws:kms:us-east-1:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + +phases: + install: + runtime-versions: + python: latest + build: + commands: + - pyenv install 3.11.0 + - pyenv local 3.11.0 + - pip install "tox < 4.0" + - tox diff --git a/codebuild/py312/awses_local.yml b/codebuild/py312/awses_local.yml new file mode 100644 index 000000000..291d091cb --- /dev/null +++ b/codebuild/py312/awses_local.yml @@ -0,0 +1,27 @@ +version: 0.2 + +env: + variables: + TOXENV: "py312-awses_local" + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID: >- + arn:aws:kms:us-west-2:658956600833:key/b3537ef1-d8dc-4780-9f5a-55776cbb2f7f + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID_2: >- + arn:aws:kms:eu-central-1:658956600833:key/75414c93-5285-4b57-99c9-30c1cf0a22c2 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_1: >- + arn:aws:kms:us-west-2:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_2: >- + arn:aws:kms:us-east-1:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + AWS_ENCRYPTION_SDK_PYTHON_DECRYPT_ORACLE_API_DEPLOYMENT_ID: "xi1mwx3ttb" + AWS_ENCRYPTION_SDK_PYTHON_DECRYPT_ORACLE_REGION: "us-west-2" + +phases: + install: + runtime-versions: + python: latest + build: + commands: + - pyenv install 3.12.0 + - pyenv local 3.12.0 + - pip install "tox < 4.0" + - cd test_vector_handlers + - tox diff --git a/codebuild/py312/examples.yml b/codebuild/py312/examples.yml new file mode 100644 index 000000000..96bf33b38 --- /dev/null +++ b/codebuild/py312/examples.yml @@ -0,0 +1,24 @@ +version: 0.2 + +env: + variables: + TOXENV: "py312-examples" + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID: >- + arn:aws:kms:us-west-2:658956600833:key/b3537ef1-d8dc-4780-9f5a-55776cbb2f7f + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID_2: >- + arn:aws:kms:eu-central-1:658956600833:key/75414c93-5285-4b57-99c9-30c1cf0a22c2 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_1: >- + arn:aws:kms:us-west-2:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_2: >- + arn:aws:kms:us-east-1:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + +phases: + install: + runtime-versions: + python: latest + build: + commands: + - pyenv install 3.12.0 + - pyenv local 3.12.0 + - pip install "tox < 4.0" + - tox diff --git a/codebuild/py312/integ.yml b/codebuild/py312/integ.yml new file mode 100644 index 000000000..ec8b2a1b0 --- /dev/null +++ b/codebuild/py312/integ.yml @@ -0,0 +1,24 @@ +version: 0.2 + +env: + variables: + TOXENV: "py312-integ" + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID: >- + arn:aws:kms:us-west-2:658956600833:key/b3537ef1-d8dc-4780-9f5a-55776cbb2f7f + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_KEY_ID_2: >- + arn:aws:kms:eu-central-1:658956600833:key/75414c93-5285-4b57-99c9-30c1cf0a22c2 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_1: >- + arn:aws:kms:us-west-2:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + AWS_ENCRYPTION_SDK_PYTHON_INTEGRATION_TEST_AWS_KMS_MRK_KEY_ID_2: >- + arn:aws:kms:us-east-1:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7 + +phases: + install: + runtime-versions: + python: latest + build: + commands: + - pyenv install 3.12.0 + - pyenv local 3.12.0 + - pip install "tox < 4.0" + - tox diff --git a/dev_requirements/ci-requirements.txt b/dev_requirements/ci-requirements.txt index 57e3871e0..4335988fd 100644 --- a/dev_requirements/ci-requirements.txt +++ b/dev_requirements/ci-requirements.txt @@ -1 +1,2 @@ +setuptools tox==3.27.1 diff --git a/tox.ini b/tox.ini index 48421de50..3e6c7a06b 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,6 @@ [tox] envlist = - py{37,38,39,310,311}-{local,integ,accept,examples}, nocmk, + py{38,39,310,311,312}-{local,integ,accept,examples}, nocmk, bandit, doc8, readme, docs, {flake8,pylint}{,-tests,-examples}, isort-check, black-check, From fb16f5b6e5e697d181a32fa28c16017f1b01973d Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 16:20:02 -0700 Subject: [PATCH 2/9] fix: error messages changed in Python 3.12 --- test/unit/test_caches_base.py | 24 +++++++++++------------- test/unit/test_material_managers_base.py | 13 ++++++------- 2 files changed, 17 insertions(+), 20 deletions(-) diff --git a/test/unit/test_caches_base.py b/test/unit/test_caches_base.py index c3aa2369b..c24b1b04c 100644 --- a/test/unit/test_caches_base.py +++ b/test/unit/test_caches_base.py @@ -19,18 +19,16 @@ def test_abstracts(): - with pytest.raises(TypeError) as excinfo: + with pytest.raises(TypeError, match='instantiate abstract class CryptoMaterialsCache') as excinfo: CryptoMaterialsCache() - excinfo.match( - r"Can't instantiate abstract class CryptoMaterialsCache with abstract methods {}".format( - ", ".join( - [ - "get_decryption_materials", - "get_encryption_materials", - "put_decryption_materials", - "put_encryption_materials", - ] - ) - ) - ) + exception = str(excinfo.value) + method_names = [ + "get_decryption_materials", + "get_encryption_materials", + "put_decryption_materials", + "put_encryption_materials" + ] + for name in method_names: + if exception.rfind(name) == -1: + raise AssertionError("{} missing from Exception Message".format(name)) diff --git a/test/unit/test_material_managers_base.py b/test/unit/test_material_managers_base.py index 792118979..34501e59a 100644 --- a/test/unit/test_material_managers_base.py +++ b/test/unit/test_material_managers_base.py @@ -19,11 +19,10 @@ def test_abstracts(): - with pytest.raises(TypeError) as excinfo: + with pytest.raises(TypeError, match='instantiate abstract class CryptoMaterialsManager') as excinfo: CryptoMaterialsManager() - - excinfo.match( - r"Can't instantiate abstract class CryptoMaterialsManager with abstract methods {}".format( - ", ".join(["decrypt_materials", "get_encryption_materials"]) - ) - ) + method_names = ["decrypt_materials", "get_encryption_materials"] + exception = str(excinfo.value) + for name in method_names: + if exception.rfind(name) == -1: + raise AssertionError("{} missing from Exception Message".format(name)) From 96a769ced59e3ec023a4a710bf958df6dc505291 Mon Sep 17 00:00:00 2001 From: Tony Knapp <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 16:23:11 -0700 Subject: [PATCH 3/9] chore: do not change static analysis python --- .github/workflows/ci_static-analysis.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci_static-analysis.yaml b/.github/workflows/ci_static-analysis.yaml index 1cfb70551..0093ae9a9 100644 --- a/.github/workflows/ci_static-analysis.yaml +++ b/.github/workflows/ci_static-analysis.yaml @@ -30,7 +30,7 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-python@v4 with: - python-version: 3.11 + python-version: 3.8 - run: | python -m pip install --upgrade pip pip install --upgrade -r dev_requirements/ci-requirements.txt From 081f9f51ee36b48464317a911ebf57e208967a32 Mon Sep 17 00:00:00 2001 From: Tony Knapp <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 16:25:58 -0700 Subject: [PATCH 4/9] chore: do not change static analysis python --- .github/workflows/ci_test-vector-handler.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci_test-vector-handler.yaml b/.github/workflows/ci_test-vector-handler.yaml index 4cfb6b5d7..12ecf8f93 100644 --- a/.github/workflows/ci_test-vector-handler.yaml +++ b/.github/workflows/ci_test-vector-handler.yaml @@ -72,7 +72,7 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-python@v4 with: - python-version: 3.11 + python-version: 3.9 - run: | python -m pip install --upgrade pip pip install --upgrade -r dev_requirements/ci-requirements.txt From bc14a532e62171357bf7f13bb8085f4ca474ac13 Mon Sep 17 00:00:00 2001 From: Tony Knapp <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 16:28:11 -0700 Subject: [PATCH 5/9] chore: do not remove 3.7 from tox, yet --- tox.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index 3e6c7a06b..9ca7a0cd6 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,6 @@ [tox] envlist = - py{38,39,310,311,312}-{local,integ,accept,examples}, nocmk, + py{37,38,39,310,311,312}-{local,integ,accept,examples}, nocmk, bandit, doc8, readme, docs, {flake8,pylint}{,-tests,-examples}, isort-check, black-check, From 624778e119784d798a1a44e0d816f5fe98432a56 Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 17:04:21 -0700 Subject: [PATCH 6/9] fix: CB needs newer images for python > 3.10 --- buildspec.yml | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/buildspec.yml b/buildspec.yml index b8b797b99..f92d203a0 100644 --- a/buildspec.yml +++ b/buildspec.yml @@ -5,44 +5,80 @@ batch: build-list: - identifier: py37_integ buildspec: codebuild/py37/integ.yml + env: + image: aws/codebuild/standard:5.0 - identifier: py37_examples buildspec: codebuild/py37/examples.yml + env: + image: aws/codebuild/standard:5.0 - identifier: py37_awses_local buildspec: codebuild/py37/awses_local.yml + env: + image: aws/codebuild/standard:5.0 - identifier: py38_integ buildspec: codebuild/py38/integ.yml + env: + image: aws/codebuild/standard:5.0 - identifier: py38_examples buildspec: codebuild/py38/examples.yml + env: + image: aws/codebuild/standard:5.0 - identifier: py38_awses_local buildspec: codebuild/py38/awses_local.yml + env: + image: aws/codebuild/standard:5.0 - identifier: py39_integ buildspec: codebuild/py39/integ.yml + env: + image: aws/codebuild/standard:5.0 - identifier: py39_examples buildspec: codebuild/py39/examples.yml + env: + image: aws/codebuild/standard:5.0 - identifier: py39_awses_latest + env: + image: aws/codebuild/standard:5.0 - identifier: py310_integ buildspec: codebuild/py310/integ.yml + env: + image: aws/codebuild/standard:6.0 - identifier: py310_examples buildspec: codebuild/py310/examples.yml + env: + image: aws/codebuild/standard:6.0 - identifier: py310_awses_latest buildspec: codebuild/py310/awses_local.yml + env: + image: aws/codebuild/standard:6.0 - identifier: py311_integ buildspec: codebuild/py311/integ.yml + env: + image: aws/codebuild/standard:7.0 - identifier: py311_examples buildspec: codebuild/py311/examples.yml + env: + image: aws/codebuild/standard:7.0 - identifier: py311_awses_latest buildspec: codebuild/py311/awses_local.yml + env: + image: aws/codebuild/standard:7.0 - identifier: py312_integ buildspec: codebuild/py312/integ.yml + env: + image: aws/codebuild/standard:7.0 - identifier: py312_examples buildspec: codebuild/py312/examples.yml + env: + image: aws/codebuild/standard:7.0 - identifier: py312_awses_latest buildspec: codebuild/py312/awses_local.yml + env: + image: aws/codebuild/standard:7.0 - identifier: code_coverage buildspec: codebuild/coverage/coverage.yml From dbba0878581ceb695e07a499a95817755b92900e Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 17:09:21 -0700 Subject: [PATCH 7/9] fix: try updating pyenv in CB --- codebuild/py312/awses_local.yml | 1 + codebuild/py312/examples.yml | 1 + codebuild/py312/integ.yml | 1 + 3 files changed, 3 insertions(+) diff --git a/codebuild/py312/awses_local.yml b/codebuild/py312/awses_local.yml index 291d091cb..f0959dbc3 100644 --- a/codebuild/py312/awses_local.yml +++ b/codebuild/py312/awses_local.yml @@ -20,6 +20,7 @@ phases: python: latest build: commands: + - cd /root/.pyenv/plugins/python-build/../.. && git pull && cd - - pyenv install 3.12.0 - pyenv local 3.12.0 - pip install "tox < 4.0" diff --git a/codebuild/py312/examples.yml b/codebuild/py312/examples.yml index 96bf33b38..aa3afd1c3 100644 --- a/codebuild/py312/examples.yml +++ b/codebuild/py312/examples.yml @@ -18,6 +18,7 @@ phases: python: latest build: commands: + - cd /root/.pyenv/plugins/python-build/../.. && git pull && cd - - pyenv install 3.12.0 - pyenv local 3.12.0 - pip install "tox < 4.0" diff --git a/codebuild/py312/integ.yml b/codebuild/py312/integ.yml index ec8b2a1b0..28126f931 100644 --- a/codebuild/py312/integ.yml +++ b/codebuild/py312/integ.yml @@ -18,6 +18,7 @@ phases: python: latest build: commands: + - cd /root/.pyenv/plugins/python-build/../.. && git pull && cd - - pyenv install 3.12.0 - pyenv local 3.12.0 - pip install "tox < 4.0" From 126a56837da941ad5a429cda89464434ab768020 Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 17:32:01 -0700 Subject: [PATCH 8/9] feat: optimize CB usage --- codebuild/py310/awses_local.yml | 4 +--- codebuild/py310/examples.yml | 4 +--- codebuild/py310/integ.yml | 4 +--- codebuild/py311/awses_local.yml | 4 +--- codebuild/py311/examples.yml | 4 +--- codebuild/py311/integ.yml | 4 +--- codebuild/py312/awses_local.yml | 1 + codebuild/py312/examples.yml | 1 + codebuild/py312/integ.yml | 1 + codebuild/py37/awses_local.yml | 4 +--- codebuild/py37/examples.yml | 4 +--- codebuild/py37/integ.yml | 4 +--- codebuild/py38/awses_local.yml | 4 +--- codebuild/py38/examples.yml | 4 +--- codebuild/py38/integ.yml | 4 +--- codebuild/py39/awses_1.7.1.yml | 4 +--- codebuild/py39/awses_2.0.0.yml | 4 +--- codebuild/py39/awses_latest.yml | 4 +--- codebuild/py39/examples.yml | 4 +--- codebuild/py39/integ.yml | 4 +--- 20 files changed, 20 insertions(+), 51 deletions(-) diff --git a/codebuild/py310/awses_local.yml b/codebuild/py310/awses_local.yml index beb967f47..df2fcf318 100644 --- a/codebuild/py310/awses_local.yml +++ b/codebuild/py310/awses_local.yml @@ -17,11 +17,9 @@ env: phases: install: runtime-versions: - python: latest + python: 3.10 build: commands: - - pyenv install 3.10.0 - - pyenv local 3.10.0 - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py310/examples.yml b/codebuild/py310/examples.yml index 4d64f5c6c..b495a327c 100644 --- a/codebuild/py310/examples.yml +++ b/codebuild/py310/examples.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.10 build: commands: - - pyenv install 3.10.0 - - pyenv local 3.10.0 - pip install "tox < 4.0" - tox diff --git a/codebuild/py310/integ.yml b/codebuild/py310/integ.yml index 1a2ca5022..6b557e709 100644 --- a/codebuild/py310/integ.yml +++ b/codebuild/py310/integ.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.10 build: commands: - - pyenv install 3.10.0 - - pyenv local 3.10.0 - pip install "tox < 4.0" - tox diff --git a/codebuild/py311/awses_local.yml b/codebuild/py311/awses_local.yml index fa153ea61..1b00712d5 100644 --- a/codebuild/py311/awses_local.yml +++ b/codebuild/py311/awses_local.yml @@ -17,11 +17,9 @@ env: phases: install: runtime-versions: - python: latest + python: 3.11 build: commands: - - pyenv install 3.11.0 - - pyenv local 3.11.0 - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py311/examples.yml b/codebuild/py311/examples.yml index 8c33bd81e..6efcd26d2 100644 --- a/codebuild/py311/examples.yml +++ b/codebuild/py311/examples.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.11 build: commands: - - pyenv install 3.11.0 - - pyenv local 3.11.0 - pip install "tox < 4.0" - tox diff --git a/codebuild/py311/integ.yml b/codebuild/py311/integ.yml index 9629e1db9..9606bee12 100644 --- a/codebuild/py311/integ.yml +++ b/codebuild/py311/integ.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.11 build: commands: - - pyenv install 3.11.0 - - pyenv local 3.11.0 - pip install "tox < 4.0" - tox diff --git a/codebuild/py312/awses_local.yml b/codebuild/py312/awses_local.yml index f0959dbc3..b1a799a97 100644 --- a/codebuild/py312/awses_local.yml +++ b/codebuild/py312/awses_local.yml @@ -23,6 +23,7 @@ phases: - cd /root/.pyenv/plugins/python-build/../.. && git pull && cd - - pyenv install 3.12.0 - pyenv local 3.12.0 + - pip install --upgrade pip - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py312/examples.yml b/codebuild/py312/examples.yml index aa3afd1c3..5441007fe 100644 --- a/codebuild/py312/examples.yml +++ b/codebuild/py312/examples.yml @@ -21,5 +21,6 @@ phases: - cd /root/.pyenv/plugins/python-build/../.. && git pull && cd - - pyenv install 3.12.0 - pyenv local 3.12.0 + - pip install --upgrade pip - pip install "tox < 4.0" - tox diff --git a/codebuild/py312/integ.yml b/codebuild/py312/integ.yml index 28126f931..a54a036b0 100644 --- a/codebuild/py312/integ.yml +++ b/codebuild/py312/integ.yml @@ -21,5 +21,6 @@ phases: - cd /root/.pyenv/plugins/python-build/../.. && git pull && cd - - pyenv install 3.12.0 - pyenv local 3.12.0 + - pip install --upgrade pip - pip install "tox < 4.0" - tox diff --git a/codebuild/py37/awses_local.yml b/codebuild/py37/awses_local.yml index c4265fc71..02dfe5d0b 100644 --- a/codebuild/py37/awses_local.yml +++ b/codebuild/py37/awses_local.yml @@ -17,11 +17,9 @@ env: phases: install: runtime-versions: - python: latest + python: 3.7 build: commands: - - pyenv install 3.7.12 - - pyenv local 3.7.12 - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py37/examples.yml b/codebuild/py37/examples.yml index 14b220524..0b240c768 100644 --- a/codebuild/py37/examples.yml +++ b/codebuild/py37/examples.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.7 build: commands: - - pyenv install 3.7.12 - - pyenv local 3.7.12 - pip install "tox < 4.0" - tox diff --git a/codebuild/py37/integ.yml b/codebuild/py37/integ.yml index 6306c20e2..b702d45cb 100644 --- a/codebuild/py37/integ.yml +++ b/codebuild/py37/integ.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.7 build: commands: - - pyenv install 3.7.12 - - pyenv local 3.7.12 - pip install "tox < 4.0" - tox diff --git a/codebuild/py38/awses_local.yml b/codebuild/py38/awses_local.yml index 936a9ca6c..9876de247 100644 --- a/codebuild/py38/awses_local.yml +++ b/codebuild/py38/awses_local.yml @@ -17,11 +17,9 @@ env: phases: install: runtime-versions: - python: latest + python: 3.8 build: commands: - - pyenv install 3.8.12 - - pyenv local 3.8.12 - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py38/examples.yml b/codebuild/py38/examples.yml index 221ad4f80..4dff71d65 100644 --- a/codebuild/py38/examples.yml +++ b/codebuild/py38/examples.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.8 build: commands: - - pyenv install 3.8.12 - - pyenv local 3.8.12 - pip install "tox < 4.0" - tox diff --git a/codebuild/py38/integ.yml b/codebuild/py38/integ.yml index 088a2c7ba..8b7acafe1 100644 --- a/codebuild/py38/integ.yml +++ b/codebuild/py38/integ.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.8 build: commands: - - pyenv install 3.8.12 - - pyenv local 3.8.12 - pip install "tox < 4.0" - tox diff --git a/codebuild/py39/awses_1.7.1.yml b/codebuild/py39/awses_1.7.1.yml index c61024409..22267ad8f 100644 --- a/codebuild/py39/awses_1.7.1.yml +++ b/codebuild/py39/awses_1.7.1.yml @@ -17,11 +17,9 @@ env: phases: install: runtime-versions: - python: latest + python: 3.9 build: commands: - - pyenv install 3.9.7 - - pyenv local 3.9.7 - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py39/awses_2.0.0.yml b/codebuild/py39/awses_2.0.0.yml index df6cd489c..d35e7e98c 100644 --- a/codebuild/py39/awses_2.0.0.yml +++ b/codebuild/py39/awses_2.0.0.yml @@ -17,11 +17,9 @@ env: phases: install: runtime-versions: - python: latest + python: 3.9 build: commands: - - pyenv install 3.9.7 - - pyenv local 3.9.7 - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py39/awses_latest.yml b/codebuild/py39/awses_latest.yml index 0675cbb0a..719ab2238 100644 --- a/codebuild/py39/awses_latest.yml +++ b/codebuild/py39/awses_latest.yml @@ -17,11 +17,9 @@ env: phases: install: runtime-versions: - python: latest + python: 3.9 build: commands: - - pyenv install 3.9.7 - - pyenv local 3.9.7 - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py39/examples.yml b/codebuild/py39/examples.yml index 6f07efcea..3d1399251 100644 --- a/codebuild/py39/examples.yml +++ b/codebuild/py39/examples.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.9 build: commands: - - pyenv install 3.9.7 - - pyenv local 3.9.7 - pip install "tox < 4.0" - tox diff --git a/codebuild/py39/integ.yml b/codebuild/py39/integ.yml index 1e9743e39..6dec85b07 100644 --- a/codebuild/py39/integ.yml +++ b/codebuild/py39/integ.yml @@ -15,10 +15,8 @@ env: phases: install: runtime-versions: - python: latest + python: 3.9 build: commands: - - pyenv install 3.9.7 - - pyenv local 3.9.7 - pip install "tox < 4.0" - tox From cbbc83fa0c498a9e43cb58dae7785d0970583671 Mon Sep 17 00:00:00 2001 From: texastony <5892063+texastony@users.noreply.github.com> Date: Mon, 30 Oct 2023 17:42:52 -0700 Subject: [PATCH 9/9] fix: Python 3.12 virtualenv does include setuptools --- codebuild/py312/awses_local.yml | 1 + codebuild/py312/examples.yml | 1 + codebuild/py312/integ.yml | 1 + 3 files changed, 3 insertions(+) diff --git a/codebuild/py312/awses_local.yml b/codebuild/py312/awses_local.yml index b1a799a97..50638c6e9 100644 --- a/codebuild/py312/awses_local.yml +++ b/codebuild/py312/awses_local.yml @@ -24,6 +24,7 @@ phases: - pyenv install 3.12.0 - pyenv local 3.12.0 - pip install --upgrade pip + - pip install setuptools - pip install "tox < 4.0" - cd test_vector_handlers - tox diff --git a/codebuild/py312/examples.yml b/codebuild/py312/examples.yml index 5441007fe..aee933e00 100644 --- a/codebuild/py312/examples.yml +++ b/codebuild/py312/examples.yml @@ -22,5 +22,6 @@ phases: - pyenv install 3.12.0 - pyenv local 3.12.0 - pip install --upgrade pip + - pip install setuptools - pip install "tox < 4.0" - tox diff --git a/codebuild/py312/integ.yml b/codebuild/py312/integ.yml index a54a036b0..156c185d9 100644 --- a/codebuild/py312/integ.yml +++ b/codebuild/py312/integ.yml @@ -22,5 +22,6 @@ phases: - pyenv install 3.12.0 - pyenv local 3.12.0 - pip install --upgrade pip + - pip install setuptools - pip install "tox < 4.0" - tox