[PEAK] Trellis throws an error related to metaclass in python 2.6.5

P.J. Eby pje at telecommunity.com
Thu Sep 30 14:04:46 EDT 2010


At 05:30 PM 9/29/2010 -0400, Christopher Stelma wrote:
>After seeing same error and the update to DecoratorTools in response,
>I applied a slightly different fix(?) for the problem.

Sorry, I don't quite understand your question.  Does the official fix 
break something for you?  It sort of sounds like you want to have 
classy ABCs, except that you're also saying you don't use them.  So, 
I'm confused.  ;-)

>Instead of killing the ABCMeta methods in the definition of
>classy_class, in the three methods of classy, I replaced references to
>"type" with "super(classy_class, classy_class)".  This lets
>ABCMeta.__new__ run when ABCMeta is the base class to do whatever
>setup is necessary, and skips straight back to type.__new__ when not.
>
>I'm not using any ABC's (directly), so is there any specific reason to
>disable it for classy sublclasses?



More information about the PEAK mailing list