Skip to content

Make agstack-pnd a first-class DPI service: BITE weather, grant-aware… #6

Make agstack-pnd a first-class DPI service: BITE weather, grant-aware…

Make agstack-pnd a first-class DPI service: BITE weather, grant-aware… #6

Workflow file for this run

name: CI
on:
push:
branches: [main, master, v2]
pull_request:
branches: [main, master]
# Every PR must pass ALL four gates before merge is allowed.
# Repository Settings > Branches > Branch protection rules should require:
# - "lint", "typecheck", "test", "catalog-validation" to pass
# - At least 1 approving review (from CODEOWNERS / maintainers)
jobs:
lint:
name: "Gate 1: Lint & Format"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- run: pip install ruff
- run: ruff check src/ tests/
- run: ruff format --check src/ tests/
typecheck:
name: "Gate 2: Type Check"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- run: pip install ".[dev]"
- run: mypy src/agstack_pnd/ --ignore-missing-imports
test:
name: "Gate 3: Tests"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- run: pip install -e ".[dev]"
- run: pytest tests/ -v --tb=short --strict-markers
catalog-validation:
name: "Gate 4: Catalog & FATFD Integrity"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- run: pip install -e ".[dev]"
- name: Validate threat catalog schema
run: python -c "from agstack_pnd.catalog.loader import list_threats; t = list_threats(); print(f'Catalog OK: {len(t)} threats loaded')"

Check failure on line 59 in .github/workflows/ci.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/ci.yaml

Invalid workflow file

You have an error in your yaml syntax on line 59
- name: Validate model UUID uniqueness
run: python -c "
from agstack_pnd.foundation.model_registry import ModelRegistry
r = ModelRegistry(); r._discover()
uuids = [str(c.metadata.uuid) for c in r._models.values()]
assert len(uuids) == len(set(uuids)), 'Duplicate UUIDs found'
print(f'Registry OK: {len(uuids)} unique models')
"
- name: Run FATFD validator
run: python .audit/validate_fatfd.py
docs:
name: "Docs Build"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- run: pip install -e ".[docs]"
- run: sphinx-build -b html docs/sphinx docs/_build