From a289f8ffd9150d63478ff22e31021a2e51ae0edd Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Sat, 2 Oct 2021 04:57:29 -0400 Subject: [PATCH] Update to latest release candidate --- .gitignore | 2 ++ 0001-matplotlibrc-path-search-fix.patch | 6 ++-- ...sion-to-2.11.0-and-update-tolerances.patch | 34 +++++++++---------- ...-increase-tolerance-on-rcupdate-test.patch | 6 ++-- ...vironment-is-passed-to-headless-test.patch | 28 --------------- ...a-few-test-tolerances-on-some-arches.patch | 18 +++++----- ...x-broken-QApplication-init-in-a-test.patch | 29 ---------------- python-matplotlib.spec | 11 +++--- sources | 4 +-- 9 files changed, 40 insertions(+), 98 deletions(-) delete mode 100644 0004-Ensure-full-environment-is-passed-to-headless-test.patch rename 0005-Increase-a-few-test-tolerances-on-some-arches.patch => 0004-Increase-a-few-test-tolerances-on-some-arches.patch (88%) delete mode 100644 0006-Fix-broken-QApplication-init-in-a-test.patch diff --git a/.gitignore b/.gitignore index d6672e2..553aa3e 100644 --- a/.gitignore +++ b/.gitignore @@ -69,3 +69,5 @@ matplotlib-1.0.0-without-gpc.tar.gz /matplotlib-3.4.3-with-freetype-2.11.0.tar.gz /matplotlib-3.5.0b1.tar.gz /matplotlib-3.5.0b1-with-freetype-2.11.0.tar.gz +/matplotlib-3.5.0rc1.tar.gz +/matplotlib-3.5.0rc1-with-freetype-2.11.0.tar.gz diff --git a/0001-matplotlibrc-path-search-fix.patch b/0001-matplotlibrc-path-search-fix.patch index ae5dd35..0959d8b 100644 --- a/0001-matplotlibrc-path-search-fix.patch +++ b/0001-matplotlibrc-path-search-fix.patch @@ -1,7 +1,7 @@ -From d3b2da006a21a9cc69ce6181497efab84b23ef0d Mon Sep 17 00:00:00 2001 +From 4039d6d10c679aa5c9a3268fbea663e05acf50d3 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/4] matplotlibrc path search fix Signed-off-by: Elliott Sales de Andrade --- @@ -9,7 +9,7 @@ Signed-off-by: Elliott Sales de Andrade 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/matplotlib/__init__.py b/lib/matplotlib/__init__.py -index 0361a37aed..7f7005f915 100644 +index ba9cd6c90c..bc800e1322 100644 --- a/lib/matplotlib/__init__.py +++ b/lib/matplotlib/__init__.py @@ -524,7 +524,8 @@ def get_cachedir(): diff --git a/0002-Set-FreeType-version-to-2.11.0-and-update-tolerances.patch b/0002-Set-FreeType-version-to-2.11.0-and-update-tolerances.patch index 9de4127..059f120 100644 --- a/0002-Set-FreeType-version-to-2.11.0-and-update-tolerances.patch +++ b/0002-Set-FreeType-version-to-2.11.0-and-update-tolerances.patch @@ -1,7 +1,7 @@ -From d5f27523c1b620a1288d3ffbb173d945d0c88555 Mon Sep 17 00:00:00 2001 +From 0779db3fa70c58e88e048bec9b738ae02fccaead 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.11.0 and update tolerances. +Subject: [PATCH 2/4] Set FreeType version to 2.11.0 and update tolerances. Signed-off-by: Elliott Sales de Andrade --- @@ -15,10 +15,10 @@ Signed-off-by: Elliott Sales de Andrade 7 files changed, 23 insertions(+), 13 deletions(-) diff --git a/lib/matplotlib/__init__.py b/lib/matplotlib/__init__.py -index 7f7005f915..5961fdffd8 100644 +index bc800e1322..10ff904c8e 100644 --- a/lib/matplotlib/__init__.py +++ b/lib/matplotlib/__init__.py -@@ -1199,7 +1199,7 @@ default_test_modules = [ +@@ -1201,7 +1201,7 @@ default_test_modules = [ def _init_tests(): # The version of FreeType to install locally for running the # tests. This must match the value in `setupext.py` @@ -28,10 +28,10 @@ index 7f7005f915..5961fdffd8 100644 from matplotlib import ft2font if (ft2font.__freetype_version__ != LOCAL_FREETYPE_VERSION or diff --git a/lib/matplotlib/tests/test_axes.py b/lib/matplotlib/tests/test_axes.py -index 509910bdee..5b6607a696 100644 +index 2d6c1deed4..472e0e6902 100644 --- a/lib/matplotlib/tests/test_axes.py +++ b/lib/matplotlib/tests/test_axes.py -@@ -6530,7 +6530,7 @@ def test_normal_axes(): +@@ -6556,7 +6556,7 @@ def test_normal_axes(): ] for nn, b in enumerate(bbaxis): targetbb = mtransforms.Bbox.from_bounds(*target[nn]) @@ -40,7 +40,7 @@ index 509910bdee..5b6607a696 100644 target = [ [150.0, 119.999, 930.0, 11.111], -@@ -6548,7 +6548,7 @@ def test_normal_axes(): +@@ -6574,7 +6574,7 @@ def test_normal_axes(): target = [85.5138, 75.88888, 1021.11, 1017.11] targetbb = mtransforms.Bbox.from_bounds(*target) @@ -50,7 +50,7 @@ index 509910bdee..5b6607a696 100644 # test that get_position roundtrips to get_window_extent axbb = ax.get_position().transformed(fig.transFigure).bounds diff --git a/lib/matplotlib/tests/test_constrainedlayout.py b/lib/matplotlib/tests/test_constrainedlayout.py -index 007fac6ec1..a8bb740779 100644 +index a8222a73d5..ea007a233f 100644 --- a/lib/matplotlib/tests/test_constrainedlayout.py +++ b/lib/matplotlib/tests/test_constrainedlayout.py @@ -411,7 +411,7 @@ def test_hidden_axes(): @@ -63,7 +63,7 @@ index 007fac6ec1..a8bb740779 100644 def test_colorbar_align(): diff --git a/lib/matplotlib/tests/test_mathtext.py b/lib/matplotlib/tests/test_mathtext.py -index 768db940c7..3ce83763eb 100644 +index 0055d54a03..09a8005e50 100644 --- a/lib/matplotlib/tests/test_mathtext.py +++ b/lib/matplotlib/tests/test_mathtext.py @@ -1,5 +1,6 @@ @@ -129,10 +129,10 @@ index 23d363b508..e94c863477 100644 diff --git a/setupext.py b/setupext.py -index 81c4fb56eb..c042f1b66d 100644 +index 0d85f479d1..42d6fbe2ca 100644 --- a/setupext.py +++ b/setupext.py -@@ -166,12 +166,18 @@ _freetype_hashes = { +@@ -167,12 +167,18 @@ _freetype_hashes = { '955e17244e9b38adb0c98df66abb50467312e6bb70eac07e49ce6bd1a20e809a', '2.10.1': '3a60d391fd579440561bf0e7f31af2222bc610ad6ce4d9d7bd2165bca8669110', @@ -143,16 +143,16 @@ index 81c4fb56eb..c042f1b66d 100644 + '2.11.0': + 'a45c6b403413abd5706f3582f04c8339d26397c4304b78fa552f2215df64101f', } - # This is the version of FreeType to use when building a local - # version. It must match the value in - # lib/matplotlib.__init__.py and also needs to be changed below in the - # embedded windows build script (grep for "REMINDER" in this file) + # This is the version of FreeType to use when building a local version. It + # must match the value in lib/matplotlib.__init__.py and also needs to be + # changed below in the embedded windows build script (grep for "REMINDER" in + # this file). Also update the cache path in `.circleci/config.yml`. -LOCAL_FREETYPE_VERSION = '2.6.1' +LOCAL_FREETYPE_VERSION = '2.11.0' LOCAL_FREETYPE_HASH = _freetype_hashes.get(LOCAL_FREETYPE_VERSION, 'unknown') - LOCAL_QHULL_VERSION = '2020.2' -@@ -556,6 +562,7 @@ class FreeType(SetupPackage): + # Also update the cache path in `.circleci/config.yml`. +@@ -580,6 +586,7 @@ class FreeType(SetupPackage): ext.extra_objects.insert( 0, str(src_path / 'objs' / '.libs' / libfreetype)) ext.define_macros.append(('FREETYPE_BUILD_TYPE', 'local')) diff --git a/0003-Slightly-increase-tolerance-on-rcupdate-test.patch b/0003-Slightly-increase-tolerance-on-rcupdate-test.patch index 3d6a52e..06b5a16 100644 --- a/0003-Slightly-increase-tolerance-on-rcupdate-test.patch +++ b/0003-Slightly-increase-tolerance-on-rcupdate-test.patch @@ -1,7 +1,7 @@ -From 4542a34eb2ddc6f39e5bad3d2b1c24230cbbdc5f Mon Sep 17 00:00:00 2001 +From af387ba8868b761273dc85b288196822ebba345c Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Fri, 4 Jun 2021 02:32:31 -0400 -Subject: [PATCH 3/6] Slightly increase tolerance on rcupdate test. +Subject: [PATCH 3/4] Slightly increase tolerance on rcupdate test. Signed-off-by: Elliott Sales de Andrade --- @@ -9,7 +9,7 @@ Signed-off-by: Elliott Sales de Andrade 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/matplotlib/tests/test_backend_pgf.py b/lib/matplotlib/tests/test_backend_pgf.py -index a463c96e61..4ff6a50de7 100644 +index 9b5b0b28ee..eac63a6902 100644 --- a/lib/matplotlib/tests/test_backend_pgf.py +++ b/lib/matplotlib/tests/test_backend_pgf.py @@ -136,7 +136,7 @@ def test_rcupdate(): diff --git a/0004-Ensure-full-environment-is-passed-to-headless-test.patch b/0004-Ensure-full-environment-is-passed-to-headless-test.patch deleted file mode 100644 index 8859af0..0000000 --- a/0004-Ensure-full-environment-is-passed-to-headless-test.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 54b7d56a0e51c44a579e6177921aa9562b0e7160 Mon Sep 17 00:00:00 2001 -From: Elliott Sales de Andrade -Date: Tue, 24 Aug 2021 03:28:52 -0400 -Subject: [PATCH 4/6] Ensure full environment is passed to headless test. - -Otherwise, e.g., `PYTHONPATH` is not available. - -Signed-off-by: Elliott Sales de Andrade ---- - lib/matplotlib/tests/test_backends_interactive.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/lib/matplotlib/tests/test_backends_interactive.py b/lib/matplotlib/tests/test_backends_interactive.py -index 36ec3bfc83..a1f27fea57 100644 ---- a/lib/matplotlib/tests/test_backends_interactive.py -+++ b/lib/matplotlib/tests/test_backends_interactive.py -@@ -301,7 +301,7 @@ else: - - """ - proc = subprocess.run([sys.executable, "-c", test_script], -- env={"MPLBACKEND": ""}) -+ env={**os.environ, "MPLBACKEND": ""}) - if proc.returncode: - pytest.fail("The subprocess returned with non-zero exit status " - f"{proc.returncode}.") --- -2.31.1 - diff --git a/0005-Increase-a-few-test-tolerances-on-some-arches.patch b/0004-Increase-a-few-test-tolerances-on-some-arches.patch similarity index 88% rename from 0005-Increase-a-few-test-tolerances-on-some-arches.patch rename to 0004-Increase-a-few-test-tolerances-on-some-arches.patch index f0690ce..b5e5a6b 100644 --- a/0005-Increase-a-few-test-tolerances-on-some-arches.patch +++ b/0004-Increase-a-few-test-tolerances-on-some-arches.patch @@ -1,7 +1,7 @@ -From 383fc4380bdc8d14d65ba48f012fd11e1d557348 Mon Sep 17 00:00:00 2001 +From 3c4d2d9d65da9065d7f82d7adf2c226f0662d6b9 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Tue, 24 Aug 2021 04:47:50 -0400 -Subject: [PATCH 5/6] Increase a few test tolerances on some arches. +Subject: [PATCH 4/4] Increase a few test tolerances on some arches. Signed-off-by: Elliott Sales de Andrade --- @@ -12,10 +12,10 @@ Signed-off-by: Elliott Sales de Andrade 4 files changed, 11 insertions(+), 6 deletions(-) diff --git a/lib/matplotlib/tests/test_axes.py b/lib/matplotlib/tests/test_axes.py -index 5b6607a696..8233a436d5 100644 +index 472e0e6902..a5e678d048 100644 --- a/lib/matplotlib/tests/test_axes.py +++ b/lib/matplotlib/tests/test_axes.py -@@ -867,7 +867,8 @@ def test_imshow(): +@@ -868,7 +868,8 @@ def test_imshow(): ax.imshow("r", data=data) @@ -25,7 +25,7 @@ index 5b6607a696..8233a436d5 100644 def test_imshow_clip(): # As originally reported by Gellule Xg # use former defaults to match existing baseline image -@@ -2059,7 +2060,8 @@ def test_contour_hatching(): +@@ -2060,7 +2061,8 @@ def test_contour_hatching(): extend='both', alpha=0.5) @@ -50,10 +50,10 @@ index 6396105f12..ea13615e4b 100644 # colorbars was cleaned up... def test_contour_addlines(): diff --git a/lib/matplotlib/tests/test_image.py b/lib/matplotlib/tests/test_image.py -index 37dddd4e47..01a06378d8 100644 +index 2c4a2763e4..b41bca0863 100644 --- a/lib/matplotlib/tests/test_image.py +++ b/lib/matplotlib/tests/test_image.py -@@ -1330,8 +1330,8 @@ def test_nonuniform_and_pcolor(): +@@ -1322,8 +1322,8 @@ def test_nonuniform_and_pcolor(): ax.set(xlim=(0, 10)) @@ -65,7 +65,7 @@ index 37dddd4e47..01a06378d8 100644 fig, axs = plt.subplots(2, 2, figsize=(3.5, 3.5), sharex=False, sharey=False, constrained_layout=True) diff --git a/lib/matplotlib/tests/test_lines.py b/lib/matplotlib/tests/test_lines.py -index 21cb221405..f19542201c 100644 +index f6917a134b..a7b5772e8c 100644 --- a/lib/matplotlib/tests/test_lines.py +++ b/lib/matplotlib/tests/test_lines.py @@ -3,6 +3,7 @@ Tests specific to the lines module. @@ -76,7 +76,7 @@ index 21cb221405..f19542201c 100644 import timeit from types import SimpleNamespace -@@ -150,7 +151,8 @@ def test_set_drawstyle(): +@@ -162,7 +163,8 @@ def test_set_drawstyle(): assert len(line.get_path().vertices) == len(x) diff --git a/0006-Fix-broken-QApplication-init-in-a-test.patch b/0006-Fix-broken-QApplication-init-in-a-test.patch deleted file mode 100644 index d4b6812..0000000 --- a/0006-Fix-broken-QApplication-init-in-a-test.patch +++ /dev/null @@ -1,29 +0,0 @@ -From d4386df74371c2dcec9bb1a7f588f46639087c49 Mon Sep 17 00:00:00 2001 -From: Elliott Sales de Andrade -Date: Tue, 24 Aug 2021 05:03:15 -0400 -Subject: [PATCH 6/6] Fix broken QApplication init in a test. - -Signed-off-by: Elliott Sales de Andrade ---- - lib/matplotlib/tests/test_backend_qt.py | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) - -diff --git a/lib/matplotlib/tests/test_backend_qt.py b/lib/matplotlib/tests/test_backend_qt.py -index b7fb708bee..ff104fcfbe 100644 ---- a/lib/matplotlib/tests/test_backend_qt.py -+++ b/lib/matplotlib/tests/test_backend_qt.py -@@ -379,8 +379,9 @@ def test_canvas_reinit(): - - @pytest.mark.backend('Qt5Agg', skip_on_importerror=True) - def test_form_widget_get_with_datetime_and_date_fields(): -- if not QtWidgets.QApplication.instance(): -- QtWidgets.QApplication() -+ from matplotlib.backends.backend_qt import _create_qApp -+ _create_qApp() -+ - form = [ - ("Datetime field", datetime(year=2021, month=3, day=11)), - ("Date field", date(year=2021, month=3, day=11)) --- -2.31.1 - diff --git a/python-matplotlib.spec b/python-matplotlib.spec index 026673d..4a33c27 100644 --- a/python-matplotlib.spec +++ b/python-matplotlib.spec @@ -30,15 +30,15 @@ %global _docdir_fmt %{name} # Updated test images for new FreeType. -%global mpl_images_version 3.5.0b1 +%global mpl_images_version 3.5.0rc1 # The version of FreeType in this Fedora branch. %global ftver 2.11.0 Name: python-matplotlib Version: 3.5.0 -%global Version 3.5.0b1 -Release: %autorelease -p b1 +%global Version 3.5.0rc1 +Release: %autorelease -p -e rc1 Summary: Python 2D plotting library # qt4_editor backend is MIT # ResizeObserver at end of lib/matplotlib/backends/web_backend/js/mpl.js is Public Domain @@ -57,9 +57,7 @@ Patch1001: 0001-matplotlibrc-path-search-fix.patch Patch1002: 0002-Set-FreeType-version-to-%{ftver}-and-update-tolerances.patch # Work around for problems with texlive 2021 (#1965547) Patch1003: 0003-Slightly-increase-tolerance-on-rcupdate-test.patch -# https://github.com/matplotlib/matplotlib/pull/20884 -Patch1004: 0004-Ensure-full-environment-is-passed-to-headless-test.patch -Patch1005: 0005-Increase-a-few-test-tolerances-on-some-arches.patch +Patch1004: 0004-Increase-a-few-test-tolerances-on-some-arches.patch BuildRequires: gcc BuildRequires: gcc-c++ @@ -284,7 +282,6 @@ cp -p %{SOURCE1} mplsetup.cfg %patch1003 -p1 %patch1004 -p1 -%patch1005 -p1 %generate_buildrequires diff --git a/sources b/sources index c94a8c0..0b4093b 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (matplotlib-3.5.0b1.tar.gz) = 5299ea0d04a686cb5a2a797c9f245b6477ee6eace04c7b1371195b5b3cfbd12fdba07497ee699443b6a51d5aacd0b9dec2ea4cdd06d6f00a6c77877174733cba -SHA512 (matplotlib-3.5.0b1-with-freetype-2.11.0.tar.gz) = cbbf471a30ec01d087fab51487a9480e73b98c475a241f0ae865f886d381b36395695befaaaeebe509863535f85dd6662fdff17680445ebc5accfd703ae20c91 +SHA512 (matplotlib-3.5.0rc1.tar.gz) = 2845e3ec6582db78d54d999ec59578848c1f02ac37fa602430b99ffed31a99be41a24404b8ad20c941e5a18acc9f5ca63961b869bbb164f436b0a8c3862e705d +SHA512 (matplotlib-3.5.0rc1-with-freetype-2.11.0.tar.gz) = 2edc7ef95259515649384dece548d41b5c59722ab5603dbf51d1ed20f7bd596e6d5e51ad179fd2d9d74f435bc719b828b3c4302d85e57e6d010e4ed094655794