WHODUNITBETA
Example report

A DEBUGGING SKILL FOR CODING AGENTS

What did I
mess up?

Connect a failure to your code, changes and available agent history. Get an explanation with evidence you can follow.

npx @coreplane/whodunit

Install once. Restart your coding agent, then ask what went wrong.

Node 22+

AN EXAMPLE

Login error · Code and recent changes

Login still reads the old setting

A change renamed the login setting. The login code still uses the old name, so it cannot find the client ID.

Root cause

The settings define authClientId. The login code asks for clientId. That key is missing, which matches the reported error.

Sources
Current configurationProvided
config.json:2
{ "authClientId": "demo-app" }
Login readerProvided
login.js:7–8
const clientId = settings.clientId;
if (!clientId) throw new Error("Missing client ID");
Reported errorProvided
login error

Error: Missing client ID

Where the value disappears

Failure pathSupporting evidence

The requested key is absent from the configuration. The settings and login reader disagree.

Sources
Current configurationProvided
config.json:2
{ "authClientId": "demo-app" }
Login readerProvided
login.js:7–8
const clientId = settings.clientId;
if (!clientId) throw new Error("Missing client ID");

What we checked

CheckEvidence
Do the names match?The configuration uses authClientId. Login still reads settings.clientId.
Sources
Current configurationProvided
config.json:2
{ "authClientId": "demo-app" }
Login readerProvided
login.js:7–8
const clientId = settings.clientId;
if (!clientId) throw new Error("Missing client ID");
Does this fit the error?Login reports “Missing client ID” when the value is absent.
Sources
Login readerProvided
login.js:7–8
const clientId = settings.clientId;
if (!clientId) throw new Error("Missing client ID");
Reported errorProvided
login error

Error: Missing client ID

Which change introduced this?The last settings edit renamed clientId to authClientId. The login reader was unchanged.
Sources
Settings changeProvided
git diff: config.json
- "clientId": "demo-app"
+ "authClientId": "demo-app"

Still unknown

  • We have not tested login with the matching setting name.

Suggested fix

Update login to read authClientId, then test login with the renamed setting.