Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ credential at a path with an exact historical exception).

## `tests`

Matrix Python 3.11 and 3.12. Each leg runs `sync` and `test`, the full suite
Matrix Python 3.12, 3.13 and 3.14. Each leg runs `sync` and `test`, the full suite
with the 90% coverage floor. This is the only work duplicated per version.

## `gnn conformance (pinned)`
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,14 @@ permissions:
jobs:
quality:
timeout-minutes: 60
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
env:
BIOFIRM_PYTHON: "3.12"
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0
- uses: ActiveInferenceInstitute/.github/.github/actions/setup-python-uv@7159e67315330aac8e414aebae0ad1e999a41448 # pinned composite action
- uses: ActiveInferenceInstitute/.github/.github/actions/setup-python-uv@7159e67315330aac8e414aebae0ad1e999a41448 # untagged; .github main 2026-11-07 (PR #2)
with:
python-version: "3.12"
- name: Lock the environment
Expand Down Expand Up @@ -55,16 +55,16 @@ jobs:

tests:
timeout-minutes: 60
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12"]
python-version: ["3.12", "3.13", "3.14"]
env:
BIOFIRM_PYTHON: ${{ matrix.python-version }}
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: ActiveInferenceInstitute/.github/.github/actions/setup-python-uv@7159e67315330aac8e414aebae0ad1e999a41448 # pinned composite action
- uses: ActiveInferenceInstitute/.github/.github/actions/setup-python-uv@7159e67315330aac8e414aebae0ad1e999a41448 # untagged; .github main 2026-11-07 (PR #2)
with:
python-version: ${{ matrix.python-version }}
- name: Lock the environment
Expand All @@ -83,12 +83,12 @@ jobs:
# pin is checked here rather than assumed. The arm also writes the resolved
# parser version to the job summary.
name: gnn conformance (pinned)
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
env:
BIOFIRM_PYTHON: "3.12"
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: ActiveInferenceInstitute/.github/.github/actions/setup-python-uv@7159e67315330aac8e414aebae0ad1e999a41448 # pinned composite action
- uses: ActiveInferenceInstitute/.github/.github/actions/setup-python-uv@7159e67315330aac8e414aebae0ad1e999a41448 # untagged; .github main 2026-11-07 (PR #2)
with:
python-version: "3.12"
- name: Lock the environment
Expand Down
2 changes: 1 addition & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ without `tests/test_gnn.py`, which the `gnn` arm owns.
CI has three jobs. `quality` runs every interpreter-independent arm once on
Python 3.12, through the pinned composite action
`ActiveInferenceInstitute/.github/.github/actions/setup-python-uv@7159e67315330aac8e414aebae0ad1e999a41448`.
`tests` runs only `./run.sh test` on Python 3.11 and 3.12. The third job is
`tests` runs only `./run.sh test` on Python 3.12, 3.13 and 3.14. The third job is
keyed `gnn-conformance` with the exact display name
`gnn conformance (pinned)`: keep both, and keep [.github/GNN.md](.github/GNN.md)
as the pointer that records what it parses. It fetches the parser revision
Expand Down
12 changes: 6 additions & 6 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ marked as such; do not treat it as an implementation contract.

## Development setup

Biofirm supports Python 3.11 and 3.12. The committed `uv.lock` provides a
Biofirm supports Python 3.12 and newer (CI tests 3.12, 3.13 and 3.14). The committed `uv.lock` provides a
hash-locked environment:

```bash
Expand All @@ -28,9 +28,9 @@ python -m pip install -e ".[dev,analysis,visualization,documents]"
The runtime dependencies in `pyproject.toml` are exact pins, and the committed
`uv.lock` carries the hashes CI verifies with `uv lock --check`. The hashed
requirements export is derived from the lock at run time and is not committed.
Each runtime pin is the newest release
that satisfies every Python version this project supports (3.11 and 3.12)
together with `inferactively-pymdp`:
The pins below were qualified while Python 3.11 was supported. The 3.12 floor
now admits the newer `numpy` and `jax` releases; raising those pins is a
separate change that must pass `./run.sh gate` on every CI interpreter:

| Pin | Newest release | Why the pin stops there |
| --- | --- | --- |
Expand All @@ -48,8 +48,8 @@ uv export --all-extras --format requirements.txt --locked --no-emit-project \
--no-header --output-file /tmp/biofirm-requirements.lock
```

