[python] fix generation of "pass" for classes