Hello, I'm trying to update my application to use the recent patch that Tres Seaver helpfully landed on zope.app.testing.
The new zope.app.testing seems to require a new zope.component, since it's importing hooks from z.component rather than zope.site. However, when I update zope.component, I get the following error from zope.app.component: Traceback (most recent call last): ... File ".../zope.app.component-3.8.3-py2.5.egg/zope/app/component/metaconfigure.py", line 15, in <module> from zope.component.zcml import PublicPermission, _checker, view, resource ImportError: cannot import name PublicPermission It appears that r83 of lp:zope.component moves PublicPermission from zope.component.zcml to zope.component.security. Now, my app is only using metaconfigure in this instance to get at PublicPermission and view, so I might as well import them from zope.component directly, solving my immediate problem. However, this still leaves zope.app.component broken with new zope.component releases. I can't find the code for zope.app.component on Launchpad, but the fix seems pretty simple – import PublicPermission from z.component.security. It seems to me that zope.component is also broken, since moving PublicPermission to a new module breaks backwards compatibility. I've attached a patch that goes some way to fixing this. More generally, I'm a bit worried that this attempt of mine to upgrade the zope.testing that my app uses is going to result in a cascade of dependency upgrades, each with their own little backwards compatibility problems. What sort of expectations should I have? e.g. Do the version numbers tell me anything about intended compatibility? Thanks, jml
=== modified file 'src/zope/component/zcml.py' --- src/zope/component/zcml.py 2010-04-06 03:01:29 +0000 +++ src/zope/component/zcml.py 2010-04-11 14:24:49 +0000 @@ -30,7 +30,7 @@ try: from zope.component.security import _checker, proxify, protectedFactory, \ securityAdapterFactory - from zope.security.zcml import Permission + from zope.security.zcml import Permission, PublicPermission except ImportError: SECURITY_SUPPORT = False from zope.schema import TextLine as Permission
_______________________________________________ Zope-Dev maillist - Zope-Dev@zope.org https://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope )