You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/workflows/claude-fix-issue.yml
+34-9Lines changed: 34 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -137,16 +137,33 @@ jobs:
137
137
138
138
## Step 4: Write a summary
139
139
140
-
After completing the fix, write two files:
140
+
After completing the fix, write three files:
141
141
142
-
1. /tmp/commit-message.txt - A concise commit message (first line: short summary under 72 chars, then a blank line, then a few bullet points describing key changes). Example:
143
-
Fix array_key_exists narrowing for template types
142
+
1. /tmp/pr-title.txt - A single-line PR title that describes **what the change does**, not what it fixes. Write it as a precise, technical description of the actual code change you made.
144
143
145
-
- Added handling for TemplateType in TypeSpecifier when processing array_key_exists
146
-
- New regression test in tests/PHPStan/Analyser/nsrt/bug-12345.php
147
-
- The root cause was that TypeSpecifier did not unwrap template bounds before narrowing
144
+
Style rules:
145
+
- Use imperative voice describing the action taken in the source code (e.g. "Report ...", "Do not ...", "Use ... instead of ...", "Narrow ... when ...")
146
+
- Be specific about classes, methods, or PHP constructs involved — use backticks for code identifiers (e.g. `??`, `IntersectionTypeMethodReflection`, `TemplateType`)
147
+
- Describe the mechanism of the fix, not the symptom or the issue
148
+
- Do NOT start with "Fix", "Bug:", "Issue:", or reference issue numbers
149
+
- Do NOT just restate the issue title
150
+
- Keep it under ~120 characters but do not sacrifice precision for brevity
148
151
149
-
2. /tmp/pr-description.md - A pull request description in this format:
152
+
Good examples (study these carefully — match this style):
153
+
- "Report promoted readonly or hooked non-nullable properties on the left side of \`??\`"
154
+
- "Do not subtract TemplateType from TemplateType"
155
+
- "IntersectionTypeMethodReflection: select method with most parameters instead of first one to query information"
156
+
- "Narrow array key type after \`array_key_exists\` on intersection types"
157
+
- "Preserve list type when assigning to existing offset"
158
+
159
+
Bad examples (do NOT write titles like these):
160
+
- "Fix phpstan/phpstan#14459: Null coalescing operator does not report redundant left operand when always defined" (restates issue, mentions issue number)
161
+
- "Fix bug with generics" (vague, not technical)
162
+
- "Two unbounded generics in conditional return are assumed to be always the same" (describes symptom, not fix)
163
+
164
+
2. /tmp/commit-message.txt - A concise commit message. The first line MUST be identical to the contents of /tmp/pr-title.txt. Then a blank line, then a few bullet points describing the key changes (what code was changed and why, in technical terms).
165
+
166
+
3. /tmp/pr-description.md - A pull request description in this format:
150
167
## Summary
151
168
Brief description of what the issue was about and what the fix does.
152
169
@@ -162,15 +179,23 @@ jobs:
162
179
163
180
Fixes phpstan/phpstan#${{ inputs.issue-number }}
164
181
165
-
These files are critical - they will be used for the commit message and PR description.
182
+
These files are critical - they will be used for the PR title, commit message, and PR description. The PR title and commit subject line must describe **what the change does**, not what it fixes.
0 commit comments