Is the following a valid __delattr__ method?
class Item:
def __delattr__(self, attr):
if attr in self.__dict__:
print ('Deleting attribute: %s' % attr)
super().__delattr__(attr)
else:
print ('Already deleted this attribute!')
Specifically, is the super() the proper way to "actually delete" the attributes? And is the attr in self.__dict__ the proper way to check if an attribute is in an instance?