Permalink
Browse files

Make stem catch explicit Exception classes

  • Loading branch information...
dmcdougall committed Nov 17, 2012
1 parent db493b5 commit 94f640e2422e3bd73769f9355b3381d66e25e264
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/matplotlib/axes.py
View
@@ -5115,7 +5115,7 @@ def stem(self, *args, **kwargs):
second = np.asarray(args[0], dtype=np.float)
x, y = y, second
args = args[1:]
- except:
+ except (IndexError, ValueError):
# The second array doesn't make sense, or it doesn't exist
second = np.arange(len(y))
x = second

0 comments on commit 94f640e

Please sign in to comment.