[Zope-Checkins] SVN: Zope/branches/2.10/lib/python/Products/ Updated Zope to use Five revision so copying site.zcml is no longer mandatory.
Log message for revision 68416: Updated Zope to use Five revision so copying site.zcml is no longer mandatory. Changed: _U Zope/branches/2.10/lib/python/Products/ -=- Property changes on: Zope/branches/2.10/lib/python/Products ___ Name: svn:externals - Five svn://svn.zope.org/repos/main/Products.Five/tags/1.5c + Five-r 68410 svn://svn.zope.org/repos/main/Products.Five/trunk ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins
[Zope-Checkins] SVN: Zope/trunk/lib/python/Products/PageTemplates/PageTemplateFile.py Merged r68414 from 2.10 branch:
Log message for revision 68415: Merged r68414 from 2.10 branch: There must be no warning when __name__ is supplied. Changed: U Zope/trunk/lib/python/Products/PageTemplates/PageTemplateFile.py -=- Modified: Zope/trunk/lib/python/Products/PageTemplates/PageTemplateFile.py === --- Zope/trunk/lib/python/Products/PageTemplates/PageTemplateFile.py 2006-05-31 17:59:21 UTC (rev 68414) +++ Zope/trunk/lib/python/Products/PageTemplates/PageTemplateFile.py 2006-05-31 18:00:30 UTC (rev 68415) @@ -59,15 +59,13 @@ _default_bindings = {'name_subpath': 'traverse_subpath'} def __init__(self, filename, _prefix=None, **kw): -name = None -if kw.has_key('__name__'): -name = kw['__name__'] -del kw['__name__'] +name = kw.pop('__name__', None) basepath, ext = os.path.splitext(filename) if name: self.id = self.__name__ = name +self._need__name__ = 0 else: self.id = self.__name__ = os.path.basename(basepath) ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins
[Zope-Checkins] SVN: Zope/branches/2.10/lib/python/Products/PageTemplates/PageTemplateFile.py There must be no warning when __name__ is supplied.
Log message for revision 68414: There must be no warning when __name__ is supplied. Changed: U Zope/branches/2.10/lib/python/Products/PageTemplates/PageTemplateFile.py -=- Modified: Zope/branches/2.10/lib/python/Products/PageTemplates/PageTemplateFile.py === --- Zope/branches/2.10/lib/python/Products/PageTemplates/PageTemplateFile.py 2006-05-31 17:36:17 UTC (rev 68413) +++ Zope/branches/2.10/lib/python/Products/PageTemplates/PageTemplateFile.py 2006-05-31 17:59:21 UTC (rev 68414) @@ -59,15 +59,13 @@ _default_bindings = {'name_subpath': 'traverse_subpath'} def __init__(self, filename, _prefix=None, **kw): -name = None -if kw.has_key('__name__'): -name = kw['__name__'] -del kw['__name__'] +name = kw.pop('__name__', None) basepath, ext = os.path.splitext(filename) if name: self.id = self.__name__ = name +self._need__name__ = 0 else: self.id = self.__name__ = os.path.basename(basepath) ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins
[Zope-Checkins] SVN: Zope/trunk/lib/python/Products/ Updated reference to a Five version that turned the site.zcml error into a warning.
Log message for revision 68411: Updated reference to a Five version that turned the site.zcml error into a warning. Changed: _U Zope/trunk/lib/python/Products/ -=- Property changes on: Zope/trunk/lib/python/Products ___ Name: svn:externals - Five svn://svn.zope.org/repos/main/Products.Five/tags/1.5c + Five-r 68410 svn://svn.zope.org/repos/main/Products.Five/trunk ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins
[Zope-Checkins] SVN: Products.Five/trunk/zcml.py Replaced error when missing site.zcml with a warning.
Log message for revision 68410: Replaced error when missing site.zcml with a warning. Changed: U Products.Five/trunk/zcml.py -=- Modified: Products.Five/trunk/zcml.py === --- Products.Five/trunk/zcml.py 2006-05-31 13:38:24 UTC (rev 68409) +++ Products.Five/trunk/zcml.py 2006-05-31 15:12:29 UTC (rev 68410) @@ -15,6 +15,7 @@ $Id$ """ +import warnings import os from zope.configuration import xmlconfig @@ -33,6 +34,7 @@ # load instance site configuration file site_zcml = os.path.join(INSTANCE_HOME, "etc", "site.zcml") skel_site_zcml = os.path.join(INSTANCE_HOME, "skel", "etc", "site.zcml") +skel_site2_zcml = os.path.join(ZOPE_HOME, "skel", "etc", "site.zcml") if os.path.exists(site_zcml): file = site_zcml @@ -40,11 +42,12 @@ # check for zope installation home skel during running unit tests file = skel_site_zcml else: -msg = "site.zcml is now required to live at '%s', for " \ - "sites upgraded from Zope 2.9 please copy site.zcml " \ - "from your installed Zope's skel/etc directory" \ - % site_zcml -raise IOError(msg) +file = skel_site2_zcml +msg = "site.zcml should now live at '%s', for " \ + "sites upgraded from Zope 2.9 please copy '%s' " \ + "to '%s'" \ + % (site_zcml, skel_site2_zcml, site_zcml) +warnings.warn(msg, DeprecationWarning) global _context _context = xmlconfig.file(file) ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins