padosoft-durable-effectslisted
Install: claude install-skill padosoft/skills
# Durable effects
A queue moves *work*. It does not move **effects**. Everything below is a way a system with a correct queue
still charges twice, ships twice, or reports success for something it killed.
**The rule: claim the effect atomically before performing it, and make every terminal outcome a state you
can read back.**
---
## 1. Delivery is not the problem. The effect is
```text
signature verified → still not idempotent
lease reclaimed → still not exactly-once
retry with the same key → still a second charge, unless something refused it
```
A valid retry carries a valid signature and runs capture, fulfilment or entitlement again. Verification and
idempotency are **two separate prior checks**, and only one of them protects the effect.
**Claim a logical effect key atomically before running the effect**: treat the same event as a duplicate,
and reject a *different* event that reuses the key. In a multi-replica deployment the unique constraint in
the durable store is the boundary — not a check in application code, and not a cache.
## 2. Reclaiming a lease is a race you can lose quietly
A stale processing claim has to be reclaimable after a crash, or a dead worker blocks the queue forever. But
the previous holder may have completed the external side effect **in the moment before it died**.
The ledger can stop the duplicate *state transition*. Only an idempotency key on the external side makes the
external operation safe across that reclaim. If the downstream