Proof layer

Formal methods with TLA+

Write TLA+ specs that catch concurrency bugs before any code exists.

  1. 01

    Why tests are not enough

    The bug that needs 3 messages in one exact order.

    Being writtenFree
  2. 02

    Systems as state machines

    States, steps and behaviours.

    Being writtenFree
  3. 03

    Your first TLA+ spec

    A transfer between two accounts, checked by TLC.

    Being writtenFree
  4. 04

    Invariants

    Things that must be true in every state.

    Being writtenPro
  5. 05

    Liveness

    Things that must happen eventually.

    Being writtenPro
  6. 06

    Modeling retries and duplicates

    Let the checker deliver every message twice.

    Being writtenPro
  7. 07

    Specifying a ledger

    Prove money is never created or lost.

    Being writtenPro
  8. 08

    Property-based testing

    Check the code against the spec's rules.

    Being writtenPro
  9. 09

    Deterministic simulation testing

    Replay any failure, exactly.

    Being writtenPro