Do not fail the whole lambda if one page failed

This commit is contained in:
Mikhail f. Shiryaev 2022-04-14 19:35:29 +02:00
parent 52a7544aa4
commit 3e6dc24a7b
No known key found for this signature in database
GPG Key ID: 4B02ED204C7D93F4

View File

@ -160,7 +160,11 @@ def get_workflow_description_fallback(event_data) -> List[WorkflowDescription]:
workflows_data = []
i = 1
for i in range(1, 6):
workflows = _exec_get_with_retry(f"{request_url}&page={i}")
try:
workflows = _exec_get_with_retry(f"{request_url}&page={i}")
except Exception as e:
print(f"Exception occured, still continue: {e}")
continue
if not workflows["workflow_runs"]:
break
# Prefilter workflows