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
-**Checking contribution guidelines?** → MUST load `reference/contribution-types.md` first
18
18
-**Verifying code conventions?** → MUST load `reference/conventions.md` first
19
-
-**Writing a review comment?** → MUST load `reference/comment-guidelines.md` first
19
+
-**Writing a review comment?** → MUST load `reference/comment-guidelines.md` first (includes bug reporting format)
20
20
21
21
**Minimum requirement:** Load at least the relevant reference file(s) before completing the review.
22
22
@@ -72,6 +72,7 @@ For each previously raised issue or remark, determine whether it has been addres
72
72
- If **all prior issues are resolved** — acknowledge the progress in the new review comment and focus only on any remaining or new issues.
73
73
- If **some prior issues remain unresolved** — carry them forward into the new review. Do not re-explain them in detail; reference them briefly (e.g., *"The changeset message format is still incorrect"*).
74
74
- If **this is the first review** (no prior bot comments) — skip this step.
75
+
- If **there is a prior review and nothing has changed** — no new issues, no resolved issues, no new concerns — **do not post a new comment**. Stop here.
75
76
76
77
> **CRITICAL:** Do not repeat the full explanation for issues already raised in a previous comment. Keep follow-up reviews concise — assume the contributor has read the prior feedback.
77
78
@@ -109,7 +110,7 @@ If the PR has more than 500 changed lines (additions + deletions) **or** more th
109
110
```bash
110
111
bash scripts/get_linked_issues.sh <pr_number>
111
112
```
112
-
Check whether any linked issue carries a `helpwanted` label. If not, apply `requires-more` and comment explaining that large contributions should be scoped and pre-approved via an issue first (reference `CONTRIBUTING.md`).
113
+
Check whether any linked issue carries a `help-wanted` label. If not, apply `requires-more` and comment explaining that large contributions should be scoped and pre-approved via an issue first (reference `CONTRIBUTING.md`).
113
114
114
115
**4b. Security scan:**
115
116
@@ -150,7 +151,27 @@ For mixed PRs, apply all relevant types.
150
151
151
152
Load `reference/conventions.md` and verify the changed files follow Medusa's conventions. Focus on the areas most relevant to the contribution type (e.g., API conventions for code changes, MDX structure for docs changes).
152
153
153
-
### Step 8 — Contextual Assessment
154
+
### Step 8 — Bug Detection
155
+
156
+
Read the actual code diff carefully and look for potential bugs. Focus on:
> **CRITICAL:** Distinguish between confirmed bugs (clear logic/runtime errors) and code smell / style issues. Only flag something as a bug if it would plausibly cause incorrect behaviour at runtime.
173
+
174
+
### Step 9 — Contextual Assessment
154
175
155
176
Before writing the review, assess whether the changes make sense in the broader context of the PR. Load `reference/comment-guidelines.md` (Contextual Assessment section) for the full checklist. Key questions:
156
177
@@ -162,7 +183,7 @@ Before writing the review, assess whether the changes make sense in the broader
162
183
163
184
Note any concerns to include in the review comment.
164
185
165
-
### Step 9 — Compose and Post Review
186
+
### Step 10 — Compose and Post Review
166
187
167
188
Load `reference/comment-guidelines.md` for comment templates and tone guidance.
Copy file name to clipboardExpand all lines: .claude/skills/reviewing-prs/reference/comment-guidelines.md
+28Lines changed: 28 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -73,6 +73,34 @@ If concerns are found, include them in the review comment under a **"Concerns"**
73
73
74
74
Keep concerns concise and factual — describe the problem, not a lecture. If unsure whether something is actually a bug, phrase it as a question: *"Should `X` also handle the case where `Y` is null?"*
75
75
76
+
## Potential Bugs Section
77
+
78
+
When bugs are found in Step 8, include a **"Potential Bugs"** section in the review comment. This section is **always required** when bugs are found — for both `initial-approval` and `requires-more`.
79
+
80
+
- Confirmed bugs (will cause incorrect runtime behaviour) → add to **Required changes** and apply `requires-more`
81
+
- Uncertain / possible bugs → include under **"Potential Bugs"** as a flagged concern, even on `initial-approval`
82
+
83
+
**Format:**
84
+
85
+
```
86
+
**Potential Bugs:**
87
+
88
+
⚠️ **`path/to/file.ts`** — <one-line description of the bug>
89
+
```typescript
90
+
// the problematic snippet
91
+
```
92
+
<Explanation of why this is a problem and what could go wrong. If a fix is obvious, suggest it.>
93
+
94
+
⚠️ **`path/to/other-file.ts`** — <anotherbug>
95
+
...
96
+
```
97
+
98
+
**Rules:**
99
+
- Always quote the relevant code snippet in a fenced code block so the author knows exactly what line is flagged
100
+
- Be specific about the failure scenario — *"this will throw if `items` is empty"* not *"this looks wrong"*
101
+
- If unsure, phrase as a question: *"Should this also handle the case where X is undefined?"*
102
+
- Do not flag style issues or code smell here — only actual correctness/runtime concerns
103
+
76
104
## Security Risk Comment Template
77
105
78
106
Use when a potential (non-malicious) security risk is found. Include it as part of the review, not as a standalone comment.
0 commit comments