heal-pr

Diagnoses and fixes failing CI, missing changesets, and sanity issues on Blade pull requests.

649|197|Updated Jan 28, 2020
One-click install
npx skills add https://github.com/razorpay/blade --skill heal-pr
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: heal-pr
Source: https://github.com/razorpay/blade/tree/main/.agents/skills/heal-pr
Command: npx skills add https://github.com/razorpay/blade --skill heal-pr

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Pull requests in the Blade repository often fail CI checks, miss required changesets, or contain other sanity issues that block merging and require manual debugging effort.

Core Features & Use Cases

  • Automated Diagnosis: Spawns a pr-sanity-critique subagent to identify all issues on a given PR.
  • Auto-Fix Workflow: Checks out the PR branch, investigates failing CI jobs with the GitHub CLI, fixes root causes, and creates changesets when source code changes warrant them.
  • Escalation Handling: Posts a structured PR comment listing issues that cannot be auto-fixed, such as infrastructure outages or flaky environments.
  • Use Case: A contributor's PR fails CI due to a lint error and a missing changeset; the skill checks out the branch, fixes the lint issue, adds the changeset, and pushes the commit automatically.

Quick Start

Heal PR number 1234 in the razorpay/blade repository by diagnosing and fixing its failing checks.

Frequently Asked Questions about heal-pr

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automatically fix a failing CI check on a GitHub pull request?

Provide the PR number, and the skill checks out the branch with gh pr checkout, inspects the failing job via gh run view, fixes the root cause in code, tests, or config, then commits and pushes the fix.

How to add a missing changeset to a Blade PR?

The skill creates a .changeset file with the appropriate bump type when the PR contains source code changes. It skips changeset creation for test-only or documentation-only changes.

Does the PR healer work on repositories other than razorpay/blade?

No, the workflow is hardcoded to the razorpay/blade repository, including its changeset conventions and the pr-sanity-critique subagent. Other repositories would require adapting the instructions.

What happens when a CI failure cannot be auto-fixed?

The skill posts a comment on the PR listing the non-fixable issues, such as infrastructure outages or flaky environments, and marks them as requiring manual intervention instead of pushing a fix.

When should changesets be skipped for a pull request?

Skip changesets when the PR only modifies test files like *.test.ts or *.spec.tsx, or contains documentation-only changes such as Markdown files or docs/ directory updates.