/wire:airflowfrom wire
Writes, deploys, and debugs Apache Airflow 2.x DAGs in Cloud Composer or self-managed estates. Activates on DAG files, deploy requests, parse failures, and queued tasks.
Ships in wire. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Before proceeding, append a one-line entry to .wire/execution_log.md:
| YYYY-MM-DD HH:MM | skill | airflow | activated | Airflow DAG work triggered this skill |
If .wire/execution_log.md does not exist, create it with the standard header first (see specs/utils/execution_log.md). If no .wire/ directory exists in the current repo, skip this step.
Write, deploy and check Airflow code in an estate a client already runs: Cloud Composer 2 or 3, or a self-managed Airflow 2.x. The skill carries Wire's general Airflow practice. The client's own rules, helper names and environment values live in the client's repo, in files this skill reads:
| File | Holds | Schema |
|---|---|---|
.wire/conventions/airflow.yml | The client's extra rules and helper names, with extends: wire | wire/schemas/convention-schema.md |
.wire/engagement/airflow_environments.yml | Environments, buckets, branches, deploy allow and forbid lists, protected paths and DAGs | wire/schemas/airflow-environments-schema.md |
.wire/engagement/review_profile.yml | PR template, tracker, review mode | wire/schemas/review-profile-schema.md |
Stop if .wire/engagement/airflow_environments.yml is missing whenever a step needs an environment value (deploy, logs, caps). Say: "No Airflow environment file. Run /wire:adopt to propose one, or write it from wire/schemas/airflow-environments-schema.md." Never write a project, bucket, environment name or region from memory or from an example.
airflow, or sits in the repo's DAG folder.status.md shows pipeline_tool: airflow or orchestration_tool: airflow./wire:pipeline-generate, /wire:orchestration-generate (existing Airflow estate mode), /wire:utils-dev-deploy or /wire:utils-dev-test-evidence runs.Keywords: "airflow", "composer", "DAG", "dag_id", "operator", "sensor", ".expand", "mapped task", "default_args", "queued", "gcs-syncd", "dag processor", "Broken DAG".
.wire/conventions/airflow.yml if present, else Wire's conventions/airflow.yml. A client file with extends: wire keeps Wire's rules and adds its own; one without extends replaces Wire's.python3 <wire>/scripts/lint_conventions.py --domain airflow \
--convention <resolved airflow.yml> --path <dag folder> --changed-from <base branch>
Without --changed-from, every finding in the folder is listed as a warning: that is the list of what to fix in an existing estate, not a reason to change files the task does not touch.
| Id | Rule | Checked by script |
|---|---|---|
| AF-001 | Use the repo's shared helpers before writing new ones | no |
| AF-002 | No project id or bucket written into Python | yes |
| AF-003 | Schedules and targets from per-environment config | no |
| AF-004 | One DAG per job, mapped tasks over the varying inputs, not copied DAGs | no |
| AF-005 | Every .expand() capped (max_active_tis_per_dag, a pool, or max_active_tasks on the DAG), cap from config | yes |
| AF-006 | A DAG file contains the words airflow and dag (safe mode skips it otherwise, with no error) | yes |
| AF-007 | DAG arguments (catchup, schedule, max_active_runs, tags, ...) on the DAG, never in default_args | yes |
| AF-101 | No Variable.get() at module level | yes |
| AF-102 | Fixed start_date, never now() or days_ago() | yes |
| AF-103 | Sensors reschedule or defer, or time out within the limit | yes |
| AF-104 | No network, process or warehouse calls at module level | yes |
| AF-105 | schedule=, not schedule_interval= | yes |
| AF-106 | No imports removed in Airflow 3 (airflow.contrib, *_operator modules, DummyOperator, days_ago) | yes |
Judgement calls that no script checks are in references/general_practice.md. Read it before writing a new DAG.
helpers: from its rule file if it has one.{{ var.value.x }}, {{ ds }}) is fine.default_args holds task arguments only: owner, retries, retry_delay, callbacks, start_date if the repo does it that way..expand() from the environment's max_mapped_tasks or a pool. Remember the scheduler's own limit on map length (max_map_length, 1024 by default).fixed, justified with a reason, or acknowledged. Findings never block.Deploy only through /wire:utils-dev-deploy, which runs wire/scripts/airflow_deploy.py. Never copy with your own gcloud storage, gsutil or rsync command.
deploy.allowed and not in deploy.forbidden. Refuse staging and production even if the user asks; say that the client's CI deploys there.Do not tell the user to trigger a run until both hold for each deployed DAG file:
gcs-syncd container); this takes up to a few minutes. Self-managed Airflow uses its own sync (git-sync, a volume); ask how it works if the environment file does not say.gcloud storage objects describe gs://<bucket>/<object> --format="value(update_time)") with the DAG processor's last parse of the file.Cloud Logging queries (gcloud logging read '<filter>' --project <project> --freshness 1h --format json). The environment's project and composer_environment come from the environment file. Composer's log names and label keys have changed between versions: read one entry with --limit 1 first and adjust the filter to what is there.
# Sync of one file to the environment
resource.type="cloud_composer_environment"
resource.labels.environment_name="<composer_environment>"
log_id("gcs-syncd")
textPayload:"<file name>"
# Parse of one file (DAG processor)
resource.type="cloud_composer_environment"
resource.labels.environment_name="<composer_environment>"
(log_id("dag-processor-manager") OR log_id("airflow-dag-processor-manager") OR log_id("airflow-scheduler"))
textPayload:"<file name>"
# Import errors for one file
resource.type="cloud_composer_environment"
resource.labels.environment_name="<composer_environment>"
(textPayload:"Broken DAG" OR textPayload:"ImportError" OR textPayload:"Traceback")
textPayload:"<file name>"
Report per file: parsed (with the time), import error (with the message), or not parsed yet.
For teams that cannot run the Airflow command line or reach the REST API. Airflow 2 workers log one line per finished task instance, Marking task as SUCCESS. or Marking task as FAILED., with dag_id, task_id, run_id and map_index:
# Task outcomes for one DAG since the upload
resource.type="cloud_composer_environment"
resource.labels.environment_name="<composer_environment>"
log_id("airflow-worker")
textPayload:"Marking task as"
textPayload:"dag_id=<dag_id>"
timestamp>="<upload time, RFC 3339>"
# Everything one task instance logged
resource.type="cloud_composer_environment"
resource.labels.environment_name="<composer_environment>"
log_id("airflow-worker")
labels.workflow="<dag_id>"
labels."task-id"="<task_id>"
A run succeeded only when every task instance in it, each mapped index included, reached success. Count the mapped indexes you expected (the length of the mapped input) against the indexes logged. For the tested-in-dev verdict, give these records to /wire:utils-dev-test-evidence; do not judge it by hand.
Check in this order. Each cause names what to read:
| Cause | How to tell |
|---|---|
| Workers at capacity | Running tasks equal workers times celery.worker_concurrency. Composer autoscaling adds workers after a delay; check the worker count in the environment's monitoring. |
| Pool full | The task's pool has no open slots (default_pool is 128 slots by default). Other DAGs' tasks may hold them. |
| DAG or task limits | max_active_tasks on the DAG, max_active_tis_per_dag on the task, max_active_runs, or core.parallelism for the whole environment, reached. |
| Long sensors in poke mode | Sensors hold worker slots while they wait (rule AF-103). Count running sensors. |
| Workers restarting | Worker pods evicted or out of memory: look for OOMKilled, eviction or restarts in the worker logs; queued tasks wait for a new worker. |
| Scheduler unhealthy | No scheduler heartbeat in the scheduler logs, or the DAG processor timing out on slow files (rule AF-104). |
| Queue name mismatch | The task sets a queue no worker listens on. |
| Task stuck after a worker died | A task queued in Celery whose worker has gone. Airflow re-queues it after scheduler.task_queued_timeout (10 minutes by default in 2.6 and later). |
| Symptom | Usual cause | Fix |
|---|---|---|
| DAG never appears, no error | File lacks the words airflow and dag (AF-006), or is in .airflowignore | Add the words; check .airflowignore |
| DAG appears, never runs | start_date moves (AF-102), DAG paused, or catchup=False with a start date after the only interval | Fixed start date; unpause |
catchup set but ignored | Put in default_args (AF-007) | Move to the DAG |
| Parse slow, scheduler lags | Module-level work: Variable.get, network or warehouse calls (AF-101, AF-104) | Move into tasks or Jinja |
| Mapped task floods workers | .expand() with no cap (AF-005) | max_active_tis_per_dag or a pool from config |
| Works in dev, fails in prod | A literal project or bucket (AF-002) | Read from per-environment config |
| Different results on re-run | Task uses the wall clock (datetime.now()) instead of the logical date | Use {{ ds }}, data_interval_start |
| Large XCom fails or slows the database | Data passed through XCom | Pass a path or table name, not the data |
| Task killed with no error | Worker out of memory | Smaller batches, more memory, or a pod per task |
| Imports fail after an upgrade | Imports removed in Airflow 3 (AF-106) | Use the providers' current paths |
Gemini CLI has no skills. The Airflow specs tell it to read this file and follow it. Every step here runs the same there: the scripts are plain Python and the queries run with gcloud logging read.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub rittmananalytics/wire-plugin --plugin wire74 skills in this plugin
/add-analytics-instrumentationEnd-to-end analytics instrumentation workflow for a PR, branch, file, directory, or feature. Reads the code, discovers what events should be tracked, and produces a concrete instrumentation plan — all in one shot. Use this skill whenever a user wants to add analytics to a PR, asks "instrument this PR", "add tracking to this branch", "what analytics does this file need", "instrument the checkout flow", "run the full instrumentation workflow", or any request that implies going from code changes to a tracking plan. Also trigger when the user gives you a PR link, branch name, file path, or feature description and mentions analytics, events, or instrumentation. This is the main entry point for the analytics workflow — prefer it over calling the individual steps (diff-intake, discover-event-surfaces, instrument-events) separately.
/agents-schemaPublish and read warehouse metadata through dbt Labs' Agents Schema (the AGENTS schema inside Snowflake, Databricks or BigQuery, written by the agents-schema CLI from a dbt manifest, LookML, Omni, OSI, Sigma and markdown skills). Activates when the user mentions Agents Schema, agents_schema, AGENTS.ROOT, the agents-schema CLI or its GitHub workflows, warehouse-delivered skills, or asks how an AI agent should find governed context for a warehouse. Used by /wire:agents_schema-generate, -validate and -review, and for ad-hoc work against an AGENTS schema.Other plugins' skills for the same job