Skip to content

Add /ort-ci skill for triaging and re-running CI checks#29721

Open
tianleiwu wants to merge 2 commits into
mainfrom
tlwu/20260715/add_skill_ort_ci
Open

Add /ort-ci skill for triaging and re-running CI checks#29721
tianleiwu wants to merge 2 commits into
mainfrom
tlwu/20260715/add_skill_ort_ci

Conversation

@tianleiwu

Copy link
Copy Markdown
Contributor

Description

Adds a new /ort-ci agent skill that documents how to trigger, re-run, and unblock ONNX Runtime CI checks on a GitHub pull request, plus a helper script that safely re-runs only genuinely failed/cancelled GitHub Actions workflows. The skill emphasizes diagnosing each failure before re-running, since most CI failures require a code change and re-running them just fails again.

Key Changes

File Change
.agents/skills/ort-ci/SKILL.md New skill documenting ORT CI triage and management: classifying a check's provider, gathering PR/check context, per-failure triage (download log -> classify -> fix or re-run), and targeted playbooks.
tools/scripts/rerun_failed_ci.sh New helper that re-runs a PR's failed/cancelled GitHub Actions runs for the current head commit, skipping workflows that already have a newer queued/in-progress run to avoid duplicate runs. Supports --dry-run and auto-detects owner/repo.
AGENTS.md Adds a CI section pointing to the new /ort-ci skill.

The skill covers the current ORT CI topology (as of 2026-07): nearly all checks run as GitHub Actions; only Linux Android Emulator QNN CI Pipeline remains on Azure Pipelines, plus the bot-driven license/cla and Python format checks. It includes step-by-step playbooks for:

  • Re-running transient GitHub Actions failures (via rerun_failed_ci.sh)
  • Unblocking license/cla
  • Fixing the Python format required check
  • Triggering the Azure Pipelines QNN Android Emulator check (/azp run and direct fallback)
  • Fixing the Windows GPU Doc Gen CI check when operator docs are out of date
  • Safety rules and post-trigger verification

Testing Notes

  • Documentation- and tooling-only change; no product code or runtime behavior is affected.
  • rerun_failed_ci.sh was exercised in --dry-run mode against live PRs (e.g. ./rerun_failed_ci.sh <pr> --dry-run) to confirm it correctly lists failed/cancelled workflows and triggers nothing.
  • The script requires an authenticated gh CLI and uses only gh's built-in --jq (no external jq binary needed).

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a new /ort-ci agent skill and supporting tooling to help contributors triage ONNX Runtime CI on pull requests, with guidance on when to diagnose vs. re-run checks and how to unblock common required checks.

Changes:

  • Added a new /ort-ci skill documenting CI triage, re-run workflows, and playbooks for common required checks (GitHub Actions, Azure Pipelines QNN, CLA bot, Python format, doc-gen).
  • Added tools/scripts/rerun_failed_ci.sh to selectively re-run genuinely failed/cancelled GitHub Actions runs for a PR head SHA while avoiding duplicate in-flight reruns.
  • Linked the new skill from AGENTS.md.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
.agents/skills/ort-ci/SKILL.md New CI triage/re-run/unblock playbook for PR checks (GHA + Azure Pipelines QNN + special checks).
tools/scripts/rerun_failed_ci.sh Helper script to re-run failed/cancelled GitHub Actions runs for a PR head SHA, with duplicate-run avoidance.
AGENTS.md Adds a CI section pointing contributors/agents to /ort-ci.

Comment on lines +75 to +79
def active: ["queued","in_progress","requested","pending","waiting"];
def needs_rerun: ["failure","cancelled","timed_out","startup_failure","action_required","stale"];
group_by(.workflowName)[]
| { latest: (sort_by(.createdAt) | last),
has_active: (any(.[]; .status as $s | active | index($s) != null)) }
Comment on lines +205 to +207
gh pr view <number> --repo microsoft/onnxruntime --json comments \
--jq '.comments[] | select(.author.login=="azure-pipelines")
| {createdAt, body}' | tail
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants