[Zope-dev] Re: OFS.Application deprecations for Zope 2.10

Chris McDonough chrism at plope.com
Mon Jun 12 09:18:04 EDT 2006


I should note that the same rationale does not really apply to  
'__ac_permissions__' and 'meta_types'; what these do can be done in  
registerClass, so the deprecation warning isn't lying for those...

- C

On Jun 12, 2006, at 9:09 AM, Chris McDonough wrote:

> Right, sorry.  I've been out of the loop.  I haven't been keeping  
> up with the latest goings on.
>
> FWIW, I recently needed to emulate this machinery for "Basket" so I  
> can sympathize with wanting to make it saner, but I question the  
> wisdom of deprecating 'methods'.
>
> IMHO, we should ignore the fact that the lookup for "methods" attrs  
> comes after the comment that says "Support old-style product  
> metadata".  registerClass does not provide an automated way to do  
> what "methods" does.  The "new regime" way to do what it does would  
> be to use a Five view, but this wouldn't work for non-URL lookups.   
> So people who use 'methods' now will need to monkeypatch in hideous  
> ways just like the 'methods' stuff does now, in which case why not  
> leave it?
>
> - C
>
> On Jun 12, 2006, at 6:57 AM, yuppie wrote:
>
>> Hi Chris!
>>
>>
>> Chris McDonough wrote:
>>> Jusst out of curiosity, what is the rationale for deprecating  
>>> "methods"?
>>
>> It has been deprecated for at least 6 years now, I just added the  
>> warnings last year.
>>
>> I don't know the old discussions, but the comments added here make  
>> pretty clear that initialize() was meant to replace  
>> '__ac_permissions__', 'meta_types' and 'methods':
>> http://svn.zope.org/Zope/trunk/lib/python/OFS/Application.py? 
>> r1=18170&r2=18185
>>
>> I guess 'methods' was never meant to be used for something else  
>> than factory methods.
>>
>> As Florent already pointed out using it for general monkey  
>> patching doesn't look like a good idea. We only can improve the  
>> product initialization if we first remove some cruft.
>>
>>
>> Cheers,
>>
>> 	Yuppie
>>
>
> _______________________________________________
> Zope-Dev maillist  -  Zope-Dev at zope.org
> http://mail.zope.org/mailman/listinfo/zope-dev
> **  No cross posts or HTML encoding!  **
> (Related lists -http://mail.zope.org/mailman/listinfo/zope-announce
> http://mail.zope.org/mailman/listinfo/zope )
>



More information about the Zope-Dev mailing list