gh-squash-merge-closes-only-one-issuelisted
Install: claude install-skill wan-huiyan/agent-traffic-control
# GitHub squash-merge auto-closes only one issue per PR
## Problem
You shipped a fix PR that addresses 4 filed issues. PR title:
> `fix(dashboard): wire /actions cohort tiles + plug 4 audit P0s (closes #447, #448, #449, #450)`
PR body opens with:
> Closes #447, #448, #449, #450 — the four template/route P0s from the audit.
PR squash-merges cleanly. CI green, branch deleted. You move on.
Later: `gh issue list --state open` shows `#448`, `#449`, `#450` still OPEN. Only `#447` got auto-closed. You spend a confused minute checking whether the fix actually shipped (it did) before realising the issues never closed.
## Context / Trigger Conditions
All of:
1. PR title or body includes a comma-separated `Closes #X, #Y, #Z` (or `Fixes`, `Resolves`) reference.
2. PR was **squash-merged** (regular merge has slightly different parsing but the same gotcha applies).
3. After merge: `gh pr view N --json state` returns `MERGED`, but `gh issue view #Y` returns `OPEN` for the second-and-later issues.
4. The first issue in the comma list IS closed correctly — proves your "Closes" keyword wasn't malformed.
This is **not** about the issues' content / labels / state. The fix did ship. The auto-close parser just bound the keyword to one issue.
## Solution
### Path A — prevent (preferred, before merge)
Write one keyword per issue in the PR body. GitHub closes each:
```markdown
## Summary
Bundles four P0 fixes from the 2026-05-07 audit.
Closes #447.
Closes #448.
Closes #449.
Closes #4