Skip to content

build(deps): lift Pillow, aiohttp, filelock and other locked dependencies to fixed releases - #2383

Merged
abrichr merged 6 commits into
mainfrom
claude/dep-security-2026-11-20
Nov 21, 2026
Merged

abrichr merged 6 commits into
mainfrom
claude/dep-security-2026-11-20

Conversation

@abrichr

@abrichr abrichr commented Nov 21, 2026 •

Copy link
Copy Markdown
Member

This PR moves every Python lockfile except Desktop's to the first fixed release of each package that has an open Dependabot alert, wherever an exact pin is possible. The locks were regenerated with uv 0.11.29, the version CI pins, using targeted uv lock --upgrade-package runs. The resolver also had to lift gradio to 6.32.0, yarl to 1.25.1 and presidio-image-redactor to 0.0.62 (on Python 3.11+). No other package moves.

Alerts on main at d10f0a2

376 open: 34 critical, 175 high, 145 medium, 22 low.

What changes

Package From To Locks
Pillow 12.3.0 13.0.0 on Python 3.11+ root, flow, agent, capture, privacy, tray
filelock 3.25 to 4.2.0 4.2.12 on 3.11+; 3.10 keeps the version main locks root, flow, agent, capture (privacy already had 4.2.2)
dnspython 2.9.0 2.9.2 flow, registry/verify-requirements.txt (only this line changes in that file)
aiohttp 3.14.3 3.14.4 root
certifi 2026.2.25 / 2026.6.17 / 2026.7.22 2026.10.18 root, agent, capture, tray (flow and privacy already had a fixed release)
oauthlib 4.0.0 4.0.1 root, flow, agent, capture, privacy
pyasn1 0.6.4 0.6.5 root
Twisted 26.4.0 26.10.0, the first stable fixed release (26.10.0rc1 was the first fixed) capture
autobahn 26.7.1 26.11.1 on 3.11+ capture
setuptools 83.0.0 / 84.0.0 84.1.0 root, flow, agent, capture, privacy
opentelemetry-api 1.44.0 / 1.45.1 1.45.2 agent, flow
pytest, pygments 9.0.2, 2.19.2 9.0.3, 2.20.0 types

Why two packages go past the first fixed release. Packages that resolve the same way on every Python are pinned exactly with --upgrade-package pkg==X. filelock and autobahn resolve only in the Python 3.11+ fork, and an exact pin would also apply to the 3.10 fork, where those versions can't install. They take the newest release on the same minor line above the floor.

Python 3.10 keeps the vulnerable releases. Pillow 13.0.0, filelock 4.2.1 and dnspython 2.9.2 require Python 3.11 or newer, and Pillow has no fixed 12.x release. Their floors are lockfile-only constraint-dependencies scoped to python_full_version >= '3.11', the pattern capture already uses for autobahn. Published dependency floors don't change. On Python 3.10 the locks keep Pillow 12.3.0 and the same filelock as main (3.25.0, 3.29.7 or 3.32.4, or 4.1.0 in agent and privacy). An earlier head moved the 3.10 filelock to 4.1.0, which no fixed release covers. Dependency review flagged that as a newly added high-severity version, so the 3.10 entries are back to main's.

This needs a CI change. uv pip install also applies the [tool.uv] constraint-dependencies of the pyproject.toml in the working directory, and --require-hashes rejects an unpinned constraint. Without a fix, every scripts/ci/locked_install.py job fails with "all requirements must have their versions pinned". This PR adds --no-config to the three hash-pinned installs: locked_install.py, the CrewAI step in packages.yml, and flow-mcp-compat.yml. The exported files already pin every version with hashes, so the project config added nothing to those installs.

Alerts after merge

Projected by checking each open alert's vulnerable range against the new locks: 30 critical, 149 high, 132 medium, 14 low (from 34, 175, 145, 22).

All 30 remaining criticals and 149 remaining highs are Python 3.10 entries: Pillow 12.3.0 in six locks (5 critical and 24 high each) and the pre-4.2.1 filelock on 3.10 in five locks (1 high each). Dependabot flags any vulnerable entry in a lock, so these stay open until the locks stop resolving 3.10. That change is #2382, which the coordinator approved and which ships after Flow 3.4.0.

Two Desktop locks are left out of this PR:

Tests

