Repository navigation
security: update vulnerable dependencies - #159
Merged
anhnh2002 merged 5 commits intoNov 23, 2026
Merged
Conversation
Refresh the pinned Python dependencies and the Mermaid frontend asset to versions that address the known advisories reported by pip-audit and npm audit. Highlights: - aiohttp 3.14.4, GitPython 3.2.1, litellm 1.100.4, mcp 1.30.0 - starlette 1.3.1 with fastapi 0.140.0 - pydantic 2.12.0 and pydantic-ai-slim 1.107.7 (replaces the pydantic-ai meta package, which pulled extras that conflict with the fixed OpenTelemetry stack) - logfire 5.6.0, openai 2.29.0, tornado 6.6, urllib3 2.8.0 - Mermaid 12.3.0 in the web viewer and CDN templates The unused openai-agents and griffe entries were dropped because they pinned openai<2 and griffe<2, which cannot coexist with the fixed versions. Verified with pip-audit (0 findings), npm audit (0 findings), and the test suite (740 passed, 25 skipped).
Collaborator
|
Thanks for tackling this! I reproduced the 740 passing tests and the Mermaid checks. Two follow-ups before merging:
The compatibility checks otherwise looked good. |
Tornado 6.6 is flagged by CVE-2026-126347 (GHSA-5cjw-f85j-cv6r), so the pin moves to 6.6.1. pyproject.toml now declares the patched minimums for the affected transitive dependencies (aiohttp>=3.14.4, urllib3>=2.8.0, tornado>=6.6.1, and the rest of the audited set) so installs that do not use requirements.txt cannot resolve to vulnerable versions.
…-updates # Conflicts: # pyproject.toml
Author
Fixed |
Raise the package minimum and requirements pin so upgrades cannot retain vulnerable protobuf 6.x releases. Bump temporalio to 1.18.0, the first release that permits protobuf 6, to keep the pinned requirements compatible.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
pip-audit -r requirements.txtreported 271 findings (173 unique advisories) across 22 Python packages, andnpm auditintests/mermaidreported 9 vulnerable packages. This PR moves the affected pins to the smallest compatible fixed versions, declares the patched minimums for the affected transitive dependencies inpyproject.toml, and leaves both audits clean.Python highlights
requirements.txtalso pins the new transitive dependencies required by those versions (httpx2,httpcore2,griffelib,logfire-sdk, the OTLP exporter helpers,cryptography,PyJWT, and the keyring runtime helpers).pyproject.tomlnow declares the patched minimums for the affected transitive dependencies (aiohttp>=3.14.4,urllib3>=2.8.0,tornado>=6.6.1, plus the rest of the audited set), so a normal package install that doesn't userequirements.txtcannot resolve to the vulnerable versions.npm / frontend
tests/mermaid,codewiki/src/fe/templates.py,codewiki/templates/github_pages/viewer_template.html, anddocs/index.html. The remaining KaTeX advisory in Mermaid 11 is only fixed in Mermaid 12; the existing 37 parser fixtures pass with the new major.npm auditnow reports 0 vulnerabilities.Compatibility notes
pydantic-ai→pydantic-ai-slim[openai,google]. Thepydantic-aimeta package installs every provider extra; itsmistralai>=2extra requiresopentelemetry-semantic-conventions<0.61, which conflicts with the fixed OpenTelemetry 1.45.2 stack. CodeWiki only imports pydantic-ai's OpenAI and Google model/providers, and the slim package provides those samepydantic_aimodules.openai-agentswas not imported anywhere and pinnedopenai<2;griffewas only used by the old pydantic-ai and is replaced bygriffelib. Both removals were required for the OpenAI and pydantic-ai fixes to resolve.<1.0upper bound, so it is the smallest FastAPI bump that allows the fixed Starlette 1.3.1.Verification
pip-audit -r requirements.txt→ No known vulnerabilities found.npm audit --prefix tests/mermaid --package-lock-only→ 0 vulnerabilities.pip install -r requirements.txt, thenpip install -e . --no-deps.pytest -p no:cacheprovider -o addopts="" tests/ -q→ 740 passed, 25 skipped.npm ci --prefix tests/mermaid --ignore-scripts --no-audit --no-fund && npm test --prefix tests/mermaid→ 37 Mermaid parser fixtures passed.pip check→ No broken requirements found.