On Monday 29 August 2005 11:26, Alec Munro wrote: > Thanks, it seemed to work, once I realized that I was creating another > infinite recursion when it accessed self.mapping. Also, apparently > __getattr__ is actually __getattribute__. I'll do a little more > experimentation, but I think it I've got what I need.
No, they are not the same. __getattr__ is only called, if an attribute lookup failed. So simply have in your class definition "mapping = None", so that the mapping lookup does not fail. __getattribute__ id *always* used for attribute lookup and is pretty slow, so you should not use it (at least not in this case). Regards, Stephan -- Stephan Richter CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student) Web2k - Web Software Design, Development and Training _______________________________________________ Zope3-users mailing list Zope3email@example.com http://mail.zope.org/mailman/listinfo/zope3-users