[Baypiggies] deleting an inherited attribute?
Rob Miller
ra at burningman.com
Wed Aug 9 00:02:14 CEST 2006
Keith Dart wrote:
> Rob Miller wrote the following on 2006-08-08 at 14:47 PDT:
> ===
>> any suggestions?
>
> ===
>
> Can you fix the other code that's checking for the attribute? If not,
> you can do this:
>
>
> class C(object):
> def _nope(self):
> raise AttributeError
> value = property(_nope)
no, but this seems to work well. i would have thought that the existence of
the property would have still caused hasattr to return True, but the
AttributeError seems to negate that.
thanks!
-r
More information about the Baypiggies
mailing list