Trace the execution path
Ask the agent to follow, step by step, which code actually runs when something happens, from the click or request to the final result.
Follow the actual sequence of function calls, conditions, and data changes for one specific action, using code reading, logs, a debugger, or added logging, to find where actual behavior departs from expected behavior.
Following a lost package's tracking history: warehouse, truck, sorting center. You find the exact stop where it went wrong instead of guessing.
Real apps have many paths, and agents sometimes fix code that never runs in the failing case. Tracing the real path pins the problem to one specific step.
I traced the execution path: the form posts to /api/reset, which calls sendResetEmail(). That function exits early because the template ID is missing in production.
Trace the execution path from clicking Reset password to the email being sent. Show me each step and where it stops behaving as expected.
Assuming the code that looks relevant is the code that runs. Old unused files, feature switches, and duplicate code fool people and agents alike.