A pin that needs Python 3.12 cannot be adopted while 3.11 stays in the support
matrix, so `requires-python` moves before the runtime pins do.
A pin that needs a newer Python than the `requires-python` floor cannot be
adopted, so the floor moves before the runtime pins do.

## Checks

Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ business decisions.

## Install

Biofirm supports Python 3.11 and 3.12.
Biofirm supports Python 3.12 and newer; CI tests 3.12, 3.13 and 3.14.

```bash
python -m venv .venv
Expand All @@ -30,8 +30,8 @@ biofirm validate
```

For a hash-locked development environment, install `uv` and run
`uv sync --frozen --all-extras`; the committed `uv.lock` covers Python 3.11 and
3.12 with platform markers, and CI derives the hashed requirements export from
`uv sync --frozen --all-extras`; the committed `uv.lock` covers Python 3.12 and
newer with platform markers, and CI derives the hashed requirements export from
it at run time rather than reading a committed copy.

All offline commands use the packaged configuration unless `--config` is
Expand Down
10 changes: 5 additions & 5 deletions TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -210,11 +210,11 @@ before it is added.
criteria exists; the experimental `graph` interface already enforces the
`experimental` label and descriptive-only framing. Blocked on that dataset
(external); no owner in this repository.
- **BF-025 — Python 3.12-only floor.** `requires-python` is `>=3.11,<3.13`, so
the newest `numpy` 2.5.x and `jax` >= 0.11.0 stay excluded and BF-020's pins
are qualified rather than current. Adopting a 3.12-only floor would unlock
them and drop the 3.11 matrix leg. Blocked on a maintainer decision about
3.11 support; no external dependency.
- **BF-025 — Python 3.12-only floor.** Floor adopted 2026-11-16:
`requires-python` is `>=3.12` (the `<3.13` cap is dropped), the 3.11 matrix
leg is gone and CI tests 3.12, 3.13 and 3.14. Remaining: raise BF-020's
`numpy` (2.5.x) and `jax` (>= 0.11.0) pins, which the new floor admits, in a
separate change gated on every CI interpreter.

## Documentation review (2026-08-02)

Expand Down
59 changes: 30 additions & 29 deletions docs/gate.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@ document.
| `sync` | 0.0s | 0.0s | Lock the environment for the selected interpreter. |
| `deps` | 0.0s | 0.0s | Verify uv.lock matches the manifests. |
| `lint` | 1.0s | 0.1s | ruff check and ruff format --check on src tests tools. |
| `types` | 18.0s | 0.4s | Strict mypy on src/biofirm. |
| `test` | 74.0s | 29.4s | pytest with the 90% coverage floor (the full suite). |
| `test-fast` | 27.0s | 14.8s | pytest without coverage and without tests/test_gnn.py. |
| `links` | 3.0s | 0.3s | tools/verify_repository.py: relative links, source data, notebooks, credential patterns, required documents. |
| `docs` | 1.0s | 0.4s | biofirm validate and biofirm validate-data. |
| `bandit` | 2.0s | 0.4s | bandit on src and tools. |
| `build` | 28.0s | 3.3s | Build sdist and wheel into dist/. |
| `install` | 32.0s | 17.7s | Install dist/ into a clean venv and exercise the CLI outside the checkout, from the locked requirements. |
| `secret` | 54.0s | 9.3s | gitleaks scan with a synthetic negative control. |
| `gnn` | 5.0s | 0.9s | Pinned GNN conformance: the shared gnn.importers reader from the pinned revision, then tests/test_gnn.py. |
| `types` | 18.0s | 0.5s | Strict mypy on src/biofirm. |
| `test` | 74.0s | 22.7s | pytest with the 90% coverage floor (the full suite). |
| `test-fast` | 27.0s | 24.1s | pytest without coverage and without tests/test_gnn.py. |
| `links` | 3.0s | 0.5s | tools/verify_repository.py: relative links, source data, notebooks, credential patterns, required documents. |
| `docs` | 1.0s | 0.2s | biofirm validate and biofirm validate-data. |
| `bandit` | 2.0s | 0.7s | bandit on src and tools. |
| `build` | 28.0s | 6.5s | Build sdist and wheel into dist/. |
| `install` | 32.0s | 51.4s | Install dist/ into a clean venv and exercise the CLI outside the checkout, from the locked requirements. |
| `secret` | 54.0s | 15.4s | gitleaks scan with a synthetic negative control. |
| `gnn` | 5.0s | 7.7s | Pinned GNN conformance: the shared gnn.importers reader from the pinned revision, then tests/test_gnn.py. |

