Skip to content
This repository has been archived by the owner on Nov 21, 2024. It is now read-only.

Commit

Permalink
restart actions: delete all dags of workflow before restart
Browse files Browse the repository at this point in the history
  • Loading branch information
DonHaul committed Aug 9, 2024
1 parent 1f6cf0b commit 0994f7c
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions backoffice/backoffice/workflows/airflow_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,10 +165,6 @@ def restart_workflow_dags(workflow_id, workflow_type, params=None):
for dag_id in executed_dags_for_workflow:
delete_workflow_dag(dag_id, str(workflow_id))

return trigger_airflow_dag(
WORKFLOW_DAGS[workflow_type].initialize, str(workflow_id), params
)

return JsonResponse(
{"error": "Failed to restart"}, status=status.HTTP_424_FAILED_DEPENDENCY
return trigger_airflow_dag(
WORKFLOW_DAGS[workflow_type].initialize, str(workflow_id), params
)

0 comments on commit 0994f7c

Please sign in to comment.