From 387f4dd4bcbb74539345ecbaaa31c5635d9c6b11 Mon Sep 17 00:00:00 2001 From: Simon Willison Date: Sun, 21 Jun 2026 16:46:20 -0700 Subject: [PATCH] Try sqlite-utils 4.0rc1 in CI Also output current sqlite-utils version in pytest headers Refs https://github.com/simonw/sqlite-utils/issues/758 --- .github/workflows/test.yml | 7 +++++++ tests/conftest.py | 7 ++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a1b2e9d2..80416ec2 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -11,6 +11,10 @@ jobs: strategy: matrix: python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"] + sqlite-utils-version: [""] + include: + - python-version: "3.14" + sqlite-utils-version: "4.0rc1" steps: - uses: actions/checkout@v6 - name: Set up Python ${{ matrix.python-version }} @@ -26,6 +30,9 @@ jobs: - name: Install dependencies run: | pip install . --group dev + if [ -n "${{ matrix.sqlite-utils-version }}" ]; then + pip install sqlite-utils==${{ matrix.sqlite-utils-version }} + fi pip freeze - name: Run tests run: | diff --git a/tests/conftest.py b/tests/conftest.py index 55110a42..8860d54c 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,4 +1,5 @@ import httpx +import importlib.metadata import os import pathlib import pytest @@ -93,7 +94,11 @@ def pytest_report_header(config): conn = sqlite3.connect(":memory:") version = conn.execute("select sqlite_version()").fetchone()[0] conn.close() - headers = ["SQLite: {}".format(version)] + sqlite_utils_version = importlib.metadata.version("sqlite-utils") + headers = [ + "SQLite: {}".format(version), + "sqlite-utils: {}".format(sqlite_utils_version), + ] if config.getoption("--playwright"): try: browsers = config.getoption("--browser")