From 87b7497ad141da03668cddbedc2a0bb612b10ad8 Mon Sep 17 00:00:00 2001 From: Jonathan Ballet Date: Mon, 26 Aug 2024 11:18:19 +0200 Subject: [PATCH] python: test with more modern versions Python 3.12 has been released in October 2023, it should be tested in the CI. Python 3.7 is not maintained anymore, removing it from the minimum required version in `pyproject.toml` files. --- .github/workflows/samples-python-fastapi-server.yaml | 2 +- .github/workflows/samples-python-petstore.yaml | 1 + .../workflows/samples-python-pydantic-v1-client-echo-api.yaml | 1 + .github/workflows/samples-python-pydantic-v1-petstore.yaml | 1 + .github/workflows/samples-python-server.yaml | 2 +- .../pyproject.toml | 4 ++-- samples/client/echo_api/python-pydantic-v1/pyproject.toml | 2 +- samples/client/echo_api/python/pyproject.toml | 4 ++-- .../openapi3/client/petstore/python-aiohttp/pyproject.toml | 4 ++-- .../client/petstore/python-pydantic-v1-aiohttp/pyproject.toml | 2 +- .../client/petstore/python-pydantic-v1/pyproject.toml | 2 +- samples/openapi3/client/petstore/python/pyproject.toml | 4 ++-- 12 files changed, 16 insertions(+), 13 deletions(-) diff --git a/.github/workflows/samples-python-fastapi-server.yaml b/.github/workflows/samples-python-fastapi-server.yaml index 052c3dfdd3cde..cc141570e2e98 100644 --- a/.github/workflows/samples-python-fastapi-server.yaml +++ b/.github/workflows/samples-python-fastapi-server.yaml @@ -21,7 +21,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 with: - python-version: '3.9' + python-version: '3.12' - name: Install dependencies working-directory: ${{ matrix.sample }} run: | diff --git a/.github/workflows/samples-python-petstore.yaml b/.github/workflows/samples-python-petstore.yaml index 118c91f84f2da..1d7ad5817fda0 100644 --- a/.github/workflows/samples-python-petstore.yaml +++ b/.github/workflows/samples-python-petstore.yaml @@ -19,6 +19,7 @@ jobs: - "3.9" - "3.10" - "3.11" + - "3.12" sample: - samples/openapi3/client/petstore/python-aiohttp - samples/openapi3/client/petstore/python diff --git a/.github/workflows/samples-python-pydantic-v1-client-echo-api.yaml b/.github/workflows/samples-python-pydantic-v1-client-echo-api.yaml index 6aa3bab3b3967..c58a74756d4ff 100644 --- a/.github/workflows/samples-python-pydantic-v1-client-echo-api.yaml +++ b/.github/workflows/samples-python-pydantic-v1-client-echo-api.yaml @@ -22,6 +22,7 @@ jobs: - "3.9" - "3.10" - "3.11" + - "3.12" steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 diff --git a/.github/workflows/samples-python-pydantic-v1-petstore.yaml b/.github/workflows/samples-python-pydantic-v1-petstore.yaml index 17969c9fc971b..663df4ce1f36e 100644 --- a/.github/workflows/samples-python-pydantic-v1-petstore.yaml +++ b/.github/workflows/samples-python-pydantic-v1-petstore.yaml @@ -19,6 +19,7 @@ jobs: - "3.9" - "3.10" - "3.11" + - "3.12" sample: - samples/openapi3/client/petstore/python-pydantic-v1-aiohttp - samples/openapi3/client/petstore/python-pydantic-v1 diff --git a/.github/workflows/samples-python-server.yaml b/.github/workflows/samples-python-server.yaml index 95ff583f0626f..2299213b7a60f 100644 --- a/.github/workflows/samples-python-server.yaml +++ b/.github/workflows/samples-python-server.yaml @@ -21,7 +21,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 with: - python-version: '3.7' + python-version: '3.12' - name: Test working-directory: ${{ matrix.sample }} run: make test-all diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/pyproject.toml b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/pyproject.toml index 0d00a14b8ebdf..8c08bb2a87c50 100644 --- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/pyproject.toml +++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/pyproject.toml @@ -10,7 +10,7 @@ keywords = ["OpenAPI", "OpenAPI-Generator", "Echo Server API"] include = ["openapi_client/py.typed"] [tool.poetry.dependencies] -python = "^3.7" +python = "^3.8" urllib3 = ">= 1.25.3" python-dateutil = ">=2.8.2" @@ -22,7 +22,7 @@ pytest = ">=7.2.1" tox = ">=3.9.0" flake8 = ">=4.0.0" types-python-dateutil = ">=2.8.19.14" -mypy = "1.4.1" +mypy = ">=1.4.1" [build-system] diff --git a/samples/client/echo_api/python-pydantic-v1/pyproject.toml b/samples/client/echo_api/python-pydantic-v1/pyproject.toml index caaec1be1b2ad..192e7c5483614 100644 --- a/samples/client/echo_api/python-pydantic-v1/pyproject.toml +++ b/samples/client/echo_api/python-pydantic-v1/pyproject.toml @@ -10,7 +10,7 @@ keywords = ["OpenAPI", "OpenAPI-Generator", "Echo Server API"] include = ["openapi_client/py.typed"] [tool.poetry.dependencies] -python = "^3.7" +python = "^3.8" urllib3 = ">= 1.25.3" python-dateutil = ">=2.8.2" diff --git a/samples/client/echo_api/python/pyproject.toml b/samples/client/echo_api/python/pyproject.toml index 0d00a14b8ebdf..8c08bb2a87c50 100644 --- a/samples/client/echo_api/python/pyproject.toml +++ b/samples/client/echo_api/python/pyproject.toml @@ -10,7 +10,7 @@ keywords = ["OpenAPI", "OpenAPI-Generator", "Echo Server API"] include = ["openapi_client/py.typed"] [tool.poetry.dependencies] -python = "^3.7" +python = "^3.8" urllib3 = ">= 1.25.3" python-dateutil = ">=2.8.2" @@ -22,7 +22,7 @@ pytest = ">=7.2.1" tox = ">=3.9.0" flake8 = ">=4.0.0" types-python-dateutil = ">=2.8.19.14" -mypy = "1.4.1" +mypy = ">=1.4.1" [build-system] diff --git a/samples/openapi3/client/petstore/python-aiohttp/pyproject.toml b/samples/openapi3/client/petstore/python-aiohttp/pyproject.toml index 1263eb6a35623..a4d39e452d011 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/pyproject.toml +++ b/samples/openapi3/client/petstore/python-aiohttp/pyproject.toml @@ -10,7 +10,7 @@ keywords = ["OpenAPI", "OpenAPI-Generator", "OpenAPI Petstore"] include = ["petstore_api/py.typed"] [tool.poetry.dependencies] -python = "^3.7" +python = "^3.8" urllib3 = ">= 1.25.3" python-dateutil = ">=2.8.2" @@ -26,7 +26,7 @@ pytest = ">=7.2.1" tox = ">=3.9.0" flake8 = ">=4.0.0" types-python-dateutil = ">=2.8.19.14" -mypy = "1.4.1" +mypy = ">=1.4.1" [build-system] diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/pyproject.toml b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/pyproject.toml index 8c0a993b36fa6..d65781e4a8a85 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/pyproject.toml +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/pyproject.toml @@ -10,7 +10,7 @@ keywords = ["OpenAPI", "OpenAPI-Generator", "OpenAPI Petstore"] include = ["petstore_api/py.typed"] [tool.poetry.dependencies] -python = "^3.7" +python = "^3.8" urllib3 = ">= 1.25.3" python-dateutil = ">=2.8.2" diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/pyproject.toml b/samples/openapi3/client/petstore/python-pydantic-v1/pyproject.toml index e3a7930993441..d67ebb4ca8e21 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1/pyproject.toml +++ b/samples/openapi3/client/petstore/python-pydantic-v1/pyproject.toml @@ -10,7 +10,7 @@ keywords = ["OpenAPI", "OpenAPI-Generator", "OpenAPI Petstore"] include = ["petstore_api/py.typed"] [tool.poetry.dependencies] -python = "^3.7" +python = "^3.8" urllib3 = ">= 1.25.3" python-dateutil = ">=2.8.2" diff --git a/samples/openapi3/client/petstore/python/pyproject.toml b/samples/openapi3/client/petstore/python/pyproject.toml index e416a2dcbdab5..88cf1c3a736e2 100644 --- a/samples/openapi3/client/petstore/python/pyproject.toml +++ b/samples/openapi3/client/petstore/python/pyproject.toml @@ -10,7 +10,7 @@ keywords = ["OpenAPI", "OpenAPI-Generator", "OpenAPI Petstore"] include = ["petstore_api/py.typed"] [tool.poetry.dependencies] -python = "^3.7" +python = "^3.8" urllib3 = ">= 1.25.3" python-dateutil = ">=2.8.2" @@ -24,7 +24,7 @@ pytest = ">=7.2.1" tox = ">=3.9.0" flake8 = ">=4.0.0" types-python-dateutil = ">=2.8.19.14" -mypy = "1.4.1" +mypy = ">=1.4.1" [build-system]