__getattr__, hasattr

Ionel Simionescu ionel at psy.uva.nl
Tue Dec 14 07:06:09 EST 1999


Hi,


It seems that since one defines __getattr__,
hasattr(obj, name) will happily answer 'yes' irrespective of the attribute
name.

This does not appear very sound to me.
Do I overlook anything?


Thanks,
ionel





More information about the Python-list mailing list