This is a systematic approach to tracking down stubborn bugs, originally from Matt Pocock's collection and translated to Chinese. The core philosophy is simple: before you do anything else, build a tight feedback loop that fails on your specific bug. Everything else (bisection, hypothesis testing, instrumentation) only works if you have that pass/fail signal first. The skill walks you through constructing that loop with various techniques, then moves through standard debugging phases. It's disciplined and opinionated about not skipping steps unless you have a good reason. If you're the type who wastes hours staring at code without a reproducible test case, this will force better habits.

skills.sh installs
4.4K
GitHub stars
5.7K
last updated
Aug 21, 2026

Install

$ npx -y skills add vinvcn/mattpocock-skills-zh-cn --skill diagnosing-bugs --agent claude-code

Installs into .claude/skills of the current project.

Files

诊断缺陷

面向棘手 bugs 的纪律。只有在明确说明理由时才跳过阶段。

探索 codebase 时,先读取 GLOSSARY.md(如果存在),建立相关 modules 的清晰 mental model,并检查你将触碰区域的 ADRs。

脱敏

这个 skill 会要求你展示 commands、outputs 和捕获的 artifacts。先 redact 掉每个 secret:用 <REDACTED> 替换。Build loops 要针对 env vars 进行,让 credential 留在 environment 里而不是你展示的内容中。捕获的 artifacts 带有 auth headers:只引用携带 signal 的那些行。

如果 redact 后的 output 不足以诊断 bug,就说明情况并询问用户。

Phase 1 - 构建 feedback loop

这就是这个 skill 的核心。 其他所有内容都是机械步骤。如果你拥有一个针对该 bug 的 tight pass/fail signal,即它会在 这个 bug 上变红,你就能找到原因;bisection、hypothesis-testing 和 instrumentation 都只是消费这个 signal。没有它,盯着代码看多久都救不了你。

在这里投入不成比例的精力。要强硬、要有创造力、拒绝放弃。

构建 loop 的方式 - 大致按以下顺序尝试

Sponsors

Details

Repository
github.com/vinvcn/mattpocock-skills-zh-cn
Category
Debugging
First seen
Jul 14, 2026

More from vinvcn/mattpocock-skills-zh-cn

All 39

Recommended

More Debugging
1dpearson2699 avatarpush-notificationsdpearson2699/swift-ios-skillsImplement, review, or debug push notifications in iOS/macOS apps — local notifications, remote (APNs) notifications, rich notifications, notification actions, s4.4Kskills.sh installs
2thedotmack avataroh-my-issuesthedotmack/claude-memCluster a GitHub issue backlog by root cause into a small set of plan-master issues, redirect children with a standardized comment, and bundle architectural-fix4.3Kskills.sh installs
3dotnet avatartest-gap-analysisdotnet/skillsPerforms pseudo-mutation analysis on production code in any language to find gaps in existing tests. Use when the user asks to find weak or shallow tests, disco4.3Kskills.sh installs
4ant-design avatarant-designant-design/antd-skillDecision guide for antd 6.x, Ant Design Pro 5/ProComponents, Ant Design X v2, and the offline `@ant-design/cli`. Use for component selection, theming/tokens, SS4.3Kskills.sh installs
5dotnet avatarbuild-perf-diagnosticsdotnet/skillsDiagnose MSBuild build performance bottlenecks using binary log analysis. USE FOR: identifying why builds are slow by analyzing binlog performance summaries, de4.2Kskills.sh installs
6forcedotcom avatargenerating-apex-testforcedotcom/sf-skillsGenerate and validate Apex test classes with TestDataFactory patterns, bulk testing (251+ records), mocking strategies, assertion best practices, and discipline4.2Kskills.sh installs