Loading libmat2/exiftool.py +12 −7 Original line number Diff line number Diff line Loading @@ -20,13 +20,18 @@ class ExiftoolParser(abstract.AbstractParser): meta_allowlist = set() # type: Set[str] def get_meta(self) -> Dict[str, Union[str, dict]]: try: if self.sandbox: out = bubblewrap.run([_get_exiftool_path(), '-json', self.filename], out = bubblewrap.run([_get_exiftool_path(), '-json', self.filename], input_filename=self.filename, check=True, stdout=subprocess.PIPE).stdout else: out = subprocess.run([_get_exiftool_path(), '-json', self.filename], out = subprocess.run([_get_exiftool_path(), '-json', self.filename], check=True, stdout=subprocess.PIPE).stdout except subprocess.CalledProcessError: # pragma: no cover raise ValueError meta = json.loads(out.decode('utf-8'))[0] for key in self.meta_allowlist: meta.pop(key, None) Loading Loading
libmat2/exiftool.py +12 −7 Original line number Diff line number Diff line Loading @@ -20,13 +20,18 @@ class ExiftoolParser(abstract.AbstractParser): meta_allowlist = set() # type: Set[str] def get_meta(self) -> Dict[str, Union[str, dict]]: try: if self.sandbox: out = bubblewrap.run([_get_exiftool_path(), '-json', self.filename], out = bubblewrap.run([_get_exiftool_path(), '-json', self.filename], input_filename=self.filename, check=True, stdout=subprocess.PIPE).stdout else: out = subprocess.run([_get_exiftool_path(), '-json', self.filename], out = subprocess.run([_get_exiftool_path(), '-json', self.filename], check=True, stdout=subprocess.PIPE).stdout except subprocess.CalledProcessError: # pragma: no cover raise ValueError meta = json.loads(out.decode('utf-8'))[0] for key in self.meta_allowlist: meta.pop(key, None) Loading