·
Last changedVersion:
This version passed the hardening gate. Hardening applied 3 targeted changes and preserved all other text. Classified findings before hardening: 2. Classified findings closed: 0. Classified findings remaining: 2. Unclassified scanner findings remaining: 0. Review findings closed: 2. Review findings remaining: 15.
2
2
Expand | File | Group | Subtype | Severity | Status |
|---|---|---|---|---|---|
SKILL.md | Malicious Code & Command Execution | — | Low | Open | |
SKILL.md | Supply Chain & Install-Time Trust | Install-time download and execute | Low | Open |
2 findings
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).
Detection — At the start of every invocation, before taking any action, determine which backend to use:
--backend pup → use pup mode immediately. Skip steps 2–4.search_datadog_ci_pipeline_events appears in your available tools.pup is executable: run pup --version via Bash. If the command exits successfully (exit code 0), pup is available.pup invocation rules:
github.com/datadog/my-repo, not github.com/DataDog/my-repo.pup auth refresh or pup auth login.| Parameter | Description |
|---|---|
PR branch | The branch under investigation (e.g. |
Repository | Lowercase, no-schema URL (e.g. |
Derive repository ID and default branch from git if not provided:
Pipeline failures:
Test failures (only if pipeline results include test-runner jobs):
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.
This step runs unconditionally — PR health context is valuable whether CI is red or green.
Code coverage (both modes):
PR number resolution (MCP mode only — skip if PR number already provided as input):
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):
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.
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?
Blast radius check — is this job failing on other branches too?
Performance fallback: if the blast radius query is slow or times out, skip it and rely on the default branch check alone.
Priority order:
@error_classification.domain / @error_classification.type present → use as primary signalget_datadog_flaky_tests with flaky_test_state:active → flaky| Failing on default branch? | Failing on ≥3 other branches? | Classification |
|---|---|---|
Yes | Yes | infra (pre-existing, widespread) |
Yes | No | infra (pre-existing on default branch) |
No | No | regression (introduced by this PR) |
No | Yes | flaky (intermittent, cross-branch) |
Insufficient data | — | unknown |
One entry per failing job:
All three lines always appear. Use "No data available" when a tool returned no data or is unavailable (pup mode for Quality/Security).
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:
flaky_category + stack traceupdate_datadog_flaky_test_states if a quick fix isn't possibleinfra → Before proposing a retry, assess whether the failure is transient:
@error_classification.type for signals like timeout, runner unavailable, network error, quota exceeded — transient failures where a retry is likely to helpIf 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_idid 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:
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.
This appendix applies only in pup mode. In MCP mode, use the tool names in the workflow sections directly.
| MCP Tool | pup Command |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
| Not available in pup — skip; report "No data available" for Quality/Security |
| Not available in pup — skip; report "No data available" for Quality/Security |
| Not available in pup — use |
Get started with chainctlchainctl skill install public/datadog-labs/unblock-pr:latest
Bring Chainguard's hardening pipeline to your first-party skills — custom rulesets, automated remediation, full audit trail.
skills.cgr.dev/public/github.com/datadog-labs/dd-software-delivery/unblock-pr:latest
MIT
HARDENING.md
LICENSE
SKILL.md