This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author eric.araujo
Recipients arielbyd, benjamin.peterson, eric.araujo
Date 2010-07-14.13:07:30
SpamBayes Score 0.0009430253
Marked as misclassified No
Message-id <1279112853.55.0.10225967224.issue9259@psf.upfronthosting.co.za>
In-reply-to
Content
Thank you for the report. Unfortunately, the 2.6 behavior was a bug, as I explained on #9220: Magic methods are looked up on the object’s class, not in the object’s __dict__. <http://docs.python.org/reference/datamodel#specialnames>

(Your test with class methods was a clever idea, but a class is a type instance, so it’s the same behavior: __enter__ is looked up on type, not on the class. Nice try :)

Tip for future bug reports: We prefer regular files over archives. Thanks again!
History
Date User Action Args
2010-07-14 13:07:33eric.araujosetrecipients: + eric.araujo, benjamin.peterson, arielbyd
2010-07-14 13:07:33eric.araujosetmessageid: <1279112853.55.0.10225967224.issue9259@psf.upfronthosting.co.za>
2010-07-14 13:07:31eric.araujolinkissue9259 messages
2010-07-14 13:07:30eric.araujocreate