`gate` and `all` are meta arms and are not timed here: `gate` checks this
document and `all` runs the other arms in order. `test-fast` had no CI arm
Expand All @@ -48,14 +48,14 @@ once per command.

## Measured facts

- Full suite (`test`): **160 passed** with
- Full suite (`test`): **158 passed** with
**90.91% coverage** against the
90% floor.
- Fast arm (`test-fast`): **145 passed**.
It runs the same suite without coverage and without `tests/test_gnn.py`,
which the `gnn` arm owns.
- GNN conformance (`gnn`): **15 passed**.
The full suite reports 0 skips from
The full suite reports 2 skips from
`tests/test_gnn.py`. Its pinned-parser checks run when a prepared export is
available, otherwise they skip; the separate `gnn` arm requires that export.

Expand All @@ -73,9 +73,9 @@ CI compares them.
| --- | --- | --- |
| Host | `Darwin/arm64` | `Darwin/arm64` |
| Python | `3.12.16` | `3.12.16` |
| uv | `0.13.7` | `0.13.8` |
| `uv.lock` SHA-256 | not recorded | `e6d9bd0a85a6ba11b554b2f73032dd0ba58ec37e11e9f7a0c36a6f03b7ca6fff` |
| Recorded | `2026-11-12` | `2026-11-16T13:26:10-0800` |
| uv | `0.13.7` | `0.13.7` |
| `uv.lock` SHA-256 | not recorded | `0140008112bd2dba66d7eaa5d24b736deebc6147a0bb1101d096de0536047431` |
| Recorded | `2026-11-12` | `2026-11-16T17:42:44-0800` |

## Receipt

Expand All @@ -100,55 +100,56 @@ CI compares them.
},
{
"arm": "types",
"seconds": 0.4,
"seconds": 0.5,
"status": "passed"
},
{
"arm": "test",
"coverage_percent": 90.91,
"seconds": 29.4,
"seconds": 22.7,
"status": "passed",
"tests_passed": 160
"tests_passed": 158,
"tests_skipped": 2
},
{
"arm": "test-fast",
"seconds": 14.8,
"seconds": 24.1,
"status": "passed",
"tests_passed": 145
},
{
"arm": "links",
"seconds": 0.3,
"seconds": 0.5,
"status": "passed"
},
{
"arm": "docs",
"seconds": 0.4,
"seconds": 0.2,
"status": "passed"
},
{
"arm": "bandit",
"seconds": 0.4,
"seconds": 0.7,
"status": "passed"
},
{
"arm": "build",
"seconds": 3.3,
"seconds": 6.5,
"status": "passed"
},
{
"arm": "install",
"seconds": 17.7,
"seconds": 51.4,
"status": "passed"
},
{
"arm": "secret",
"seconds": 9.3,
"seconds": 15.4,
"status": "passed"
},
{
"arm": "gnn",
"seconds": 0.9,
"seconds": 7.7,
"status": "passed",
"tests_passed": 15
}
Expand Down Expand Up @@ -241,13 +242,13 @@ CI compares them.
},
"coverage_floor": 90,
"environment": {
"lock_sha256": "e6d9bd0a85a6ba11b554b2f73032dd0ba58ec37e11e9f7a0c36a6f03b7ca6fff",
"lock_sha256": "0140008112bd2dba66d7eaa5d24b736deebc6147a0bb1101d096de0536047431",
"machine": "arm64",
"python": "3.12.16",
"system": "Darwin",
"uv": "0.13.8"
"uv": "0.13.7"
},
"recorded": "2026-11-16T13:26:10-0800",
"recorded": "2026-11-16T17:42:44-0800",
"schema": "biofirm-gate-receipt/v1"
}
```
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ name = "biofirm"
dynamic = ["version"]
description = "Reproducible ecological control, bioregion research, and decision analysis."
readme = "README.md"
requires-python = ">=3.11,<3.13"
requires-python = ">=3.12"
license = { text = "MIT" }
authors = [{ name = "Active Inference Institute" }]
dependencies = [
Expand Down Expand Up @@ -59,7 +59,7 @@ packages = ["src/biofirm"]
path = "src/biofirm/_version.py"

[tool.ruff]
target-version = "py311"
target-version = "py312"
line-length = 100
src = ["src", "tests"]

Expand Down
Loading
Loading