Skip to content

chore(deps): allow pillow 13 - #830

Open
svaningelgem wants to merge 1 commit into
qdrant:mainfrom
svaningelgem:chore/allow-pillow-13
Open

svaningelgem wants to merge 1 commit into
qdrant:mainfrom
svaningelgem:chore/allow-pillow-13

Conversation

@svaningelgem

Copy link
Copy Markdown

Raises the pillow cap to <14.0; image tests pass on Pillow 13.0.0. Closes #829.

@svaningelgem
svaningelgem requested a review from joein as a code owner October 19, 2026 06:43
@coderabbitai

coderabbitai Bot commented Oct 19, 2026

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 4395439f-9324-41b5-82f9-fdd002d5a140
📥 Commits

Reviewing files that changed from the base of the PR and between de502ca and 9f04c8c.

⛔ Files ignored due to path filters: 1
  • uv.lock is excluded by !**/*.lock
📒 Files selected for processing: 1
  • pyproject.toml

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.

📝 Walkthrough

The Pillow upper bound changes from <13.0 to <14.0 for runtime Python versions 3.10–3.14+, with existing lower bounds preserved. The documentation dependency constraint changes from <13.0.0 to <14.0.0.

Priority: ➖ Normal

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Other · Severity of issue fixed: Medium

Merge Risk: ⚪ Minimal · up to 9f04c

The widened cap addresses the requested Pillow 13 upgrade path. No specific merge-blocking risk is established; proceed with normal project checks.

Pre-merge checks: Passed 5
Check name Status Explanation
Title check Passed The title clearly identifies the dependency change that enables Pillow 13 support.
Description check Passed The description accurately states the Pillow cap change, test result, and linked issue.
Linked Issues check Passed Issue #829 requires support for Pillow 13. The pull request changes the runtime Pillow upper bound from <13.0 to <14.0 for Python 3.10–3.14. It preserves the existing lower bounds and updates the docu…
Out of Scope Changes check Passed The reviewed changes only update Pillow version bounds in pyproject.toml. The runtime change implements issue #829. The documentation dependency change supports the same version-compatibility objectiv…
Docstring Coverage Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Full details: Linked Issues check

Explanation

Issue #829 requires support for Pillow 13. The pull request changes the runtime Pillow upper bound from <13.0 to <14.0 for Python 3.10–3.14. It preserves the existing lower bounds and updates the documentation dependency group from <13.0.0 to <14.0.0. The pull request description reports that image tests pass with Pillow 13.0.0.

Full details: Out of Scope Changes check

Explanation

The reviewed changes only update Pillow version bounds in pyproject.toml. The runtime change implements issue #829. The documentation dependency change supports the same version-compatibility objective. No unrelated change is shown.

Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0 files. (1 skipped: 1 unsupported.)

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@m-misiura

Copy link
Copy Markdown

Enabling e.g. Pillow 13 is very relevant to my projects as it would enable better CVE resolution; @joein could you provide any timescales on when this might be feasible?

Thanks in advance

pvliesdonk added a commit to pvliesdonk/markdown-vault-mcp that referenced this pull request Oct 21, 2026
…sory fixes

pillow 12.3.0 carries eight advisories fixed only in 13.0.0, and every
fastembed release through 0.9.0 caps pillow<13.0. A [tool.uv]
override-dependencies entry lifts the cap until fastembed releases
qdrant/fastembed#830.

Refs #1824

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
pvliesdonk added a commit to pvliesdonk/markdown-vault-mcp that referenced this pull request Oct 21, 2026
…sory fixes (#1826)

## Closes / Refs

Closes #1824
Refs pvliesdonk/fastmcp-server-template#813, #1823

## What & why

CI's `Dependency Audit` fails on #1823 and will fail on `main` on its
next run. `pillow` 12.3.0 carries eight new advisories (CVE-2026-112395,
-112397, -112400, -112404, -112895, -112896, -112897, -112899), all
fixed only in 13.0.0. `pillow` comes in only through `fastembed`, and
every `fastembed` release through 0.9.0 caps `pillow<13.0`, so neither
Renovate nor `uv lock --upgrade` can reach the fix. The Docker image
installs `--extra all`, so the vulnerable `pillow` ships in it.

The change:

- `[tool.uv] override-dependencies = ["pillow>=13"]` with `# until:
#1824`. An override is needed because a constraint would intersect with
`<13.0` and resolve to nothing. Upstream qdrant/fastembed#830 raises the
cap with no code change, and fastembed's image tests pass on Pillow
13.0.0. `import fastembed` loads Pillow, and it imports cleanly on
13.0.0. This server only uses text embeddings, which never call Pillow.
Nothing else in the lock moves. The `certifi` bump this PR first carried
(PYSEC-2026-4320) landed on `main` separately in #1828.

## What this PR deliberately does NOT do

Nothing beyond the override. The branch is rebased onto `main` at
template v11.4.0, whose audit reads the hashed export with
`--require-hashes --disable-pip`
(pvliesdonk/fastmcp-server-template#814). pip no longer re-resolves the
dependencies, so the override no longer causes `ResolutionImpossible`.
v11.4.0 also takes the audit out of `CI Success`
(pvliesdonk/fastmcp-server-template#816).

After this merges, tick the rebase box on #1823.

## Design

None.

## Local review

- [x] Ran a local self-review of the cumulative diff before `gh pr
create`.
- [x] No commit carries `!`.

Self-review `96992a30..433defa` (after rebasing onto `main` and
re-locking), charters: rules, diff, comments, history (normative: none
in this change). Coverage: full. Template conformance: no new drift.
`check_pins.py`: OK, two pins with open exit conditions. The lock
changes one package version, pillow 12.3.0 → 13.0.0. `main`'s audit
commands report `No known vulnerabilities found`, and the full suite
passes on pillow 13 (6405 passed; one git-lineage test that also fails
on a clean `main` locally was deselected). pillow 13.0.0 has cp311–cp314
manylinux wheels for x86_64 and aarch64, which covers the
`python:3.14-slim` image. No findings.

**Title type is a call for the account holder.** `fix(deps)` cuts a
patch release, so the Docker image ships the patched pillow. Precedent
for advisory bumps (#1688, #1747) is `chore(deps)`, but those touched
nothing that ships.

## Docs impact

- [ ] `README.md`: not affected.
- [ ] `docs/` site pages: not affected.
- [ ] `docs/design/`: not affected.
- [ ] Inline docstrings: not affected.
- [x] No spec, so no decisions to port.

Gates: ruff, mypy and pre-commit pass. `uv run pytest -q` passes (6394
passed, 2 skipped) except
`tests/test_git_merge_lineage.py::TestTheBoundaryHoldsAcrossTheMerge::test_a_predecessor_of_the_old_name_stays_out`.
That test fails identically on pristine `main` under local git 2.56.0
(CI runs 2.55.0), and it has nothing to do with this change.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---
_Agent-authored: written by [Claude Code](https://claude.ai/code) under
this account's credentials. Analysis and proposal, not a decision by the
account holder._

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
BBYU26 added a commit to Admin-Atlas/Personal-Manager that referenced this pull request Oct 22, 2026
…stls-webpki; Python 3.11 or newer → 3.148.7-alpha (#968)

pip-audit and cargo-deny, and with them the required `dependencies`
check, have been red on main and on every PR since this week's
advisories. This takes all of them in one place.

pillow 12.3.0 carries CVE-2026-112895, -112400, -112397, -112896,
-112897, -112395, -112404 and -112899, and GitHub lists about forty more
advisories published from 2026-10-17, two of them critical (among them
heap overflows in the FlashPix and JPEG decoders). All are fixed only in
pillow 13.0.0; there is no 12.x after 12.3.0.

certifi before 2026.10.19 trusts the emSign ECC Root CA - G3, under
which eight eMudhra intermediates have compromised keys (PYSEC-2026-4320,
GHSA-6q48-6c7w-9gw2). The same distrust reaches Rust as
RUSTSEC-2026-0381 (webpki-roots), RUSTSEC-2026-0382 (rustls-webpki) and
RUSTSEC-2026-0383 (webpki-root-certs), all CVE-2026-111943.
`cargo update -p` moves rustls-webpki 0.103.15 to 0.103.16 and
webpki-roots and webpki-root-certs 1.0.7 to 1.0.10, and nothing else in
Cargo.lock. In the sidecar locks certifi moves to 2026.10.19 with every
other pin held. Its licence was re-entered by hand after reading the
wheel: MPL-2.0, with a LICENSE byte-identical to 2026.7.22's.

fastembed 0.9.0, the latest release, still declares pillow<13 on every
Python although its code runs on 13 (qdrant/fastembed#830 lifts the cap;
open and unmerged). So pillow==13.0.0 also goes in a new
sidecar/requirements-override.txt, which `just lock-regen` passes to
`uv pip compile --override` for the base lock only and stamps in its
header. check-requirements-lock verifies the stamp, and that the file
only overrides packages requirements.txt pins at the same version.
Remove the override line once a fastembed release allows pillow 13.

Because the lock is resolved past that cap, pip's own resolver refuses
it, so every install of a lock now passes --no-deps beside
--require-hashes: the base and optional-component installs in
sidecar.rs, pr.yml's locked-dependency test step and release.yml's
python-smoke. Every line is still pinned and hash-checked, and the lock
is complete because uv resolved it. `just pip-audit` now audits the
hashed locks with --disable-pip instead of installing them; on the old
locks it still reports all eight pillow advisories.

pillow 13 needs Python 3.11, so MIN_PYTHON goes from 3.10 to 3.11 (3.10
reaches end of life this month). The Windows and Linux installers bundle
3.12, and on a Mac PM uses the machine's Python when it is new enough
and downloads its own 3.12 otherwise. So the new floor reaches only a
venv an older PM built on a 3.10, which is rebuilt once on the next
launch, and from-source development on a machine with nothing newer
than 3.10. The setup messages now take the version from MIN_PYTHON. The
locks lose the 13 package versions that existed only for Python below
3.11, and tzdata's 3.10 marker. pillow 13.0.0's wheel LICENSE is
MIT-CMU plus the permissive licences of its bundled natives,
byte-identical to 12.3.0's on Linux and macOS.

Hardening, on any pillow: the sidecar opens a photo only as a photo
format (JPEG, PNG, WebP, and HEIF once pi-heif has registered it), the
one its extension names tried first. A TIFF, FlashPix, EPS or any other
format renamed .jpg no longer reaches its decoder, while a PNG or WebP
saved as .jpg, or a JPEG saved as .png, still reads. Without pi-heif a
.heic is tried as the other three, so a real HEIC is refused and a JPEG
saved as .heic still reads; any other extension is refused.
The fallback that handed rapidocr the raw path when PM's own open
failed is gone, since rapidocr opens a path with no such restriction.
With OCR on, the pixels are decoded before the engine loads, so a file
cut off halfway comes back with no size (its EXIF kept) and its row
blames the file, not text recognition; with OCR off nothing decodes the
pixels, as before. The photo's file is closed once it has been read.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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.

[Feature]: Support pillow 13

2 participants