]# python3 pdf2pdfocr.py -i /home/amuthuraman/NonOcrpdf/test.pdf
[2019-05-30 02:43:00.729260] [LOG] Tesseract can 'textonly_pdf': False
[2019-05-30 02:43:00.739282] [LOG] Tesseract version: 3
Traceback (most recent call last):
File "pdf2pdfocr.py", line 1214, in
pdf2ocr = Pdf2PdfOcr(args)
File "pdf2pdfocr.py", line 450, in init
self.check_external_tools()
File "pdf2pdfocr.py", line 531, in check_external_tools
if not self.test_convert():
File "pdf2pdfocr.py", line 1031, in test_convert
stderr=subprocess.DEVNULL, shell=self.shell_mode)
File "/usr/lib64/python3.6/subprocess.py", line 729, in init
restore_signals, start_new_session)
File "/usr/lib64/python3.6/subprocess.py", line 1278, in _execute_child
executable = os.fsencode(executable)
File "/usr/lib64/python3.6/os.py", line 800, in fsencode
filename = fspath(filename) # Does type-checking of filename.
TypeError: expected str, bytes or os.PathLike object, not NoneType
Please check if ImageMagick is installed and "convert" program is available in your path. I will fix the script to show the correct error message. Thanks for reporting.
]# python3 pdf2pdfocr.py -i /home/amuthuraman/NonOcrpdf/test.pdf [2019-05-30 02:43:00.729260] [LOG] Tesseract can 'textonly_pdf': False [2019-05-30 02:43:00.739282] [LOG] Tesseract version: 3 Traceback (most recent call last): File "pdf2pdfocr.py", line 1214, in
pdf2ocr = Pdf2PdfOcr(args)
File "pdf2pdfocr.py", line 450, in init
self.check_external_tools()
File "pdf2pdfocr.py", line 531, in check_external_tools
if not self.test_convert():
File "pdf2pdfocr.py", line 1031, in test_convert
stderr=subprocess.DEVNULL, shell=self.shell_mode)
File "/usr/lib64/python3.6/subprocess.py", line 729, in init
restore_signals, start_new_session)
File "/usr/lib64/python3.6/subprocess.py", line 1278, in _execute_child
executable = os.fsencode(executable)
File "/usr/lib64/python3.6/os.py", line 800, in fsencode
filename = fspath(filename) # Does type-checking of
filename
. TypeError: expected str, bytes or os.PathLike object, not NoneType