From ba53fc441a01b5ce4d78edbbc211fce163776a28 Mon Sep 17 00:00:00 2001 From: Florent Pollet Date: Tue, 24 Nov 2026 09:50:47 -0500 Subject: [PATCH] Prepare meds-algorithm-template 0.4.0a3 Release the meds-algorithm 0.4.0a6 pins (#53), the temporal-leakage run_e2e documentation (#52) and the Read the Docs move (#49). Generated release workflows no longer fix Python 3.11: an algorithm requiring Python >= 3.12 (Curiosity) failed its first publish at uv sync. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01NJQdbHt5icm1CgFVHsHTNx --- README.md | 6 ++++-- RELEASING.md | 16 ++++++++-------- pyproject.toml | 2 +- template/.github/workflows/publish.yml | 4 ++-- uv.lock | 2 +- 5 files changed, 16 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index d807484..1691b5a 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ GitHub repository. It needs Git and network access; it does not bundle a second Install the pinned generator with: ```bash -uvx --from 'meds-algorithm-template==0.4.0a2' meds-algorithm-template ../my-meds-algorithm --trust +uvx --from 'meds-algorithm-template==0.4.0a3' meds-algorithm-template ../my-meds-algorithm --trust ``` Use `--defaults --data-file answers.yaml` for unattended generation. The answers file records the @@ -216,10 +216,12 @@ and [shared-package assessment](https://meds-algorithm.readthedocs.io/en/latest/ ## Changes -### Unreleased +### 0.4.0a3 (2026-11-24) - Generate projects using `meds-algorithm==0.4.0a6`, the first release with the temporal-leakage conformance (future-blind rerun and null-world chance test) that `tests/e2e.py` documents. +- Generated release workflows no longer fix Python 3.11: uv picks an interpreter that satisfies + `project.requires-python`, so algorithms that require a newer Python can publish. - Move the documentation site and prompt builder to `meds-algorithm` on Read the Docs. Generated-repository guides remain template-owned. - Require confirmation for material scientific ambiguities by default; offer explicitly enabled exploratory diff --git a/RELEASING.md b/RELEASING.md index eb0bc77..536c475 100644 --- a/RELEASING.md +++ b/RELEASING.md @@ -28,7 +28,7 @@ release the shared package first, then keep all dependency pins and install exam | `template/pyproject.toml.jinja`, project dependencies | Use `meds-algorithm[data]==0.4.0a6` | | `template/pyproject.toml.jinja`, test extra | Use `meds-algorithm[conformance]==0.4.0a6` | | `template/pyproject.toml.jinja`, orchestration extra | Use `meds-algorithm[orchestration]==0.4.0a6` | -| `README.md` | Document the shared PyPI version and update the generator install example to `0.4.0a2` | +| `README.md` | Document the shared PyPI version and update the generator install example to `0.4.0a3` | | `uv.lock` | Regenerate with `uv lock` | | `template/pyproject.toml.jinja`, Hatch metadata | Remove `allow-direct-references` after replacing all Git requirements | @@ -61,15 +61,15 @@ update URL without creating a real release tag or fetching a nonexistent release ## 2. Tag and rehearse on TestPyPI -Candidate generator version: **0.4.0a2**. Once the release changes are merged and CI passes: +Candidate generator version: **0.4.0a3**. Once the release changes are merged and CI passes: ```bash git switch main git pull --ff-only -git tag v0.4.0a2 -git push origin v0.4.0a2 +git tag v0.4.0a3 +git push origin v0.4.0a3 gh workflow run publish.yml --repo McDermottHealthAI/MEDS_algorithm_template \ - --ref v0.4.0a2 -f index=testpypi + --ref v0.4.0a3 -f index=testpypi gh run list --repo McDermottHealthAI/MEDS_algorithm_template --workflow publish.yml --limit 5 gh run watch RUN_ID --repo McDermottHealthAI/MEDS_algorithm_template --exit-status ``` @@ -85,7 +85,7 @@ check_env=$(mktemp -d) uv venv "$check_env" uv pip install --python "$check_env/bin/python" 'copier>=9.17.1,<10' 'pyyaml>=6' uv pip install --python "$check_env/bin/python" --no-deps \ - --index-url https://test.pypi.org/simple/ 'meds-algorithm-template==0.4.0a2' + --index-url https://test.pypi.org/simple/ 'meds-algorithm-template==0.4.0a3' "$check_env/bin/meds-algorithm-template" --version "$check_env/bin/meds-algorithm-template" "$check_env/generated" --defaults --trust uv pip install --python "$check_env/bin/python" "$check_env/generated[test]" @@ -102,12 +102,12 @@ After the TestPyPI rehearsal succeeds: ```bash gh workflow run publish.yml --repo McDermottHealthAI/MEDS_algorithm_template \ - --ref v0.4.0a2 -f index=pypi + --ref v0.4.0a3 -f index=pypi # Find and watch the new run, then approve the pypi environment deployment. # After it succeeds, verify in another clean environment: pypi_env=$(mktemp -d) uv venv "$pypi_env" -uv pip install --python "$pypi_env/bin/python" 'meds-algorithm-template==0.4.0a2' +uv pip install --python "$pypi_env/bin/python" 'meds-algorithm-template==0.4.0a3' "$pypi_env/bin/meds-algorithm-template" "$pypi_env/generated" --defaults --trust uv pip install --python "$pypi_env/bin/python" "$pypi_env/generated[test]" "$pypi_env/bin/minimal-meds-algorithm" profiles diff --git a/pyproject.toml b/pyproject.toml index 0c94fcd..0ed6550 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "meds-algorithm-template" -version = "0.4.0a2" +version = "0.4.0a3" description = "A minimal, contract-first Copier template for MEDS algorithm repositories." readme = "README.md" license = "MIT" diff --git a/template/.github/workflows/publish.yml b/template/.github/workflows/publish.yml index ce50c11..9a3312e 100644 --- a/template/.github/workflows/publish.yml +++ b/template/.github/workflows/publish.yml @@ -25,9 +25,9 @@ jobs: with: fetch-depth: 0 persist-credentials: false + # No fixed interpreter: uv picks one that satisfies project.requires-python, so raising the minimum (as + # algorithms that need Python 3.12 do) cannot break the release build. - uses: astral-sh/setup-uv@v6 - with: - python-version: "3.11" - name: Require a version tag on reviewed main history run: | test "$GITHUB_REF_TYPE" = tag diff --git a/uv.lock b/uv.lock index 1ff5d19..768dbb3 100644 --- a/uv.lock +++ b/uv.lock @@ -257,7 +257,7 @@ orchestration = [ [[package]] name = "meds-algorithm-template" -version = "0.4.0a2" +version = "0.4.0a3" source = { editable = "." } dependencies = [ { name = "copier" },