Skip to content
This repository was archived by the owner on Sep 20, 2023. It is now read-only.

Commit c4aca1b

Browse files
authored
fix: Parsing pages, but should be paragraphs (#147)
The code intends to be parsing paragraphs from a page, but was instead parsing pages from a document.
1 parent 7e9abd7 commit c4aca1b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

samples/snippets/batch_process_documents_sample.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ def batch_process_documents(
102102
field_value = get_text(form_field.field_value, document)
103103
print("Extracted key value pair:")
104104
print(f"\t{field_name}, {field_value}")
105-
for paragraph in document.pages:
105+
for paragraph in page.paragraphs:
106106
paragraph_text = get_text(paragraph.layout, document)
107107
print(f"Paragraph text:\n{paragraph_text}")
108108
else:

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy