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

Skip to content

Commit 20ca818

Browse files
committed
Corrected use of cbook.warn_deprecated()
1 parent 0f8a452 commit 20ca818

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

lib/matplotlib/axes.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6281,7 +6281,8 @@ def scatter(self, x, y, s=20, c='b', marker='o', cmap=None, norm=None,
62816281
edgecolors = kwargs.get('edgecolors', None)
62826282
if faceted is not None:
62836283
cbook.warn_deprecated(
6284-
'1.2', 'faceted', alternative='edgecolor', obj_type='option')
6284+
'1.2', name='faceted', alternative='edgecolor',
6285+
obj_type='option')
62856286
if faceted:
62866287
edgecolors = None
62876288
else:
@@ -7537,7 +7538,8 @@ def pcolor(self, *args, **kwargs):
75377538
vmax = kwargs.pop('vmax', None)
75387539
if 'shading' in kwargs:
75397540
cbook.warn_deprecated(
7540-
'1.2', 'shading', alternative='edgecolors', obj_type='option')
7541+
'1.2', name='shading', alternative='edgecolors',
7542+
obj_type='option')
75417543
shading = kwargs.pop('shading', 'flat')
75427544

75437545
X, Y, C = self._pcolorargs('pcolor', *args, allmatch=False)

lib/matplotlib/mpl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import warnings
55
from matplotlib import cbook
66
cbook.warn_deprecated(
7-
'1.3', 'matplotlib.mpl', alternative='`import matplotlib as mpl`',
7+
'1.3', name='matplotlib.mpl', alternative='`import matplotlib as mpl`',
88
obj_type='module')
99
from matplotlib import artist
1010
from matplotlib import axis

0 commit comments

Comments
 (0)