Skip to content
Skillpedia
Deploy & cloud (DevOps)10k · #11898

gha

What it does

This skill investigates a failed GitHub Actions run from its link. It finds the real cause of the failure, then checks past runs to see if the problem is recurring. It is for developers who keep seeing failing builds.

When to use it

  • ✓When a GitHub Actions run has failed and you want to know the exact cause.
  • ✓When a job in your workflow fails sometimes and you want to know how often it fails.
  • ✓When you want to find the commit that first made a job start failing.

Skill link

https://github.com/ykdojo/claude-code-tips/blob/main/skills/gha/SKILL.md

Copy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.

How to use

The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.

Ready-to-paste message

Use this skill to help me: https://github.com/ykdojo/claude-code-tips/blob/main/skills/gha/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
Want your AI to find skills like this on its own?Install the free Skillpedia MCP: one line, and it searches 15,000+ skills before each task.Install in 1 minute →

Example of what to ask your AI

“Look at this failed GitHub Actions run and tell me what caused it and whether it keeps happening.”

5 new skills a week. 1 minute to read.

How it works

The skill uses the GitHub command line tool to read the run logs and find what caused the failure. It then checks recent runs of the same job to see its success rate and when it last passed.

Technical content (original SKILL.md)

Original text by the author, straight from GitHub.

Investigate this GitHub Actions URL: $ARGUMENTS

Use the gh CLI to analyze this workflow run. Your investigation should:

  1. Get basic info & identify actual failure:

    • What workflow/job failed, when, and on which commit?
    • CRITICAL: Read the full logs carefully to find what SPECIFICALLY caused the exit code 1
    • Distinguish between warnings/non-fatal errors vs actual failures
    • Look for patterns like "failing:", "fatal:", or script logic that determines when to exit 1
    • If you see both "non-fatal" and "fatal" errors, focus on what actually caused the failure
  2. Check flakiness: Check the past 10-20 runs of THE EXACT SAME failing job:

    • IMPORTANT: If a workflow has multiple jobs, you must check history for the SPECIFIC JOB that failed, not just the workflow
    • Use gh run list --workflow=<workflow-name> to get run IDs, then gh run view <run-id> --json jobs to check the specific job's status
    • Is this a one-time failure or recurring pattern for THIS SPECIFIC JOB?
    • What's the success rate for THIS JOB recently?
    • When did THIS JOB last pass?
  3. Identify breaking commit (if there's a pattern of failures for the specific job):

    • Find the first run where THIS SPECIFIC JOB failed and the last run where it passed
    • Identify the commit that introduced the failure
    • Verify by checking: does THIS JOB fail in ALL runs after that commit? Does it pass in ALL runs before?
    • If verified, report the breaking commit with high confidence
  4. Root cause: Based on logs, history, and any breaking commit, what's the likely cause?

    • Focus on what ACTUALLY caused the failure (not just any errors you see)
    • Verify your hypothesis against the logs and failure logic
  5. Check for existing fix PRs: Search for open PRs that might already address this issue:

    • Use gh pr list --state open --search "<keywords>" with relevant error messages or file names
    • Check if any open PR modifies the failing file/workflow
    • If a fix PR exists, note it in your report and skip the recommendation section

Write a final report with:

  • Summary of failure (what specifically triggered the exit code 1)
  • Flakiness assessment (one-time vs recurring, success rate)
  • Breaking commit (if identified and verified)
  • Root cause analysis (based on the ACTUAL failure trigger)
  • Existing fix PR (if found - include PR number and link)
  • Recommendation (skip if fix PR already exists)
FAQ

Does it need GitHub access?

Yes. It uses the gh command line tool, so you need to be signed in with access to the repository.

Does it check every job in a workflow?

It checks the specific job that failed, not just the workflow, so the history is for the right job.

Does it fix the failure for me?

The skill focuses on finding the cause and the commit that introduced it.

Details

Original description by the author

Analyze GitHub Actions failures and identify root causes

repo: ykdojo/claude-code-tips

Popularity

GitHub stars
10k
Ranking position
#11898
License
—
Updated
9/25/2026

Is this skill useful?

0

Sign in to vote.

Comments

  • …

More skills from this repository

Similar skills