8000 Reset the available animation movie writer on rcParam change by jankatins · Pull Request #5628 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content

Reset the available animation movie writer on rcParam change #5628

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Feb 7, 2016
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Pep8 fixes
  • Loading branch information
jankatins committed Feb 7, 2016
commit 33f564ac275d997458aab4e79a96ccdb9e547f97
13 changes: 8 additions & 5 deletions lib/matplotlib/animation.py
Original file line number Diff line number Diff line change
Expand Up @@ -459,13 +459,16 @@ def finish(self):
try:
stdout = [s.decode() for s in self._proc._stdout_buff]
stderr = [s.decode() for s in self._proc._stderr_buff]
verbose.report("MovieWriter.finish: stdout: %s" % stdout, level='helpful')
verbose.report("MovieWriter.finish: stderr: %s" % stderr, level='helpful')
verbose.report("MovieWriter.finish: stdout: %s" % stdout,
level='helpful')
verbose.report("MovieWriter.finish: stderr: %s" % stderr,
level='helpful')
except Exception as e:
pass
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not my finest code, but it works on py35...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just to provide improved debugging feed back right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, when the called converter fails and the user adds the mpl.verbose.set_level("helpful") before calling the failing method again...

Unfortunately, it doesn't work for the unittests unless I add such a set_level call in the unittest file :-(

raise RuntimeError('Error creating movie, return code: '
+ str(self._proc.returncode)
+ ' Try setting mpl.verbose.set_level("helpful")')
msg = ('Error creating movie, return code: ' +
str(self._proc.returncode) +
' Try setting mpl.verbose.set_level("helpful")')
raise RuntimeError(msg)

def cleanup(self):
MovieWriter.cleanup(self)
Expand Down
0