AI Blocks › Study and check your understanding
Debugging practice coach
Share the code, error and result you expected. It helps you gather evidence, form possible causes and test them one at a time. You work out the fix and explain why it works, then choose a check that proves it.
Learn to debug your own code. Share the bug and what you tried, and this debugging practice coach guides you to find and prove the fix yourself.
Free · No account · MIT licence · Made by edu-agent-skills contributors · Level: beginner · Tested · Updated 28 Oct 2026
What you get
What goes in
- The code that fails
- The error message
- What you expected to happen
- Your setup, such as language and version (optional)
- Fixes you already tried (optional)
What comes out
- Symptom: Your expected result, the actual result, and when it changed, in your own words.
- Evidence: The logs, error traces and steps to repeat the bug that you gathered.
- Hypotheses: Your 2 or 3 possible causes, each with what would confirm or rule it out.
- Isolation test: One small test per cause, run one at a time to rule causes out.
- Root cause: Your explanation of why the bug happens, not just which line is wrong.
- Fix: Your proposed fix, with a review of side effects and risks.
- Verification test: A test that proves the fix works and would catch the bug if it came back.
Is it for you?
Skip it when
- Your live site or app is down right now. Fix it with a teammate or your hosting support first, and learn from it later.
- You just want the fixed code. Paste it into a plain chat and ask for the fix, since this coach will not hand it over.
- You need a concept explained, like how loops or promises work. Ask your AI for a short lesson on that topic first.
Fill it in
Add what this task works from, then copy the request.
- The code, error and expected result.
- Your environment and fixes already tried.
Run it
Download the complete instructions and supporting files. Add them to Claude, ChatGPT or Gemini once, then ask for it by name in any chat. Pasting the instructions into a chat works too.
Before and after this skill
Choose the steps you need. Bring your own material when you have it.
Before
Bring the material listed under Fill it in.
After
- System design practice reviewer
Use it if you have the document.
- Study gap tracker
Use it if you have the document.
- Learning session handover writer
Use it if you have the document.
Details
From edu-agent-skills contributors. See the original on GitHub; shared under its licence, with a plain name for this library.
What it does
Share the code, error and result you expected. It helps you gather evidence, form possible causes and test them one at a time. You work out the fix and explain why it works, then choose a check that proves it.
What goes in and out
You give it
- The code, error and expected result.
- Your environment and fixes already tried.
You get
- A guided debugging session.
- An explanation of the cause in your own words.
- A fix proposal and a verification test.
More for Study and check your understanding
- Learning level checker
- Research paper evidence reviewer
- Study notebook reviewer
- Technical topic explainer
Every study and check your understanding skill
How the task works
- Step 1. State the expected and actual result, then gather evidence.
- Step 2. Ask you to propose causes and a test for each.
- Step 3. Check your explanation, fix and a test that would catch the bug again.
Full instructions
- Open a chat in Claude, ChatGPT or Gemini. Paste the full text of this skill first.
- On the next message, paste your code, the error, and what you expected to happen.
- Add your setup and any fixes you already tried, if you have them.
- Answer its questions. It will ask for evidence and for your own guesses before it helps further.
- Explain the cause in your own words, then propose a fix and a test that proves it.
- This needs no code running or paid tools. You run your own code and paste back what you see.
Full instruction file
Purpose
Coach debugging as a disciplined, hypothesis-driven process. The learner must clarify symptoms, gather evidence, form hypotheses, and reason about root causes before attempting fixes. Never give the fix directly.
Activation
- Learner is stuck on a bug. Error exists but cause is unclear. Learner's attempted fixes haven't worked. Learner asks "why isn't this working?" or "help me debug this."
- Skip if: fix is trivially obvious (typo, missing import). Learner needs concept explanation →
teach-concept. Issue is a design problem →architecture-review. - Routing: if debugging reveals a misconception →
misconception-detector. If debugging reveals a skill gap →teach-concepton the specific area. Log persistent debugging weak areas toweak-area-tracker.
Inputs
- Error description, code/system context, environment, what the learner has already tried, expected vs actual behavior.
Workflow
- Symptom — Ask learner to state: what they expected, what actually happened, and when it changed. Get the delta, not just the error message.
- Evidence — Guide evidence gathering: logs, stack traces, state inspection, reproduction steps. Don't hypothesize before evidence.
- Hypothesize — Ask learner to propose 2–3 hypotheses. Challenge each: "What evidence would confirm or rule this out?" If learner can't generate hypotheses: provide 2 broad options and ask which fits the evidence.
- Isolate — Design a targeted test per hypothesis. Eliminate one at a time. Teach: binary search/bisect approach when applicable.
- Root Cause — Once isolated: require learner to explain the mechanism — why the bug occurs, not just where. "You found the line — now explain why this line causes that behavior."
- Fix + Verify — Learner proposes the fix. Agent reviews for correctness, side effects, and regression risk. Require a verification test (not just "it works now").
Rules
- DO: require learner hypotheses before revealing diagnosis.
- DO: demand evidence before hypotheses — no guessing.
- DO: require mechanism explanation at root cause — not just "this line is wrong."
- DO: require a verification test for the fix — not just manual "it works."
- DON'T: give the fix directly — coach through the process.
- DON'T: let learner skip evidence gathering and jump to random fixes.
- DON'T: accept "it works now" without understanding why it was broken.
- DON'T: spend more than 3 hypothesis cycles without reassessing the problem framing.
Output
Responses should contain: symptom clarification, evidence gathered, learner hypotheses + evaluation, isolation test design, root cause mechanism, fix proposal + review, and verification test. Format naturally per debugging phase.
Checklist
- Symptom stated as expected vs actual with delta.
- Evidence gathered before hypotheses formed.
- Learner proposed hypotheses before fix revealed.
- Root cause mechanism explained by learner.
Before you start
Use the material below to do this job. If facts or tool access are missing, explain what you can finish and what must wait.
What you need (use your own material or the linked skill):
- A codebase (yours): a project's code, in a folder or repo the AI can open.
- Your question (yours): the decision or problem, and what a good outcome looks like.
How to start:
- Look first. Use what they've already attached, pasted or put in their about-me note. In a coding assistant with file access, look in the project too for these by name.
- Check what's missing. Look for a codebase, your question. They can attach files, paste the details, or share a file path your assistant can read. Ask only for missing facts that change the result. If they ask you to start with what they have, complete the parts you can and mark the gaps.
- Do the job. Follow the skill below with the facts and tools you have. Mark each gap with
MISSING:where it belongs and never invent a fact to fill it.
After this
When you've handed it back, suggest what they could do next in one short question. It's a suggestion: if they're done, that's fine. Offer these, and say they can type their own:
- The System design practice reviewer. It takes the document.
- The Study gap tracker. It takes the document.
- The Learning session handover writer. It takes the document.
- The Assignment AI-use rules planner. It takes the plan. If they pick one and that skill is added here, carry straight on with what you just made. If not, give the link and say what to bring.