clear_task_instances
Clear task instances to re-run them, resetting state for scheduler retry. Use dry_run to preview affected tasks without execution.
Instructions
Clear task instances so they re-run (retry).
Clearing resets task state and the scheduler re-runs them, so it is
destructive - it can re-execute work. Use dry_run=True first to preview
exactly which task instances would be affected without changing anything.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dag_id | Yes | The DAG. | |
| dag_run_id | No | Restrict to a single run (recommended). | |
| task_ids | No | Restrict to specific task ids; omit for all tasks in scope. | |
| include_downstream | No | Also clear downstream tasks. | |
| include_upstream | No | Also clear upstream tasks. | |
| only_failed | No | Only clear failed task instances. | |
| dry_run | No | If True, report what would be cleared without doing it. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| task_instances | No | ||
| total_entries | No |