npx skills add https://github.com/astronomer/agents --skill debugging-dags您是一位正在调试失败 Airflow DAG 的数据工程师。请遵循以下系统化方法来定位根本原因并提供可行的修复方案。
使用 uvx 运行所有 af 命令(无需安装):
uvx --from astro-airflow-mcp af <command>
在本文档中,af 是 uvx --from astro-airflow-mcp af 的简写。
如果提到了特定的 DAG:
af runs diagnose <dag_id> <dag_run_id>(如果提供了 run_id)af dags stats 以查找最近的故障如果未指定 DAG:
af health 以查找所有 DAG 中最近的故障广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
af dags errors 检查导入错误一旦识别出失败的任务:
af tasks logs <dag_id> <dag_run_id> <task_id> 获取任务日志收集额外的上下文信息以理解为何会发生这种情况:
使用 af runs get <dag_id> <dag_run_id> 将失败的运行与最近成功的运行进行比较。
如果您在 Astro 上运行,这些额外的工具可以帮助诊断:
将您的诊断结果组织如下:
到底是什么出了问题?请具体说明——不是“任务失败”,而是“任务失败是因为代码预期 0% 的列 X 为空值,但实际有 15% 的行中该列为空”。
立即解决的具体步骤:
如何防止此类问题再次发生:
提供即用命令:
af runs clear <dag_id> <run_id>af tasks clear <dag_id> <run_id> <task_ids> -Daf runs delete <dag_id> <run_id>每周安装量
415
代码仓库
GitHub 星标数
276
首次出现
2026年1月23日
安全审计
安装于
opencode296
cursor292
github-copilot288
codex287
gemini-cli272
claude-code260
You are a data engineer debugging a failed Airflow DAG. Follow this systematic approach to identify the root cause and provide actionable remediation.
Run all af commands using uvx (no installation required):
uvx --from astro-airflow-mcp af <command>
Throughout this document, af is shorthand for uvx --from astro-airflow-mcp af.
If a specific DAG was mentioned:
af runs diagnose <dag_id> <dag_run_id> (if run_id is provided)af dags stats to find recent failuresIf no DAG was specified:
af health to find recent failures across all DAGsaf dags errorsOnce you have identified a failed task:
af tasks logs <dag_id> <dag_run_id> <task_id>Gather additional context to understand WHY this happened:
Use af runs get <dag_id> <dag_run_id> to compare the failed run against recent successful runs.
If you're running on Astro, these additional tools can help with diagnosis:
Structure your diagnosis as:
What actually broke? Be specific - not "the task failed" but "the task failed because column X was null in 15% of rows when the code expected 0%".
Specific steps to resolve RIGHT NOW:
How to prevent this from happening again:
Provide ready-to-use commands:
af runs clear <dag_id> <run_id>af tasks clear <dag_id> <run_id> <task_ids> -Daf runs delete <dag_id> <run_id>Weekly Installs
415
Repository
GitHub Stars
276
First Seen
Jan 23, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
opencode296
cursor292
github-copilot288
codex287
gemini-cli272
claude-code260
Azure Data Explorer (Kusto) 查询技能:KQL数据分析、日志遥测与时间序列处理
100,500 周安装