From d5701051c9eeeca318c0ca378df6b285f87e92fd Mon Sep 17 00:00:00 2001 From: Apostolis Bessas Date: Thu, 29 May 2025 08:29:54 +0300 Subject: [PATCH 1/4] Update versions used in CI Ubuntu 20.04 and Python 3.8 have reached EOL already. --- .github/workflows/release.yml | 8 ++++---- .github/workflows/test.yaml | 8 ++++---- Dockerfile | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f453e064..a947675a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -4,12 +4,12 @@ on: workflow_dispatch: inputs: requested_release_tag: - description: 'The tag to use for this release (e.g., `v2.3.0`)' + description: "The tag to use for this release (e.g., `v2.3.0`)" required: true jobs: build_and_upload: - runs-on: 'ubuntu-20.04' + runs-on: "ubuntu-24.04" environment: production permissions: # id-token for the trusted publisher setup @@ -22,7 +22,7 @@ jobs: - uses: actions/setup-python@v2 name: Install Python with: - python-version: 3.8 + python-version: 3.12 - run: | pip install packaging @@ -80,4 +80,4 @@ jobs: run: | python setup.py sdist - name: Upload to PyPI - uses: closeio/gh-action-pypi-publish@ec4db0b4ddc65acdf4bff5fa45ac92d78b56bdf0 # v1.9 + uses: closeio/gh-action-pypi-publish@ec4db0b4ddc65acdf4bff5fa45ac92d78b56bdf0 # v1.9 diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index dd5fa4fa..0c2297c1 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -11,9 +11,9 @@ jobs: lint: strategy: matrix: - python-version: [ '3.8', '3.9', '3.10', '3.11' ] + python-version: ["3.9", "3.10", "3.11", "3.12"] name: Lint ${{ matrix.python-version }} - runs-on: 'ubuntu-20.04' + runs-on: "ubuntu-24.04" container: python:${{ matrix.python-version }} steps: - name: Checkout code @@ -28,8 +28,8 @@ jobs: test: strategy: matrix: - python-version: ['3.8', '3.9', '3.10', '3.11'] - os: ['ubuntu-20.04'] + python-version: ["3.9", "3.10", "3.11", "3.12"] + os: ["ubuntu-24.04"] redis-version: [4, 5, "6.2.6", "7.0.9"] redis-py-version: [3.3.0, 4.6.0] # Do not cancel any jobs when a single job fails diff --git a/Dockerfile b/Dockerfile index 5b08240b..3fe061c5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM circleci/python:3.8 +FROM python:3.12 WORKDIR /src COPY requirements.txt . From d4f3770dff6b7bc4d80e3f60f7e60a8b02244de7 Mon Sep 17 00:00:00 2001 From: Apostolis Bessas Date: Thu, 29 May 2025 09:33:20 +0300 Subject: [PATCH 2/4] Switch to ruff linter from lintlizard The latter is unmaintained and currently incompatible with python 3.12. --- .github/workflows/test.yaml | 2 +- requirements-lint.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 0c2297c1..223028cb 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -22,7 +22,7 @@ jobs: - name: Lint code run: | pip install -c requirements.txt -r requirements-lint.txt - lintlizard --ci + ruff check tasktiger tests # Run tests test: diff --git a/requirements-lint.txt b/requirements-lint.txt index b49ffbc6..345a13cf 100644 --- a/requirements-lint.txt +++ b/requirements-lint.txt @@ -1,2 +1,2 @@ -lintlizard==0.26.0 types-redis +ruff==0.11.11 From 73dba47235c78cbe7554c0e7a34b93f158d500e3 Mon Sep 17 00:00:00 2001 From: Apostolis Bessas Date: Thu, 29 May 2025 11:01:52 +0300 Subject: [PATCH 3/4] Upgrade the redis dependency --- .github/workflows/test.yaml | 2 +- requirements.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 223028cb..8cc8db90 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -31,7 +31,7 @@ jobs: python-version: ["3.9", "3.10", "3.11", "3.12"] os: ["ubuntu-24.04"] redis-version: [4, 5, "6.2.6", "7.0.9"] - redis-py-version: [3.3.0, 4.6.0] + redis-py-version: [6.1.0] # Do not cancel any jobs when a single job fails fail-fast: false name: Python ${{ matrix.python-version }} on ${{ matrix.os }} with Redis ${{ matrix.redis-version }} and redis-py==${{ matrix.redis-py-version }} diff --git a/requirements.txt b/requirements.txt index cd109265..d0c4fe88 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,4 +1,4 @@ click==8.1.7 -redis==4.5.2 +redis==6.1.0 structlog==24.1.0 croniter From 032519dd67f9fcedff67f492fe143e326b4372b5 Mon Sep 17 00:00:00 2001 From: Apostolis Bessas Date: Thu, 29 May 2025 11:10:43 +0300 Subject: [PATCH 4/4] Modernize docker-compose file Make sure the 6379 port is published locally as well. --- docker-compose.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 05ac0f48..db6d0e66 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,9 +1,8 @@ -version: "3.7" services: redis: image: redis:7.0.9 - expose: - - 6379 + ports: + - 127.0.0.1:6379:6379 tasktiger: build: context: .