Add check for error reading
This commit is contained in:
parent
fd93451903
commit
d128e8844d
1 changed files with 2 additions and 1 deletions
|
@ -72,7 +72,8 @@ class image_classifier:
|
|||
exif_info = exif.Image(image_file)
|
||||
if exif_info.has_exif:
|
||||
for key in exif_info.list_all():
|
||||
print(f"{key}: {exif_info[key]}")
|
||||
if key != 'cannot read a base/unknown IFD tag instance':
|
||||
print(f"{key}: {exif_info[key]}")
|
||||
else:
|
||||
self._log.debug("No exif info in the image.")
|
||||
# get date
|
||||
|
|
Loading…
Reference in a new issue