Production & Reliability · 3 to 4 hours
Debug an integration with partial failures and retries
Find why an SMS reply webhook sent duplicate texts, left some messages unanswered, and multiplied model calls under rate limits, timeouts, and redeliveries. Fix each defect with a regression test, then declare the release check for the fix.
Hands-on debugging
4 h
1
Step 1: The question
Suppose a fictional veterinary clinic network's SMS reply handler misbehaved during a Monday peak. Using the incident, the handler contract, and the log and code in the diagnosis exercise, attribute every symptom to a defect with evidence and predict the fixed handler's result on the incident replay. Then fix the handler in the linked practice problem with the smallest change per defect and one regression test each, decide the order and shape of the fixes, and declare the release check before the fix ships.
Constraints
- Use only the evidence in the incident, the handler contract, and the diagnosis exercise
- The provider's 10-second window, its redelivery policy, and the send API's 24-hour key window cannot change
- Every delivery gets a response within the handler's 8,000 ms budget
- Do not weaken a control to hide a symptom: keep deduplication, the attempt limit, and the idempotency key
- Tests take time and provider responses as data: no real clock, network, or randomness
Deliverables
- A cause table: each symptom, the defect or defects behind it, and the log line, provider record, or code line that shows it, plus what each fix alone would change
- The fixed handler's calls, keys, outcomes, and texts on the incident replay, predicted before running any test
- The fixed handler passing the practice problem's tests, with one regression test per defect that fails on the old code
- Why a retried send is safe after your fix: unknown outcomes, the key, the payload, the key window, and a redelivery that arrives mid-processing
- The fix order, minimal or structural fix with trade-offs, and a release check written before deploy
Hard questions are part of Premium: the study guide, reference answer, rubric, and exercises unlock with Premium.
