diff --git a/doc/api/next_api_changes/2018-09-06-AL-HTMLWriter.rst b/doc/api/next_api_changes/2018-09-06-AL-HTMLWriter.rst new file mode 100644 index 000000000000..dae0bd26943d --- /dev/null +++ b/doc/api/next_api_changes/2018-09-06-AL-HTMLWriter.rst @@ -0,0 +1,4 @@ +The HTMLWriter constructor is more strict +````````````````````````````````````````` +It no longer normalizes unknown values of *default_mode* to 'loop', but errors +out instead. diff --git a/lib/matplotlib/animation.py b/lib/matplotlib/animation.py index 56e45d5865dc..5280601cbd46 100644 --- a/lib/matplotlib/animation.py +++ b/lib/matplotlib/animation.py @@ -846,8 +846,8 @@ def __init__(self, fps=30, codec=None, bitrate=None, extra_args=None, self._bytes_limit *= 1024 * 1024 if self.default_mode not in ['loop', 'once', 'reflect']: - self.default_mode = 'loop' - _log.warning("unrecognized default_mode: using 'loop'") + raise ValueError( + "unrecognized default_mode {!r}".format(self.default_mode)) super().__init__(fps, codec, bitrate, extra_args, metadata)