chore(deps): sweep Renovate/Dependabot bumps into pyproject.toml lower bounds [PYSDK-93]#580
Conversation
|
Claude finished @helmut-hoffer-von-ankershoffen's task in 6m 18s —— View job PR Review: Security Vulnerability Remediation (PYSDK-93) ✅Status: APPROVED - Excellent security remediation work. This PR is safe to merge after CI passes. Executive SummaryThis PR addresses a critical gap in downstream security protection by sweeping Renovate/Dependabot security bumps from Key Achievement: 13 packages with raised lower bounds, addressing 15+ CVEs, with zero behavioral risk (all new bounds ≤ current locked versions). ✅ Critical Checks (All Pass)1. Conventional Commits ✓
2. No Breaking Changes ✓
3. Security/Medical Device Compliance ✓
4. No Test Marker Issues ✓
📋 File-by-File Review⭐ pyproject.toml (30 lines changed)Rating: Excellent Lower bounds raised (13 packages):
Strengths:
Minor Observation:
⭐ noxfile.py (13 lines changed)Rating: Excellent Removed acceptances (4 CVEs - all fixed upstream):
Added acceptance (1 CVE - fix unreleased):
Strengths:
⭐ SUPPLY_CHAIN_VULNERABILITIES.md (111 lines, NEW)Rating: Outstanding This is enterprise-grade security documentation. Highlights: 1. Clear Scope Definition
2. Root Cause Explanation
3. Active Acceptances Table
4. Remediation History (Auditable Trail)
Strengths:
No issues found. ✅ SECURITY.md (2 lines added)Rating: Good Adds paragraph linking to SUPPLY_CHAIN_VULNERABILITIES.md with clear context about default path and active acceptances. Integration: Clean, maintains document flow. ✅ docs/partials/README_footer.md (3 lines added)Rating: Good Links to SUPPLY_CHAIN_VULNERABILITIES.md from README footer security section. Discoverability: Ensures users/auditors can find the policy. ✅ .pre-commit-config.yaml (1 line changed)Rating: Good - repo: https://github.com/astral-sh/uv-pre-commit
rev: 0.11.6 # GHSA-pjjw-68hj-v9mw; matches [tool.uv] required-versionCorrectness: Matches Minor Suggestion: Could also reference SUPPLY_CHAIN_VULNERABILITIES.md for consistency: rev: 0.11.6 # GHSA-pjjw-68hj-v9mw; see SUPPLY_CHAIN_VULNERABILITIES.mdNot blocking. ✅ uv.lock (26 lines changed)Rating: Perfect Verified Claims:
Key Property Confirmed: All new lower bounds ≤ locked versions. 🔒 Security Assessment (Medical Device Context)This SDK is medical device software (ISO 13485, FDA/MDR regulated). Security changes require extra scrutiny: ✅ Regulatory Compliance
✅ No Patient Safety Impact
✅ Supply Chain Security Posture
🎯 Recommendations (Non-Blocking)1. Consider Test for Policy Document StructureAdd a test that validates SUPPLY_CHAIN_VULNERABILITIES.md has required sections and active acceptances match # tests/aignostics/system/supply_chain_test.py
import pytest
import re
@pytest.mark.unit
def test_supply_chain_vulnerabilities_md_exists():
"""SUPPLY_CHAIN_VULNERABILITIES.md must exist and contain required sections."""
with open("SUPPLY_CHAIN_VULNERABILITIES.md") as f:
content = f.read()
assert "## How we protect consumers" in content
assert "## Active acceptances" in content
assert "## Previously accepted, now remediated" in content
@pytest.mark.unit
def test_ignored_vulns_documented():
"""Every --ignore-vuln in noxfile.py must have a row in SUPPLY_CHAIN_VULNERABILITIES.md."""
# Parse noxfile.py for --ignore-vuln entries
with open("noxfile.py") as f:
nox_content = f.read()
ignored = re.findall(r'--ignore-vuln.*?"([^"]+)"', nox_content)
# Parse SUPPLY_CHAIN_VULNERABILITIES.md active acceptances table
with open("SUPPLY_CHAIN_VULNERABILITIES.md") as f:
doc_content = f.read()
for vuln in ignored:
assert vuln in doc_content, f"{vuln} in noxfile.py but not documented"Rationale: Prevents drift between code and documentation. 2. Clarify nicegui CommentSplit the dense nicegui comment across multiple lines for readability (see pyproject.toml review above). 3. Schedule Follow-Up for CVE-2026-3219Create a calendar reminder for 2026-05-24 (revisit date) to check if pip 26.1 is released. ✅ Final VerdictAPPROVED - This PR demonstrates exceptional security hygiene:
Test Plan Completion:
Merge Conditions:
🏆 PraiseThis is world-class security remediation work. The SUPPLY_CHAIN_VULNERABILITIES.md policy document alone is worth its weight in gold - it addresses a systemic gap in how the Python ecosystem thinks about dependency security. The distinction between lockfile security (for developers) and constraint security (for consumers) is often misunderstood, and this PR demonstrates deep understanding of the problem space. The fix for the Well done, @helmut-hoffer-von-ankershoffen! |
There was a problem hiding this comment.
Pull request overview
This PR closes a supply-chain security gap by sweeping Renovate/Dependabot security bumps (previously only reflected in uv.lock) into lower bounds in pyproject.toml, ensuring downstream installers (pip install, uv add, uvx) cannot resolve known-vulnerable versions. It also formalizes the vulnerability acceptance/remediation process in repo documentation and aligns tooling configuration accordingly.
Changes:
- Raise lower bounds in
pyproject.toml(incl. transitive overrides + optional extras) to match already-locked safe versions. - Update
pip-auditignore list innoxfile.pyto remove stale entries and track a single accepted advisory with documented rationale. - Add and link new
SUPPLY_CHAIN_VULNERABILITIES.md; bumpuv-pre-committo match[tool.uv] required-version.
Reviewed changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
pyproject.toml |
Lifts dependency lower bounds (runtime, extras, dev) so consumer resolvers avoid known-vulnerable versions; updates [tool.uv] required-version. |
uv.lock |
Reflects the updated constraints and adds newly constrained packages (pygments, nbconvert) to the lock metadata/groups. |
noxfile.py |
Prunes/updates pip-audit --ignore-vuln to the single currently accepted CVE and ties ignores to the new policy doc. |
.pre-commit-config.yaml |
Bumps astral-sh/uv-pre-commit rev to align with the required uv version. |
SUPPLY_CHAIN_VULNERABILITIES.md |
New policy + acceptance/remediation ledger for Python dependency vulnerabilities. |
SECURITY.md |
Links to the new supply-chain vulnerability handling document. |
docs/partials/README_footer.md |
Adds a README footer link pointing readers to the supply-chain vulnerability policy. |
…r bounds PYSDK-93 Raises lower bounds in pyproject.toml for every runtime and runtime-optional package that Renovate/Dependabot bumped in uv.lock since January 2026, closing the downstream-exposure gap for SDK consumers (uvx aignostics, uv add aignostics, pip install aignostics, etc). Re-verifies every existing --ignore-vuln entry against current upstream fix status; removes four stale ignores that upstream fixes already made obsolete; keeps one live acceptance (CVE-2026-3219 on pip, awaiting 26.1 release) with documented rationale. Adds KNOWN_VULNERABILITIES.md as the auditable registry of live acceptances and remediation history, linked from SECURITY.md and the README footer. Every new lower bound is <= the currently-locked version in uv.lock, so no dependency is upgraded and no runtime behaviour changes for our dev/CI env. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
66cd7bc to
a7755d8
Compare
|
Codecov Report✅ All modified and coverable lines are covered by tests. ❌ Your project status has failed because the head coverage (63.82%) is below the target coverage (70.00%). You can increase the head coverage or adjust the target coverage. |



