debug SKILL.md skillA

debug from riot-org/riot is an agent skill: a SKILL.md folder an AI agent loads when a task calls for it.

Install it, pinned
mdr add riot-org/riot/debug@git:20260817.d4dfa41

Pins git:20260817.d4dfa41 in mdr.lock. Pin the fingerprint instead.

Audit grade
A, 17 of 17 checks passed
Kind
SKILL.md skill
Repository
riot-org/riot
Path
crates/riot-kernel/builtin/skills/debug/SKILL.md
Versions recorded
1
Latest version
git:20260817.d4dfa41, committed Aug 17, 2026
Size
2,427 bytes
Repository stars
22
License
a license file GitHub does not identify

排查 bug 时用。顺序是硬的:先复现、再让证据淘汰假设、修根因、用原始复现路径验证。不要看到第一个可疑点就动手改。.

Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.

What the file says

# 调试

顺序是硬的:**复现 → 定位 → 修 → 验证**。跳过复现直接改,修完也不知道
修没修好;「看起来像这个问题」的改动堆几层,代码比原来更难懂。

## 1. 复现

- 拿到最小复现路径:什么输入、什么操作、期望什么、实际什么。
- 按用户的描述复现不出来时,先对齐环境差异(版本、配置、数据),
  不要按「大概是这个意思」开修。
- 间歇性的 bug 先想并发、时序、未初始化、缓存。复现率不到 100% 也要
  拿到一个「多跑几次必现」的脚本——没有它,最后没法证明修好了。

## 2. 定位:让证据淘汰假设

- 看到症状先列 2-3 个候选假设,再找**能区分它们**的证据——不是找
  支持第一个假设的证据。
- 二分收敛:注释掉一半、在中间点打日志、`git bisect`。每一步的目标
  是砍掉一半可能性,而不是「再看一眼」。
- `[约束]` 打日志要打**变量的值**,不是「到这里了」。执行路径只占
  bug 的少数,多数 bug 错在数据不在路径。
- git 历史是证据:`git log -p -- 那个文件` 看这行什么时候变的、当时
  的提交想干什么。「以前是好的」这类 bug,bisect 比读代码快得多。

## 3. 修

- 修**根因**,不是在症状处打补丁。上游给了空值,在下游判空只是把
  炸点挪远了,还把上游的问题盖住了。
- 最小改动。定位过程中看到的其它可疑点,记下来告诉用户,不要一起
  改——一起改就分不清哪个改动起了作用。

## 4. 验证

- 用第 1 步的**原始复现路径**再跑一遍,不是用「我觉得等价」的路径。
- 跑一遍相关测试,确认没修出新的问题。
- 收尾回答两个问题:**同类的地方还有吗**(同一个错误模式往往不止
  一处,grep 一把);**要不要加个测试守住这里**(这个 bug 能溜进来,
  说明现在没有测试拦它)。

## 调试自己刚写的代码时

嫌疑最大的不是代码,是自己对「输入长什么样」「这个 API 行为如何」的
假设。打印真实输入和中间值对着看,比反复重读代码快。

Read the whole file at its exact version.

How to install

The exact contents, by fingerprint
mdr add riot-org/riot/debug@sha256:630ed39a9fb87d2c

The line at the top of this page pins the label git:20260817.d4dfa41, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.

Badge

mdr badge

