Skip to content

Commit

Permalink
Don't raise 409 errors from OS
Browse files Browse the repository at this point in the history
  • Loading branch information
amywieliczka committed Oct 1, 2024
1 parent b7d8ce3 commit 4f51f1b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion record_indexer/index_collection.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,11 @@ def delete_by_query(index: str, data: dict[str, Any]):
auth=settings.get_auth(),
verify=settings.verify_certs()
)
if not (200 <= r.status_code <= 299):
if not (200 <= r.status_code <= 299 or r.status_code == 409):
print_opensearch_error(r, url)
r.raise_for_status()
if r.status_code == 409:
print("Ignoring 409 Conflict Error Response")
return r


Expand Down

0 comments on commit 4f51f1b

Please sign in to comment.