{"slug": "i-asked-claude-what-it-was-missing-and-it-told-me-what-was-broken", "title": "I asked Claude what it was missing and it told me what was broken", "summary": "A developer ran a prompt in Claude Code asking which tools the agent was missing, and the model instead returned a prioritized audit of the developer's broken configuration, flagging a dead MCP server, a CLAUDE.md rule instructing Claude to use Grep and Glob tools that don't exist in the session, a three-year-old pyright powering the language server, nine Python installs, and a session-journalling hook that had been silently failing since roughly May due to an exhausted OpenAI account. The developer fixed the items one at a time with Claude investigating and proposing each change, and noted that a deny rule in their own settings blocked Claude's attempt to rm -rf an old Ruby version manager folder, after which it moved files to the macOS Trash instead.", "body_md": "I read [Stéphane Derosiaux’s post about asking Claude Code which tools it wished it had](https://sderosiaux.substack.com/p/claude-code-told-me-what-tools-it), and it’s a sweet idea - instead of guessing what would make Claude more useful on your machine, you ask it, and it goes off and looks. He got back a list of command-line tools (`semgrep`, `fd`, `git-delta` and friends) plus a couple of suggestions I liked even more, like keeping your machine setup in version control and asking Claude which of your instructions it keeps forgetting.\n\nSo obviously I had to try it, and I typed his prompt into Claude Code more or less straight away:\n\nwhat tools are you missing to be effective on my machine? analyse what’s installed, what’s missing, what’s broken, what’s redundant. Prioritise by impact on your ability to help me. Make no changes, just report\n\nI was expecting a shopping list. What I got was an embarrassingly long explanation of how much of a mess my setup was, and almost none of it was about missing tools at all.\n\n## The tools were fine, the config was not\n\nClaude split the work across two cheaper subagents, one looking at the command-line tooling and one looking at the Claude Code configuration itself, and then ranked everything into four priorities - things that block it or carry risk, things that cost time on every task, missing tools, and general cleanup.\n\nPriority one opened with an MCP server I’d stopped using, still sitting in my config and failing to connect every time. Then there was the bit that surprised me - in [my last post](https://theotherjenai.substack.com/p/four-ways-i-make-my-claude-budget) I told recommended pasting a rule into your `CLAUDE.md` that says to search with the Grep and Glob tools instead of shelling out to `grep` and `find`. Claude pointed out that, in my sessions at least, those tools don’t exist. So it had been reading an instruction to use tools it didn’t have, every session, and quietly doing its own thing instead. (I’ve changed the rule to use `rg` with capped output, which is what it was doing anyway.)\n\nThe rest of the list was less dramatic but more of it. My permissions were too loose in some places, allowing things I’d never want it to do without asking, and too tight in others, so it had to ask before running completely harmless read-only commands. `pyright` was about three years old and was the thing powering Claude’s language server (I always use these tools in the venv of a repo for actual work, so I never noticed). I had four different Pythons on `PATH`, plus five more in `pyenv`, plus `~/.local/bin` on there about four times, one of which was a literal `~` that never expands. A plugin I’d used once in thirty days was injecting a hook into every session. And a session journalling hook I’d built had been failing on every single session since roughly May because the OpenAI account behind it had run out of credit and I hadn’t noticed because it failed quietly.\n\n## Fixing it, one thing at a time\n\nI didn’t want Claude loose on all of this at once, so we went through it one item at a time - it investigated, proposed a fix, waited for me to say yes, made the change, checked it, and ticked it off in the report. That took most of a morning, and I’ll be honest, at one point I typed “removing all this stuff scares me lol”, because it really does when you’ve got no idea which of the nine Pythons is quietly holding something up.\n\nTwo things from that morning are worth passing on. The first is that my own guard rails worked on me - Claude tried to `rm -rf` an old Ruby version manager folder and a deny rule in my own settings stopped it, so I had to do that one myself. After that it moved things to the macOS Trash instead of deleting them, which I’d recommend as a default for any cleanup like this. The second is that it did break something. It removed the Homebrew copy of `pnpm` because it thought my Node version manager was handling it, except the version manager was passing straight through to the Homebrew copy, so `pnpm` stopped working entirely. It noticed and reinstalled it immediately, but the reinstall jumped two major versions, so there’s a small project of mine that will probably break the next time I open it. Checking what depends on something before removing it is now an explicit rule.\n\nAnd some things I said no to. Claude really wanted me to consolidate the Pythons, and I really didn’t want to, because I don’t know what half of them are for and I’m not finding out on a Friday. That’s a fine answer, but the next audit would just flag them again, so the report now has a “decided, keep” section and future runs list those under “Accepted as is” instead of nagging me about them forever.\n\n## The best idea in the original post\n\nThe suggestion I liked most from Stéphane’s post was asking Claude to look for constraints it keeps forgetting, so I pushed that a bit further and had it scan my last 60 days of sessions (272 of them) for the places where I’d corrected it - “no”, “don’t”, “I said”, “stop”, that kind of thing - and group them by the rule I was restating.\n\nThe top one, by a distance, was some version of “when I say plan, I mean don’t touch anything”. Roughly 37 sessions of me typing “plan”, “investigate” or “work out how” and Claude taking that as permission to start editing files. The rule was already in my `CLAUDE.md`, it just only listed a couple of trigger words, so every time I phrased it differently it didn’t count. Second was me telling it to hand implementation to cheaper agents (about 31 sessions), and third was asking it to explain things in order and define terms instead of assuming I remembered what we’d done three hours ago (about 18, and yes I do have the memory of a goldfish). Those counts are rough and probably undercounts, but it’s a weirdly confronting thing to see, a ranked list of the things you’ve said over and over to something that was never going to remember them unless you wrote them down properly.\n\nThis paid for itself in my very next session when I purposely didn’t tell it to plan and use subagents, and it actually did, woop!\n\n## Making it repeatable\n\nThe obvious problem with all this is that my setup will drift again, because I’ll install things, forget about them, add hooks and never look at them again. So I turned the audit into a skill called `claudit` that I can rerun whenever. It reads the last report first, runs the same two scans, and then sorts every finding into Fixed, Still open, New, or Accepted as is, so the second run is a diff rather than another wall of findings. It never changes anything itself, and it saves each report with the date in the filename so I can see how things move over time.\n\nWhen I wrote [my last post](LINK) I said I could stick my agents and skills in a repo if anyone wanted them, so I did - `claudit` [is in my claude-code-skills repo](https://github.com/jmackown/claude-code-skills) along with the agents from that post. If you’d rather not install a skill and just want to see what happens, this is the one-off prompt I ended up with, which is more thorough than my original one-liner:\n\n```\nAudit my machine to find what you need to be more effective here.\nReport what is installed, missing, broken and redundant, ranked by its impact on\nyour ability to help me. Make no changes: no installs, no edits, no auth flows, no\ngit writes. Never print secrets or tokens. If you find one in plain text, report\nwhere it is and redact the value.\n\nRun two read-only subagents in parallel:\n\n1. Command-line tooling\n   - Core: git, gh (and auth status), rg, fd, fzf, jq, yq, git-delta, ast-grep,\n     semgrep, shellcheck, watchexec, sqlite3/psql/duckdb, docker (daemon up?).\n   - Languages: every python3/node on PATH and which wins, version managers\n     (uv, pyenv, volta, nvm, fnm), linters and type checkers with versions\n     (flag anything over a year old).\n   - Language servers that your LSP tool can use (pyright/basedpyright,\n     typescript-language-server, gopls, and so on).\n   - Cloud CLIs I use, and whether they are logged in.\n   - Package manager health (e.g. `brew doctor`, outdated count).\n   - PATH: duplicates, missing directories, shadowed binaries, broken lines in\n     shell rc files.\n   - Redundancy: the same tool installed by several package managers.\n\n2. Claude Code configuration\n   - MCP servers (user, project and connector): which connect, which fail, and why.\n     Check that stdio commands exist. Flag credentials written into config files.\n   - Hooks: what runs on which event, whether the scripts exist, and per-tool-call\n     overhead.\n   - Permissions: rules that are too broad (e.g. allow-all on gh), deny rules that\n     are easy to bypass, and read-only commands or MCP tools that prompt for no\n     good reason.\n   - Plugins, skills, agents and commands: duplicates, overlaps, and references to\n     files, paths or commands that don't exist.\n   - CLAUDE.md files and memory: instructions that name tools you don't have,\n     rules that contradict each other or contradict a skill, and how much they\n     cost in context.\n   - Settings env vars that conflict.\n\nThen give me one report with these sections:\n- Priority 1: blocks you or carries risk\n- Priority 2: costs time on every task\n- Priority 3: missing tools, as a table of tool and why it helps you\n- Priority 4: redundancy and cleanup\n- What works\n\nBe concrete: file paths, line numbers, versions, and exact error text.\nRecommend; don't list every option.\n```\n\nIt’s read-only, so the worst that can happen is you find out something you’d rather not know. Which, given that mine started with instructions for tools that don’t exist and ended with nine Pythons I’m still too scared to touch, is very much the point.", "url": "https://wpnews.pro/news/i-asked-claude-what-it-was-missing-and-it-told-me-what-was-broken", "canonical_source": "https://theotherjenai.substack.com/p/i-asked-claude-what-it-was-missing", "published_at": "2026-10-09 12:51:54+00:00", "updated_at": "2026-10-09 13:21:52.480666+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "developer-tools", "mlops"], "entities": ["Claude Code", "Anthropic", "Stéphane Derosiaux", "OpenAI", "pyright", "Homebrew", "pnpm", "pyenv"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/i-asked-claude-what-it-was-missing-and-it-told-me-what-was-broken", "markdown": "https://wpnews.pro/news/i-asked-claude-what-it-was-missing-and-it-told-me-what-was-broken.md", "text": "https://wpnews.pro/news/i-asked-claude-what-it-was-missing-and-it-told-me-what-was-broken.txt", "jsonld": "https://wpnews.pro/news/i-asked-claude-what-it-was-missing-and-it-told-me-what-was-broken.jsonld"}}