[![mdr](https://markdownregistry.com/badge/art_y25lmncxehp3gszd.svg)](https://markdownregistry.com/a/art_y25lmncxehp3gszd)

3 badge image fetches in 30 days. What the badge shows.

Versions

The registry has recorded 1 version of this file, committed on Aug 17, 2026.

versioncommittedcommitsizeaudit
git:20260817.d4dfa41 latest2026-08-17 d4dfa41 2,427 BA view

Audit of the latest version

A  17 of 17 checks passed. Fixed automatic checks with no AI involved, so the same checks give the same answer every run.
  • pass: Frontmatter block present
  • pass: Frontmatter declares a name
  • pass: Frontmatter declares a description
  • pass: Size between 200 bytes and 200 KB (2427 bytes)
  • pass: No zero-width or bidi control characters
  • pass: No instruction hidden inside an HTML comment
  • pass: No link to an exfiltration or paste host
  • pass: No credential-shaped string
  • pass: No instruction to send local credentials anywhere
  • pass: No text hidden with inline styles
  • pass: No prompt-injection phrasing
  • pass: No curl or wget piped into a shell
  • pass: No recursive delete of root, home or parent
  • pass: No instruction to read or print local credentials
  • pass: No base64 blob over 200 characters
  • pass: No link to a raw IP address
  • pass: No script tag

Source

GitHub

riot-org/riot · 22 stars · license a license file GitHub does not identify · pushed 2026-10-29 · branch master

API

GET https://markdownregistry.com/api/v1/artifacts/art_y25lmncxehp3gszd
GET https://markdownregistry.com/api/v1/resolve?ref=riot-org/riot/debug
GET https://markdownregistry.com/api/v1/blob/630ed39a9fb87d2c25eae3401ae35ed70fbe0d5d9b717ad6bbe8f15a1c563f4b

Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.

Guides: the SKILL.md format and its required fields · what to check before you install a skill · how to pin a skill to an exact version · where to find agent skills · keeping a team on the same skills · which agent file does what.

More from riot-org/riot

add-command SKILL.md skill
riot-org/riot · .riot/skills/add-command/SKILL.md · 给前端加一个 Tauri 命令时用。要改五处,漏了其中三处只表现为运行时「command not found」;权限文件还有个先后顺序的坑会让 build.rs 直接 panic。
git:20260817.d00a470 · audit A · 22 stars
add-tool SKILL.md skill
riot-org/riot · .riot/skills/add-tool/SKILL.md · 给 Riot 加一个模型能调的工具时用。Tool trait 的必答项、fail-closed 默认值的判据、注册位置、以及几条写错了不报错只是行为悄悄降级的规则。
git:20261011.281dcd7 · audit A · 22 stars
commit-batch SKILL.md skill
riot-org/riot · .riot/skills/commit-batch/SKILL.md · 工作区堆了多个不相关主题的改动、要整理成提交时用。按主题切分而不是拆成一堆小提交,并照这个仓库的消息风格写。
git:20260817.d00a470 · audit A · 22 stars
mutate SKILL.md skill
riot-org/riot · .riot/skills/mutate/SKILL.md · 动过权限决策链、Bash 分析、路径围栏、安全检查、文件工具或进程执行器之后用。跑变异测试,并正确解读存活的变异。
git:20260817.d00a470 · audit A · 22 stars
protocol-change SKILL.md skill
riot-org/riot · .riot/skills/protocol-change/SKILL.md · 改了 crates/riot-protocol 里的类型之后用。重新生成绑定,并检查 serde tag 撞名这类 Rust 类型层面看不出来的问题。
git:20260817.d00a470 · audit A · 22 stars
review SKILL.md skill
riot-org/riot · .riot/skills/review/SKILL.md · 审查一批改动时用。缺陷优先,并按这个仓库特有的失效方式去找问题——那些编译通过、类型正确、看起来合理的写法。
git:20260817.d00a470 · audit A · 22 stars
verify SKILL.md skill
riot-org/riot · .riot/skills/verify/SKILL.md · 改完代码要验证时用。按这个仓库的分层防线依次跑,并说明每一层拦的是什么。别只跑 cargo build 就当验证过了。
git:20260817.d00a470 · audit A · 22 stars
add-mcp SKILL.md skill
riot-org/riot · crates/riot-kernel/builtin/skills/add-mcp/SKILL.md · 用户想加、改、排查 MCP 服务器,或从 Cursor / Claude Desktop / VS Code 搬 MCP 配置过来时用。用户级只认 stdio(远程走 mcp-remote 桥)、config.json…
git:20261014.9c3854a · audit B · 22 stars
commit SKILL.md skill
riot-org/riot · crates/riot-kernel/builtin/skills/commit/SKILL.md · 要把改动提交成 git commit 时用。先看清工作区里有几件事、按主题分组、只暂存这一组,以及消息里该写什么不该写什么。
git:20261014.9c3854a · audit A · 22 stars
create-plugin SKILL.md skill
riot-org/riot · crates/riot-kernel/builtin/skills/create-plugin/SKILL.md · 用户想写一个 Riot 插件、把已有的技能/命令/hooks/MCP 打包分发、或把 Claude Code / Cursor 插件搬到 Riot 时用。目录布局、三种清单格式、dev.riot 扩展字段、本地链接调试流程和市场发布。
git:20261014.9c3854a · audit A · 22 stars
extend-riot SKILL.md skill
riot-org/riot · crates/riot-kernel/builtin/skills/extend-riot/SKILL.md · 用户想加技能、斜杠命令、hook、项目约定(AGENTS.md),或要给命令配 API key、密码这类机密时用。各扩展点的目录、格式限制和优先级规则。MCP 服务器转 add-mcp,打成可分发的插件转 create-plugin。
git:20261014.9c3854a · audit B · 22 stars
retro SKILL.md skill
riot-org/riot · crates/riot-kernel/builtin/skills/retro/SKILL.md · 任务磕磕碰碰才做成、被纠正了好几次之后用;用户说「复盘」「总结经验」「记下来」时也用。回顾这次会话的纠错轨迹,筛出下次还会犯的错,沉淀进 AGENTS.md 或技能,同类任务下次不用再教一遍。
git:20261014.9c3854a · audit A · 22 stars

Every file in riot-org/riot

Other files named debug

debug SKILL.md skill
yeachan-heo/oh-my-claudecode · skills/debug/SKILL.md · Diagnose the current OMC session or repo state using logs, traces, state, and focused reproduction
git:20260925.570ed1c · audit A · 40,492 stars
debug SKILL.md skill
nanocoai/nanoclaw · .claude/skills/debug/SKILL.md · Debug container agent issues. Use when things aren't working, container fails, authentication problems, or to…
git:20261022.0474572 · audit B · 31,064 stars
debug SKILL.md skill
agentic-community/mcp-gateway-registry · .claude/skills/debug/SKILL.md · Debug issues in the MCP Gateway Registry using first-principles thinking. Invoke when something is broken, timing out…
v1.0 · audit A · 1,034 stars
debug SKILL.md skill
suboss87/fdeops · skills/debug/SKILL.md · Investigate a failure, regression or incorrect result in an integration or application, even before it can be…
git:20261005.ed7f271 · audit A · 947 stars
debug SKILL.md skill
rsmdt/the-startup · plugins/start/skills/debug/SKILL.md · Systematically diagnose and resolve bugs through conversational investigation and root cause analysis
git:20261011.48bd3ee · audit A · 577 stars
debug SKILL.md skill
fcakyon/labrat · plugin/skills/debug/SKILL.md · Evidence-before-action diagnosis of failing ML experiments. Probes the system before guessing causes, process list…
git:20260430.e4e97e0 · audit A · 452 stars
debug SKILL.md skill
ericrisco/rsc-harness · skills/debug/SKILL.md · Use when something is broken — a failing or flaky test, crash, wrong result or regression — and the root cause must be…
git:20261003.f0c84d6 · audit A · 429 stars
debug SKILL.md skill
sd0xdev/sd0x-harness · skills/debug/SKILL.md · Interactive debugging workflow with hypothesis-driven probe loop. Use when: unknown bugs, script errors, silent…
git:20260925.3600370 · audit A · 194 stars

Browse by kind, by grade A, or by owner.