renseiai/donmai-kits/rust-debugging

Claude Code and agent skill by renseiai/donmai-kits

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Diagnose Rust compile, borrow-checker, trait, Clippy, formatting, and test failures. Use when Cargo commands fail or report lifetime, bound, lint, or test errors.

Install

npx vskill@latest install renseiai/donmai-kits/rust-debugging

SKILL.md

Rust Debugging

Overview

Debugging Rust compile errors, borrow-checker failures, clippy lints, and test failures. Systematic diagnosis for the most common Cargo failure modes.

Triggers

Use this skill when:

  • cargo build fails to compile (borrow checker, trait bounds, lifetimes)
  • cargo clippy -- -D warnings blocks the validate gate
  • cargo test fails, panics, or doctests break
  • cargo fmt --check reports formatting drift

Debugging Workflow

1. Compile / Borrow-Checker Errors
cargo build 2>&1 | head -60

Read the FIRST error and its help: / note: lines — rustc's diagnostics usually point at the exact fix.

Common root causes:

  • Borrow conflicts — restructure ownership, clone deliberately, or scope the

borrow with a block

  • Lifetime mismatches — name the lifetime explicitly or return an owned value
  • Missing trait bounds — add where T: Trait or derive the trait
  • Moved value used after move — borrow (&) instead, or clone
2. Clippy Lints (validate gate)
cargo clippy -- -D warnings 2>&1 | head -40

Fix the lint rather than #[allow(...)]-ing it; clippy's suggestion is usually the idiomatic form.

3. Test Failures
cargo test 2>&1 | grep -E "FAILED|panicked|error\[" | head -30

Common root causes:

  • unwrap()/expect() panics on None/Err — handle the variant
  • Doctest failures — the example in /// comments must compile and run
  • Integration tests in tests/ need the crate's public API only

Notes

  • cargo/rustc live in ~/.cargo/bin. If a command reports cargo: not found,

source ~/.cargo/env first (the toolchain installer wrote it there).

Security

  • Security scanPassed, 90 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
0

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/renseiai/donmai-kits/rust-debugging/badge)](https://verified-skill.com/skills/renseiai/donmai-kits/rust-debugging)

Something wrong with this skill or its page? Tell us.