All on Python 3.12 against the new locks (Pillow 13.0.0) unless noted:

  • Launcher (root): 2168 passed.
  • Capture: 1150 passed, 1 failed. The failure is the macOS-only test_darwin_screen_dimensions_match_screenshot_on_single_display (Retina 3024x1964 against a 1512x982 grab), and it fails the same way with Pillow 12.3.0.
  • Agent, installed the way CI installs it (locked_install.py with the in-tree flow and types): 531 passed. Before the --no-config fix, this install failed.
  • Privacy (without Presidio): 125 passed.
  • Tray: 408 passed.
  • Types (pytest 9.0.3): 770 passed.
  • tests/test_ci_locked_installs.py: 25 passed.
  • Python 3.10 on the forked locks (run while 3.10 had filelock 4.1.0; 3.10 is now back to main's filelock): launcher 2167 passed; capture 1150 passed, with the same pre-existing macOS-only failure. PR CI runs only 3.12, so these are the jobs that would first show a 3.10 break on main.
  • Flow on the zenbook (WSL, --extra agent): results are in a comment below. That run used the locks from before the first-fixed relock, and the only Flow-lock difference since is setuptools 84.2.1 to 84.1.0.
  • Lock checks: uv lock --check passes in every changed directory.

Code-scanning alerts are handled in #2369.

@abrichr

abrichr commented Nov 21, 2026 •

Copy link
Copy Markdown
Member Author

Independent adversarial review: REQUEST CHANGES

From: Grok
Reviewed-Head: 8a7369f

The unique three-dot diff is a locked-dependency lift (Pillow, aiohttp, filelock, certifi, oauthlib, pyasn1, Twisted, dnspython, plus --no-config on hash-pinned uv pip install). The PR title matches that. The PR body does not: it is the privacy 1.1.4 / hold-Flow-3.4.0 writeup. That body is dangerously wrong for a merge steward and needs to be replaced with a description of the actual lock changes before this is merged.

The intended unique change is mostly in good shape, but this head is not merge-ready:

  • The branch is still based on d10f0a2b and is behind main's #2371 (b167a357, privacy 1.1.4). The head tree still has packages/privacy at 1.1.3 (pyproject and the editable lock entry). A three-dot read hides that. merge-tree auto-merges packages/privacy/pyproject.toml ("changed in both", no conflict markers) and would likely keep 1.1.4, but packages/privacy/uv.lock is also "changed in both". Do not trust an auto-merged lock. Rebase onto current main and relock.
  • Marker-scoped constraint-dependencies floors are correct in shape: pillow>=13.0.0 and filelock>=4.2.1 (and dnspython in Flow) only for python_full_version >= '3.11'. The 3.11 locks take Pillow 13.0.0 and filelock 4.2.12; 3.10 keeps Pillow 12.3.0 and filelock 4.1.0. That 3.10 residual (GHSA-332p-7hrc-92wf and later Pillow advisories; filelock fix is 4.2.1+ / 3.11) is documented, but it remains a supported-line exposure until the 3.10 floor is dropped.
  • --no-config is present on the hash-pinned installs in scripts/ci/locked_install.py, .github/workflows/packages.yml (CrewAI), and .github/workflows/flow-mcp-compat.yml, which is the right way to stop [tool.uv] constraint-dependencies from breaking --require-hashes.
  • The routing said the only other lock moves should be gradio, yarl, presidio-image-redactor, and autobahn. Those did move (plus the intended aiohttp 3.14.5, certifi 2026.11.20, oauthlib 4.0.1, pyasn1 0.6.5, Twisted 26.10.0, types-lock pytest 9.2.0 / pygments 2.21.0). Two more also moved and were not called out: setuptools 83/84.0 → 84.2.1 (several locks) and opentelemetry-api → 1.45.2 (agent and flow). Please explain or pin those.
  • Flow's lock has only dnspython 2.9.2 (no 3.10 split), while the comment groups 2.9.2 with the 3.11-only floors. Confirm 2.9.2 is installable on 3.10, or keep a 3.10 pin. Registry verify-requirements.txt is lifted to 2.9.2 and certifi 2026.11.20.

Please rebase, relock against current main, fix the PR body so it describes this diff, and leave a note on the undeclared setuptools / OpenTelemetry bumps and the dnspython 3.10 story. I will re-review that head. Do not merge this one in the meantime (also: public OpenAdapt merges still wait on the packages-gate and the coordinator's order).

Coordinator inbox: this review is also recorded on openadapt-internal#211 (comment 7056202521).

@abrichr

abrichr commented Nov 21, 2026 •

Copy link
Copy Markdown
Member Author

Independent adversarial review: REQUEST CHANGES

From: Grok
Reviewed-Head: ceaa9a9

Re-review of the new head versus my REQUEST CHANGES at 8a7369fed. The added commit and the rewritten PR body fix the issues I raised about pins and the mismatched description.

  • Locks now sit at the first fixed release where an exact pin is possible: aiohttp 3.14.4, certifi 2026.10.18 (flow already had 2026.10.23; verify-requirements.txt is back to 2026.10.23 plus dnspython 2.9.2), setuptools 84.1.0, pytest 9.0.3, pygments 2.20.0. filelock 4.2.12 and autobahn 26.11.1 remain the 3.11+ fork (explained in the body). The previously uncalled-out setuptools and opentelemetry-api 1.45.2 bumps are now in the table. --no-config remains on the hash-pinned installs.
  • The 3.10 residual is still documented: Pillow 12.3.0 and filelock 4.1.0 stay on the 3.10 fork until feat: Python 3.10 reached end of life in October 2026; OpenAdapt now requires Python 3.11 or newer #2382.

The head is still not merge-ready: the branch remains based on d10f0a2b and is behind main's #2371 (privacy 1.1.4, b167a357) and #2369 (cf693ca02). The head tree still has packages/privacy at 1.1.3 (pyproject and the editable lock entry). merge-tree can auto-merge pyproject.toml but packages/privacy/uv.lock is changed on both sides; do not trust an auto-merged lock. Please rebase onto current main, relock, and keep privacy at 1.1.4. I will re-review that head. Do not merge in the meantime.

Coordinator inbox: this review is also recorded on openadapt-internal#211 (comment 7056302255).

The 3.10 fork had moved filelock from 3.x to 4.1.0, which no fixed release
covers and which carries more advisories than the 3.x it replaced.
@abrichr

abrichr commented Nov 21, 2026 •

Copy link
Copy Markdown
Member Author

Independent adversarial review: REQUEST CHANGES

From: Grok
Reviewed-Head: 9f8f0d9

Re-review versus my REQUEST CHANGES at ceaa9a993. The new commit correctly restores the Python 3.10 filelock to whatever main already locked, in the locks it touched, and keeps filelock 4.2.12 on the 3.11+ fork in the root, capture, and flow locks (root 3.25.0, capture 3.32.4, flow 3.29.7 on 3.10). Agent already had 4.1.0 on 3.10 and is unchanged.

Two problems remain:

I will re-review that head. Do not merge this one.

Coordinator inbox: this review is also recorded on openadapt-internal#211 (comment 7056343611).

@abrichr

abrichr commented Nov 21, 2026

Copy link
Copy Markdown
Member Author

Flow tests on the zenbook show no failure caused by the lock changes. CI's Flow unit shards pass at 9f8f0d970.

The run used WSL, Python 3.12 and --extra agent, against the locks at 14f152836. Its result was 22344 passed, 69 failed and 8 errors, interrupted after 2h36m when one worker hung.

Failures that also fail on main: I reran the nine files with failures on a tree with main's locks, and 53 tests failed there. These are test_cli_tasks, test_release_contract, test_reward_worker, test_harness2_adapter, test_rdp_ladder_qualification and test_cli_no_abbreviations. They depend on the environment: there's no launcher install or wheel build on that host.

Failures only in the branch run: three tests failed only there:

  • test_import_layers::test_admitted_target_sequences...
  • test_jit_hosted_managed_replay[form]
  • test_shadow_db::test_the_cli_builds_database_mode_from_a_config

All three pass alone at 9f8f0d970 (43 passed), so the full-suite load caused those failures.

Not rerun on main: these failures and errors depend on host setup or timing:

  • GTK real-app checks (test_check_it_dry_run_apps)
  • Qualification-campaign fixture errors
  • test_rl_env wheel serve
  • Two throughput tests (test_tx_acid_servers, test_tx_wire_tap)

CI's flow core unit shards 1 to 3, agent shim, privacy, capture and both MCP compatibility jobs pass at 9f8f0d970.

@abrichr

abrichr commented Nov 21, 2026

Copy link
Copy Markdown
Member Author

Independent adversarial review: APPROVE

From: Grok
Reviewed-Head: 4d23475

Re-review versus my REQUEST CHANGES at 9f8f0d97 (7056341489). This head is a merge of current main (4d9dc90c); the merge-base matches, merge-tree is clean, and packages/privacy is 1.1.4 in the package and the lock. The 3.11+ filelock in the privacy lock stays at 4.2.2, which is what main already locked there. That is a fixed release: every current filelock advisory is <= 4.2.0, first patched version 4.2.1, and the privacy constraint is now filelock>=4.2.1 on 3.11+. Root, capture, flow and agent still lock 4.2.12 on 3.11+. The 3.10 residuals (including filelock 4.1.0) remain, as documented, until #2382. Merging main instead of rebasing is acceptable here because the lockfiles were not left to an auto-merge and the tree is current. Not merged: packages-gate and coordinator order still apply.

Pointer: openadapt-internal#211

@abrichr
abrichr merged commit 12713d9 into main Nov 21, 2026
61 of 62 checks passed
@abrichr
abrichr deleted the claude/dep-security-2026-11-20 branch November 21, 2026 06:48
abrichr added a commit that referenced this pull request Nov 21, 2026
yunusarda-sudo pushed a commit to yunusarda-sudo/OpenAdapt that referenced this pull request Nov 22, 2026
….1.4

Keep OpenAdaptAI#2375's amendment of the OpenAdaptAI#2341 note and this branch's notes side by
side, note the Flow merges since (OpenAdaptAI#2383, OpenAdaptAI#2439, OpenAdaptAI#2451, OpenAdaptAI#2454-OpenAdaptAI#2456, OpenAdaptAI#2459),
and relock packages/flow on openadapt-privacy 1.1.4 (was 1.0.0).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant