add state_attrs method; bifurcate for versions