How this skill is triggered — by the user, by Claude, or both
Slash command
/claude-tricks:debugThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Systematically debug and fix failing tests, build errors, or runtime issues using aggressive parallelization at every phase.
Systematically debug and fix failing tests, build errors, or runtime issues using aggressive parallelization at every phase.
DO NOT STOP UNTIL THE ISSUE IS FIXED AND TESTS PASS.
$ARGUMENTS - Test name, error message, or description of the issueLaunch three parallel agents simultaneously to maximize information gathering speed.
Agent 1 - Reproduce the failure:
If test failure:
# Run specific test
./gradlew test --tests "*$ARGUMENTS*" --info
# Or run all tests to find failures
./gradlew test
If build error:
./gradlew build --stacktrace
If runtime error, get the full stack trace and identify the failing component.
Capture all error details: full error message, stack trace, test name and class, file and line number, input that caused the failure.
Agent 2 - Check recent changes:
git diff HEAD~5 --name-only
git diff HEAD~5 -- <relevant paths>
Identify what files changed recently that could be related to the failure. Summarize which changes are most likely to have introduced the bug.
Agent 3 - Check git history:
git log --oneline -15
git log --oneline -5 -- <files related to $ARGUMENTS>
Determine if this is a regression by finding when the relevant code last changed and who changed it.
Wait for all three agents to complete. Synthesize their findings to determine:
Using the error details from Phase 1, launch three parallel agents to analyze all relevant code simultaneously.
Agent 1 - Analyze the failing test (use Explore or read directly):
Read and understand the failing test file completely. Document:
Agent 2 - Analyze the code under test (use Explore or read directly):
Read the production code that the test exercises. Document:
Agent 3 - Analyze related dependencies (use Explore or read directly):
Read related files: interfaces, shared utilities, configuration, DI modules, database schemas, or mocks that the code under test depends on. Document:
Wait for all three agents to complete. Synthesize their findings into a root cause hypothesis:
Use elite-fullstack-architect to implement the fix:
After implementing the fix, launch two parallel agents to verify simultaneously.
Agent 1 - Run the specific failing test:
./gradlew test --tests "*FailingTestName*" --info
Confirm the original failure is resolved. If it still fails, report the new error details.
Agent 2 - Run related tests:
./gradlew test --tests "*RelatedModule*"
Confirm no closely related tests have broken as a side effect of the fix.
Wait for both agents to complete. If either agent reports a failure, return to Phase 2 with the new information and repeat. Do not proceed until both pass.
Launch two parallel agents for final validation.
Agent 1 - Code review (use code-griller):
Review the fix for:
If the review finds issues, fix them before proceeding.
Agent 2 - Full test suite:
./gradlew test
./gradlew build
Run the entire test suite and build to catch any regressions anywhere in the codebase.
Wait for both agents to complete. If the full suite has failures, fix every one of them (there are no "pre-existing" failures). If the code review raised issues, address them and re-run verification.
If the bug was not caught by existing tests:
Run the new tests to confirm they pass:
./gradlew test --tests "*NewTestName*"
git add -A
git commit -m "$(cat <<'EOF'
(fix): [description of what was fixed]
Root cause: [brief explanation]
EOF
)"
# Run with debug output
./gradlew test --tests "*TestName*" --info
# Run single test class
./gradlew :module:test --tests "com.example.TestClass"
# Run multiple times
for i in {1..10}; do ./gradlew test --tests "*FlakyTest*" || break; done
IMPORTANT: There is no such thing as a "pre-existing" test failure. If any test fails, whether it appears related to your changes or not, you must fix it. The task always completes with completely passing tests.
npx claudepluginhub christyjacob4/claude-tricks --plugin claude-tricksGuides systematic root-cause debugging when tests fail, builds break, or unexpected errors occur. Provides a structured triage checklist to preserve evidence, localize, and fix issues instead of guessing.
Diagnoses and fixes test failures, build errors, runtime errors, environment issues, and more by categorizing errors and applying targeted strategies with minimal context.
Guides systematic investigation of test failures using dual-hypothesis approach (test wrong vs. implementation bug) and step-by-step protocol. Use for diagnosing test errors or establishing test failure mindset.