iterate-pr

Iterate on a PR until CI passes. Use when you need to fix CI failures, address review feedback, or continuously push fixes until all checks are green. Automates the feedback-fix-push-wait cycle.

Author

Install

Hot:0

Download and extract to your skills directory

Copy command and send to OpenClaw for auto-install:

Download and install this skill https://openskills.cc/api/download?slug=sickn33-skills-iterate-pr&locale=en&source=copy

iterate-pr - PR Automatic Iteration Skill

Skill Overview


iterate-pr is a GitHub PR automation skill that continuously iterates on the current branch until all CI checks pass and all code review feedback has been handled. It automates the full loop: collecting feedback, fixing code, pushing commits, and waiting for checks.

Use Cases

1. Fixing CI Check Failures


When a code push triggers failures in GitHub Actions or other CI systems, iterate-pr can automatically identify the failure causes, retrieve detailed logs, and guide you through the fix workflow. It supports common code quality tools such as Sentry, Codecov, Cursor, Bugbot, Seer, and more.

2. Handling Code Review Feedback


When faced with a large number of manual review comments or bot replies, this skill can systematically collect all feedback (including inline comments and review comments in the discussion thread), verify whether each issue is valid, and guide you to make targeted code changes.

3. Continuous Iteration Until Merge


In scenarios where you need multiple rounds of pushes to pass all quality gates, iterate-pr repeatedly runs the “check-fix-push-wait” loop until all checks are green and there are no unhandled review comments, ensuring the PR meets the merge standard.

Core Features

1. Smart CI Status Monitoring


Using the gh pr checks command to monitor all PR check statuses in real time, the skill intelligently identifies five states: pass, fail, pending, skipping, and cancel. It also provides guidance specifically for pending checks (e.g., Sentry, Codecov) to avoid redundant work.

2. Comprehensive Feedback Collection


Integrates multiple GitHub CLI API endpoints to collect review status, inline code comments, and discussion comments in one go. It can differentiate feedback from automation tools versus human review comments, and prioritizes issues that genuinely need fixing.

3. Validation and Fix Mechanism


Before addressing any feedback, it requires reviewing the relevant code context to verify that the issue truly exists and to check whether it has already been fixed in later commits. Invalid feedback can be skipped, ensuring code changes are made only for real issues.

FAQs

What prerequisites does iterate-pr require?


To use this skill, you need to install and configure the GitHub CLI (gh) tool and complete authentication (via gh auth login). Also, the current branch must already have an associated Pull Request; otherwise, the skill will indicate that it cannot continue.

Will it stop after retrying the same failure multiple times?


Yes. If the same failure still exists after attempting fixes 3 times, the skill will recommend stopping the automatic iteration. This may be due to unstable tests (flaky tests) or a deeper issue that requires human judgment, so you should seek help rather than continuing to retry automatically.

How should I handle pending statuses for Codecov and Sentry checks?


For automated checks like Codecov, Sentry, Cursor, Bugbot, Seer—when they are in a pending state—you should wait for the checks to complete. These tools often post additional feedback comments after the checks finish, and handling them too early can lead to duplicated work. The skill recommends using gh pr checks --watch --interval 30 to wait for all checks to complete.