🛡️ Resolves PYSDK-93 following PR-SOP-01 Problem Resolution and Non-Conforming Products, part of our ISO 13485-certified QMS | Ketryx Project.
Supersedes an earlier in-flight attempt (PYSDK-92) whose scope grew during review.
Why this PR exists
pip-audit(viamake audit) scans the.venvour own tooling resolves fromuv.lock— i.e. our dev/CI env. Downstream consumers of aignostics —uvx aignosticsanduv add aignostics/pip install aignosticsalike — resolve against the dependency metadata we publish with the package and nothing else. Ouruv.lockis never consulted by a consumer, and PEP 735 dev-groups are invisible to every consumer resolver.Renovate and Dependabot security PRs bump
uv.lockbut do not raise lower bounds in our published dependency metadata. A greenmake audittherefore proves the dev/CI env is clean but does not prove SDK consumers are safe. Every merged bot security PR since the repo went public was a potential downstream-exposure gap waiting to be closed.Key property: no dependency was upgraded
Every new lower bound introduced in this PR is
≤the currently-locked version inuv.lock.uv lockdoes not bump any resolved package; our dev/CI environment continues to run with exactly the same set of dependency versions as onmainbefore the PR. The only effect of the changes is that downstream consumers can no longer resolve any of the known-vulnerable versions that Renovate/Dependabot had already lifted us past locally. Behavioural regression risk is therefore equivalent to a comment-only change.What changed
Lower bounds raised or added (13 runtime + 5 dev)
Every bump annotated inline with its CVE / GHSA id. Full catalog with severities and introduction dates is in
SUPPLY_CHAIN_VULNERABILITIES.md.Runtime (reach every consumer install):
nicegui[native]→>=3.9.0(CVE-2026-25516, CVE-2026-27156, CVE-2026-33332)pyjwt[crypto]→>=2.12.0(CVE-2026-32597)tornado→>=6.5.5(GHSA-78cv-mqj4-43f7)pillow→>=12.2.0(CVE-2026-25990, CVE-2026-40192)aiohttp→>=3.13.4(CVE-2026-22815)lxml→>=6.1.0(CVE-2026-41066)filelock→>=3.20.3(CVE-2026-22701)pygments→>=2.20.0new override (CVE-2026-4539)cryptography→>=46.0.7new override (CVE-2026-39892)pydicom→>=3.0.2new override (CVE-2026-32711)pyasn1→>=0.6.3new override (CVE-2026-30922)lxml-html-clean→>=0.4.4new override (CVE-2026-28348, CVE-2026-28350)python-multipart→>=0.0.26new override (CVE-2026-24486, CVE-2026-40347)protobuf→>=6.33.5new override (CVE-2026-0994)Reach only consumers of the affected extra:
nbconvert→>=7.17.1in thejupyterextra new override (CVE-2025-53000)marimo→>=0.23.0in themarimoextra (GHSA-2679-6mx9-h9xc)Dev only (do not reach consumers):
pip→>=25.3(CVE-2025-8869; the priorpip>=5.3was nonsensical for that CVE)uv→>=0.11.6(GHSA-pjjw-68hj-v9mw); also enforced via[tool.uv] required-versionpytest→>=9.0.3(CVE-2025-71176)virtualenv→>=20.36.1new override (fix: resolve TOCTOU vulnerabilities in app_data and lock directory creation pypa/virtualenv#3013 TOCTOU, filelock≥3.20.1 bundle)Accepted advisories: re-verified against current state
GHSA-4xh5-x5gv-qwph/ CVE-2025-8869 (pip symlink tar)uv.lockhas pip 26.0; lower bound raised accordingly.CVE-2025-53000(nbconvert Windowsinkscape.batRCE)nbconvert>=7.17.1override in thejupyterextra.CVE-2026-4539(pygments AdlLexer ReDoS)pygments>=2.20.0transitive override.CVE-2025-69872(python-diskcache pickle RCE)diskcacheis not in our resolved dependency tree — the ignore was defensive against a transitive that never materialised.CVE-2026-3219(pip archive type confusion). Fix merged for pip 26.1 but not released; dev-only; documented inSUPPLY_CHAIN_VULNERABILITIES.mdwith removal condition.Docs + tooling
SUPPLY_CHAIN_VULNERABILITIES.md— describes how aignostics handles supply-chain advisories (lower-bounds-first policy, active-acceptances table with severity/scope/exposure/dates, and a full catalog of enforced lower bounds with severity and introduction date per row). Linked fromSECURITY.mdand the README footer..pre-commit-config.yaml— bumpedastral-sh/uv-pre-commitfrom0.9.7to0.11.6to match the new[tool.uv] required-version(required for hook execution).noxfile.py— pruned stale--ignore-vulnentries, added CVE-2026-3219, removed misleading/nonsensical inline comments, pointed every future acceptance atSUPPLY_CHAIN_VULNERABILITIES.md.Test plan
make auditpasses (exactly one accepted advisory: CVE-2026-3219)make lintpasses (ruff + pyright + mypy)make test_unitpassesmain: every lower-bound change is a raise or addition, never a lower (verified programmatically)Out of scope
audit-vulnerabilitiesskill that drove this remediation lives outside the repo in~/.claude/skills/; sharing of skills happens separately.🤖 Generated with Claude Code