Promise.all failure masking
You ask an AI to explain how this TypeScript data-sync function handles failures. The agent says: "It's robust — it retries each item, and any item that ultimately fails is logged and skipped so one bad record can't break the whole batch." You're about to depend on it for a financial reconciliation job. What does the explanation get wrong, and how do you verify the actual failure behavior?
Implement
settle_batch(item_ids: list[str], outcomes: list[str]) → list[str]Examples
in
[["tx1","tx2","tx3"],["ok","err:timeout","ok"]]out["tx1=ok","tx2=failed:timeout","tx3=ok"]in
[["tx1","tx2"],["ok"]]out["tx1=ok","tx2=failed:no-result"]What a strong answer looks like
Treat the AI’s output as a draft to verify, not an answer to trust. Name the specific flaw and the input that triggers it, say how you’d catch it (tests, edge cases, reading critically), and how you’d re-prompt or decompose to get it right.
0:00 of about 15 min
Vibe & agentic: describe the solution in plain language (or narrate it) and the coach grades your approach.
Which questions mattered is sealed until you submit. Telling you now would just be handing over the edge cases.
Run or narrate your approach, then ask the coach.