[Zope-dev] SVN: Zope/trunk/lib/python/Products/Five/security.py Restore Products.Five.security.initializeClass.

Tres Seaver tseaver at palladion.com
Sun Jan 4 11:51:59 EST 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Martin Aspeli wrote:
> Tres Seaver wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> Stefan H. Holek wrote:
>>> Log message for revision 94498:
>>>   Restore Products.Five.security.initializeClass.
>>>
>>> Changed:
>>>   U   Zope/trunk/lib/python/Products/Five/security.py
>>>
>>> -=-
>>> Modified: Zope/trunk/lib/python/Products/Five/security.py
>>> ===================================================================
>>> --- Zope/trunk/lib/python/Products/Five/security.py	2009-01-03 23:57:24 UTC (rev 94497)
>>> +++ Zope/trunk/lib/python/Products/Five/security.py	2009-01-04 07:44:36 UTC (rev 94498)
>>> @@ -26,6 +26,7 @@
>>>  from zope.security.management import thread_local
>>>  from zope.security.simplepolicies import ParanoidSecurityPolicy
>>>  
>>> +from App.class_init import InitializeClass as initializeClass
>>>  from AccessControl.SecurityInfo import ClassSecurityInfo
>>>  from AccessControl.SecurityManagement import getSecurityManager
>> Does third-party code import that symbol, spelled with the lower-case
>> 'i'?  If so, let's go ahead and make a 'zope.deferredimport.deprecated'
>> entry, and point people to the correct location and spelling.
> 
> I have a feeling there are uses of it out there, though I can't remember 
> where exactly. I dug through this code quite a few times.
> 
> Also, I think Five.security.initializeClass is meant as a convenience 
> import. That's all it ever was, and it fits with other symbols in 
> Five.security. It may be that we just want a deferred import, not a 
> deprecated one.

Without a committment to a "zapi-style" (i.e., permananent, canonical
API import module), I am -1 on "convenience imports":  they mask
dependencies, help create cycles, etc.

In *this* case (upgrading to a new major version of the whole Zope2
appserver framework) a deprecation seems warranted:  nobody is going to
"accidentally" upgrade to Zope 2.12 and start seeing deprecatino
warnings they don't expect.


Tres.
- --
===================================================================
Tres Seaver          +1 540-429-0999          tseaver at palladion.com
Palladion Software   "Excellence by Design"    http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJYOkv+gerLs4ltQ4RAms+AKCFwoYhvRZdbl3SM56NktZrMk4T1wCguVVM
+Di3Ze9cz7GdnrCQ57FpNe4=
=M0lM
-----END PGP SIGNATURE-----



More information about the Zope-Dev mailing list