We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 859c303 commit 19af6f4Copy full SHA for 19af6f4
haystack/nodes/file_converter/pdf.py
@@ -54,9 +54,9 @@ def __init__(
54
super().__init__(
55
remove_numeric_tables=remove_numeric_tables, valid_languages=valid_languages, id_hash_keys=id_hash_keys
56
)
57
-
58
- verify_installation = subprocess.run(["pdftotext -v"], shell=True)
59
- if verify_installation.returncode == 127:
+ try:
+ subprocess.run(["pdftotext", "-v"], shell=False, check=False)
+ except FileNotFoundError:
60
raise FileNotFoundError(
61
"""pdftotext is not installed. It is part of xpdf or poppler-utils software suite.
62
0 commit comments