Files
AgentHub/plugins/agenthub/commands/agenthub-doctor.md
T
nntrivi2001 6f9b9c36b8 feat(doctor): catch half-written installs, not just absent ones
Runtime deps checked that node_modules existed, which is true of the broken
tree too — it now verifies every declared dependency landed. Dashboard UI
quotes the last client-build.log error instead of repeating the build command,
and npm and free disk get their own rows: both truncate installs silently.
2026-09-08 15:44:41 +07:00

38 lines
1.8 KiB
Markdown

---
description: Diagnose a plugin-installed AgentHub — Node, npm, disk, bootstrap, server, hooks, CLI, UI build
---
Run the diagnostic and report what it found. Do not fix anything unless the user
asks.
```bash
node "${CLAUDE_PLUGIN_ROOT}/scripts/plugin-doctor.js"
```
Print the output verbatim, then add at most three lines of guidance based on the
`FAIL` and `WARN` rows:
- `FAIL Node` → the installed Node is too old for `node:sqlite`; the server
cannot start until Node is upgraded.
- `FAIL Hooks` → duplicate hook entries double every token and cost figure.
Starting a new Claude Code session removes them automatically (the bootstrap
backs the file up as `settings.json.agenthub-bak` first).
- `FAIL Server` → run `/agenthub-update`, then check
`~/.claude/agenthub/runtime/bootstrap.log` and `server.log`.
- `FAIL Runtime deps` → the install is incomplete, not merely absent. Delete
`~/.claude/agenthub/runtime/node_modules` before running `/agenthub-update`;
reinstalling over the broken tree is what let it survive.
- `FAIL npm` or `FAIL Disk` → nothing else in the report can be trusted until
these are fixed; both silently truncate installs.
- `WARN agenthub CLI` → print the exact `export PATH=...` line from the output.
- `WARN Skill plugins` → the pipelines name slash commands no installed plugin
provides. The dashboard is unaffected; `/agenthub:ship-feature(-lane)` is what
stops partway. The bootstrap normally installs these itself, so this row also
means that attempt has not run or did not succeed — say `/agenthub-update` retries
it, and print the `claude plugin install …` line from the output as the manual
route.
- `WARN Dashboard UI` → run `/agenthub-open` to build the bundle. When the row
quotes a build error, report that error — it is the actual problem.
No preamble, no summary of things that passed.