iterate-pr

iterate-pr is a skill for Claude Code, Codex from canonical/charm-tech. It costs 47 tokens per session (1,878 once invoked), scanned A, a copy of iterate-pr, Apache-2.0.

A workflow for repeatedly checking a pull request, fixing CI failures, responding to review feedback, and waiting for the checks to pass. A pull request is a proposed code change, and CI is automated testing and validation.

In plain words
What is it for?
Fetching pull-request check results and failure details, retrieving review feedback, categorizing its urgency, and iterating until the required checks are green.
Why use it?
It organizes the repeated fix-and-check cycle needed before a code change can be merged.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/canonical/charm-tech/iterate-pr
Any agent
npx skills add canonical/charm-tech --skill iterate-pr
Clone the repo
git clone --depth 1 https://github.com/canonical/charm-tech

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for iterate-pr

README.md
[![agentmods](https://agentmods.dev/badge/skills/canonical/charm-tech/iterate-pr.svg)](https://agentmods.dev/skills/canonical/charm-tech/iterate-pr)
Your own site
<a href="https://agentmods.dev/skills/canonical/charm-tech/iterate-pr"><img src="https://agentmods.dev/badge/skills/canonical/charm-tech/iterate-pr.svg" alt="Measured on agentmods" height="20"></a>
Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,878 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 88% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00047 $0.01878
Opus 5 $0.00023 $0.00939
Sonnet 5 $0.00009 $0.00376
Haiku 4.5 $0.00005 $0.00188

Measured 5d ago against content hash e1323d71b181, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

iterate-pr scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/fetch_pr_checks.py, scripts/fetch_pr_feedback.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

88% identical to iterate-pr — 30 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

skills/engineering/iterate-pr/SKILL.md · 184 lines

How it starts

The opening of the file, as written. The whole thing — 184 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Iterate on PR Until CI Passes

Continuously iterate on the current branch until all CI checks pass and review feedback is addressed.

Requires: GitHub CLI (gh) authenticated.

Important: Run all scripts from the repository root (where .git lives), not from the skill directory. Use the full path to each script — substitute <skill-dir> in the commands below with this skill's actual install path.

Bundled Scripts

scripts/fetch_pr_checks.py

Fetches CI check status and extracts failure snippets from logs.

uv run <skill-dir>/scripts/fetch_pr_checks.py [--pr NUMBER]

Returns JSON:

{
  "pr": {"number": 123, "branch": "feat/foo"},
  "summary": {"total": 5, "passed": 3, "failed": 2, "pending": 0},
  "checks": [
    {"name": "tests", "status": "fail", "log_snippet": "...", "run_id": 123},
    {"name": "lint", "status": "pass"}
  ]
}

scripts/fetch_pr_feedback.py

Fetches and categorizes PR review feedback using the LOGAF scale.

uv run <skill-dir>/scripts/fetch_pr_feedback.py [--pr NUMBER]

Returns JSON with feedback categorized as:

  • high - Must address before merge (h:, blocker, changes requested)
  • medium - Should address (m:, standard feedback)
  • low - Optional (l:, nit, style, suggestion)
  • bot - Informational automated comments (Codecov, Dependabot, etc.)
  • resolved - Already resolved threads

Review bot feedback (from Sentry, Warden, Cursor, Bugbot, CodeQL, etc.) appears in high/medium/low with review_bot: true — it is NOT placed in the bot bucket.

Each feedback item may also include:

  • thread_id - GraphQL node ID for inline review comments (used for replies)

Workflow

1. Identify PR

gh pr view --json number,url,headRefName

Stop if no PR exists for the current branch.

2. Gather Review Feedback

Run <skill-dir>/scripts/fetch_pr_feedback.py to get categorized feedback already posted on the PR.

Read the full file on GitHub · 184 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 184 lines · 47 tokens per session scan A e1323d71b181

Subscribe to this mod's changes

iterate-pr is a skill published in the GitHub repository canonical/charm-tech (2 stars, last pushed 19d ago), licensed Apache-2.0. It adds 47 tokens to every session and 1,878 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 88% identical to iterate-pr, differing in 30 lines, and is treated as a copy.

Related

Other skills, from other repositories

import-prom-rule

Bulk import of a Prometheus alert rule YAML file (create a whole set of rules at once). Dedicated to handling a remote URL or local YAML text, automatically parsing the three formats groups / a plain rules array / a single rule. ⚠️ Do not use this skill for single-rule creation — when the user describes a single alert…

ccfos/nightingale · 125 tokens

chinese-git-workflow

国内 Git 平台配置参考——Gitee、Coding.net、极狐 GitLab、CNB 的 SSH/HTTPS/凭据/CI 接入差异与镜像同步配置。仅在用户显式 /chinese-git-workflow 时调用,不要根据上下文自动触发。.

jnMetaCode/superpowers-zh · 69 tokens

azsdk-common-pipeline-analysis

Analyze Azure SDK CI/CD pipeline failures into a structured diagnosis, and define the required output format. Load this skill before calling azsdkanalyzepipeline, which returns raw failure data that this skill interprets and formats. USE FOR: "pipeline failed", "build failure", "CI check failing", "tests failing in…

Azure/azure-sdk-for-net · 192 tokens

configure-env-variables

Configures environment variables for Power Pages site settings to support ALM across environments. Creates environment variable definitions in Dataverse, guides the user through linking site settings to those variables via the Power Pages Management app, adds the variables to the solution, and generates a…

microsoft/power-platform-skills · 119 tokens

desktop-principles

Desktop-specific UX principles - hover states, pointer precision, keyboard shortcuts, multi-window, focus management. Covers macOS, Windows, Linux, web desktop.

Jwuthri/Tracely-ai · 36 tokens

atmos-cache

Atmos caching: CI cache configuration and commands, GitHub Actions cache integration, Terraform registry cache mirror/list/prune/stats/trust, and cache modernization guidance.

cloudposse/atmos · 35 tokens