Fix verapdf NotADirectoryError crash on some platforms

Catch OSError (parent of both FileNotFoundError and
NotADirectoryError) in verapdf.available() so environments where
executing `verapdf` raises NotADirectoryError gracefully fall back
instead of crashing the pipeline. Fixes #1638.
This commit is contained in:
James R. Barlow
2026-03-10 02:08:59 -07:00
parent 5b9d6f979e
commit 57bb554a70
+1 -1
View File
@@ -36,7 +36,7 @@ def available() -> bool:
"""Check if verapdf is available."""
try:
version()
except MissingDependencyError:
except (MissingDependencyError, OSError):
return False
return True