Skip to content

Commit 2ba853d

Browse files
authored
Merge pull request #26428 from matplotlib/v3.7.2-doc
Merge branch v3.7.2-doc into v3.7.x
2 parents 2e6570a + 08877f8 commit 2ba853d

File tree

10 files changed

+52
-14
lines changed

10 files changed

+52
-14
lines changed

doc/_static/zenodo_cache/8118151.svg

Lines changed: 35 additions & 0 deletions
Loading

doc/users/project/citing.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ By version
2929
.. START OF AUTOGENERATED
3030
3131
32+
v3.7.2
33+
.. image:: ../../_static/zenodo_cache/8118151.svg
34+
:target: https://doi.org/10.5281/zenodo.8118151
3235
v3.7.1
3336
.. image:: ../../_static/zenodo_cache/7697899.svg
3437
:target: https://doi.org/10.5281/zenodo.7697899

examples/misc/packed_bubbles.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,7 @@ def check_collisions(self, bubble, bubbles):
7676

7777
def collides_with(self, bubble, bubbles):
7878
distance = self.outline_distance(bubble, bubbles)
79-
idx_min = np.argmin(distance)
80-
return idx_min if type(idx_min) == np.ndarray else [idx_min]
79+
return np.argmin(distance, keepdims=True)
8180

8281
def collapse(self, n_iterations=50):
8382
"""

lib/matplotlib/dviread.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -622,7 +622,7 @@ def __init__(self, scale, tfm, texname, vf):
622622
for char in range(nchars)]
623623

624624
def __eq__(self, other):
625-
return (type(self) == type(other)
625+
return (type(self) is type(other)
626626
and self.texname == other.texname and self.size == other.size)
627627

628628
def __ne__(self, other):

lib/matplotlib/font_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -851,7 +851,7 @@ def set_fontconfig_pattern(self, pattern):
851851
pattern syntax for use here.
852852
"""
853853
for key, val in parse_fontconfig_pattern(pattern).items():
854-
if type(val) == list:
854+
if type(val) is list:
855855
getattr(self, "set_" + key)(val[0])
856856
else:
857857
getattr(self, "set_" + key)(val)

lib/matplotlib/tests/test_axes.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2834,12 +2834,12 @@ def _as_mpl_axes(self):
28342834

28352835
# testing axes creation with plt.axes
28362836
ax = plt.axes([0, 0, 1, 1], projection=prj)
2837-
assert type(ax) == PolarAxes
2837+
assert type(ax) is PolarAxes
28382838
plt.close()
28392839

28402840
# testing axes creation with subplot
28412841
ax = plt.subplot(121, projection=prj)
2842-
assert type(ax) == PolarAxes
2842+
assert type(ax) is PolarAxes
28432843
plt.close()
28442844

28452845

lib/matplotlib/tests/test_cbook.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ def test_callback_complete(self, pickle):
224224

225225
# test that we can add a callback
226226
cid1 = self.connect(self.signal, mini_me.dummy, pickle)
227-
assert type(cid1) == int
227+
assert type(cid1) is int
228228
self.is_not_empty()
229229

230230
# test that we don't add a second callback
@@ -249,7 +249,7 @@ def test_callback_disconnect(self, pickle):
249249

250250
# test that we can add a callback
251251
cid1 = self.connect(self.signal, mini_me.dummy, pickle)
252-
assert type(cid1) == int
252+
assert type(cid1) is int
253253
self.is_not_empty()
254254

255255
self.disconnect(cid1)
@@ -267,7 +267,7 @@ def test_callback_wrong_disconnect(self, pickle):
267267

268268
# test that we can add a callback
269269
cid1 = self.connect(self.signal, mini_me.dummy, pickle)
270-
assert type(cid1) == int
270+
assert type(cid1) is int
271271
self.is_not_empty()
272272

273273
self.disconnect("foo")

lib/matplotlib/tests/test_image.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1461,6 +1461,6 @@ def test_str_norms(fig_test, fig_ref):
14611461
axrs[3].imshow(t, norm=colors.SymLogNorm(linthresh=2, vmin=.3, vmax=.7))
14621462
axrs[4].imshow(t, norm="logit", clim=(.3, .7))
14631463

1464-
assert type(axts[0].images[0].norm) == colors.LogNorm # Exactly that class
1464+
assert type(axts[0].images[0].norm) is colors.LogNorm # Exactly that class
14651465
with pytest.raises(ValueError):
14661466
axts[0].imshow(t, norm="foobar")

lib/matplotlib/tests/test_scale.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,22 +37,22 @@ def test_symlog_mask_nan():
3737
x = np.arange(-1.5, 5, 0.5)
3838
out = slti.transform_non_affine(slt.transform_non_affine(x))
3939
assert_allclose(out, x)
40-
assert type(out) == type(x)
40+
assert type(out) is type(x)
4141

4242
x[4] = np.nan
4343
out = slti.transform_non_affine(slt.transform_non_affine(x))
4444
assert_allclose(out, x)
45-
assert type(out) == type(x)
45+
assert type(out) is type(x)
4646

4747
x = np.ma.array(x)
4848
out = slti.transform_non_affine(slt.transform_non_affine(x))
4949
assert_allclose(out, x)
50-
assert type(out) == type(x)
50+
assert type(out) is type(x)
5151

5252
x[3] = np.ma.masked
5353
out = slti.transform_non_affine(slt.transform_non_affine(x))
5454
assert_allclose(out, x)
55-
assert type(out) == type(x)
55+
assert type(out) is type(x)
5656

5757

5858
@image_comparison(['logit_scales.png'], remove_text=True)

tools/cache_zenodo_svg.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ def _get_xdg_cache_dir():
6363

6464
if __name__ == "__main__":
6565
data = {
66+
"v3.7.2": "8118151",
6667
"v3.7.1": "7697899",
6768
"v3.7.0": "7637593",
6869
"v3.6.3": "7527665",

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy