360 Secure SkillHub
360 安全技能中心

RedHat Debugger

核心功能:通过复现→隔离→修复→验证的确定性流程,定位故障根因,提供最小修复方案并验证,防止回归。典型场景:测试失败、运行时错误、性能退化或异常输出。输入需提供症状,可选复现步骤、日志、环境信息;输出为含根因、修复、验证及后续建议的结构化结果,遵循安全规则,禁用不当修复手段。

mzfshark
mzfshark
热度 37.05
最近更新 2026-05-11 17:45:41
分类:开发依赖:纯提示词应用场景:调试排错

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add axodus-debugging
Metadata
name
debugging
description
Diagnose failures using reproduce → isolate → fix → verify workflow.
metadata
{"author":"RedHat Dev","version":"1.0.0","owner":"RedHat Dev Agent","category":"quality"}

SKILL: debugging

Purpose

Diagnose errors with a deterministic workflow: reproduce → isolate → fix → verify.

When to Use

  • Tests are failing.
  • Runtime errors occur (stack traces, crashes, misbehavior).
  • Performance regressions or unexpected output is reported.

Inputs

  • symptom (required, string): error message, failing test, or observed behavior.
  • repro_steps (optional, string): how to reproduce.
  • logs (optional, string): relevant logs/traces.
  • environment (optional, object|string): OS, versions, env vars (no secrets).

Steps

  1. Reproduce deterministically:
    • capture exact command(s)
    • capture versions
  2. Localize failure:
    • narrow to smallest failing unit/test
    • add targeted logging/diagnostics if needed
  3. Form hypotheses and test them one by one.
  4. Implement the smallest fix that resolves the root cause.
  5. Add/adjust tests to prevent regression.
  6. Verify:
    • original repro no longer fails
    • related tests still pass

Validation

  • Root cause is stated explicitly (not only the symptom).
  • Fix is verified by test/repro.
  • No unrelated behavior changes are introduced.

Output

root_cause: "<what broke and why>"
fix: "<what changed>"
verification: ["<commands/tests>"]
follow_ups: ["<optional hardening>"]

Safety Rules

  • Do not “fix” by disabling tests or checks unless explicitly approved and justified.
  • Prefer reversible debugging changes (guarded logs, small diffs).

Example

Symptom: “TypeError: cannot read property 'x' of undefined in production.” Output: root cause (missing null check), fix, and regression test.