From e70ea811c99c16f3382c08153eda573df0825536 Mon Sep 17 00:00:00 2001 From: jvoisin Date: Thu, 18 Oct 2018 19:19:56 +0200 Subject: Implement support for .avi files, via ffmpeg - This commit introduces optional dependencies (namely ffmpeg): mat2 will spit a warning when trying to process an .avi file if ffmpeg isn't installed. - Since metadata are obtained via exiftool, this commit also refactors a bit our exfitool wrapper. --- libmat2/abstract.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'libmat2/abstract.py') diff --git a/libmat2/abstract.py b/libmat2/abstract.py index 0084796..414a68b 100644 --- a/libmat2/abstract.py +++ b/libmat2/abstract.py @@ -7,7 +7,8 @@ assert Set # make pyflakes happy class AbstractParser(abc.ABC): """ This is the base class of every parser. - It might yield `ValueError` on instantiation on invalid files. + It might yield `ValueError` on instantiation on invalid files, + and `RuntimeError` when something went wrong in `remove_all`. """ meta_list = set() # type: Set[str] mimetypes = set() # type: Set[str] @@ -27,4 +28,7 @@ class AbstractParser(abc.ABC): @abc.abstractmethod def remove_all(self) -> bool: + """ + :raises RuntimeError: Raised if the cleaning process went wrong. + """ pass # pragma: no cover -- cgit v1.3