Skip to content

Commit

Permalink
Fetch document after patch
Browse files Browse the repository at this point in the history
  • Loading branch information
duckduckgrayduck authored Sep 27, 2024
1 parent 877c87f commit 8b4956b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,10 @@ def main(self):
)
resp.raise_for_status()
while True:
document_ref = self.client.documents.get(document.id)
time.sleep(10)
if (
document.status == "success"
document_ref.status == "success"
): # Break out of for loop if document status becomes success
break

Expand Down

0 comments on commit 8b4956b

Please sign in to comment.