Check for Existing PRs Before Creating

lesson workflow active workflow/check-existing-prs.md View on GitHub

Check for Existing PRs Before Creating

Rule

Always check for existing PRs addressing the same issue before creating a new PR.

Context

When investigating an issue and planning to create a PR to fix it.

Detection

Observable signals indicating you should check first:

Pattern

Check before creating:

# Search by issue number and topic
gh pr list --state open --search "605 in:body"
gh pr list --state open --search "mcp config"

# If found: Review and coordinate
# If not found: Proceed with new PR
git checkout -b fix-issue-605
gh pr create

Outcome

Following this pattern leads to:

Time saved: Finding existing PR takes 30 seconds vs hours of duplicate work.

Related

Match Keywords

about to create PR gh pr create git checkout -b fix- gh pr list --search issue has been open for a while duplicate PR risk