The 30 day simulation
Eight scenarios on a fake PayPal and a fake clock. Labelled SIMULATED.
30 day simulated timeline
Scroll the figure sideways, or open it full size.
docs/evidence/SIM/SIM-MULTIDAY.md (seed 20261107).Text version of this diagram
Everything here is simulated: a fake PayPal and a fake clock.
- S1: hold day 0, capture day 1. 6/6 checks, PASS.
- S2: close day 2.5, inside honor period. 6/6 checks, PASS.
- S3: capture day 3.5, reauthorized. 8/8 checks, PASS.
- S4: reauth day 3, capture day 5. 5/5 checks, PASS.
- S5: never reauthorized, day 30. 6/6 checks, PASS.
- S6: crash and restart at day 2. 10/10 checks, PASS.
- S7: late expiry webhook, day 31. 5/5 checks, PASS.
- S8: 40 lots, 100 bidders, crashes. 7/7 checks, PASS.
S8 ran 40 lots: 40 settled, 0 in review. 294 holds, 94 reauthorize calls, 51 process crashes survived, 31 PayPal faults armed, 3 lots used the runner-up fallback, 8 of 8 injected rate-limit storms settled after a restart.
Ledger: held $159,385.00 = captured $34,170.00 + released $125,215.00 + open $0.00.
What it is
The settlement saga, the reauthorization pass, the journal stores and the webhook merge run over simulated days against a model of PayPal's authorization rules, in seconds, with an injected clock. The model is the fake PayPal with these assumptions: honor period 3 days, authorization valid 29 days, reauthorize allowed only after the honor period and answered with a new authorization id, capture after validity fails.
| Scenario | Title | Checks | Result |
|---|---|---|---|
| S1 | Hold at day 0, capture at day 1 | 6/6 | SIMULATED PASS |
| S2 | Auction closes at day 2.5, capture before the honor period ends | 6/6 | SIMULATED PASS |
| S3 | Capture at day 3.5, after the honor period, with reauthorization | 8/8 | SIMULATED PASS |
| S4 | Capture at day 5 after reauthorization at day 3 | 5/5 | SIMULATED PASS |
| S5 | Hold never reauthorized, capture at day 30 | 6/6 | SIMULATED PASS |
| S6 | Server crash and restart between hold and capture at day 2 | 10/10 | SIMULATED PASS |
| S7 | Webhook for an expired authorization arriving late | 5/5 | SIMULATED PASS |
| S8 | 30 simulated days, 100 bidders, random crashes | 7/7 | SIMULATED PASS |
S8: thirty days, a hundred bidders, random crashes
Forty lots, 100 bidders, a 3 percent crash chance at every boundary, outages of 1 to 4 days in 5 percent of crashes, and random PayPal faults. Every fifth lot gets two injected rate-limit (429) answers on its first capture and a restart after a two hour outage. The figures on the timeline above are read from the committed file.
Process crashes in this suite are exceptions at a saga boundary: they are not real process kills.
- docs/evidence/SIM/SIM-MULTIDAY.mdgenerated file; do not edit by hand
- packages/payments/test/simdays/multiday.test.tsthe suite that generates it
- .github/workflows/sim-multiday.ymlthe CI job
Last updated on
Gate G5: speech accuracy partial
Is speech-to-text accurate enough to accept bids without confirmation? Not proven. On synthetic audio the numbers now meet the limit, but they were tuned on the same clips. Real numbers, method and limits.
Latency in progress
Measured PayPal sandbox latency and the targets it does not meet.