Skip to main content
Partly proven

The failure class is proven below — a deliberately buggy handler and a fixed one were run against the same inputs, and they diverged. A fix on your own code has not been proven on this receipt. That is a separate claim, and only prove_fix establishes it — it reproduces the bug on your repository, applies your diff, and re-runs. Call it before you apply the fix, because it needs the still-broken tree.

sandbox · stripe
30 other runs
Scoped to run run_2f8e7882-6c49-406f-96e0-90ffa2b9dc5c.View all 31 runs →
2EB5D851FD15 · reference testBug reproduced

Duplicate webhook created a second charge

The same event was delivered twice.

Before the fix
2 deliveries → 2 charges
second delivery created another charge
After the fix
2 deliveries → 1 charge
second delivery recognized as duplicate
3 related checks passed0 unexpected failures2 webhook deliveries tested1 expected error responsetook 2544ms
FetchSandbox reference handlers. Behavioral simulation of a duplicate-webhook handler bug. Stripe delivers at-least-once, so payment_intent.succeeded can arrive 2-3x with the SAME event.id. Both handlers are FetchSandbox reference implementations, NOT your code: the buggy one processes every delivery (double charge), the fixed one dedupes on the stable event id. Apply the brain's fix_pattern (atomic dedup on event.id) to your handler to inherit this behavior.

what changed

The same request, before your fix vs. after — this is what the bug did, and what it does once fixed.

Before the fix
2 deliveries → 2 charges
  1. First deliverycharge 0 → 1
  2. Duplicate deliverycharge 1 → 2
  3. Finaldouble charge detected
After the fix
2 deliveries → 1 charge
  1. First deliverycharge 0 → 1
  2. Duplicate deliverystays 1
  3. Finalexactly 1 charge

request timeline

Before the fix · reference handler
After the fix · reference handler

run timeline

Every request and webhook the run made, in order.

  1. 17:41:05.377POST /v1/customers20015ms
  2. 17:41:05.407POST /v1/payment_intents20021ms
  3. 17:41:05.416POST /v1/payment_intents/pi_PT55ABS03ZN1U65QB9FY9WTR/confirm4021ms
ok failed webhook

full request history (3)

timetypepath / eventstatusdur

run metadata

sandbox id: a8c3b9fbd9spec: Stripe APIstatus: runningscenario: defaultrun id: run_2f8e7882-6c49-406f-96e0-90ffa2b9dc5crequests: 3created: 2026-09-22T21:19:37.289632+00:00
Generated by FetchSandbox — anyone with this link can read the proof.