Skip to content

Commit 3ed62e4

Browse files
committed
BUG: Fix function signature mismatch for set_clim
The dummy parent class introduced in matplotlib#13234 had a `set_clim` with a different signature to the version in `ScalarMappable`. This caused code which called it and passed both arguments to fail, rather than simply no-op.
1 parent ddb38ae commit 3ed62e4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/colorbar.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ def set_cmap(self, cmap):
331331
pass
332332

333333
@cbook.deprecated("3.1", alternative="ScalarMappable.set_clim")
334-
def set_clim(self, cmap):
334+
def set_clim(self, vmin=None, vmax=None):
335335
"""
336336
`.colorbar.Colorbar.set_clim` does nothing; set the limits on
337337
the mappable associated with this colorbar.

0 commit comments

Comments
 (0)