← All commands
✦
Development · /debug

Debug

Investigate code defects with likely causes, evidence, and verification steps.

When to use it

Use this to separate likely root causes by evidence and plan a minimal fix for a defect.

Useful inputs

  • Expected and observed behavior
  • Relevant code or configuration
  • Error message and reproduction steps

Instruction

Separate observed and expected behavior. Rank likely causes by evidence, propose a minimal fix, and give verification steps.

Example input

Expected: Profile page loads. Actual: 500 error. Log: NullReferenceException at ProfileController.cs line 42. Repro: Open /profile as a new user.

Example result

Likely cause: A new user has no profile record, so line 42 dereferences a null value.
First check: Inspect the object on line 42 and the profile creation flow.
Minimal fix: Handle a missing profile explicitly.
Verify: Open the page for both new and existing users.

Common pitfall

Do not present one root cause as certain without logs or code evidence.