Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 7aca539

Browse files
committed
addressed linting issues
Addressed linting issues
1 parent 5ddcb77 commit 7aca539

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

lib/matplotlib/axes/_axes.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3302,10 +3302,9 @@ def pie(self, x, explode=None, labels=None, colors=None,
33023302

33033303
if np.any(x < 0):
33043304
raise ValueError("Wedge sizes 'x' must be non negative values")
3305-
33063305
if not np.all(np.isfinite(x)):
33073306
raise ValueError('Wedge sizes must be finite numbers')
3308-
3307+
33093308
sx = x.sum()
33103309

33113310
if normalize:

lib/matplotlib/tests/test_axes.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9725,6 +9725,5 @@ def test_bar_shape_mismatch():
97259725
def test_pie_non_finite_values():
97269726
fig, ax = plt.subplots()
97279727
df = [5, float('nan'), float('inf')]
9728-
97299728
with pytest.raises(ValueError, match='Wedge sizes must be finite numbers'):
9730-
ax.pie(df, labels=['A', 'B', 'C'])
9729+
ax.pie(df, labels=['A', 'B', 'C'])

0 commit comments

Comments
 (0)