From 9099d0b09152ba3ca6b74962a1b1ffb1cfbe3860 Mon Sep 17 00:00:00 2001 From: DWesl <22566757+DWesl@users.noreply.github.com> Date: Thu, 4 Nov 2021 10:10:19 -0400 Subject: [PATCH 1/3] Update Cygwin test dependencies They weren't getting detected, so I specified the python version explicitly. --- .github/workflows/test-cygwin.yml | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/.github/workflows/test-cygwin.yml b/.github/workflows/test-cygwin.yml index ee8a5cf0200..2f1cdfa2d37 100644 --- a/.github/workflows/test-cygwin.yml +++ b/.github/workflows/test-cygwin.yml @@ -33,14 +33,14 @@ jobs: with: platform: ${{ matrix.platform }} packages: >- - python3-cffi - python3-devel - python3-numpy - python3-olefile - python3-pip + python38-cffi + python38-devel + python38-numpy + python38-olefile + python38-pip python3-pyqt5 - python3-setuptools - python3-tkinter + python38-setuptools + python38-tkinter ghostscript libfreetype-devel libimagequant-devel @@ -52,29 +52,33 @@ jobs: libwebp-devel libX11-xcb-devel subversion + netpbm + jpeg + ImageMagick - name: Install Python dependencies run: | - python3 -m pip install pyroma pytest pytest-cov pytest-timeout + which python3.8 + python3.8 -m pip install pyroma pytest pytest-cov pytest-timeout cd $GITHUB_WORKSPACE pushd depends && ./install_extra_test_images.sh && popd - name: Build Pillow run: | cd $GITHUB_WORKSPACE - CFLAGS="-coverage" python3 setup.py build_ext install + CFLAGS="-coverage" python3.8 setup.py build_ext install - name: Test Pillow run: | cd $GITHUB_WORKSPACE - python3 selftest.py --installed - python3 -c "from PIL import Image" - python3 -m pytest -v --cov PIL --cov Tests --cov-report term --cov-report xml Tests + python3.8 selftest.py --installed + python3.8 -c "from PIL import Image" + python3.8 -m pytest -v --cov PIL --cov Tests --cov-report term --cov-report xml Tests - name: Upload coverage run: | cd $GITHUB_WORKSPACE - python3 -m pip install codecov + python3.8 -m pip install codecov bash <(curl -s https://codecov.io/bash) -F GHA_Windows env: CODECOV_NAME: ${{ matrix.name }} From 25c3f03d482d3369b1c6f87ee93326378bdeb4f9 Mon Sep 17 00:00:00 2001 From: DWesl <22566757+DWesl@users.noreply.github.com> Date: Thu, 4 Nov 2021 15:00:31 -0400 Subject: [PATCH 2/3] Add rebase step before Cygwin tests Try to head off fork() failures in the tests running external tools. --- .github/workflows/test-cygwin.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/test-cygwin.yml b/.github/workflows/test-cygwin.yml index 2f1cdfa2d37..6f0da969a1a 100644 --- a/.github/workflows/test-cygwin.yml +++ b/.github/workflows/test-cygwin.yml @@ -67,6 +67,11 @@ jobs: run: | cd $GITHUB_WORKSPACE CFLAGS="-coverage" python3.8 setup.py build_ext install + + - name: Rebase Pillow DLLs + run: | + cd $GITHUB_WORKSPACE + /usr/bin/rebase --database --oblivious $(find /usr/{,local/}lib/python3.8/site-packages/ -name \*.dll) - name: Test Pillow run: | From 053cf53105b3850412a07a601e54ceab4a70d8ff Mon Sep 17 00:00:00 2001 From: DWesl <22566757+DWesl@users.noreply.github.com> Date: Thu, 4 Nov 2021 20:03:24 -0400 Subject: [PATCH 3/3] Don't try to run the netpbm tests on Cygwin CI. They're crashing on CI and fine locally. There's no obvious reason for them to crash, so skip installing and testing that. --- .github/workflows/test-cygwin.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/test-cygwin.yml b/.github/workflows/test-cygwin.yml index 6f0da969a1a..4bf7b435853 100644 --- a/.github/workflows/test-cygwin.yml +++ b/.github/workflows/test-cygwin.yml @@ -52,7 +52,6 @@ jobs: libwebp-devel libX11-xcb-devel subversion - netpbm jpeg ImageMagick