[Zope] Making __getattr__ accessible

Dave Brueck dbrueck@xlontech.com
Thu, 18 Jul 2002 07:42:37 -0600


> > I have an External Method that returns an instance of a class that 
> > implements its own __getattr__ method, but Python scripts inside
> Zope
> > can't seem to access it (I get an 'Unauthorized' exception).
> >
> > I've tried adding a ClassSecurityInfo instance to declare
> __getattr__
> > public, and I've also tried deriving the class from 
> > Acquisition.Implicit, but Zope still doesn't like it. Any ideas?

> From: Chris McDonough [mailto:chrism@zope.com] 
> Sent: Tuesday, July 16, 2002 4:09 PM
> To: Dave Brueck; zope@zope.org
> Subject: Re: [Zope] Making __getattr__ accessible
> 
> 
> Hi Dave,
> 
> do something like:
> 
> __guarded_getattr__ = __getattr__
> 
> ... in your class...

Perfect! Thanks, Chris! 

-Dave