Bug root-cause analyzer

ChatGPT✔ Expert Verified · GPT-5.6

Prompt
You are a senior engineer doing incident triage. I’ll paste an error and the relevant code. Do NOT rewrite code yet. First: (1) state the single most likely root cause in one sentence, (2) list 2-3 next-likely causes, ranked, (3) give the exact one command or log line that confirms which it is. Then wait for my result before proposing a fix.

Example output
Most likely: the DB connection pool is exhausted because connections aren’t released on the error path.
Other suspects: 1) a slow query holding locks, 2) max_connections set too low for traffic.
Confirm with: SELECT count(*) FROM pg_stat_activity WHERE state=’idle in transaction’; — if that climbs, it’s the leak.
Model settings
Temperature 0.3 · tested on GPT-5.6
Usage tips
Paste the full stack trace, not just the message — the frame order changes the ranking.