Skip to content

Commit adc6689

Browse files
authored
Merge branch 'main' into jxl-support2
2 parents 90ba70d + f78663b commit adc6689

126 files changed

Lines changed: 870 additions & 540 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.ci/requirements-cibw.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
cibuildwheel==3.3.0
1+
cibuildwheel==3.3.1

.ci/requirements-mypy.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
mypy==1.19.0
1+
mypy==1.19.1
22
arro3-compute
33
arro3-core
44
IceSpringPySideStubs-PyQt6
@@ -9,7 +9,6 @@ packaging
99
pyarrow-stubs
1010
pybind11
1111
pytest
12-
sphinx
1312
types-atheris
1413
types-defusedxml
1514
types-olefile

.github/renovate.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
"labels": [
77
"Dependency"
88
],
9+
"minimumReleaseAge": "7 days",
910
"packageRules": [
1011
{
1112
"groupName": "github-actions",

.github/workflows/cifuzz.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,13 +44,13 @@ jobs:
4444
language: python
4545
dry-run: false
4646
- name: Upload New Crash
47-
uses: actions/upload-artifact@v5
47+
uses: actions/upload-artifact@v6
4848
if: failure() && steps.build.outcome == 'success'
4949
with:
5050
name: artifacts
5151
path: ./out/artifacts
5252
- name: Upload Legacy Crash
53-
uses: actions/upload-artifact@v5
53+
uses: actions/upload-artifact@v6
5454
if: steps.run.outcome == 'success'
5555
with:
5656
name: crash

.github/workflows/docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ jobs:
4949
run: python3 .github/workflows/system-info.py
5050

5151
- name: Cache libimagequant
52-
uses: actions/cache@v4
52+
uses: actions/cache@v5
5353
id: cache-libimagequant
5454
with:
5555
path: ~/cache-libimagequant

.github/workflows/lint.yml

Lines changed: 17 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -2,55 +2,31 @@ name: Lint
22

33
on: [push, pull_request, workflow_dispatch]
44

5+
permissions: {}
6+
57
env:
68
FORCE_COLOR: 1
7-
8-
permissions:
9-
contents: read
9+
PREK_COLOR: always
10+
RUFF_OUTPUT_FORMAT: github
1011

1112
concurrency:
1213
group: ${{ github.workflow }}-${{ github.ref }}
1314
cancel-in-progress: true
1415

1516
jobs:
16-
build:
17-
17+
lint:
1818
runs-on: ubuntu-latest
19-
2019
name: Lint
21-
2220
steps:
23-
- uses: actions/checkout@v6
24-
with:
25-
persist-credentials: false
26-
27-
- name: pre-commit cache
28-
uses: actions/cache@v4
29-
with:
30-
path: ~/.cache/pre-commit
31-
key: lint-pre-commit-${{ hashFiles('**/.pre-commit-config.yaml') }}
32-
restore-keys: |
33-
lint-pre-commit-
34-
35-
- name: Set up Python
36-
uses: actions/setup-python@v6
37-
with:
38-
python-version: "3.x"
39-
cache: pip
40-
cache-dependency-path: "setup.py"
41-
42-
- name: Build system information
43-
run: python3 .github/workflows/system-info.py
44-
45-
- name: Install dependencies
46-
run: |
47-
python3 -m pip install -U pip
48-
python3 -m pip install -U tox
49-
50-
- name: Lint
51-
run: tox -e lint
52-
env:
53-
PRE_COMMIT_COLOR: always
54-
55-
- name: Mypy
56-
run: tox -e mypy
21+
- uses: actions/checkout@v6
22+
with:
23+
persist-credentials: false
24+
- uses: actions/setup-python@v6
25+
with:
26+
python-version: "3.x"
27+
- name: Install uv
28+
uses: astral-sh/setup-uv@v7
29+
- name: Lint
30+
run: uvx --with tox-uv tox -e lint
31+
- name: Mypy
32+
run: uvx --with tox-uv tox -e mypy

.github/workflows/test-windows.yml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ jobs:
112112

113113
- name: Cache build
114114
id: build-cache
115-
uses: actions/cache@v4
115+
uses: actions/cache@v5
116116
with:
117117
path: winbuild\build
118118
key:
@@ -196,8 +196,9 @@ jobs:
196196
# trim ~150MB for each job
197197
- name: Optimize build cache
198198
if: steps.build-cache.outputs.cache-hit != 'true'
199-
run: rmdir /S /Q winbuild\build\src
200-
shell: cmd
199+
run: |
200+
rm -rf winbuild\build\src
201+
shell: bash
201202

202203
- name: Build Pillow
203204
run: |
@@ -214,9 +215,7 @@ jobs:
214215
215216
- name: Test Pillow
216217
run: |
217-
path %GITHUB_WORKSPACE%\winbuild\build\bin;%PATH%
218218
.ci\test.cmd
219-
shell: cmd
220219
221220
- name: Prepare to upload errors
222221
if: failure()
@@ -225,7 +224,7 @@ jobs:
225224
shell: bash
226225

227226
- name: Upload errors
228-
uses: actions/upload-artifact@v5
227+
uses: actions/upload-artifact@v6
229228
if: failure()
230229
with:
231230
name: errors

.github/workflows/test.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ concurrency:
2929
env:
3030
COVERAGE_CORE: sysmon
3131
FORCE_COLOR: 1
32+
PIP_DISABLE_PIP_VERSION_CHECK: 1
3233

3334
jobs:
3435
build:
@@ -92,7 +93,7 @@ jobs:
9293

9394
- name: Cache libimagequant
9495
if: startsWith(matrix.os, 'ubuntu')
95-
uses: actions/cache@v4
96+
uses: actions/cache@v5
9697
id: cache-libimagequant
9798
with:
9899
path: ~/cache-libimagequant
@@ -143,7 +144,7 @@ jobs:
143144
mkdir -p Tests/errors
144145
145146
- name: Upload errors
146-
uses: actions/upload-artifact@v5
147+
uses: actions/upload-artifact@v6
147148
if: failure()
148149
with:
149150
name: errors

.github/workflows/wheels-dependencies.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -95,16 +95,16 @@ if [[ -n "$IOS_SDK" ]]; then
9595
else
9696
FREETYPE_VERSION=2.14.1
9797
fi
98-
HARFBUZZ_VERSION=12.3.0
99-
LIBPNG_VERSION=1.6.53
98+
HARFBUZZ_VERSION=12.3.2
99+
LIBPNG_VERSION=1.6.54
100100
JPEGTURBO_VERSION=3.1.3
101101
OPENJPEG_VERSION=2.5.4
102102
JPEGXL_VERSION=0.11.1
103103
XZ_VERSION=5.8.2
104104
ZSTD_VERSION=1.5.7
105105
TIFF_VERSION=4.7.1
106-
LCMS2_VERSION=2.17
107-
ZLIB_NG_VERSION=2.3.2
106+
LCMS2_VERSION=2.18
107+
ZLIB_NG_VERSION=2.3.3
108108
LIBWEBP_VERSION=1.6.0
109109
BZIP2_VERSION=1.0.8
110110
LIBXCB_VERSION=1.17.0
@@ -283,7 +283,7 @@ function build {
283283

284284
build_simple xcb-proto 1.17.0 https://xorg.freedesktop.org/archive/individual/proto
285285
if [[ -n "$IS_MACOS" ]]; then
286-
build_simple xorgproto 2024.1 https://www.x.org/pub/individual/proto
286+
build_simple xorgproto 2025.1 https://www.x.org/pub/individual/proto
287287
build_simple libXau 1.0.12 https://www.x.org/pub/individual/lib
288288
build_simple libpthread-stubs 0.5 https://xcb.freedesktop.org/dist
289289
else

.github/workflows/wheels.yml

Lines changed: 21 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ jobs:
134134
CIBW_MANYLINUX_X86_64_IMAGE: ${{ matrix.manylinux }}
135135
MACOSX_DEPLOYMENT_TARGET: ${{ matrix.macosx_deployment_target }}
136136

137-
- uses: actions/upload-artifact@v5
137+
- uses: actions/upload-artifact@v6
138138
with:
139139
name: dist-${{ matrix.name }}
140140
path: ./wheelhouse/*.whl
@@ -186,24 +186,18 @@ jobs:
186186

187187
- name: Build wheels
188188
run: |
189-
setlocal EnableDelayedExpansion
190-
for %%f in (winbuild\build\license\*) do (
191-
set x=%%~nf
192-
rem Skip FriBiDi license, it is not included in the wheel.
193-
set fribidi=!x:~0,7!
194-
if NOT !fribidi!==fribidi (
195-
rem Skip imagequant license, it is not included in the wheel.
196-
set libimagequant=!x:~0,13!
197-
if NOT !libimagequant!==libimagequant (
198-
echo. >> LICENSE
199-
echo ===== %%~nf ===== >> LICENSE
200-
echo. >> LICENSE
201-
type %%f >> LICENSE
202-
)
203-
)
204-
)
205-
call winbuild\\build\\build_env.cmd
206-
%pythonLocation%\python.exe -m cibuildwheel . --output-dir wheelhouse
189+
for f in winbuild/build/license/*; do
190+
name=$(basename "${f%.*}")
191+
# Skip FriBiDi license, it is not included in the wheel.
192+
[[ $name == fribidi* ]] && continue
193+
# Skip imagequant license, it is not included in the wheel.
194+
[[ $name == libimagequant* ]] && continue
195+
echo "" >> LICENSE
196+
echo "===== $name =====" >> LICENSE
197+
echo "" >> LICENSE
198+
cat "$f" >> LICENSE
199+
done
200+
cmd //c "winbuild\\build\\build_env.cmd && $pythonLocation\\python.exe -m cibuildwheel . --output-dir wheelhouse"
207201
env:
208202
CIBW_ARCHS: ${{ matrix.cibw_arch }}
209203
CIBW_BEFORE_ALL: "{package}\\winbuild\\build\\build_dep_all.cmd"
@@ -217,16 +211,16 @@ jobs:
217211
-e CI -e GITHUB_ACTIONS
218212
mcr.microsoft.com/windows/servercore:ltsc2022
219213
powershell C:\pillow\.github\workflows\wheels-test.ps1 %CD%\..\venv-test'
220-
shell: cmd
214+
shell: bash
221215

222216
- name: Upload wheels
223-
uses: actions/upload-artifact@v5
217+
uses: actions/upload-artifact@v6
224218
with:
225219
name: dist-windows-${{ matrix.cibw_arch }}
226220
path: ./wheelhouse/*.whl
227221

228222
- name: Upload fribidi.dll
229-
uses: actions/upload-artifact@v5
223+
uses: actions/upload-artifact@v6
230224
with:
231225
name: fribidi-windows-${{ matrix.cibw_arch }}
232226
path: winbuild\build\bin\fribidi*
@@ -246,7 +240,7 @@ jobs:
246240

247241
- run: make sdist
248242

249-
- uses: actions/upload-artifact@v5
243+
- uses: actions/upload-artifact@v6
250244
with:
251245
name: dist-sdist
252246
path: dist/*.tar.gz
@@ -256,7 +250,7 @@ jobs:
256250
runs-on: ubuntu-latest
257251
name: Count dists
258252
steps:
259-
- uses: actions/download-artifact@v6
253+
- uses: actions/download-artifact@v7
260254
with:
261255
pattern: dist-*
262256
path: dist
@@ -275,13 +269,13 @@ jobs:
275269
runs-on: ubuntu-latest
276270
name: Upload wheels to scientific-python-nightly-wheels
277271
steps:
278-
- uses: actions/download-artifact@v6
272+
- uses: actions/download-artifact@v7
279273
with:
280274
pattern: dist-!(sdist)*
281275
path: dist
282276
merge-multiple: true
283277
- name: Upload wheels to scientific-python-nightly-wheels
284-
uses: scientific-python/upload-nightly-action@b36e8c0c10dbcfd2e05bf95f17ef8c14fd708dbf # 0.6.2
278+
uses: scientific-python/upload-nightly-action@5748273c71e2d8d3a61f3a11a16421c8954f9ecf # 0.6.3
285279
with:
286280
artifacts_path: dist
287281
anaconda_nightly_upload_token: ${{ secrets.ANACONDA_ORG_UPLOAD_TOKEN }}
@@ -297,7 +291,7 @@ jobs:
297291
permissions:
298292
id-token: write
299293
steps:
300-
- uses: actions/download-artifact@v6
294+
- uses: actions/download-artifact@v7
301295
with:
302296
pattern: dist-*
303297
path: dist

0 commit comments

Comments
 (0)