[Checkins] SVN: zope.app.security/trunk/ - Bug: The `gopherlib` module has been deprecated in Python 2.5. Whenever the

Stephan Richter srichter at cosmos.phy.tufts.edu
Tue Jun 24 06:42:40 EDT 2008


Log message for revision 87700:
  - Bug: The `gopherlib` module has been deprecated in Python 2.5. Whenever the
    ZCML of this package was included when using Python 2.5, a deprecation
    warning had been raised stating that `gopherlib` has been
    deprecated. Provided a simple condition to check whether Python 2.5 or later
    is installed by checking for the deleted `regex` module and thus optionally
    load the security declaration for `gopherlib`.
  
  This has finally annoyed me enough. :-)
  
  

Changed:
  U   zope.app.security/trunk/CHANGES.txt
  U   zope.app.security/trunk/setup.py
  U   zope.app.security/trunk/src/zope/app/security/globalmodules.zcml

-=-
Modified: zope.app.security/trunk/CHANGES.txt
===================================================================
--- zope.app.security/trunk/CHANGES.txt	2008-06-24 08:32:22 UTC (rev 87699)
+++ zope.app.security/trunk/CHANGES.txt	2008-06-24 10:42:39 UTC (rev 87700)
@@ -2,16 +2,23 @@
 CHANGES
 =======
 
-3.6.0dev (unreleased)
----------------------
+3.5.1 (2008-06-24)
+------------------
 
-- ...
+- Bug: The `gopherlib` module has been deprecated in Python 2.5. Whenever the
+  ZCML of this package was included when using Python 2.5, a deprecation
+  warning had been raised stating that `gopherlib` has been
+  deprecated. Provided a simple condition to check whether Python 2.5 or later
+  is installed by checking for the deleted `regex` module and thus optionally
+  load the security declaration for `gopherlib`.
 
 3.5.0 (2008-02-05)
 ------------------
 
-- zope.app.security.principalregistry.PrincipalRegistry.getPrincipal returns
-  zope.security.management.system_user when its id is used for the search key.
+- Feature:
+  `zope.app.security.principalregistry.PrincipalRegistry.getPrincipal` returns
+  `zope.security.management.system_user` when its id is used for the search
+  key.
 
 3.4.0 (2007-10-27)
 ------------------

Modified: zope.app.security/trunk/setup.py
===================================================================
--- zope.app.security/trunk/setup.py	2008-06-24 08:32:22 UTC (rev 87699)
+++ zope.app.security/trunk/setup.py	2008-06-24 10:42:39 UTC (rev 87700)
@@ -22,7 +22,7 @@
     return open(os.path.join(os.path.dirname(__file__), *rnames)).read()
 
 setup(name='zope.app.security',
-      version = '3.6.0dev',
+      version = '3.5.1',
       author='Zope Corporation and Contributors',
       author_email='zope3-dev at zope.org',
       description='Security Components for Zope 3 Applications',

Modified: zope.app.security/trunk/src/zope/app/security/globalmodules.zcml
===================================================================
--- zope.app.security/trunk/src/zope/app/security/globalmodules.zcml	2008-06-24 08:32:22 UTC (rev 87699)
+++ zope.app.security/trunk/src/zope/app/security/globalmodules.zcml	2008-06-24 10:42:39 UTC (rev 87700)
@@ -1,4 +1,6 @@
-<configure xmlns="http://namespaces.zope.org/zope">
+<configure
+    xmlns="http://namespaces.zope.org/zope"
+    xmlns:zcml="http://namespaces.zope.org/zcml">
 
   <!-- 4. String Services -->
 
@@ -223,7 +225,11 @@
                        error_proto" />
   </module>
 
-  <module module="gopherlib">
+  <!-- This package has been deprecated in Python 2.5; let's use a cheap way
+       of detecting Python 2.5 by checking whether the package "regex" exists,
+       which has been deleted in that version. -->
+  <module module="gopherlib"
+          zcml:condition="installed regex">
     <allow attributes="send_selection send_query" />
   </module>
 



More information about the Checkins mailing list