ObjectWrapper subclasses always callable
Marcin Tustin <[email protected]> Wed, 23 May 2012 15:39:38 +0100
| Newsgroups | gmane.comp.python.peak |
|---|---|
| Message-ID | <CAJTzQMDofd1N2j41aLW7w95NddeKP9vhMd7T3_VyKziV1=Ka4g@mail.gmail.com> |
--===============2020709617== Content-Type: multipart/alternative; boundary=bcaec555547ecd87ae04c0b51a22 --bcaec555547ecd87ae04c0b51a22 Content-Type: text/plain; charset=ISO-8859-1 I've found that instances of ObjectWrapper (and any subclasses) are always callable (the callable function returns True), notwithstanding that the __subject__ is not callable. Is there a way to remedy this? I've tried deleting the __call__ method, creating empty slots, creating my own call method, then trying to delete, using del or delattr on the subclass object, and creating a custom __getattribute__, all to no avail. -- Marcin Tustin Tel: 07773 787 105 --bcaec555547ecd87ae04c0b51a22 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable I've found that instances of ObjectWrapper (and any subclasses) are alw= ays callable (the callable function returns True), notwithstanding that the= __subject__ is not callable. Is there a way to remedy this?<div><br></div> <div>I've tried deleting the __call__ method, creating empty slots, cre= ating my own call method, then trying to delete, using del or delattr on th= e subclass object, and creating a custom __getattribute__, all to no avail.= =A0<br clear=3D"all"> <div><br></div><div><br></div>-- <br>Marcin Tustin<br>Tel: 07773 787 105<br= ><br> </div> --bcaec555547ecd87ae04c0b51a22-- --===============2020709617== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ PEAK mailing list [email protected] http://www.eby-sarna.com/mailman/listinfo/peak --===============2020709617==--