Review a DAG for idempotency and retry safety
Walk the Pipeline Reviewer's four-step pass over a DAG: apply the idempotency test to every task, check retry, timeout and concurrency settings, predict backfill behaviour, and propose missing integration tests — then close the loop with the Airflow DAG Reviewer's checklist so every task is safe to re-run before the DAG merges.
At a glance
| When | A DAG is about to merge and must be safe to retry; A backfill is being considered and its behaviour must be predicted first |
|---|---|
| Where | Airflow / Orchestration |
| Why | Non-idempotent tasks duplicate rows on every retry, and the reviewer's read-only four-step pass surfaces that before the DAG ships. |
Learning objectives
- Apply the idempotency test to every task in a DAG
- Justify retry, timeout and concurrency settings per task
- Predict what a backfill will do before running it
What you need
- A DAG file or pull request to review
- The pipeline's schedule and SLA
- [object Object]
Steps
- Apply the idempotency test to every task. (from agent-pipeline-reviewer )
- Check retry, timeout and concurrency settings. (from agent-pipeline-reviewer )
- Predict backfill behaviour. (from agent-pipeline-reviewer )
- Propose missing integration tests. (from agent-pipeline-reviewer )
- Set retries with a backoff — a task that retries instantly will hammer a downstream. (from skill-airflow-dag-reviewer )
- Cap max_active_runs and pool limits so a backfill cannot starve the daily run. (from skill-airflow-dag-reviewer )
Check yourself
- On the fixture of 8 DAGs with seeded non-idempotency bugs, the review flags every seeded bug and no healthy task.
- Reviewing a task that appends without a partition key, you flag it as duplicating rows on retry.
Worked example
The idempotency test — from skill-airflow-dag-reviewer
"If this task runs twice for the same logical date, is the output the same?"
If no, fix it before anything else — retries will happen.
DAG review checklist — from skill-airflow-dag-reviewer
1. Every task writes to a partition keyed by the logical date, or uses MERGE.
2. `catchup` is a deliberate choice, not a default.
3. Retries have a backoff; a task that retries instantly will hammer a downstream.
4. `max_active_runs` and pool limits prevent a backfill from starving the daily run.
5. Sensors use `reschedule`, not `poke`, so they don't hold a worker slot.
Install the DAG reviewer — from skill-airflow-dag-reviewer
npx de-agent-platform add airflow-dag-reviewer
Sourced from
Security scan
Last sweep 2026-10-24: 0 finding(s), 0 marked as examples.
Common gotchas
- A task that appends without a partition key will duplicate rows on retry.
- `catchup` is a deliberate choice, not a default.
- Sensors use `reschedule`, not `poke`, so they don't hold a worker slot.
Production considerations
- The reviewer is read-only analysis and never triggers a run.
- Keep the fixture of 8 DAGs with seeded non-idempotency bugs in CI so regressions resurface.
Diagram
dag review pass
|
|- idempotency test per task --> flag appends without partition keys
|
|- retry/timeout/concurrency check --> backoff + max_active_runs
|
|- predict backfill behaviour --> propose missing integration tests
Registry stats
| Verification | community · Oct 21, 2026 |
|---|---|
| Completeness | 81 |
| Trust multiplier | ×1.25 |
| Composite | 34.15 · adequate |
| Freshness | 3 days since last source check |
| Difficulty | beginner |
| Version | 0.1.0 |
| License | CC-BY-4.0 |
| Security flags | none |
Did this solve your problem?
Review a DAG for idempotency and retry safety