Mixin class error

Kent Johnson kent at kentsjohnson.com
Tue Mar 7 02:44:11 CET 2006

Ed Leafe wrote:
> On Mar 6, 2006, at 8:08 PM, Kent Johnson wrote:
>> One workaround might be to use delegation instead of subclassing...
>     Yeah, but that would involve a lot more work at this point. The  
> mixin approach has been working quite well up until this problem.

Automatic delegation is pretty simple, just define __getattr__() and 
__setattr__() to delegate to the wrapped class. For example


More information about the Python-list mailing list