From 66f2c439db0d17ab04479e559fa5eed11ffd941c Mon Sep 17 00:00:00 2001 From: Frank Niessink Date: Tue, 30 Jul 2024 16:37:37 +0200 Subject: [PATCH] Update to Python 3.13. --- .circleci/config.yml | 2 +- .github/workflows/api_server.yml | 35 +++++++++--------- .../workflows/application-tests-quality.yml | 27 +++++++------- .github/workflows/application-tests.yml | 3 +- .github/workflows/collector.yml | 35 +++++++++--------- .github/workflows/documentation.yml | 37 +++++++++---------- .github/workflows/feature-tests-quality.yml | 27 +++++++------- .github/workflows/feature-tests.yml | 3 +- .github/workflows/notifier.yml | 35 +++++++++--------- .github/workflows/release-quality.yml | 27 +++++++------- .github/workflows/shared_code.yml | 35 +++++++++--------- .github/workflows/sonarcloud.yml | 2 +- .readthedocs.yaml | 12 +++--- components/api_server/Dockerfile | 4 +- components/api_server/pyproject.toml | 3 +- components/collector/Dockerfile | 4 +- components/collector/pyproject.toml | 3 +- components/notifier/Dockerfile | 4 +- components/notifier/pyproject.toml | 3 +- components/shared_code/pyproject.toml | 3 +- components/testdata/Dockerfile | 2 +- docs/pyproject.toml | 3 +- docs/src/development.md | 4 +- release/pyproject.toml | 3 +- sonar-project.properties | 2 +- tests/application_tests/pyproject.toml | 3 +- tests/feature_tests/pyproject.toml | 3 +- 27 files changed, 153 insertions(+), 171 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b49dd12b7d..a2c10ae715 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -91,7 +91,7 @@ jobs: export COMPOSE_FILE=docker/docker-compose.yml:docker/docker-compose.ci.yml docker compose build && docker compose up -d docker ps - docker run -it -w `pwd` -v `pwd`:`pwd` --network=container:docker-www-1 python:3.12.4-bookworm tests/application_tests/ci/test.sh + docker run -it -w `pwd` -v `pwd`:`pwd` --network=container:docker-www-1 python:3.13.0rc1-bookworm tests/application_tests/ci/test.sh docker ps docker compose logs > build/containers.log - run: diff --git a/.github/workflows/api_server.yml b/.github/workflows/api_server.yml index c2607b6b68..1108d62a59 100644 --- a/.github/workflows/api_server.yml +++ b/.github/workflows/api_server.yml @@ -4,24 +4,23 @@ on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4.1.7 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Install dependencies - run: | - cd components/api_server - ci/pip-install.sh - - name: Test - run: | - cd components/api_server - ci/unittest.sh - - name: Quality - run: | - cd components/api_server - ci/quality.sh + - uses: actions/checkout@v4.1.7 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13.0-rc.1" + - name: Install dependencies + run: | + cd components/api_server + ci/pip-install.sh + - name: Test + run: | + cd components/api_server + ci/unittest.sh + - name: Quality + run: | + cd components/api_server + ci/quality.sh diff --git a/.github/workflows/application-tests-quality.yml b/.github/workflows/application-tests-quality.yml index aeae88f33f..a32a3a4f6a 100644 --- a/.github/workflows/application-tests-quality.yml +++ b/.github/workflows/application-tests-quality.yml @@ -4,20 +4,19 @@ on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4.1.7 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Install dependencies - run: | - cd tests/application_tests - ci/pip-install.sh - - name: Quality - run: | - cd tests/application_tests - ci/quality.sh + - uses: actions/checkout@v4.1.7 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13.0-rc.1" + - name: Install dependencies + run: | + cd tests/application_tests + ci/pip-install.sh + - name: Quality + run: | + cd tests/application_tests + ci/quality.sh diff --git a/.github/workflows/application-tests.yml b/.github/workflows/application-tests.yml index dff735e40c..58ba48694c 100644 --- a/.github/workflows/application-tests.yml +++ b/.github/workflows/application-tests.yml @@ -3,7 +3,6 @@ name: Application tests on: [push] jobs: - build: runs-on: ubuntu-latest @@ -17,7 +16,7 @@ jobs: run: | mkdir -p build docker compose --file docker/docker-compose.yml --file docker/docker-compose.ci.yml --project-name quality-time up --build --detach --wait - docker run -t -w `pwd` -v `pwd`:`pwd` --network=container:quality-time-www-1 python:3.12.4-bookworm tests/application_tests/ci/test.sh + docker run -t -w `pwd` -v `pwd`:`pwd` --network=container:quality-time-www-1 python:3.13.0rc1-bookworm tests/application_tests/ci/test.sh - name: Save container logs if: always() run: | diff --git a/.github/workflows/collector.yml b/.github/workflows/collector.yml index b6955dbf56..ebf8e34c70 100644 --- a/.github/workflows/collector.yml +++ b/.github/workflows/collector.yml @@ -4,24 +4,23 @@ on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4.1.7 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Install dependencies - run: | - cd components/collector - ci/pip-install.sh - - name: Test - run: | - cd components/collector - ci/unittest.sh - - name: Quality - run: | - cd components/collector - ci/quality.sh + - uses: actions/checkout@v4.1.7 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13.0-rc.1" + - name: Install dependencies + run: | + cd components/collector + ci/pip-install.sh + - name: Test + run: | + cd components/collector + ci/unittest.sh + - name: Quality + run: | + cd components/collector + ci/quality.sh diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 925e5b5488..dd26339e7b 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -4,25 +4,24 @@ on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4.1.7 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Install dependencies - run: | - cd docs - ci/pip-install.sh - npm install --ignore-scripts - - name: Test - run: | - cd docs - ci/unittest.sh - - name: Quality - run: | - cd docs - ci/quality.sh + - uses: actions/checkout@v4.1.7 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13.0-rc.1" + - name: Install dependencies + run: | + cd docs + ci/pip-install.sh + npm install --ignore-scripts + - name: Test + run: | + cd docs + ci/unittest.sh + - name: Quality + run: | + cd docs + ci/quality.sh diff --git a/.github/workflows/feature-tests-quality.yml b/.github/workflows/feature-tests-quality.yml index 4275036cb3..4b34a4ec79 100644 --- a/.github/workflows/feature-tests-quality.yml +++ b/.github/workflows/feature-tests-quality.yml @@ -4,20 +4,19 @@ on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4.1.7 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Install dependencies - run: | - cd tests/feature_tests - ci/pip-install.sh - - name: Quality - run: | - cd tests/feature_tests - ci/quality.sh + - uses: actions/checkout@v4.1.7 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13.0-rc.1" + - name: Install dependencies + run: | + cd tests/feature_tests + ci/pip-install.sh + - name: Quality + run: | + cd tests/feature_tests + ci/quality.sh diff --git a/.github/workflows/feature-tests.yml b/.github/workflows/feature-tests.yml index e3559e2a13..aba22f9f1f 100644 --- a/.github/workflows/feature-tests.yml +++ b/.github/workflows/feature-tests.yml @@ -3,7 +3,6 @@ name: Feature tests on: [push] jobs: - build: runs-on: ubuntu-latest @@ -12,7 +11,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v5 with: - python-version: '3.12' + python-version: "3.13.0-rc.1" - name: Run feature tests run: ./tests/feature_tests/ci/test.sh - name: Upload artifacts diff --git a/.github/workflows/notifier.yml b/.github/workflows/notifier.yml index 5a566bd133..b337a8e359 100644 --- a/.github/workflows/notifier.yml +++ b/.github/workflows/notifier.yml @@ -4,24 +4,23 @@ on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4.1.7 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Install dependencies - run: | - cd components/notifier - ci/pip-install.sh - - name: Test - run: | - cd components/notifier - ci/unittest.sh - - name: Quality - run: | - cd components/notifier - ci/quality.sh + - uses: actions/checkout@v4.1.7 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13.0-rc.1" + - name: Install dependencies + run: | + cd components/notifier + ci/pip-install.sh + - name: Test + run: | + cd components/notifier + ci/unittest.sh + - name: Quality + run: | + cd components/notifier + ci/quality.sh diff --git a/.github/workflows/release-quality.yml b/.github/workflows/release-quality.yml index fd93ec8fb2..e01e0be8eb 100644 --- a/.github/workflows/release-quality.yml +++ b/.github/workflows/release-quality.yml @@ -4,20 +4,19 @@ on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4.1.7 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Install dependencies - run: | - cd release - ci/pip-install.sh - - name: Quality - run: | - cd release - ci/quality.sh + - uses: actions/checkout@v4.1.7 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13.0-rc.1" + - name: Install dependencies + run: | + cd release + ci/pip-install.sh + - name: Quality + run: | + cd release + ci/quality.sh diff --git a/.github/workflows/shared_code.yml b/.github/workflows/shared_code.yml index 584896498c..a289a4cb89 100644 --- a/.github/workflows/shared_code.yml +++ b/.github/workflows/shared_code.yml @@ -4,24 +4,23 @@ on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4.1.7 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Install dependencies - run: | - cd components/shared_code - ci/pip-install.sh - - name: Test - run: | - cd components/shared_code - ci/unittest.sh - - name: Quality - run: | - cd components/shared_code - ci/quality.sh + - uses: actions/checkout@v4.1.7 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13.0-rc.1" + - name: Install dependencies + run: | + cd components/shared_code + ci/pip-install.sh + - name: Test + run: | + cd components/shared_code + ci/unittest.sh + - name: Quality + run: | + cd components/shared_code + ci/quality.sh diff --git a/.github/workflows/sonarcloud.yml b/.github/workflows/sonarcloud.yml index da833eac8e..be2aa7606e 100644 --- a/.github/workflows/sonarcloud.yml +++ b/.github/workflows/sonarcloud.yml @@ -21,7 +21,7 @@ jobs: uses: actions/setup-python@v5 if: env.SONAR_TOKEN != null with: - python-version: "3.12" + python-version: "3.13.0-rc.1" - name: Set up Node uses: actions/setup-node@v4.0.3 if: env.SONAR_TOKEN != null diff --git a/.readthedocs.yaml b/.readthedocs.yaml index 7298dcf808..8e8c1e13ec 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -9,20 +9,20 @@ version: 2 build: os: ubuntu-22.04 tools: - python: "3.12" + python: "3.13" apt_packages: - graphviz # Build documentation in the docs/ directory with Sphinx sphinx: - configuration: docs/src/conf.py + configuration: docs/src/conf.py # Additional formats to build formats: - - pdf + - pdf # Requirements to install python: - install: - - requirements: docs/requirements/requirements-dev.txt - - requirements: docs/requirements/requirements-internal-rtd.txt + install: + - requirements: docs/requirements/requirements-dev.txt + - requirements: docs/requirements/requirements-internal-rtd.txt diff --git a/components/api_server/Dockerfile b/components/api_server/Dockerfile index bb7efcd597..8fae30e49e 100644 --- a/components/api_server/Dockerfile +++ b/components/api_server/Dockerfile @@ -1,4 +1,4 @@ -FROM python:3.12.4-alpine3.20 AS compile-image +FROM python:3.13.0rc1-alpine3.20 AS compile-image WORKDIR /home/server @@ -12,7 +12,7 @@ COPY api_server/requirements/requirements-internal.txt /requirements-internal.tx COPY shared_code /home/shared_code/ RUN pip install --no-cache-dir --use-pep517 -r /requirements-internal.txt -FROM python:3.12.4-alpine3.20 +FROM python:3.13.0rc1-alpine3.20 LABEL maintainer="Quality-time team " LABEL description="Quality-time API-server" diff --git a/components/api_server/pyproject.toml b/components/api_server/pyproject.toml index c066ab5199..25bdc88ba6 100644 --- a/components/api_server/pyproject.toml +++ b/components/api_server/pyproject.toml @@ -1,10 +1,9 @@ [project] name = "api-server" version = "5.15.0" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", ] dependencies = [ "bottle==0.12.25", diff --git a/components/collector/Dockerfile b/components/collector/Dockerfile index d4847acb44..23e3f40de5 100644 --- a/components/collector/Dockerfile +++ b/components/collector/Dockerfile @@ -1,4 +1,4 @@ -FROM python:3.12.4-alpine3.20 AS compile-image +FROM python:3.13.0rc1-alpine3.20 AS compile-image WORKDIR /home/collector @@ -12,7 +12,7 @@ COPY shared_code /home/shared_code/ COPY collector/requirements/requirements-internal.txt /requirements-internal.txt RUN pip install --no-cache-dir --use-pep517 -r /requirements-internal.txt -FROM python:3.12.4-alpine3.20 +FROM python:3.13.0rc1-alpine3.20 LABEL maintainer="Quality-time team " LABEL description="Quality-time collector" diff --git a/components/collector/pyproject.toml b/components/collector/pyproject.toml index 928fc5b738..01dc59c815 100644 --- a/components/collector/pyproject.toml +++ b/components/collector/pyproject.toml @@ -1,10 +1,9 @@ [project] name = "collector" version = "5.15.0" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", ] dependencies = [ "aiogqlc==5.1.0", diff --git a/components/notifier/Dockerfile b/components/notifier/Dockerfile index a197062849..ff47d954c1 100644 --- a/components/notifier/Dockerfile +++ b/components/notifier/Dockerfile @@ -1,4 +1,4 @@ -FROM python:3.12.4-alpine3.20 AS compile-image +FROM python:3.13.0rc1-alpine3.20 AS compile-image WORKDIR /home/notifier @@ -12,7 +12,7 @@ COPY shared_code /home/shared_code/ COPY notifier/requirements/requirements-internal.txt /requirements-internal.txt RUN pip install --no-cache-dir --use-pep517 -r /requirements-internal.txt -FROM python:3.12.4-alpine3.20 +FROM python:3.13.0rc1-alpine3.20 LABEL maintainer="Quality-time team " LABEL description="Quality-time notifier" diff --git a/components/notifier/pyproject.toml b/components/notifier/pyproject.toml index 0d2c6c668c..3acaee158f 100644 --- a/components/notifier/pyproject.toml +++ b/components/notifier/pyproject.toml @@ -1,10 +1,9 @@ [project] name = "notifier" version = "5.15.0" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", ] dependencies = [ "aiohttp==3.10.5", diff --git a/components/shared_code/pyproject.toml b/components/shared_code/pyproject.toml index 9f192d5ade..8b0a2fbdc5 100644 --- a/components/shared_code/pyproject.toml +++ b/components/shared_code/pyproject.toml @@ -1,10 +1,9 @@ [project] name = "shared-code" version = "5.15.0" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", ] dependencies = [ "bottle==0.12.25", diff --git a/components/testdata/Dockerfile b/components/testdata/Dockerfile index 1d2b0f8ebb..6baf0573fa 100644 --- a/components/testdata/Dockerfile +++ b/components/testdata/Dockerfile @@ -1,4 +1,4 @@ -FROM python:3.12.4-alpine3.20 +FROM python:3.13.0rc1-alpine3.20 LABEL maintainer="Quality-time team " LABEL description="Quality-time testdata" diff --git a/docs/pyproject.toml b/docs/pyproject.toml index ab04edf5bf..7f55d11727 100644 --- a/docs/pyproject.toml +++ b/docs/pyproject.toml @@ -1,10 +1,9 @@ [project] name = "docs" version = "5.15.0" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", ] dependencies = [ "furo==2023.9.10", diff --git a/docs/src/development.md b/docs/src/development.md index 9ac4dd4156..655a37f438 100644 --- a/docs/src/development.md +++ b/docs/src/development.md @@ -12,7 +12,7 @@ If you want to get *Quality-time* up and running quickly, for example for a demo #### Install prerequisites -Prerequisites are Docker and Git for both scenario's. For scenario 2 you also need Python 3.12 and a recent version of Node.js (we currently use Node.js v20). +Prerequisites are Docker and Git for both scenario's. For scenario 2 you also need Python 3.13 and a recent version of Node.js (we currently use Node.js v20). Clone this repository: @@ -429,7 +429,7 @@ The application tests in theory test all components through the frontend, but un ```console docker-compose up -d -docker run -it -w `pwd` -v `pwd`:`pwd` --network=container:qualitytime_www_1 python:3.12.4-bookworm tests/application_tests/ci/test.sh +docker run -it -w `pwd` -v `pwd`:`pwd` --network=container:qualitytime_www_1 python:3.13.0rc1-bookworm tests/application_tests/ci/test.sh ``` ## Documentation and changelog diff --git a/release/pyproject.toml b/release/pyproject.toml index 41b0e11ec5..963afc32ca 100644 --- a/release/pyproject.toml +++ b/release/pyproject.toml @@ -1,10 +1,9 @@ [project] name = "release" version = "5.15.0" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", ] dependencies = [ "gitpython==3.1.43", diff --git a/sonar-project.properties b/sonar-project.properties index af73ddabcd..d4c94742f2 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -7,7 +7,7 @@ sonar.projectVersion=5.15.0 # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # This property is optional if sonar.modules is set. sonar.sources=components/collector,components/notifier,components/api_server,components/shared_code,components/frontend -sonar.python.version=3.12 +sonar.python.version=3.13 # Exclude third party software and generated code from analysis sonar.exclusions=**/coverage/**/*,**/build/**/*,**/node_modules/**/* diff --git a/tests/application_tests/pyproject.toml b/tests/application_tests/pyproject.toml index b8d7799c06..0f9355c8c5 100644 --- a/tests/application_tests/pyproject.toml +++ b/tests/application_tests/pyproject.toml @@ -1,10 +1,9 @@ [project] name = "application-tests" version = "5.15.0" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", ] dependencies = [ "axe-selenium-python==2.1.6", diff --git a/tests/feature_tests/pyproject.toml b/tests/feature_tests/pyproject.toml index f5818c1876..25b2c1f497 100644 --- a/tests/feature_tests/pyproject.toml +++ b/tests/feature_tests/pyproject.toml @@ -1,10 +1,9 @@ [project] name = "feature-tests" version = "5.15.0" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", ] dependencies = [ "asserts==0.13.1",