2021-06-04 07:32:13 +00:00
|
|
|
From 69ecaadda7a7f59130056458ce9ca6a231aebf5a Mon Sep 17 00:00:00 2001
|
2019-05-31 05:44:54 +00:00
|
|
|
From: Elliott Sales de Andrade <quantum.analyst@gmail.com>
|
2020-03-04 04:05:13 +00:00
|
|
|
Date: Fri, 14 Feb 2020 06:05:42 -0500
|
2021-06-04 07:32:13 +00:00
|
|
|
Subject: [PATCH 2/4] Set FreeType version to 2.10.4 and update tolerances.
|
2019-05-31 05:44:54 +00:00
|
|
|
|
|
|
|
Signed-off-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
|
|
|
|
---
|
2019-11-23 01:10:32 +00:00
|
|
|
lib/matplotlib/__init__.py | 2 +-
|
2020-06-30 00:38:52 +00:00
|
|
|
lib/matplotlib/tests/test_axes.py | 4 ++--
|
2019-11-23 01:10:32 +00:00
|
|
|
lib/matplotlib/tests/test_constrainedlayout.py | 2 +-
|
2020-06-30 00:38:52 +00:00
|
|
|
lib/matplotlib/tests/test_polar.py | 2 +-
|
2019-11-23 01:10:32 +00:00
|
|
|
lib/matplotlib/tests/test_tightlayout.py | 10 +++++-----
|
2020-11-12 06:35:38 +00:00
|
|
|
setupext.py | 6 +++++-
|
|
|
|
6 files changed, 15 insertions(+), 11 deletions(-)
|
2019-05-31 05:44:54 +00:00
|
|
|
|
|
|
|
diff --git a/lib/matplotlib/__init__.py b/lib/matplotlib/__init__.py
|
2021-06-04 07:32:13 +00:00
|
|
|
index 9d795f65f5..5755ad73da 100644
|
2019-05-31 05:44:54 +00:00
|
|
|
--- a/lib/matplotlib/__init__.py
|
|
|
|
+++ b/lib/matplotlib/__init__.py
|
2021-06-04 07:32:13 +00:00
|
|
|
@@ -1137,7 +1137,7 @@ default_test_modules = [
|
2020-03-04 04:05:13 +00:00
|
|
|
def _init_tests():
|
2019-05-31 05:44:54 +00:00
|
|
|
# The version of FreeType to install locally for running the
|
|
|
|
# tests. This must match the value in `setupext.py`
|
|
|
|
- LOCAL_FREETYPE_VERSION = '2.6.1'
|
2020-11-12 06:35:38 +00:00
|
|
|
+ LOCAL_FREETYPE_VERSION = '2.10.4'
|
2019-05-31 05:44:54 +00:00
|
|
|
|
|
|
|
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
|
2021-06-04 07:32:13 +00:00
|
|
|
index ec4773d465..d63c200b1b 100644
|
2019-05-31 05:44:54 +00:00
|
|
|
--- a/lib/matplotlib/tests/test_axes.py
|
|
|
|
+++ b/lib/matplotlib/tests/test_axes.py
|
2021-06-04 07:32:13 +00:00
|
|
|
@@ -6500,7 +6500,7 @@ def test_normal_axes():
|
2019-05-31 05:44:54 +00:00
|
|
|
]
|
|
|
|
for nn, b in enumerate(bbaxis):
|
|
|
|
targetbb = mtransforms.Bbox.from_bounds(*target[nn])
|
|
|
|
- assert_array_almost_equal(b.bounds, targetbb.bounds, decimal=2)
|
|
|
|
+ assert_array_almost_equal(b.bounds, targetbb.bounds, decimal=0)
|
|
|
|
|
|
|
|
target = [
|
|
|
|
[150.0, 119.999, 930.0, 11.111],
|
2021-06-04 07:32:13 +00:00
|
|
|
@@ -6518,7 +6518,7 @@ def test_normal_axes():
|
2019-05-31 05:44:54 +00:00
|
|
|
|
|
|
|
target = [85.5138, 75.88888, 1021.11, 1017.11]
|
|
|
|
targetbb = mtransforms.Bbox.from_bounds(*target)
|
|
|
|
- assert_array_almost_equal(bbtb.bounds, targetbb.bounds, decimal=2)
|
|
|
|
+ assert_array_almost_equal(bbtb.bounds, targetbb.bounds, decimal=0)
|
|
|
|
|
|
|
|
# test that get_position roundtrips to get_window_extent
|
|
|
|
axbb = ax.get_position().transformed(fig.transFigure).bounds
|
2019-11-23 01:10:32 +00:00
|
|
|
diff --git a/lib/matplotlib/tests/test_constrainedlayout.py b/lib/matplotlib/tests/test_constrainedlayout.py
|
2021-02-19 10:46:28 +00:00
|
|
|
index 67474628e7..d3e9d105dc 100644
|
2019-11-23 01:10:32 +00:00
|
|
|
--- a/lib/matplotlib/tests/test_constrainedlayout.py
|
|
|
|
+++ b/lib/matplotlib/tests/test_constrainedlayout.py
|
2021-02-19 10:46:28 +00:00
|
|
|
@@ -429,7 +429,7 @@ def test_hidden_axes():
|
2019-11-23 01:10:32 +00:00
|
|
|
extents1 = np.copy(axs[0, 0].get_position().extents)
|
|
|
|
|
2020-06-30 00:38:52 +00:00
|
|
|
np.testing.assert_allclose(
|
2021-02-19 10:46:28 +00:00
|
|
|
- extents1, [0.045552, 0.543288, 0.47819, 0.982638], rtol=1e-5)
|
|
|
|
+ extents1, [0.045552, 0.543288, 0.47819, 0.982638], rtol=1e-2)
|
|
|
|
|
|
|
|
|
|
|
|
def test_colorbar_align():
|
2020-06-30 00:38:52 +00:00
|
|
|
diff --git a/lib/matplotlib/tests/test_polar.py b/lib/matplotlib/tests/test_polar.py
|
2021-06-04 07:32:13 +00:00
|
|
|
index c614eff027..daf4e26fb8 100644
|
2020-06-30 00:38:52 +00:00
|
|
|
--- a/lib/matplotlib/tests/test_polar.py
|
|
|
|
+++ b/lib/matplotlib/tests/test_polar.py
|
2021-02-19 10:46:28 +00:00
|
|
|
@@ -312,7 +312,7 @@ def test_get_tightbbox_polar():
|
2020-06-30 00:38:52 +00:00
|
|
|
fig.canvas.draw()
|
|
|
|
bb = ax.get_tightbbox(fig.canvas.get_renderer())
|
|
|
|
assert_allclose(
|
|
|
|
- bb.extents, [107.7778, 29.2778, 539.7847, 450.7222], rtol=1e-03)
|
|
|
|
+ bb.extents, [107.7778, 29.2778, 539.7847, 450.7222], rtol=1)
|
|
|
|
|
|
|
|
|
|
|
|
@check_figures_equal(extensions=["png"])
|
2019-05-31 05:44:54 +00:00
|
|
|
diff --git a/lib/matplotlib/tests/test_tightlayout.py b/lib/matplotlib/tests/test_tightlayout.py
|
2021-02-19 10:46:28 +00:00
|
|
|
index 23d363b508..e94c863477 100644
|
2019-05-31 05:44:54 +00:00
|
|
|
--- a/lib/matplotlib/tests/test_tightlayout.py
|
|
|
|
+++ b/lib/matplotlib/tests/test_tightlayout.py
|
2021-02-19 10:46:28 +00:00
|
|
|
@@ -172,12 +172,12 @@ def test_outward_ticks():
|
2019-05-31 05:44:54 +00:00
|
|
|
plt.tight_layout()
|
|
|
|
# These values were obtained after visual checking that they correspond
|
|
|
|
# to a tight layouting that did take the ticks into account.
|
|
|
|
- ans = [[[0.091, 0.607], [0.433, 0.933]],
|
|
|
|
- [[0.579, 0.607], [0.922, 0.933]],
|
|
|
|
- [[0.091, 0.140], [0.433, 0.466]],
|
|
|
|
- [[0.579, 0.140], [0.922, 0.466]]]
|
|
|
|
+ ans = [[[0.09, 0.61], [0.43, 0.93]],
|
|
|
|
+ [[0.58, 0.61], [0.92, 0.93]],
|
|
|
|
+ [[0.09, 0.14], [0.43, 0.47]],
|
|
|
|
+ [[0.58, 0.14], [0.92, 0.47]]]
|
|
|
|
for nn, ax in enumerate(fig.axes):
|
|
|
|
- assert_array_equal(np.round(ax.get_position().get_points(), 3),
|
|
|
|
+ assert_array_equal(np.round(ax.get_position().get_points(), 2),
|
|
|
|
ans[nn])
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/setupext.py b/setupext.py
|
2021-02-19 10:46:28 +00:00
|
|
|
index d8d0b6b393..aabb7ed9fd 100644
|
2019-05-31 05:44:54 +00:00
|
|
|
--- a/setupext.py
|
|
|
|
+++ b/setupext.py
|
2021-02-19 10:46:28 +00:00
|
|
|
@@ -167,12 +167,16 @@ _freetype_hashes = {
|
2020-07-19 03:14:00 +00:00
|
|
|
'955e17244e9b38adb0c98df66abb50467312e6bb70eac07e49ce6bd1a20e809a',
|
|
|
|
'2.10.1':
|
|
|
|
'3a60d391fd579440561bf0e7f31af2222bc610ad6ce4d9d7bd2165bca8669110',
|
|
|
|
+ '2.10.2':
|
|
|
|
+ 'e09aa914e4f7a5d723ac381420949c55c0b90b15744adce5d1406046022186ab',
|
2020-11-12 06:35:38 +00:00
|
|
|
+ '2.10.4':
|
|
|
|
+ '5eab795ebb23ac77001cfb68b7d4d50b5d6c7469247b0b01b2c953269f658dac',
|
2020-07-19 03:14:00 +00:00
|
|
|
}
|
|
|
|
# This is the version of FreeType to use when building a local
|
2019-05-31 05:44:54 +00:00
|
|
|
# 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)
|
|
|
|
-LOCAL_FREETYPE_VERSION = '2.6.1'
|
2020-11-12 06:35:38 +00:00
|
|
|
+LOCAL_FREETYPE_VERSION = '2.10.4'
|
2019-05-31 05:44:54 +00:00
|
|
|
LOCAL_FREETYPE_HASH = _freetype_hashes.get(LOCAL_FREETYPE_VERSION, 'unknown')
|
|
|
|
|
2021-02-19 10:46:28 +00:00
|
|
|
LOCAL_QHULL_VERSION = '2020.2'
|
2019-05-31 05:44:54 +00:00
|
|
|
--
|
2021-06-04 07:32:13 +00:00
|
|
|
2.31.1
|
2019-05-31 05:44:54 +00:00
|
|
|
|