Padosoft Atomic Invariants

Use this skill whenever code enforces something that must hold only once or only so many times — a single-use code or coupon, a nonce, a rate or quota limit, "the first one wins", a stock reservation, an idempotency key, a state transition that must happen once — and whenever the user reports that two requests both succeeded where one should have failed, a coupon was redeemed twice, a job ran twice, or a counter drifted under load. It checks that the read and the write of the invariant live in one atomic step and that a constraint backs the rule where it matters. Do not use it for general transaction design, for retry policy, or for distributed consensus.

padosoft Updated

File contents

padosoft/skills/tree/main/skills/padosoft-atomic-invariants commit ca232ab233

Frequently asked questions

npx skillmds@latest add padosoft/padosoft-atomic-invariants