Skip to content

Commit e76e5a8

Browse files
committed
Remove dead code from LGTM alerts.
These are all overwritten later on without being read.
1 parent c64e8bb commit e76e5a8

File tree

6 files changed

+0
-19
lines changed

6 files changed

+0
-19
lines changed

lib/matplotlib/axis.py

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

22542254
def set_default_intervals(self):
22552255
# docstring inherited
2256-
xmin, xmax = 0., 1.
22572256
# only change view if dataLim has not changed and user has
22582257
# not changed the view:
22592258
if (not self.axes.dataLim.mutatedx() and
@@ -2514,7 +2513,6 @@ def set_inverted(self, inverted):
25142513

25152514
def set_default_intervals(self):
25162515
# docstring inherited
2517-
ymin, ymax = 0., 1.
25182516
# only change view if dataLim has not changed and user has
25192517
# not changed the view:
25202518
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
@@ -1456,8 +1456,6 @@ def subfigures(self, nrows=1, ncols=1, squeeze=True,
14561456
# Returned axis array will be always 2-d, even if nrows=ncols=1.
14571457
return sfarr
14581458

1459-
return sfarr
1460-
14611459
def add_subfigure(self, subplotspec, **kwargs):
14621460
"""
14631461
Add a `~.figure.SubFigure` to the figure as part of a subplot
@@ -1832,7 +1830,6 @@ def _do_layout(gs, mosaic, unique_ids, nested):
18321830
dict[label, Axes]
18331831
A flat dict of all of the Axes created.
18341832
"""
1835-
rows, cols = mosaic.shape
18361833
output = dict()
18371834

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

lib/matplotlib/gridspec.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -627,7 +627,6 @@ def _from_subplot_args(figure, args):
627627
if not (isinstance(rows, Integral) and isinstance(cols, Integral)):
628628
_api.warn_deprecated("3.3", message=message)
629629
rows, cols = map(int, [rows, cols])
630-
gs = GridSpec(rows, cols, figure=figure)
631630
if isinstance(num, tuple) and len(num) == 2:
632631
if not all(isinstance(n, Integral) for n in num):
633632
_api.warn_deprecated("3.3", message=message)

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)