8000 specify exception in try...except · AmitAronovitch/matplotlib@80c8c43 · GitHub
[go: up one dir, main page]

Skip to content

Commit 80c8c43

Browse files
committed
specify exception in try...except
1 parent b001785 commit 80c8c43

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/animation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -660,7 +660,7 @@ def save(self, filename, writer=None, fps=None, dpi=None, codec=None,
660660

661661
try:
662662
writer = writers.list()[0]
663-
except:
663+
except IndexError:
664664
raise ValueError("Cannot save animation: no writers are "
665665
"available. Please install mencoder or "
666666
"ffmpeg to save animations.")

0 commit comments

Comments
 (0)
0