Skip to content

Add pr-to-green skill and CI/conflict subagents#737

Merged
drbenvincent merged 2 commits into
mainfrom
pr-to-green
Feb 25, 2026
Merged

Add pr-to-green skill and CI/conflict subagents#737
drbenvincent merged 2 commits into
mainfrom
pr-to-green

Conversation

@drbenvincent

@drbenvincent drbenvincent commented Feb 25, 2026

Copy link
Copy Markdown
Collaborator

Summary

Adds a pr-to-green skill and two supporting Cursor subagents to streamline the maintainer workflow for getting PRs to a mergeable state.

  • pr-to-green skill (.github/skills/pr-to-green/SKILL.md): deterministic workflow for syncing a PR branch with base, resolving conflicts, fixing failing checks, pushing, and verifying remote CI. Includes early exit when PR is already green, an iteration loop for cascading failures, and explicit maintainer escalation for complex conflicts (especially .ipynb).
  • ci-failure-investigator subagent (.cursor/agents/ci-failure-investigator.md): triages noisy/multi-job CI failures into root-cause rankings and minimal fix plans. Runs on fast model to keep cost low.
  • merge-conflict-analyst subagent (.cursor/agents/merge-conflict-analyst.md): classifies conflicts by risk, auto-resolves mechanical ones, and escalates semantic/high-risk conflicts (especially notebooks and core contracts) to the maintainer with options and trade-offs.

Usage

Invoke in Cursor chat with a PR number:

Use pr-to-green for PR #724

The skill fetches PR metadata from GitHub, checks out the branch, and walks through sync/fix/push/verify. If the PR is already green it exits early. Subagents are delegated automatically when CI logs are noisy (ci-failure-investigator) or merge conflicts are non-trivial (merge-conflict-analyst).

Introduce three new docs: a CI failure investigator agent (.cursor/agents/ci-failure-investigator.md), a merge conflict analyst agent (.cursor/agents/merge-conflict-analyst.md), and a PR-to-green workflow skill (.github/skills/pr-to-green/SKILL.md). These add repository-specific triage and conflict-resolution guidance (failure-family grouping, root-cause ranking, minimal patch plans, verification commands), strict output formats, escalation rules for high-risk conflicts (notebooks, core contract changes), and CausalPy guardrails (conda command conventions, test placement, non-destructive git practices). Designed to standardize automated/manual maintainer workflows for syncing PRs and restoring CI green.
@drbenvincent drbenvincent added the agents Agent related issues specifically for use by developers label Feb 25, 2026
@read-the-docs-community

Copy link
Copy Markdown

@codecov

codecov Bot commented Feb 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.59%. Comparing base (077fbb6) to head (4770c19).
⚠️ Report is 88 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #737      +/-   ##
==========================================
- Coverage   94.62%   94.59%   -0.03%     
==========================================
  Files          45       45              
  Lines        7590     7590              
  Branches      462      462              
==========================================
- Hits         7182     7180       -2     
- Misses        248      249       +1     
- Partials      160      161       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@drbenvincent drbenvincent merged commit 7418939 into main Feb 25, 2026
14 checks passed
@drbenvincent drbenvincent deleted the pr-to-green branch February 25, 2026 19:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent related issues specifically for use by developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants