gcp-composer-troubleshooting

Diagnose Cloud Composer and Airflow DAG failures using gcloud logs and remote code analysis.

Updated Aug 26, 2026
One-click install
npx skills add https://github.com/Lathika-laa/Recipe_Box --skill gcp-composer-troubleshooting-lathika-laa
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: gcp-composer-troubleshooting
Source: https://github.com/Lathika-laa/Recipe_Box/tree/main/.github/.gemini/skills/gcp-composer-troubleshooting
Command: npx skills add https://github.com/Lathika-laa/Recipe_Box --skill gcp-composer-troubleshooting-lathika-laa

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? When a Cloud Composer (Apache Airflow) DAG fails, finding the root cause requires digging through scattered logs and verifying which code version actually ran. This Skill guides an evidence-based Root Cause Analysis (RCA) workflow so failures are explained with concrete log entries and code references instead of guesswork. ## Core Features & Use Cases - Log-Based Evidence Gathering: Uses gcloud logging read with filters on severity, environment, and DAG ID to locate failures and stack traces. - Remote Code Verification: Downloads the actual DAG code from the environment's GCS bucket and checks consistency against local files before analysis. - RCA Report Generation: Correlates logs with code, pinpoints the failing line, proposes a fix, and produces a saved RCA report. - Pipeline Template Validation: Provides compliant templates for declarative deployment.yaml and orchestration-pipeline.yaml files covering dbt, PySpark, and BigQuery actions. - Use Case: A user reports that the daily_sales_agg DAG failed yesterday; the Skill fetches error logs, downloads the remote DAG, identifies a KeyError at a specific line, and generates an RCA report with a recommended fix. ## Quick Start Ask the assistant to troubleshoot a failed Composer DAG by providing the DAG ID, environment name, and approximate failure time, and request a root cause analysis report.

Frequently Asked Questions about gcp-composer-troubleshooting

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I troubleshoot a failed Cloud Composer DAG?▼

Start by reading error logs with gcloud logging read filtered on resource.type=cloud_composer_environment and severity>=ERROR. Then download the actual DAG code from the environment's GCS bucket and correlate the stack trace with the failing line.

How to fetch Airflow task failure logs with gcloud?▼

Use gcloud logging read with a filter combining resource.labels.environment_name, labels.dag_id, and severity>=ERROR, plus a limit and table format. Broaden the startTime and endTime range if the exact failure time is uncertain.

Why does my local DAG differ from the one running in Composer?▼

The Composer environment runs code from its GCS bucket, which may not match your local files if deployments are out of sync. Always download the remote DAG with gcloud storage cp and confirm which version to analyze before doing the RCA.

Can this skill fix my DAG code automatically?▼

No, the workflow is read-only first: it proves the root cause using logs and remote code, then proposes a fix. Code is only modified when the user explicitly asks for the fix to be applied.

What information is needed to start a Composer root cause analysis?▼

Provide the DAG ID, and ideally the Run ID or Task ID plus an approximate failure time. If you only have a vague error, supply a time range so logs can be searched.