CI Failure Diagnoser
Reads a failing CI log, pinpoints the failing step and root cause, then tells you whether it's a real bug, a build/lint issue, or a flaky test.
What this skill does
Key features
- Locates the exact failing step and command in a CI log
- Classifies the failure: test, build, lint, or environment/flake
- Quotes the specific error lines instead of vague summaries
- Proposes a concrete fix for real failures and a retry path for flakes
- Distinguishes flaky signals (timeouts, network) from deterministic bugs
Use cases
- Triaging a red pipeline before a release
- Deciding whether to re-run a job or actually fix code
- Explaining an opaque CI failure to someone new to the project
SKILL.md
The skill definition — its metadata and the exact instructions an agent follows. Copy it into a SKILL.md file in your agent's skills folder.
| name | ci-failure-triage |
|---|---|
| description | Diagnose a failing CI log, identify the failing step and root cause, and propose a fix or flake retry. |
| allowed-tools | Read, Bash(git log:*), Bash(git diff:*) |
| output | triage report |
| classifies | test | build | lint | flake |
Musts
- Read the full log and identify the first step that failed, not just the last line printed.
- Quote the actual error output that caused the failure; do not paraphrase it away.
- Classify the failure as test, build, lint, or environment/flake before proposing anything.
- Give flake vs real-bug a stated confidence, based on retry behavior and error type.
- Propose a specific fix for real failures; for flakes, name the unstable step and a retry or stabilization path.
Guidelines
- Treat timeouts, DNS/network errors, and pass-on-retry as flake signals, not proof of a bug.
- Treat assertion mismatches, compile errors, and type errors as deterministic until shown otherwise.
- Point at the smallest reproducing command a developer can run locally.
Output format
Failing step: "Run tests" (jest)
Category: test failure (real, high confidence)
Error:
Expected 200, received 429 at auth.test.ts:41
Root cause: rate limiter now rejects the 6th request; the test
still assumes unlimited attempts.
Fix: update the test to expect 429 after 5 attempts, or raise the
limit in test config. Re-run CI after applying.
FAQ
Can it tell a flaky test from a real failure?
It looks for flake signals — timeouts, network errors, ordering-dependent failures, passing on retry — versus deterministic assertion or compile errors. It states its confidence and never labels a real bug as flaky just to make the pipeline green.
Does it fix and re-run CI itself?
No. It reads the log and proposes the change or the retry. You apply the fix and re-run the pipeline, so a human decides what merges.
Before running any skill, read its instructions and the tools it's allowed to use, and test it on a safe target first. See LLM security best practices.