Agent skill

Unblock PR

by datadog-labs in datadog-labs/agent-skills

Load when investigating a failing PR CI pipeline or checking PR health.

MITAuto-check passedTesting & QA

Install Unblock PR

skills CLI
$ npx skills add datadog-labs/agent-skills --skill unblock-pr -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install datadog-labs/agent-skills unblock-pr --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/datadog-labs/agent-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/dd-software-delivery/unblock-pr .claude/skills/unblock-pr && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
unblock-pr
GitHub stars
177
Token cost
~2.7k tokens
SKILL.md length
1,070 words
Files
1
Skills in repo
39
Repo updated
First seen
Licence
MIT

At a glance

Load when investigating a failing PR CI pipeline or checking PR health.

  • Works in 7 steps: Parse Input → Get PR CI Summary (run in parallel) → 5 — Fetch PR Health (run in parallel… → …
  • Tasks that involve Failing and flaky tests
  • SKILL.md covers Backend, Input, Workflow and Tool Reference
  • Calls git, gh and brew; reaches github.com

What it does

Unblock PR is an agent skill from datadog-labs/agent-skills. Load when investigating a failing PR CI pipeline or checking PR health. Attributes each CI failure as flaky, infra, or regression, proposes a targeted action, and reports code coverage and quality/security status.

Its SKILL.md is about 2.7k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Testing & QA, covering Failing and flaky tests, CI/CD and Test coverage. It works with Model Context Protocol, Datadog and GitHub. The repository describes itself as: Public repository for Datadog Agent Skills. The licence is MIT.

When your agent uses it

  • Tasks that involve Failing and flaky tests
  • Tasks that involve CI/CD
  • Tasks that involve Test coverage

Example prompts

  • “/unblock-pr”

Workflow steps

7 steps, taken from the step headings in SKILL.md.

  1. Parse Input
  2. Get PR CI Summary (run in parallel)
  3. 5 — Fetch PR Health (run in parallel with STEP 1)
  4. Blame Guard per Failing Job
  5. Classify Each Failure
  6. Produce Triage Brief
  7. Propose Actions

What it can do on your machine

Read from SKILL.md and the folder at commit d2411cc. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git
    • gh
    • brew

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • github.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Unblock PR loads about 2.7k tokens when it runs. Until then it costs about 56 tokens; SKILL.md has 1,070 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~56
When it runs · the whole SKILL.md, loaded when a task matches
~2.7k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from datadog-labs/agent-skills at commit d2411cc, republished under its MIT licence (© datadog-labs). 1,070 words, ~2,685 tokens.

Download SKILL.mdSave it as .claude/skills/unblock-pr/SKILL.md (or your agent's skills folder).
name
unblock-pr
description
Load when investigating a failing PR CI pipeline or checking PR health. Attributes each CI failure as flaky, infra, or regression, proposes a targeted action, and reports code coverage and quality/security status.
metadata.version
1.0.0
metadata.author
datadog-labs
metadata.repository
https://github.com/datadog-labs/agent-skills
metadata.tags
datadog,ci,cicd,flaky,flaky-tests,pipeline
metadata.alwaysApply
false

Unblock PR

One-line summary: Investigate a failing PR CI pipeline — attribute each failure as flaky, infra, or regression and propose a targeted action.

Requires: dd-pup skill (pup CLI installed and authenticated), triage-flaky-test skill (for flaky failure deep investigation).


Backend

Detection — At the start of every invocation, before taking any action, determine which backend to use:

  1. If the user passed --backend pup anywhere → use pup mode immediately. Skip steps 2–4.
  2. Check whether search_datadog_ci_pipeline_events appears in your available tools.
  3. If present → use MCP mode throughout. Call tools exactly as named in this skill's workflow sections.
  4. If absent → check whether pup is executable: run pup --version via Bash. If the command exits successfully (exit code 0), pup is available.
  5. If pup responds → use pup mode throughout. Translate every tool call using the Tool Reference appendix at the bottom of this file.
  6. If neither is available → stop and tell the user:

    "Neither the Datadog MCP server nor the pup CLI is available. Connect the MCP server or install pup (brew install datadog-labs/pack/pup)."

pup invocation rules:

  • Invoke via Bash. pup always outputs JSON — parse directly.
  • Repository IDs passed to pup must be fully lowercase (the API rejects mixed-case): github.com/datadog/my-repo, not github.com/DataDog/my-repo.
  • If pup returns a 401/403, tell the user to run pup auth refresh or pup auth login.

Input

ParameterDescription
PR branchThe branch under investigation (e.g. my-feature-branch)
RepositoryLowercase, no-schema URL (e.g. github.com/org/repo). Derive from git remote get-url origin if not provided.

Workflow

STEP 0 — Parse Input

Derive repository ID and default branch from git if not provided:

bash
# Repository ID: fully lowercase, no-schema URL (the API rejects mixed-case)
git remote get-url origin
# Strip protocol and trailing .git, then lowercase the result
# e.g. https://github.com/DataDog/my-repo.git → github.com/datadog/my-repo

# Default branch
git symbolic-ref refs/remotes/origin/HEAD
# Strip refs/remotes/origin/ prefix — fall back to main if unset
STEP 1 — Get PR CI Summary (run in parallel)

Pipeline failures:

Tool: search_datadog_ci_pipeline_events
query: @ci.status:error @git.branch:<branch> @git.repository.id_v2:"<repo>"
ci_level: job
from: now-24h

Test failures (only if pipeline results include test-runner jobs):

Tool: search_datadog_test_events
query: @test.status:fail @git.branch:<branch> @git.repository.id_v2:"<repo>"
from: now-24h
test_level: test

Run both in parallel. Collect all distinct @test.service values from test event results. If more than one distinct service is found, note each separately in the triage brief — do not collapse them into a single service filter. If pipeline results contain only infrastructure job types (build, lint, deploy) with no test-runner output, discard test results and skip to STEP 3.

STEP 1.5 — Fetch PR Health (run in parallel with STEP 1)

This step runs unconditionally — PR health context is valuable whether CI is red or green.

Code coverage (both modes):

Tool: get_datadog_code_coverage_branch_summary
repository_id: <repo>
branch: <branch>

PR number resolution (MCP mode only — skip if PR number already provided as input):

Tool: get_prs_by_head_branch
repo_url: https://<repo>
head_branch: <branch>

Use the first open PR returned. If no open PR is found, skip the quality/security fetch and report "No data available" for Quality and Security.

Code quality and security (MCP mode only — only if PR number is available):

Tool: search_pr_insights
repo_url: https://<repo>
pr_number: <pr_number>

Extract only code_quality and code_security from products_status. Ignore failed_tests, flaky_tests, and failed_jobs — CI data comes from STEP 1–3.

pup mode note: PR number resolution and search_pr_insights are not available in pup. Quality and Security always show "No data available" in pup mode.

STEP 2 — Blame Guard per Failing Job

First check whether @error_classification.domain / @error_classification.type are present on job events from STEP 1 — if populated, use them as primary classification signals.

For each failing job where classification is still needed, run both checks in parallel:

Default branch check — was this job already failing before this PR?

Tool: aggregate_datadog_ci_pipeline_events
query: @ci.status:error @ci.job.name:"<job>" @git.branch:<default-branch> @git.repository.id_v2:"<repo>"
ci_level: job
aggregation: count
from: now-24h

Blast radius check — is this job failing on other branches too?

Tool: aggregate_datadog_ci_pipeline_events
query: @ci.status:error @ci.job.name:"<job>" @git.repository.id_v2:"<repo>"
ci_level: job
aggregation: count
group_by: ["@git.branch"]
from: now-24h

Performance fallback: if the blast radius query is slow or times out, skip it and rely on the default branch check alone.

STEP 3 — Classify Each Failure

Priority order:

  1. If @error_classification.domain / @error_classification.type present → use as primary signal
  2. If test failure AND test in get_datadog_flaky_tests with flaky_test_state:active → flaky
  3. Use blame guard results:
Failing on default branch?Failing on ≥3 other branches?Classification
YesYesinfra (pre-existing, widespread)
YesNoinfra (pre-existing on default branch)
NoNoregression (introduced by this PR)
NoYesflaky (intermittent, cross-branch)
Insufficient data—unknown
STEP 4 — Produce Triage Brief

One entry per failing job:

PR CI Triage Brief
==================
Branch:   <branch>
Repo:     <repo>

Job: <job-name>
  Classification:  <flaky | infra | regression | unknown>
  Evidence:        <1 key data point — error message, pipeline count, or test result>
  Confidence:      <high | medium | low>
  Recommended:     <action>

[repeat for each failing job]

Overall: <N> failures — <e.g. "1 regression, 1 flaky, 1 infra">

PR Health
=========
Coverage:   <X>% on <branch> | No data available
Quality:    <N violations (X high, Y medium)> | No violations | No data available
Security:   <N violations> | No violations | No data available

All three lines always appear. Use "No data available" when a tool returned no data or is unavailable (pup mode for Quality/Security).

Show full SKILL.md (418 more words)Show less
STEP 5 — Propose Actions

regression → Prompt user to investigate their code changes. No write action available.

flaky → Load triage-flaky-test skill for deep investigation. Invoke it once per distinct failing test name classified as flaky, passing the test name (from @test.name in STEP 1 results) and the derived repository as inputs. That skill will:

  • Attempt an agent-native fix using flaky_category + stack trace
  • Propose quarantine via update_datadog_flaky_test_states if a quick fix isn't possible

infra → Before proposing a retry, assess whether the failure is transient:

  • Check @error_classification.type and error message for signals like timeout, runner unavailable, network error, quota exceeded — transient failures where a retry is likely to help
  • If the error is deterministic (build misconfiguration, missing secret, explicit test assertion failure), a retry is unlikely to help — suggest investigating the root cause
  • If the failure is pre-existing on the default branch, inform the user — a retry will likely fail again; await the upstream fix instead

If transient:

MCP mode — GitHub Actions: use retry_datadog_ci_job. From the failing job event, collect:

  • @ci.provider.name → ci_provider ("github")
  • @git.repository.id_v2 → repository_id
  • @ci.job.id → job_id
  • event id field → event_uuid (optional)

For pipeline_id: use @ci.pipeline.id directly if it matches ^\d+-[1-9]\d*$ (e.g. 26027867390-1). If it is a bare numeric run ID, combine it with @github.run_attempt from the same event: "{@ci.pipeline.id}-{@github.run_attempt}". Fallback: parse @ci.pipeline.url — extract {run_id} and {attempt} from runs/{run_id}/attempts/{attempt}.

After retry returns, confirm via search_datadog_ci_pipeline_events (query: @ci.job.name:"<job>" @git.branch:<branch>, from: now-5m) that a new run appears.

Fallback / pup mode — GitHub Actions: extract the run ID from @ci.pipeline.url:

bash
gh run rerun <run_id> --failed

GitLab / other providers (both modes): share @ci.pipeline.url and direct to the provider UI.

unknown → Suggest checking raw job logs via the CI provider UI or @ci.pipeline.url from the pipeline event.


Tool Reference

This appendix applies only in pup mode. In MCP mode, use the tool names in the workflow sections directly.

MCP Toolpup Command
search_datadog_ci_pipeline_events (ci_level: job)pup cicd events search --query "..." --level job --from 24h --limit 50
aggregate_datadog_ci_pipeline_events (count, group_by branch)pup cicd events aggregate --query "..." --compute count --group-by "@git.branch" --from 24h
aggregate_datadog_ci_pipeline_events (count, no group_by)pup cicd events aggregate --query "..." --compute count --from 24h
search_datadog_test_eventspup cicd tests search --query "..." --from 24h --limit 50
get_datadog_flaky_testspup cicd flaky-tests search --query "flaky_test_state:active ..."
update_datadog_flaky_test_statesWrite body to /tmp/flaky-update.json, then pup test-optimization flaky-tests update --file /tmp/flaky-update.json
get_datadog_code_coverage_branch_summaryrepo_lower=$(echo "<repo>" | tr '[:upper:]' '[:lower:]') && pup code-coverage branch-summary --repo "$repo_lower" --branch "<branch>"
get_prs_by_head_branchNot available in pup — skip; report "No data available" for Quality/Security
search_pr_insightsNot available in pup — skip; report "No data available" for Quality/Security
retry_datadog_ci_jobNot available in pup — use gh run rerun <run_id> --failed instead

© datadog-labs, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in dd-software-delivery/unblock-pr of datadog-labs/agent-skills.

Open the folder on GitHubat commit d2411cc

Compare with similar skills

Unblock PR next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Unblock PR compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Unblock PR this skilldatadog-labs/agent-skills177—~2.7kAutomated safety check: PassMIT
Reviewapollographql/apollo-mcp-server314—~2.9kAutomated safety check: PassMIT
Dd Unblock PRDataDog/pup1k—~1.7kAutomated safety check: PassApache-2.0
GreptimeDB Fuzz CI Failure InvestigationGreptimeTeam/greptimedb6.7k—~4.4kAutomated safety check: PassApache-2.0
MAUI CI Investigatordotnet/maui23k—~2kAutomated safety check: PassMIT
Babysit PRZenUml/web-sequence150—~871Automated safety check: PassMIT

Similar skills

  • Review

    apollographql/apollo-mcp-server

    Review a GitHub pull request for a Rust codebase. An agent skill from apollographql/apollo-mcp-server.

    314 GitHub stars~2.9k tokensUpdated 3 days ago
    Testing & QAAuto-check passed
  • Dd Unblock PR

    DataDog/pup

    Official

    Load when investigating a failing PR CI pipeline or checking PR health.

    1k GitHub stars~1.7k tokensUpdated today
    Testing & QAAuto-check passed
  • Diagnoses a failed GreptimeDB fuzz CI job by pulling its GitHub Actions logs and fuzz artifacts, then matching the evidence to the local source code.

    6.7k GitHub stars~4.4k tokensUpdated today
    Testing & QAAuto-check passed
  • Official

    Adds dotnet/maui-specific context for investigating failing PR checks and broken nightly builds: pipelines, Helix logs, binlogs and merge-readiness verdicts.

    23k GitHub stars~2k tokensUpdated today
    Testing & QAAuto-check passed
  • Babysit PR

    ZenUml/web-sequence

    Monitor and diagnose GitHub Actions checks on ZenUML web-sequence PRs, fixing code-caused CI failures when appropriate.

    150 GitHub stars~871 tokensUpdated 5 days ago
    Testing & QAAuto-check passed
  • Azsdk Common Pipeline Analysis

    Azure/azure-sdk-tools

    Official

    Analyze Azure SDK CI/CD pipeline failures into a structured diagnosis, and define the required output format.

    134 GitHub stars~1.2k tokensUpdated today
    Testing & QAAuto-check passed

More from datadog-labs/agent-skills

All 39 skills in this repo
  • Bootstrap a reproducible LLM Observability experiment through the Python ddtrace SDK or the Node dd-trace SDK.

    177 GitHub stars~2.3k tokensUpdated yesterday
    Auto-check passed
  • Dd Account Setup

    datadog-labs/agent-skills

    Ensure the user has an authenticated Datadog account with a valid DDAPIKEY on the right region before any Datadog setup or instrumentation.

    177 GitHub stars~4.5k tokensUpdated yesterday
    Auto-check: notes
  • Dd Orchestrator

    datadog-labs/agent-skills

    Entry point for Datadog onboarding. An agent skill from datadog-labs/agent-skills.

    177 GitHub stars~6.7k tokensUpdated yesterday
    Auto-check passed
  • Dd Apm

    datadog-labs/agent-skills

    APM - install, onboard, instrument, enable, set up, configure, traces, services, dependencies, performance analysis, Data Streams Monitoring (DSM), queue lag, pipeline latency.

    177 GitHub stars~2k tokensUpdated yesterday
    Auto-check passed
  • Agent Install

    datadog-labs/agent-skills

    Install the Datadog Agent on Kubernetes using the Datadog Operator — required before enabling Single Step Instrumentation (SSI), which automatically instruments applications for APM without code…

    177 GitHub stars~2.1k tokensUpdated yesterday
    Auto-check: warnings
  • Dd AWS Integration

    datadog-labs/agent-skills

    Set up the Datadog AWS integration with Terraform - creates the cross-account IAM role Datadog assumes (external ID, no stored credentials), attaches the permission policies Datadog publishes, and…

    177 GitHub stars~6.8k tokensUpdated yesterday
    Auto-check: notes

Questions about Unblock PR

What does Unblock PR do?

Load when investigating a failing PR CI pipeline or checking PR health. Unblock PR is an agent skill from datadog-labs/agent-skills. Load when investigating a failing PR CI pipeline or checking PR health.

When should I use Unblock PR?

Unblock PR fits situations like: tasks that involve Failing and flaky tests; tasks that involve CI/CD; tasks that involve Test coverage.

How do I install Unblock PR in Claude Code?

Run `npx skills add datadog-labs/agent-skills --skill unblock-pr -a claude-code`. Or copy the skill folder (dd-software-delivery/unblock-pr in datadog-labs/agent-skills) into .claude/skills/unblock-pr in your project. Claude Code loads it when a task matches its description.

How do I install Unblock PR in Codex?

Run `npx skills add datadog-labs/agent-skills --skill unblock-pr -a codex`. Or copy the skill folder (dd-software-delivery/unblock-pr in datadog-labs/agent-skills) into .agents/skills/unblock-pr in your project. Codex loads it when a task matches its description.

Can I use Unblock PR in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add datadog-labs/agent-skills --skill unblock-pr -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/unblock-pr, .gemini/skills/unblock-pr, .github/skills/unblock-pr and .opencode/skills/unblock-pr in your project.

What does Unblock PR need to run?

Going by SKILL.md and its folder, Unblock PR needs the command-line tools its instructions call (git, gh and brew).

Does Unblock PR access the network?

SKILL.md names 1 domain. In commands or code: github.com; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.

Is Unblock PR safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Unblock PR use?

Unblock PR is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Unblock PR use?

About 2.7k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Unblock PR?

Skills that share tags, products or a category with Unblock PR: Review (apollographql/apollo-mcp-server, 314 stars), Dd Unblock PR (DataDog/pup, 1k stars), GreptimeDB Fuzz CI Failure Investigation (GreptimeTeam/greptimedb, 6.7k stars) and MAUI CI Investigator (dotnet/maui, 23k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Unblock PR?

datadog-labs (a GitHub organization) maintains it in datadog-labs/agent-skills, which has 177 GitHub stars. The repository holds 39 skills in this directory. The repository was last updated on October 8, 2026.

Source: datadog-labs/agent-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.