From 9d428b07ae610fddd508c8fef31ecc0207dde339 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Tue, 30 Jun 2020 05:42:19 -0400 Subject: [PATCH] Add more test dependencies. --- 0001-matplotlibrc-path-search-fix.patch | 2 +- ...sion-to-2.10.1-and-update-tolerances.patch | 2 +- ...-tolerance-slightly-for-32-bit-syste.patch | 2 +- 0004-Update-aarch64-tolerances.patch | 2 +- ...ease-tolerance-for-ppc64le-and-s390x.patch | 2 +- ...our-s-test_internal_cpp_api-directly.patch | 2 +- ...ce-for-test_usetex-and-test_rgba_mar.patch | 44 +++++++++++++++++++ python-matplotlib.spec | 14 +++++- 8 files changed, 62 insertions(+), 8 deletions(-) create mode 100644 0007-Increase-tolerance-for-test_usetex-and-test_rgba_mar.patch diff --git a/0001-matplotlibrc-path-search-fix.patch b/0001-matplotlibrc-path-search-fix.patch index 906ab8f..fd90740 100644 --- a/0001-matplotlibrc-path-search-fix.patch +++ b/0001-matplotlibrc-path-search-fix.patch @@ -1,7 +1,7 @@ From e56c8930052b4ac06f5ae58cac8d97dec728f314 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Wed, 27 Sep 2017 19:35:59 -0400 -Subject: [PATCH 1/6] matplotlibrc path search fix +Subject: [PATCH 1/7] matplotlibrc path search fix Signed-off-by: Elliott Sales de Andrade --- diff --git a/0002-Set-FreeType-version-to-2.10.1-and-update-tolerances.patch b/0002-Set-FreeType-version-to-2.10.1-and-update-tolerances.patch index 1f41a15..ffcc5f4 100644 --- a/0002-Set-FreeType-version-to-2.10.1-and-update-tolerances.patch +++ b/0002-Set-FreeType-version-to-2.10.1-and-update-tolerances.patch @@ -1,7 +1,7 @@ From e67b2eb6fb233085fb58e61217a946ea28f3649f Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Fri, 14 Feb 2020 06:05:42 -0500 -Subject: [PATCH 2/6] Set FreeType version to 2.10.1 and update tolerances. +Subject: [PATCH 2/7] Set FreeType version to 2.10.1 and update tolerances. Signed-off-by: Elliott Sales de Andrade --- diff --git a/0003-Increase-default-tolerance-slightly-for-32-bit-syste.patch b/0003-Increase-default-tolerance-slightly-for-32-bit-syste.patch index a837e04..4a85571 100644 --- a/0003-Increase-default-tolerance-slightly-for-32-bit-syste.patch +++ b/0003-Increase-default-tolerance-slightly-for-32-bit-syste.patch @@ -1,7 +1,7 @@ From a200118d059ec46d29ef2e5b71892d60d31a6103 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Sun, 28 Jun 2020 17:37:36 -0400 -Subject: [PATCH 3/6] Increase default tolerance slightly for 32-bit systems. +Subject: [PATCH 3/7] Increase default tolerance slightly for 32-bit systems. Around 900 tests fail on 32-bit systems, but with rather small RMS. diff --git a/0004-Update-aarch64-tolerances.patch b/0004-Update-aarch64-tolerances.patch index 4010ba7..bdbf526 100644 --- a/0004-Update-aarch64-tolerances.patch +++ b/0004-Update-aarch64-tolerances.patch @@ -1,7 +1,7 @@ From 954ebfd469a0979e0817db96760ea1f5542f2729 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Mon, 29 Jun 2020 03:49:29 -0400 -Subject: [PATCH 4/6] Update aarch64 tolerances. +Subject: [PATCH 4/7] Update aarch64 tolerances. Signed-off-by: Elliott Sales de Andrade --- diff --git a/0005-Increase-tolerance-for-ppc64le-and-s390x.patch b/0005-Increase-tolerance-for-ppc64le-and-s390x.patch index 75eb308..2045338 100644 --- a/0005-Increase-tolerance-for-ppc64le-and-s390x.patch +++ b/0005-Increase-tolerance-for-ppc64le-and-s390x.patch @@ -1,7 +1,7 @@ From efd56e93d7e8f6a63d734f98c6110795dd914418 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Mon, 29 Jun 2020 17:29:56 -0400 -Subject: [PATCH 5/6] Increase tolerance for ppc64le and s390x. +Subject: [PATCH 5/7] Increase tolerance for ppc64le and s390x. These are mostly the same as the aarch64 increased tolerances. diff --git a/0006-Fix-running-contour-s-test_internal_cpp_api-directly.patch b/0006-Fix-running-contour-s-test_internal_cpp_api-directly.patch index 3e2c756..4b649bb 100644 --- a/0006-Fix-running-contour-s-test_internal_cpp_api-directly.patch +++ b/0006-Fix-running-contour-s-test_internal_cpp_api-directly.patch @@ -1,7 +1,7 @@ From 717fb2ce07ac66794df6b4e1833e14d2c8036233 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Mon, 29 Jun 2020 17:35:37 -0400 -Subject: [PATCH 6/6] Fix running contour's test_internal_cpp_api directly. +Subject: [PATCH 6/7] Fix running contour's test_internal_cpp_api directly. The `matplotlib._contour` module is lazily loaded, so using it directly (as done in this test) may fail if something else doesn't load it. This diff --git a/0007-Increase-tolerance-for-test_usetex-and-test_rgba_mar.patch b/0007-Increase-tolerance-for-test_usetex-and-test_rgba_mar.patch new file mode 100644 index 0000000..c1f7c11 --- /dev/null +++ b/0007-Increase-tolerance-for-test_usetex-and-test_rgba_mar.patch @@ -0,0 +1,44 @@ +From 1c614f815ec7f563cbfbab4f8a2155a46080965b Mon Sep 17 00:00:00 2001 +From: Elliott Sales de Andrade +Date: Tue, 30 Jun 2020 04:43:57 -0400 +Subject: [PATCH 7/7] Increase tolerance for test_usetex and test_rgba_markers. + +These should have been updated in images, but weren't. They can be fixed +properly for 3.3.0 final. + +Signed-off-by: Elliott Sales de Andrade +--- + lib/matplotlib/tests/test_axes.py | 2 +- + lib/matplotlib/tests/test_usetex.py | 3 ++- + 2 files changed, 3 insertions(+), 2 deletions(-) + +diff --git a/lib/matplotlib/tests/test_axes.py b/lib/matplotlib/tests/test_axes.py +index 48cfdf582..50dc95925 100644 +--- a/lib/matplotlib/tests/test_axes.py ++++ b/lib/matplotlib/tests/test_axes.py +@@ -3435,7 +3435,7 @@ def test_transparent_markers(): + ax.plot(data, 'D', mfc='none', markersize=100) + + +-@image_comparison(['rgba_markers'], remove_text=True) ++@image_comparison(['rgba_markers'], remove_text=True, tol=6.2) + def test_rgba_markers(): + fig, axs = plt.subplots(ncols=2) + rcolors = [(1, 0, 0, 1), (1, 0, 0, 0.5)] +diff --git a/lib/matplotlib/tests/test_usetex.py b/lib/matplotlib/tests/test_usetex.py +index 25006f174..c2a9c9b20 100644 +--- a/lib/matplotlib/tests/test_usetex.py ++++ b/lib/matplotlib/tests/test_usetex.py +@@ -13,7 +13,8 @@ if not mpl.checkdep_usetex(True): + @image_comparison( + baseline_images=['test_usetex'], + extensions=['pdf', 'png'], +- style="mpl20") ++ style="mpl20", ++ tol=12.9) + def test_usetex(): + mpl.rcParams['text.usetex'] = True + fig = plt.figure() +-- +2.25.4 + diff --git a/python-matplotlib.spec b/python-matplotlib.spec index 9588a6f..50d7a3f 100644 --- a/python-matplotlib.spec +++ b/python-matplotlib.spec @@ -43,7 +43,7 @@ Name: python-matplotlib Version: 3.3.0 %global Version 3.3.0rc1 -Release: 0.1.rc1%{?dist} +Release: 0.2.rc1%{?dist} Summary: Python 2D plotting library # qt4_editor backend is MIT License: Python and MIT @@ -67,6 +67,8 @@ Patch0002: 0004-Update-aarch64-tolerances.patch Patch0003: 0005-Increase-tolerance-for-ppc64le-and-s390x.patch # https://github.com/matplotlib/matplotlib/pull/17797 Patch0004: 0006-Fix-running-contour-s-test_internal_cpp_api-directly.patch +# Will be fixed for 3.3.0 final. +Patch0005: 0007-Increase-tolerance-for-test_usetex-and-test_rgba_mar.patch BuildRequires: gcc BuildRequires: gcc-c++ @@ -77,6 +79,11 @@ BuildRequires: qhull-devel BuildRequires: xorg-x11-server-Xvfb BuildRequires: zlib-devel +BuildRequires: ghostscript +BuildRequires: ImageMagick +BuildRequires: inkscape + +BuildRequires: texlive-dvipng BuildRequires: texlive-latex-bin BuildRequires: texlive-tex-bin BuildRequires: texlive-xetex-bin @@ -268,7 +275,6 @@ Requires: python3-wxpython4 %package -n python3-matplotlib-doc Summary: Documentation files for python-matplotlib %if %{with_html} -BuildRequires: texlive-dvipng BuildRequires: graphviz BuildRequires: python3-sphinx BuildRequires: tex(latex) @@ -310,6 +316,7 @@ cp -p %{SOURCE1} setup.cfg %patch0002 -p1 %patch0003 -p1 %patch0004 -p1 +%patch0005 -p1 %build @@ -451,6 +458,9 @@ PYTHONDONTWRITEBYTECODE=1 \ %changelog +* Tue Jun 30 2020 Elliott Sales de Andrade - 3.3.0-0.2.rc1 +- Add more test dependencies + * Mon Jun 29 2020 Elliott Sales de Andrade - 3.3.0-0.1.rc1 - Update to latest version