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

Skip to content

Commit 71617e2

Browse files
authored
Update stacklevel value
1 parent f1a988f commit 71617e2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/matplotlib/backends/backend_wx.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1555,7 +1555,7 @@ def save_figure(self, *args):
15551555
warnings.warn(
15561556
'extension %s did not match the selected '
15571557
'image type %s; going with %s' %
1558-
(ext, format, ext), stacklevel=0)
1558+
(ext, format, ext), stacklevel=2)
15591559
format = ext
15601560
try:
15611561
self.canvas.figure.savefig(
@@ -1721,7 +1721,7 @@ def trigger(self, *args):
17211721
warnings.warn(
17221722
'extension %s did not match the selected '
17231723
'image type %s; going with %s' %
1724-
(ext, format, ext), stacklevel=0)
1724+
(ext, format, ext), stacklevel=2)
17251725
format = ext
17261726
if default_dir != "":
17271727
matplotlib.rcParams['savefig.directory'] = dirname

0 commit comments

Comments
 (0)