結果 : python check if class instance has attribute