Fix class for py2