# DEPS — mgf-test-supervisor's bidirectional dependency manifest

> **§1** — what mgf-test-supervisor depends on. **§2** — who depends on
> mgf-test-supervisor. Knowing both directions makes deprecation,
> breaking-change blast-radius, and feature-prioritisation tractable.
>
> **Per standard DOC-16** (v2.12): every project ships a `DEPS.md`.
> Replaces the former `USERS.md`.

Last verified: 2026-05-28.

---

## §1 What mgf-test-supervisor depends on

`mgf-test-supervisor` is **stdlib-only at runtime** (per **TS-23**): the
supervisor MUST run even when the project-under-test's venv is
half-broken, so its runtime depends on **no third-party package and no
`mgf-*` sibling**. `pytest` is NOT a runtime dependency either — the
supervisor invokes the *consumer's* `pytest` as a subprocess.

| Dependency | Window | Why | Tier |
|---|---|---|---|
| *(none)* | — | stdlib-only at runtime (TS-23) | runtime |
| `mgf-common` | unpinned (`dev` extra) | **DEV dep only** — the `TestRecord` / `MARKER_TIER` / `SCHEMA_VERSION` alignment-contract; mirrored in `mgf.common.testing` for consumer-side parsing | `dev` |
| `pytest` | `>=8.0` | runs the supervisor's own self-hosted suite | `dev` |
| `pytest-asyncio` | `>=0.23` | async test support | `dev` |
| `pytest-timeout` | `>=2.3,<3` | per-test timeout backing the hung-test demo + own suite | `dev` |
| `pytest-cov` | `>=5.0` | coverage gate (TS-06) | `dev` |
| `ruff` | `>=0.4` | lint/format gate | `dev` |
| `mypy` | `>=1.10` | strict type gate | `dev` |

**The runtime-vs-dev nuance.** `mgf-common` is the only `mgf-*` sibling
named in this project's deps, and it is a **dev dependency, not a
runtime one**. It exists solely so the alignment tests
(`tests/unit/test_alignment_with_mgf_common.py` here +
`tests/unit/testing/test_supervisor_alignment.py` in mgf-common) can pin
the JSONL `TestRecord` schema contract on both sides. At runtime the
supervisor imports nothing from `mgf-common` — a field rename in one
without the other fails CI on both, but the shipped supervisor stays
stdlib-pure.

---

## §2 Who depends on mgf-test-supervisor

`mgf-test-supervisor` is the **federation test runner** (`mtest`),
adopted as a **dev dependency** across the federation. Effectively
**every `mgf-*` sibling** wires it as its test driver (dev dep), plus
consumer applications that adopt the federation tier model (TS-22..27).

| Project / sibling | Location | Pinned | Notes |
|---|---|---|---|
| **all `mgf-*` siblings** | Codeberg `magogi-admin/*` | dev dep | federation test runner — every sibling on the TS-22..27 tier model wires `mtest` |
| ↳ `mgf-common` | `/home/bassam/PycharmProjects/mgf-common` | dev (+ `TestRecord` schema alignment contract) | bidirectional alignment pin |
| ↳ `mgf-fastapi` / `mgf-sqlalchemy` / `mgf-alembic` | Codeberg | dev | |
| ↳ `mgf-livepush` / `mgf-tele-core` / `mgf-tele-teltonika` / `mgf-auth` | Codeberg | dev (adopted 2026-05-28) | |
| **PlasmaMapper** | `/home/bassam/PycharmProjects/PlasmaMapper` | dev dep | reference adopter — `make test-*` tiers + `tools/test_all.py` polyglot runner; tier-0..3 budgets |

A CLI / tier-contract (`MARKER_TIER`) change here ripples to **every**
row above — walk this table before shipping a breaking change.

---

## §3 Maintenance

Updated every MINOR release + when a dependency or consumer changes,
or when the tier contract (`MARKER_TIER`) changes.

Import-survey note: because adoption is **dev-only** (`mtest` is invoked
as a CLI, not imported into runtime code), the usual `grep` for
`from|import` import sites does **not** find consumers — the coupling
is the pinned `[dev]` entry in each consumer's `pyproject.toml` plus the
JSONL/CLI contract, not Python import sites. Survey adopters by:

```sh
grep -rl "mgf-test-supervisor" /home/bassam/PycharmProjects/*/pyproject.toml
```
