Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,7 @@ jobs:
run: uv sync --frozen --extra dev --extra test --extra performance

- name: Audit dependencies for known vulnerabilities
# PYSEC-2026-3740 (CVE-2026-81726): nltk path traversal in model-artifact
# APIs (TransitionParser, AveragedPerceptron, PerceptronTagger, maxent).
# Unreachable here: only sent_tokenize and rouge_score's Porter stemmer
# are used. No fixed nltk release yet.
# TODO: drop the ignore - https://github.com/mlcommons/endpoints/issues/520
run: uv run pip-audit --ignore-vuln PYSEC-2026-3740
run: uv run pip-audit

bfcl-smoke:
runs-on: ubuntu-latest
Expand Down
9 changes: 3 additions & 6 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -828,12 +828,9 @@ these during code review of AI-assisted PRs.
to an exact version (`==`). After adding a dependency, run `pip-audit`
(included in `dev` extras) to verify it has no known vulnerabilities. When
adding dependencies, use `uv add <package>==<version>` to update both
`pyproject.toml` and `uv.lock` atomically, then run
`uv run pip-audit --ignore-vuln PYSEC-2026-3740` to check for vulnerabilities
(the ignored `nltk` advisory has no fixed release and its affected APIs are
unused; tracked in https://github.com/mlcommons/endpoints/issues/520). Note:
`[build-system] requires` is also pinned to exact versions for
reproducibility.
`pyproject.toml` and `uv.lock` atomically, then run `uv run pip-audit` to
check for vulnerabilities. Note: `[build-system] requires` is also pinned to
exact versions for reproducibility.
- **Using `requests`/`aiohttp` for HTTP**: This project has its own HTTP client
(`endpoint_client/http.py`) using `httptools`. AI defaults to `requests` or
`aiohttp` — these should not appear in production code (test dependencies are
Expand Down
6 changes: 1 addition & 5 deletions docs/DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -254,13 +254,9 @@ After adding a dependency, run `pip-audit` to verify it has no known
vulnerabilities:

```bash
uv run pip-audit --ignore-vuln PYSEC-2026-3740
uv run pip-audit
```

`PYSEC-2026-3740` is an `nltk` advisory with no fixed release whose affected
APIs this repo doesn't use; CI ignores it too. Drop the flag once
[#520](https://github.com/mlcommons/endpoints/issues/520) is resolved.

## Performance Considerations

Code in `load_generator/`, `endpoint_client/worker.py`, and
Expand Down
13 changes: 7 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -139,12 +139,16 @@ dev = [
# [tool.uv].conflicts), these floors force uv to fork filelock/virtualenv:
# patched here, pinned only inside the bfcl fork. Closes CVE-2025-68146 /
# CVE-2026-22701 / CVE-2026-112907 / CVE-2026-112913 / CVE-2026-112940
# (filelock) and CVE-2026-22702 / CVE-2026-113713 (virtualenv).
# (filelock) and CVE-2026-22702 / CVE-2026-113713 / CVE-2026-115586
# (virtualenv).
"filelock>=4.2.1",
"virtualenv==21.14.10",
"virtualenv==21.14.13",
# pip is pulled in transitively (pip-audit -> pip-api -> pip); force past
# PYSEC-2026-3721 (fixed in 26.2), which otherwise fails `uv run pip-audit`.
"pip==26.2",
# msgpack is pulled in transitively (pip-audit -> cachecontrol -> msgpack);
# force past CVE-2026-114613 (fixed in 1.2.3).
"msgpack==1.2.3",
]
test = [
# Includes optional dependencies for full test coverage
Expand Down Expand Up @@ -181,10 +185,7 @@ rouge = [
# NOTE: not self-contained at runtime - nltk needs the punkt/punkt_tab
# corpora and evaluate.load("rouge") fetches its metric script from the HF
# Hub, so an offline image must prefetch both.
# nltk advisory PYSEC-2026-3740 has no fixed release and is ignored in CI's
# pip-audit (affected APIs unused); tracked in
# https://github.com/mlcommons/endpoints/issues/520
"nltk==3.10.3",
"nltk==3.10.4",
"evaluate==0.4.6",
"rouge-score==0.1.2",
]
Expand Down
Loading
Loading