[Checkins] SVN: Products.CMFCore/branches/2.2/Products/CMFCore/Extensions/migrateToCMF21.py - remove code that has turned into a GenericSetup upgrade step
Jens Vagelpohl
jens at dataflake.org
Wed Dec 9 12:56:27 EST 2009
Log message for revision 106347:
- remove code that has turned into a GenericSetup upgrade step
in CMFDefault.
Changed:
U Products.CMFCore/branches/2.2/Products/CMFCore/Extensions/migrateToCMF21.py
-=-
Modified: Products.CMFCore/branches/2.2/Products/CMFCore/Extensions/migrateToCMF21.py
===================================================================
--- Products.CMFCore/branches/2.2/Products/CMFCore/Extensions/migrateToCMF21.py 2009-12-09 17:21:36 UTC (rev 106346)
+++ Products.CMFCore/branches/2.2/Products/CMFCore/Extensions/migrateToCMF21.py 2009-12-09 17:56:27 UTC (rev 106347)
@@ -17,9 +17,6 @@
$Id$
"""
-from zope.component import getSiteManager
-from zope.dottedname.resolve import resolve
-from zope.site.hooks import setSite
from logging import getLogger
import sys
import transaction
@@ -35,22 +32,6 @@
, 'Products.CMFActionIcons:actionicons' : 'portal_actionicons'
}
-# These are utilities that were registered in CMF 2.1 pre-releases but
-# are no longer present.
-BAD_UTILITIES = [
- 'Products.CMFCalendar.interfaces.ICalendarTool',
- 'Products.CMFCore.interfaces.IActionsTool',
- 'Products.CMFCore.interfaces.ICatalogTool',
- 'Products.CMFCore.interfaces.IContentTypeRegistry',
- 'Products.CMFCore.interfaces.ISkinsTool',
- 'Products.CMFCore.interfaces.ITypesTool',
- 'Products.CMFCore.interfaces.IURLTool',
- 'Products.CMFCore.interfaces.IConfigurableWorkflowTool',
- 'Products.CMFCore.interfaces.IMembershipTool',
- 'Products.CMFCore.interfaces.IMetadataTool',
- 'Products.CMFCore.interfaces.IRegistrationTool',
- ]
-
def _log(msg):
logger.info(msg)
print msg
@@ -64,20 +45,6 @@
_log(' - converting site at %s' % site_path)
ps = site.portal_setup
- # We have to call setSite to make sure we have a site with a proper
- # acquisition context.
- setSite(site)
-
- # First we remove utility registrations that are no longer
- # needed.
- sm = getSiteManager(site)
- for util in BAD_UTILITIES:
- iface = resolve(util)
- if sm.queryUtility(iface) is not None:
- sm.unregisterUtility(provided=iface)
-
- # Next we need to run items from the default CMF Site profile
-
# Check if we have new-style action providers, if not we need to
# run the action provider step from CMFDefault:default as well
if not site.portal_actions.objectIds(['CMF Action Category']):
More information about the checkins
mailing list