Retry helper returns null
You're the staff engineer doing a sampling audit of agent contributions across your Java services after noticing a rise in silent production failures. This retry helper, generated by an agent and copy-pasted into several services, is a representative sample:
What's wrong here, and given it's already spread across services, how do you run the audit and remediation as a leadership task rather than a one-off fix?
retry_plan(attempt_results: list[str], max_attempts: int, base_delay_ms: int, max_delay_ms: int) → list[str][["retryable","ok"],3,100,1000]out["try:retryable","sleep:100","try:ok","return:ok"][["fatal"],3,100,1000]out["try:fatal","throw:non_retryable"][["retryable","retryable","retryable"],3,100,250]out["try:retryable","sleep:100","try:retryable","sleep:200","try:retryable","throw:exhausted"]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.
Vibe & agentic: describe the solution in plain language (or narrate it) and the coach grades your approach.