Throw exception on corrupt text

This commit is contained in:
James R. Barlow
2018-10-30 16:35:09 -07:00
parent 600d31a907
commit a195713bb4
+3 -2
View File
@@ -258,9 +258,10 @@ def is_ocr_required(pageinfo, log, options):
"some text on this page cannot be mapped to characters: "
"consider using --force-ocr instead")
)
raise PriorOcrFoundError() # Wrong error but will do for now
else:
log.info(msg.format(page,
"redoing OCR"))
log.info(msg.format(page,
"redoing OCR"))
ocr_required = True
elif options.skip_text:
log.info(msg.format(page,