Skip to content

Commit 450cdc6

Browse files
authored
Merge pull request #20439 from QuLogic/fix-lgtm
Remove dead code from LGTM alerts.
2 parents 5793748 + 7c0b9ee commit 450cdc6

File tree

5 files changed

+0
-18
lines changed

5 files changed

+0
-18
lines changed

lib/matplotlib/axis.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2251,7 +2251,6 @@ def set_inverted(self, inverted):
22512251

22522252
def set_default_intervals(self):
22532253
# docstring inherited
2254-
xmin, xmax = 0., 1.
22552254
# only change view if dataLim has not changed and user has
22562255
# not changed the view:
22572256
if (not self.axes.dataLim.mutatedx() and
@@ -2512,7 +2511,6 @@ def set_inverted(self, inverted):
25122511

25132512
def set_default_intervals(self):
25142513
# docstring inherited
2515-
ymin, ymax = 0., 1.
25162514
# only change view if dataLim has not changed and user has
25172515
# not changed the view:
25182516
if (not self.axes.dataLim.mutatedy() and

lib/matplotlib/backends/web_backend/js/nbagg_mpl.js

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -228,11 +228,6 @@ mpl.figure.prototype._canvas_extra_style = function (el) {
228228
};
229229

230230
mpl.figure.prototype._key_event_extra = function (event, _name) {
231-
var manager = IPython.notebook.keyboard_manager;
232-
if (!manager) {
233-
manager = IPython.keyboard_manager;
234-
}
235-
236231
// Check for shift+enter
237232
if (event.shiftKey && event.which === 13) {
238233
this.canvas_div.blur();

lib/matplotlib/figure.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1447,8 +1447,6 @@ def subfigures(self, nrows=1, ncols=1, squeeze=True,
14471447
# Returned axis array will be always 2-d, even if nrows=ncols=1.
14481448
return sfarr
14491449

1450-
return sfarr
1451-
14521450
def add_subfigure(self, subplotspec, **kwargs):
14531451
"""
14541452
Add a `~.figure.SubFigure` to the figure as part of a subplot
@@ -1823,7 +1821,6 @@ def _do_layout(gs, mosaic, unique_ids, nested):
18231821
dict[label, Axes]
18241822
A flat dict of all of the Axes created.
18251823
"""
1826-
rows, cols = mosaic.shape
18271824
output = dict()
18281825

18291826
# we need to merge together the Axes at this level and the axes

lib/matplotlib/markers.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -805,7 +805,6 @@ def _set_plus_filled(self):
805805
self._transform = Affine2D()
806806
self._snap_threshold = 5.0
807807
self._joinstyle = JoinStyle.miter
808-
fs = self.get_fillstyle()
809808
if not self._half_fill():
810809
self._path = self._plus_filled_path
811810
else:

lib/matplotlib/offsetbox.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -475,13 +475,6 @@ def get_extent_offsets(self, renderer):
475475
if not whd_list:
476476
return 2 * pad, 2 * pad, pad, pad, []
477477

478-
if self.height is None:
479-
height_descent = max(h - yd for w, h, xd, yd in whd_list)
480-
ydescent = max(yd for w, h, xd, yd in whd_list)
481-
height = height_descent + ydescent
482-
else:
483-
height = self.height - 2 * pad # width w/o pad
484-
485478
hd_list = [(h, yd) for w, h, xd, yd in whd_list]
486479
height, ydescent, yoffsets = _get_aligned_offsets(hd_list,
487480
self.height,

0 commit comments

Comments
 (0)