From 8388863c8aeed109bc87b1667cd981d79d1538e9 Mon Sep 17 00:00:00 2001 From: Logan Wang Date: Sat, 22 Nov 2025 23:28:24 +1100 Subject: [PATCH] Expand test coverage on python 313/314 and pg --- .github/workflows/linux.yaml | 4 ++-- .github/workflows/macos.yaml | 2 ++ docs/installation.rst | 4 ++-- docs/testing.rst | 2 +- setup.py | 2 ++ tox.ini | 32 ++++++++++++++++++++++++++++++-- 6 files changed, 39 insertions(+), 7 deletions(-) diff --git a/.github/workflows/linux.yaml b/.github/workflows/linux.yaml index ac09ce5..9067be9 100644 --- a/.github/workflows/linux.yaml +++ b/.github/workflows/linux.yaml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - py: ['3.8', '3.9', '3.10', '3.11', '3.12'] + py: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13', '3.14'] steps: - name: checkout uses: actions/checkout@v4 @@ -30,7 +30,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - pg: [12, 13, 14, 15] + pg: [12, 13, 14, 15, 16, 17, 18] steps: - name: checkout uses: actions/checkout@v4 diff --git a/.github/workflows/macos.yaml b/.github/workflows/macos.yaml index 2504d68..94bd7b8 100644 --- a/.github/workflows/macos.yaml +++ b/.github/workflows/macos.yaml @@ -17,6 +17,8 @@ jobs: - postgresql@14 - postgresql@15 - postgresql@16 + - postgresql@17 + - postgresql@18 runs-on: macos-14 steps: - name: os info diff --git a/docs/installation.rst b/docs/installation.rst index a8da7aa..ccc2aa1 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -19,8 +19,8 @@ approach is to create a psycopg2 wheel for distribution to production machines Compatibility """"""""""""" -pgcopy is tested with Python versions 3.8 -- 3.12 and -PostgreSQL versions 12 -- 16 +pgcopy is tested with Python versions 3.8 -- 3.14 and +PostgreSQL versions 12 -- 18 .. note:: diff --git a/docs/testing.rst b/docs/testing.rst index c3c3ca4..19841ee 100644 --- a/docs/testing.rst +++ b/docs/testing.rst @@ -16,7 +16,7 @@ database: For more thorough testing, tox_ with tox-docker_ will run tests on python -versions 3.8 -- 3.12 and postgresql versions 12 -- 16:: +versions 3.8 -- 3.14 and postgresql versions 12 -- 18:: $ tox diff --git a/setup.py b/setup.py index 78cfb49..9095c61 100644 --- a/setup.py +++ b/setup.py @@ -45,6 +45,8 @@ def get_version(package_name, default="0.1"): "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", + "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", "Development Status :: 5 - Production/Stable", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", diff --git a/tox.ini b/tox.ini index 6b42c50..0aa7d13 100644 --- a/tox.ini +++ b/tox.ini @@ -1,7 +1,7 @@ [tox] envlist = - py{38,39,310,311,312} - py310-pg{12,13,14,15} + py{38,39,310,311,312,313,314} + py310-pg{12,13,14,15,16,17,18} vector psycopg28 [testenv] @@ -24,6 +24,12 @@ docker = pg13 docker = pg14 [testenv:py310-pg15] docker = pg15 +[testenv:py310-pg16] +docker = pg16 +[testenv:py310-pg17] +docker = pg17 +[testenv:py310-pg18] +docker = pg18 [testenv:vector] base_python = python3.10 docker = pgvector @@ -97,6 +103,28 @@ healthcheck_timeout = 1 healthcheck_retries = 30 healthcheck_interval = 1 healthcheck_start_period = 1 +[docker:pg17] +image = postgres:17 +environment= + POSTGRES_HOST_AUTH_METHOD=trust +healthcheck_cmd = psql --user=postgres \ + --host=127.0.0.1 --quiet --no-align --tuples-only \ + -1 --command="SELECT 1" +healthcheck_timeout = 1 +healthcheck_retries = 30 +healthcheck_interval = 1 +healthcheck_start_period = 1 +[docker:pg18] +image = postgres:18 +environment= + POSTGRES_HOST_AUTH_METHOD=trust +healthcheck_cmd = psql --user=postgres \ + --host=127.0.0.1 --quiet --no-align --tuples-only \ + -1 --command="SELECT 1" +healthcheck_timeout = 1 +healthcheck_retries = 30 +healthcheck_interval = 1 +healthcheck_start_period = 1 [docker:pgvector] image = pgvector/pgvector:pg16 environment=