Traps, Invariants, and Dead-ends