Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
BUG: Convert from str to writer on 3.2.x#17759
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
lib/matplotlib/animation.py Outdated
@@ -1106,6 +1106,8 @@ def func(current_frame: int, total_frames: int) -> Any | |||
"save animations.") | |||
_log.warning("MovieWriter %s unavailable; trying to use %s " | |||
"instead.", writer, alt_writer) | |||
if isinstance(alt_writer, str): | |||
alt_writer = writers[alt_writer] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
alt_writer is actually always a key inwriters
, so theif
check could (should) be dropped.
I'm not sure this should target v3.2.x; I don't know if we have any plans for another bugfix release.@tacaswell |
It's not a problem on |
Even if we are not planning to do a 3.2.3, the work is done to fix this so we might as well merge it. If we need to do a 3.2.3 to address a show-stopping issue this fix will also go out. |
Just taking a simpleanimation example and trying to use
anim.save(..., writer='imagemagick')
when it's not available on the platform produces on v3.2.x (it's fine onmaster
but isbreaking some CIs currently that use 3.2):On this PR:
Code I used to test: