ci-failure-fix
Skill0 starsChanged 6 days agoMITView on GitHub
Diagnose and fix a failing CI pipeline (GitHub Actions, GitLab CI, CircleCI, Jenkins...). Use when the user says "CI is red", "the build fails", "checks are failing on my PR", "it passes locally but fails in CI", or pastes a CI log.
- Installs packages
In this repository24 other files it gives its agents.
- api-docsSkill
- changelogSkill
- code-reviewSkill
- commit-messageSkill
- competitor-analysisSkill
- data-analystSkill
- debug-detectiveSkill
- dependency-upgradeSkill
- dockerizeSkill
- email-replierSkill
- eval-promptSkill
- incident-postmortemSkill
- meeting-notesSkill
- migration-safetySkill
- pr-descriptionSkill
- product-specSkill
- readme-writerSkill
- refactor-safelySkill
- research-briefSkill
- security-checkSkill
- seo-articleSkill
- sql-helperSkill
- support-replySkill
- write-testsSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 3 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 17
Already broken on the base branch: check the latest run on main.
- Distinctive: line 23
Use the exact command from the workflow file, not your usual one.
- Distinctive: line 30
Test bug (order dependence, real clock, real network, shared fixtures): make the test deterministic.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Fix a failing CI build
1. Get the real log
- GitHub Actions:
gh run list --branch <branch> -L 5, thengh run view <id> --log-failed. GitLab: the failed job's log. Otherwise ask for the full log of the failed step, not a screenshot. - Find the first error, not the last line. Later failures are often consequences.
- Note which job, step, runner OS and runtime version failed.
2. Classify
- Real failure from this change: fails consistently, related to the diff.
- Already broken on the base branch: check the latest run on main. If main is red too, say so; the fix may not belong in this PR.
- Flaky: passed on re-run with the same commit, or fails at random places (timeouts, ordering, network, time zones, shared state). Check the run history before calling it flaky.
- Environment: CI-only differences: runtime or tool version, missing secret (forks do not get secrets), cache, OS (case-sensitive paths on Linux, line endings on Windows), timezone, locale, CPU count, missing system package.
3. Reproduce locally
- Use the exact command from the workflow file, not your usual one.
- Match the CI environment: same runtime version (read the workflow and
.nvmrc,.tool-versions,python-version), clean install from the lockfile (npm ci,pip install -r,bundle install --frozen), the same env vars,CI=true. - Still passes locally? Diff the environments one by one. For containers, run the job image locally. Ask the user for access only if you truly need it.
4. Fix the cause
- Code bug: fix it and add or keep the test that caught it.
- Test bug (order dependence, real clock, real network, shared fixtures): make the test deterministic.
- Environment: pin the version, add the missing setup step or fix the path. Explain why CI differed.
- Lockfile drift: regenerate it with the project's package manager and version.
Do not
- Skip, delete or mark the test as expected-to-fail, add
continue-on-error, lower coverage thresholds, or increase timeouts to make CI green, unless the user explicitly agrees and you record why. - Re-run until it passes and call it fixed.
- Print or change secrets. If a secret is missing, tell the user which one and where to set it.
Report
- Failing job and step, and the first real error (quoted).
- Classification and the evidence for it.
- Cause in one sentence.
- The fix, and proof: the command you ran locally and its result, or the new CI run.
- Anything still unverified (for example, it needs a secret you cannot see).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

