[IronPython] bug when overriding __delattr__

Michael Foord fuzzyman at voidspace.org.uk
Wed Jun 23 14:39:53 CEST 2010

On 23/06/2010 13:38, Ronnie Maor wrote:
> The following code works in CPython 2.6.2, but is broken in both IPy 
> 2.6 and 2.6.1
> >>> class A(object):
> ...     def __delattr__(self,name):
> ...             object.__delattr__(self,name)
> ...
> >>> a = A()
> >>> a.x = 3
> >>> del a.x
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File "<stdin>", line 3, in __delattr__
> AttributeError: 'A' object has no attribute 'x'

You are correct, but this has already been reported and is fixed on 
trunk. The fix will be in 2.6.2 which will hopefully be released soon... :-)

All the best,


> _______________________________________________
> Users mailing list
> Users at lists.ironpython.com
> http://lists.ironpython.com/listinfo.cgi/users-ironpython.com


READ CAREFULLY. By accepting and reading this email you agree, on behalf of your employer, to release me from all obligations and waivers arising from any and all NON-NEGOTIATED agreements, licenses, terms-of-service, shrinkwrap, clickwrap, browsewrap, confidentiality, non-disclosure, non-compete and acceptable use policies ("BOGUS AGREEMENTS") that I have entered into with your employer, its partners, licensors, agents and assigns, in perpetuity, without prejudice to my ongoing rights and privileges. You further represent that you have the authority to release me from any BOGUS AGREEMENTS on behalf of your employer.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20100623/398e5ae5/attachment.html>

More information about the Ironpython-users mailing list