Skip to content

Commit 9239820

Browse files
committed
Merge branch 'main' into fix/gimppalette
2 parents ea271be + e1bf0f6 commit 9239820

File tree

735 files changed

+36793
-18044
lines changed

Some content is hidden

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

735 files changed

+36793
-18044
lines changed

.appveyor.yml

Lines changed: 0 additions & 95 deletions
This file was deleted.

.ci/after_success.sh

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
#!/bin/bash
22

33
# gather the coverage data
4-
python3 -m pip install codecov
5-
if [[ $MATRIX_DOCKER ]]; then
6-
python3 -m coverage xml --ignore-errors
7-
else
8-
python3 -m coverage xml
9-
fi
4+
python3 -m pip install coverage
5+
python3 -m coverage xml

.ci/build.sh

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,5 @@
33
set -e
44

55
python3 -m coverage erase
6-
if [ $(uname) == "Darwin" ]; then
7-
export CPPFLAGS="-I/usr/local/miniconda/include";
8-
fi
96
make clean
107
make install-coverage

.ci/install.sh

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
aptget_update()
44
{
5-
if [ ! -z $1 ]; then
5+
if [ -n "$1" ]; then
66
echo ""
77
echo "Retrying apt-get update..."
88
echo ""
99
fi
10-
output=`sudo apt-get update 2>&1`
10+
output=$(sudo apt-get update 2>&1)
1111
echo "$output"
1212
if [[ $output == *[WE]:\ * ]]; then
1313
return 1
@@ -20,16 +20,17 @@ fi
2020
set -e
2121

2222
if [[ $(uname) != CYGWIN* ]]; then
23-
sudo apt-get -qq install libfreetype6-dev liblcms2-dev python3-tk\
24-
ghostscript libffi-dev libjpeg-turbo-progs libopenjp2-7-dev\
25-
cmake meson imagemagick libharfbuzz-dev libfribidi-dev
23+
sudo apt-get -qq install libfreetype6-dev liblcms2-dev libtiff-dev python3-tk\
24+
ghostscript libjpeg-turbo8-dev libopenjp2-7-dev\
25+
cmake meson imagemagick libharfbuzz-dev libfribidi-dev\
26+
sway wl-clipboard libopenblas-dev
2627
fi
2728

2829
python3 -m pip install --upgrade pip
2930
python3 -m pip install --upgrade wheel
30-
PYTHONOPTIMIZE=0 python3 -m pip install cffi
3131
python3 -m pip install coverage
3232
python3 -m pip install defusedxml
33+
python3 -m pip install ipython
3334
python3 -m pip install olefile
3435
python3 -m pip install -U pytest
3536
python3 -m pip install -U pytest-cov
@@ -41,8 +42,15 @@ if [[ $(uname) != CYGWIN* ]]; then
4142

4243
# PyQt6 doesn't support PyPy3
4344
if [[ $GHA_PYTHON_VERSION == 3.* ]]; then
44-
sudo apt-get -qq install libegl1 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-shape0 libxkbcommon-x11-0
45-
python3 -m pip install pyqt6
45+
sudo apt-get -qq install libegl1 libxcb-cursor0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-shape0 libxkbcommon-x11-0
46+
# TODO Update condition when pyqt6 supports free-threading
47+
if ! [[ "$PYTHON_GIL" == "0" ]]; then python3 -m pip install pyqt6 ; fi
48+
fi
49+
50+
# Pyroma uses non-isolated build and fails with old setuptools
51+
if [[ $GHA_PYTHON_VERSION == 3.9 ]]; then
52+
# To match pyproject.toml
53+
python3 -m pip install "setuptools>=67.8"
4654
fi
4755

4856
# webp

.ci/requirements-cibw.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
cibuildwheel==2.23.1

.ci/requirements-mypy.txt

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
mypy==1.15.0
2+
IceSpringPySideStubs-PyQt6
3+
IceSpringPySideStubs-PySide6
4+
ipython
5+
numpy
6+
packaging
7+
pytest
8+
sphinx
9+
types-atheris
10+
types-defusedxml
11+
types-olefile
12+
types-setuptools

.ci/test.cmd

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
python.exe -c "from PIL import Image"
2+
IF ERRORLEVEL 1 EXIT /B
3+
python.exe -bb -m pytest -v -x -W always --cov PIL --cov Tests --cov-report term --cov-report xml Tests

.ci/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ set -e
44

55
python3 -c "from PIL import Image"
66

7-
python3 -bb -m pytest -v -x -W always --cov PIL --cov Tests --cov-report term Tests $REVERSE
7+
python3 -bb -m pytest -v -x -W always --cov PIL --cov Tests --cov-report term --cov-report xml Tests $REVERSE

.clang-format

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,13 @@
33
BasedOnStyle: Google
44
AlwaysBreakAfterReturnType: All
55
AllowShortIfStatementsOnASingleLine: false
6-
AlignAfterOpenBracket: AlwaysBreak
6+
AlignAfterOpenBracket: BlockIndent
77
BinPackArguments: false
88
BinPackParameters: false
99
BreakBeforeBraces: Attach
1010
ColumnLimit: 88
1111
DerivePointerAlignment: false
12+
IndentGotoLabels: false
1213
IndentWidth: 4
1314
Language: Cpp
1415
PointerAlignment: Right

.coveragerc

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,22 @@
22

33
[report]
44
# Regexes for lines to exclude from consideration
5-
exclude_lines =
6-
# Have to re-enable the standard pragma:
7-
pragma: no cover
8-
9-
# Don't complain if non-runnable code isn't run:
5+
exclude_also =
6+
# Don't complain if non-runnable code isn't run
107
if 0:
118
if __name__ == .__main__.:
129
# Don't complain about debug code
1310
if DEBUG:
11+
# Don't complain about compatibility code for missing optional dependencies
12+
except ImportError
13+
if TYPE_CHECKING:
14+
@abc.abstractmethod
15+
# Empty bodies in protocols or abstract methods
16+
^\s*def [a-zA-Z0-9_]+\(.*\)(\s*->.*)?:\s*\.\.\.(\s*#.*)?$
17+
^\s*\.\.\.(\s*#.*)?$
1418

1519
[run]
1620
omit =
1721
Tests/32bit_segfault_check.py
18-
Tests/bench_cffi_access.py
1922
Tests/check_*.py
2023
Tests/createfontdatachunk.py

0 commit comments

Comments
 (0)