Skip to content

RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.

fix exception in pdf parser (#584)

KevinHuShd589b0f56832
diff --git a/deepdoc/parser/pdf_parser.py b/deepdoc/parser/pdf_parser.py
index 67b9d172c7..4c3255c706 100644
--- a/deepdoc/parser/pdf_parser.py
+++ b/deepdoc/parser/pdf_parser.py
@@ -470,7 +470,8 @@ class RAGFlowPdfParser:
continue
if re.match(r"[0-9]{2,3}/[0-9]{3}$", up["text"]) \
- or re.match(r"[0-9]{2,3}/[0-9]{3}$", down["text"]):
+ or re.match(r"[0-9]{2,3}/[0-9]{3}$", down["text"]) \
+ or not down["text"].strip():
i += 1
continue