1
0
Fork 0

fix(llms): pin the install line to 1.8.0 and hold every pin to the version

llms.txt still installed v1.1.0 seven releases later: no check read it, and
the release commit bumps only the surfaces it remembers. A test now holds every
git pin and index floor in README.md and llms.txt to __version__, and every git
pin to the open/ address.
This commit is contained in:
Kjell Tore Guttormsen 2026-10-31 21:57:43 +01:00
commit cde4431031
Signed by: ktg
SSH key fingerprint: SHA256:JakMjO6FTBBzN0Bhfj9saOoEjaFxlSdYuZQQpM/lF9Q
2 changed files with 40 additions and 1 deletions

View file

@ -3,5 +3,5 @@
> Write-time defensive layer for Python pipelines that persist LLM output: sanitize, fence, tool-less quarantined transform, capability isolation, scan before persist, fail-secure.
```bash
pip install "llm-ingestion-guard @ git+https://git.fromaitochitta.com/open/llm-ingestion-pipeline-security.git@v1.1.0"
pip install "llm-ingestion-guard @ git+https://git.fromaitochitta.com/open/llm-ingestion-pipeline-security.git@v1.8.0"
```

View file

@ -0,0 +1,39 @@
"""Every printed install pin names the current release.
`llms.txt` carried `@v1.1.0` through seven releases because no check read it: the
release commit bumps the surfaces it remembers. This test reads every git pin
(`.git@vX.Y.Z`) and every index lower bound (`>=X.Y.Z`) in the files a reader
copies an install line from, and holds each to `__version__`.
"""
from __future__ import annotations
import re
from pathlib import Path
import pytest
import llm_ingestion_guard
ROOT = Path(__file__).resolve().parent.parent
SURFACES = ["README.md", "llms.txt"]
CANONICAL = "git+https://git.fromaitochitta.com/open/llm-ingestion-pipeline-security.git@"
GIT_PIN = re.compile(r"llm-ingestion-pipeline-security\.git@v(\d+\.\d+\.\d+)")
INDEX_FLOOR = re.compile(r'"llm-ingestion-guard>=(\d+\.\d+\.\d+)')
@pytest.mark.parametrize("name", SURFACES)
def test_install_pins_name_the_current_release(name):
text = (ROOT / name).read_text(encoding="utf-8")
pins = GIT_PIN.findall(text) + INDEX_FLOOR.findall(text)
assert pins, f"{name}: no install pin found"
version = llm_ingestion_guard.__version__
assert all(p == version for p in pins), f"{name}: pins {pins} != {version}"
@pytest.mark.parametrize("name", SURFACES)
def test_git_pins_point_at_the_public_address(name):
text = (ROOT / name).read_text(encoding="utf-8")
for line in text.splitlines():
if ".git@v" in line:
assert CANONICAL in line, f"{name}: {line.strip()}"