layout update and pythonic precondition