Skip to content

~95% on SimpleQA (e.g. Qwen3.6-27B on a 3090). Supports all local and cloud LLMs (llama.cpp, Ollama, Google, ...). 10+ search engines - arXiv, PubMed, your private documents. Everything Local & Encrypted.

1001 B
Raw Blame
"""Keep a reviewed build-specific scanner correction narrowly scoped."""

# allow: no-sut-import — validates the native scanner configuration contract.

from pathlib import Path

import yaml


def test_reviewed_python_metadata_correction_keeps_its_exact_build_scope():
    path = Path(__file__).resolve().parents[2] / ".grype.yaml"
    policy = yaml.safe_load(path.read_text(encoding="utf-8"))
    rows = [
        row
        for row in policy["ignore"]
        if row.get("vulnerability") == "CVE-2026-12345"
    ]
    assert len(rows) == 1
    assert rows[0]["package"] == {
        "name": "python",
        "version": "3.14.10",
        "type": "binary",
    }
    assert set(rows[0]) == {"vulnerability", "package", "reason"}
    trivy = path.with_name(".trivyignore").read_text(encoding="utf-8")
    active_ids = {
        line.split()[0]
        for line in trivy.splitlines()
        if line.strip() and not line.lstrip().startswith("#")
    }
    assert "CVE-2026-12345" not in active_ids