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: .claude/skills/cursor-bugbot/SKILL.md
+40-2Lines changed: 40 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,8 @@ Drive the Cursor Bugbot fix-and-respond loop end-to-end. This is the canonical f
13
13
14
14
-`/cursor-bugbot <PR#>` — full audit-and-fix on one PR (default).
15
15
-`/cursor-bugbot check <PR#>` — list Bugbot findings, classify them, but don't fix or reply.
16
-
-`/cursor-bugbot reply <comment-id> <state>` — single-comment reply where `<state>` is `fixed`, `false-positive`, or `wont-fix`.
16
+
-`/cursor-bugbot reply <comment-id> <state>` — single-comment reply where `<state>` is `fixed`, `false-positive`, or `wont-fix`. Auto-resolves the thread for `fixed` / `false-positive`; leaves open for `wont-fix`.
17
+
-`/cursor-bugbot resolve <PR#>` — sweep all Bugbot threads on the PR that have author replies but are still open; resolve them. Useful for closing out a PR before merge.
17
18
-`/cursor-bugbot scope <PR#>` — re-evaluate the PR title and body against the actual commits and rewrite them when out of step.
18
19
19
20
## Why a skill
@@ -76,7 +77,7 @@ For each `real` finding:
76
77
4. Stage + commit the fix with a message that names the finding (e.g., `fix(hooks): address Cursor Bugbot finding on scanSocketApiKeys lineNumber`).
77
78
5. Note the new commit SHA — the reply needs it.
78
79
79
-
### Phase 4 — Reply on each thread
80
+
### Phase 4 — Reply + resolve on each thread
80
81
81
82
**Critical**: replies go on the inline review-comment thread, not as a detached PR comment. The CLI form:
82
83
@@ -85,6 +86,41 @@ gh api "repos/{owner}/{repo}/pulls/<PR#>/comments/<comment-id>/replies" \
85
86
-X POST -f body="…"
86
87
```
87
88
89
+
After replying, **resolve the thread** so it's marked done in the PR review UI (the reply alone doesn't auto-resolve). Resolution is a GraphQL mutation; first resolve the thread node ID from the comment's databaseId, then resolve:
90
+
91
+
```bash
92
+
# Step 1: get the thread node ID (PRRT_…) for a given comment databaseId.
-**`real`, fixed**: resolve after the fix commit lands and the reply is posted.
120
+
-**`already-fixed`**: resolve immediately after the reply (the fix already exists).
121
+
-**`false-positive`**: resolve immediately after the reply *unless* the verdict is contested by the reviewer.
122
+
-**`wont-fix`**: do NOT resolve. The reviewer decides; leave it open as an open question.
123
+
88
124
Reply templates:
89
125
90
126
-**Real, fixed**: `Fixed in <commit-sha>. <one-sentence what changed>. <propagation note if any>.`
@@ -145,13 +181,15 @@ Bugbot will re-review the new HEAD automatically. New findings → loop back to
145
181
146
182
- Every Bugbot finding on the PR has a reply on its inline thread.
147
183
- Every `real` finding has a corresponding fix commit on the PR branch.
184
+
- Every reply that closes the matter (fixed / already-fixed / false-positive) is followed by `resolveReviewThread`. `wont-fix` threads stay open for reviewer judgment.
148
185
- The PR title and body match the actual commits.
149
186
- The PR branch is pushed.
150
187
151
188
## Anti-patterns
152
189
153
190
- ❌ Replying via `gh pr comment` (detached). Doesn't thread, doesn't notify the reviewer.
154
191
- ❌ Force-rewriting a Bugbot's finding by editing the comment via `--method PATCH`. The bot may re-post.
192
+
- ❌ Resolving a thread without a written reply. Future you (or the reviewer) won't know what happened. Reply first, resolve second.
155
193
- ❌ Closing Bugbot threads via the GitHub UI without a written reply. Future you (or the reviewer) won't know what happened.
156
194
- ❌ Fixing a Bugbot finding by deleting the offending code without understanding *why* the code was there. Bugbot doesn't know about your domain; the human reviewer does.
157
195
- ❌ Treating "Bugbot Autofix determined this is a false positive" as a definitive verdict without checking. The autofix bot is right ~95% of the time but verifying takes 10 seconds.
0 commit comments