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
docs(skill): prefer server-side fixes over client band-aids in /bugs
Adds an explicit root-cause-location check to Step 2: when the symptom
surfaces in the CLI/MCP but the clean fix is server-side (API contract,
error-body shape, auth, pricing, etc.), move the bug to run402-private
rather than patching the client. Client band-aids ossify bad server
contracts and force every consumer to reimplement the workaround.
Introduces a wrong-repo bucket in the categorization table, a Step 3
section with the exact gh issue create / close commands for moving bugs
across repos, and a new row in the Step 5 report.
Motivated by the v1.35.1 triage of GH-35 (image endpoint returning a
bare 402) — the CLI could have added a hardcoded hint, but that would
have hidden the real server-side gap and only helped one of three
clients.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: .claude/skills/bugs/SKILL.md
+26-3Lines changed: 26 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -52,25 +52,43 @@ For each bug:
52
52
-`cli/lib/` - CLI command modules (`*.mjs`)
53
53
-`openclaw/scripts/` - OpenClaw skill shims (`*.mjs`, usually re-export from `cli/lib/`)
54
54
3. Check git log to see if the relevant code has already been changed
55
-
4. Categorize into exactly one bucket:
55
+
4. **Ask: where does the root cause OPTIMALLY live?** Not "where *can* I patch it" — where does the fix belong architecturally. This repo (`run402-public`) is a thin client over a server API. The server lives in `~/Developer/run402-private` (GitHub: `kychee-com/run402-private`). If the symptom surfaces in the CLI/MCP but the clean fix is server-side (API contract, error-body shape, auth model, pricing logic, rate limits, payment flow, etc.), the bug belongs in the private repo. **Do NOT patch the client to compensate for a non-optimal server response, even if you can.** Client-side band-aids ossify bad server contracts — every consumer (CLI, MCP, OpenClaw, third-party integrations) then has to reimplement the same workaround. Example from v1.35.1 triage: the image endpoint returned a bare 402 with no error body. The CLI *could* have added a hardcoded "check your allowance" hint on empty 402s, but that would hide the real issue (server not returning `message`/`hint`/`accepts`) and only patch one of the three consumers. That bug was moved to the private repo so the server can be fixed once for all clients.
56
+
5. Categorize into exactly one bucket:
56
57
57
58
| Category | Criteria | Action |
58
59
|----------|----------|--------|
59
60
|`already-fixed`| Code already changed, or a release was published that contains the fix | Close |
60
61
|`not-a-bug`| Expected behavior, environment issue, or user error | Close with explanation |
62
+
|`wrong-repo`| Symptom is here but root cause OPTIMALLY belongs in `run402-private` (server API, backend logic, infra) | Move to private repo, close here with pointer |
61
63
|`needs-spec-change`| "Bug" is actually missing functionality or a design decision | Flag as feature request - do NOT fix |
62
-
|`fixable`| Real code bug with a clear fix | Spawn fix agent |
64
+
|`fixable`| Real code bug with a clear client-side fix (the root cause genuinely lives in this repo)| Spawn fix agent |
63
65
64
66
Print a summary table as you go so progress is visible.
65
67
66
-
## Step 3: Close resolved bugs and flag feature requests
68
+
## Step 3: Close resolved bugs, move wrong-repo bugs, flag feature requests
67
69
68
70
### Already-fixed / not-a-bug
69
71
70
72
```
71
73
gh issue close <NUMBER> --repo kychee-com/run402 --comment "<one-line explanation>"
72
74
```
73
75
76
+
### Wrong-repo (server-side root cause)
77
+
78
+
Create a new issue in the private repo with the full reproduction, then close the public issue with a pointer:
79
+
80
+
```
81
+
gh issue create --repo kychee-com/run402-private --title "<original title>" --body "Moved from kychee-com/run402#<NUMBER> — root cause is server-side (<one-line why>).
82
+
83
+
<original body>
84
+
85
+
## Where to fix
86
+
<one or two sentences on which server module / endpoint owns the fix, and what the corrected behavior should look like>"
87
+
gh issue close <NUMBER> --repo kychee-com/run402 --comment "Moved to private repo for server-side fix: kychee-com/run402-private#<N>. <one-line on why the client-side workaround is not the right layer>"
88
+
```
89
+
90
+
Do NOT also ship a client-side band-aid unless the user explicitly asks for one. Move the bug and move on.
91
+
74
92
### Needs-spec-change
75
93
76
94
Add label and comment, do NOT close:
@@ -129,6 +147,7 @@ After all agents complete (or if there were no fixable bugs), present the full r
129
147
- Total: N open GitHub issues
130
148
- Closed (already-fixed): N
131
149
- Closed (not-a-bug): N
150
+
- Moved to private repo (server-side root cause): N
132
151
- Feature requests (flagged): N
133
152
- Fixes ready: N
134
153
- Fix failures: N
@@ -141,6 +160,10 @@ After all agents complete (or if there were no fixable bugs), present the full r
0 commit comments