invariant as a predicate, updated session