ci-flaky-patrol

Classify stale PR CI failures and choose rerun, comment, or no-action responses.

27.5k|3.0k|Updated Jun 26, 2025
One-click install
npx skills add https://github.com/QwenLM/qwen-code --skill ci-flaky-patrol
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: ci-flaky-patrol
Source: https://github.com/QwenLM/qwen-code/tree/main/.qwen/skills/ci-flaky-patrol
Command: npx skills add https://github.com/QwenLM/qwen-code --skill ci-flaky-patrol

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Stale pull request CI failures pile up and waste maintainer time: some are transient infrastructure flakes worth rerunning, some are genuine regressions caused by the PR, and some are too ambiguous to act on. This Skill triages a bounded batch of failed CI runs and picks the safest response for each.

Core Features & Use Cases

  • Failure Classification: Reads ci-flaky-input.json and assigns each candidate exactly one action: rerun, comment, or no_action, with a confidence level and bilingual (English/Chinese) reasons.
  • Flaky Test Detection: When a rerun is caused by a nondeterministic test, it emits a flakyTest object with the exact failing file and test title so a deflake fix can be opened; infrastructure flakes get a plain rerun.
  • Safety-First Design: Treats CI logs as untrusted data, never follows instructions found in logs, caps actions per PR head, and writes only ci-flaky-decisions.json.
  • Use Case: A maintainer runs the patrol over 20 stale PRs with failing checks; the Skill outputs structured JSON decisions so the driver can rerun flaky jobs, comment on real regressions, and skip ambiguous cases.

Quick Start

Classify the CI failures listed in ci-flaky-input.json and write your decisions to ci-flaky-decisions.json.

Frequently Asked Questions about ci-flaky-patrol

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

FAQPage Schema
How do I automatically triage flaky CI failures on pull requests?▼

Provide a ci-flaky-input.json file listing candidate failures with logs and changed files. The Skill classifies each as rerun, comment, or no_action and writes decisions to ci-flaky-decisions.json for the driver to execute.

How does the skill decide between rerun and comment for a CI failure?▼

It chooses rerun only with concrete transient evidence such as runner timeouts, network failures, or explicit flaky-test signals. It chooses comment when the failure is clearly caused by the PR, verified by comparing the failure against the changed files.

When does the skill report a flaky test for a deflake fix?▼

Only when the rerun cause is a nondeterministic test, such as a named test that timed out or is order-dependent. Infrastructure flakes like ENOSPC or network errors get a plain rerun with no flakyTest object.

Can this skill handle main-branch CI failures?▼

No, main-branch failures are explicitly out of scope. The Skill only processes pull request candidates supplied by the JavaScript driver, which also enforces a maximum of three actions per PR head.

Is it safe to let an AI read CI logs that may contain injected instructions?▼

Yes, the Skill treats every log as untrusted data and never follows instructions found inside it. It is restricted to read_file and write_file tools and may only write the ci-flaky-decisions.json output file.