[Checkins] SVN: Products.CMFCore/trunk/Products/CMFCore/ - removed support for deprecated marker attributes
Yvo Schubbe
y.2009 at wcm-solutions.de
Wed Dec 9 06:36:41 EST 2009
Log message for revision 106326:
- removed support for deprecated marker attributes
Changed:
U Products.CMFCore/trunk/Products/CMFCore/CHANGES.txt
U Products.CMFCore/trunk/Products/CMFCore/DirectoryView.py
U Products.CMFCore/trunk/Products/CMFCore/PortalFolder.py
U Products.CMFCore/trunk/Products/CMFCore/TypesTool.py
U Products.CMFCore/trunk/Products/CMFCore/WorkflowTool.py
-=-
Modified: Products.CMFCore/trunk/Products/CMFCore/CHANGES.txt
===================================================================
--- Products.CMFCore/trunk/Products/CMFCore/CHANGES.txt 2009-12-09 11:34:08 UTC (rev 106325)
+++ Products.CMFCore/trunk/Products/CMFCore/CHANGES.txt 2009-12-09 11:36:40 UTC (rev 106326)
@@ -4,6 +4,10 @@
2.3.0-alpha (unreleased)
------------------------
+- Tools and PortalFolder: Removed support for deprecated marker attributes.
+ '_isDirectoryView', '_isPortalRoot', '_isTypeInformation' and '_isAWorkflow'
+ are no longer supported.
+
- utils: Removed deprecated functions.
'getToolByInterfaceName', 'initializeBasesPhase1', 'initializeBasesPhase2',
'expandpath' and 'minimalpath' are no longer available.
Modified: Products.CMFCore/trunk/Products/CMFCore/DirectoryView.py
===================================================================
--- Products.CMFCore/trunk/Products/CMFCore/DirectoryView.py 2009-12-09 11:34:08 UTC (rev 106325)
+++ Products.CMFCore/trunk/Products/CMFCore/DirectoryView.py 2009-12-09 11:36:40 UTC (rev 106326)
@@ -487,13 +487,6 @@
while ob:
if IDirectoryView.providedBy(ob):
ob = aq_parent(ob)
- elif getattr(ob, '_isDirectoryView', 0):
- # BBB
- warn("The '_isDirectoryView' marker attribute is deprecated, "
- "and will be removed in CMF 2.3. Please mark the "
- "instance with the 'IDirectoryView' interface instead.",
- DeprecationWarning, stacklevel=2)
- ob = aq_parent(ob)
else:
break
return ob
Modified: Products.CMFCore/trunk/Products/CMFCore/PortalFolder.py
===================================================================
--- Products.CMFCore/trunk/Products/CMFCore/PortalFolder.py 2009-12-09 11:34:08 UTC (rev 106325)
+++ Products.CMFCore/trunk/Products/CMFCore/PortalFolder.py 2009-12-09 11:36:40 UTC (rev 106326)
@@ -18,7 +18,6 @@
import base64
import marshal
import re
-from warnings import warn
from AccessControl.SecurityInfo import ClassSecurityInfo
from AccessControl.SecurityManagement import getSecurityManager
@@ -336,14 +335,6 @@
while ob is not None:
if ISiteRoot.providedBy(ob):
break
- # BBB
- if getattr(ob, '_isPortalRoot', False):
- warn("The '_isPortalRoot' marker attribute for site "
- "roots is deprecated and will be removed in "
- "CMF 2.3; please mark the root object with "
- "'ISiteRoot' instead.",
- DeprecationWarning, stacklevel=2)
- break
ob = aq_parent(ob)
if ob is not None:
Modified: Products.CMFCore/trunk/Products/CMFCore/TypesTool.py
===================================================================
--- Products.CMFCore/trunk/Products/CMFCore/TypesTool.py 2009-12-09 11:34:08 UTC (rev 106325)
+++ Products.CMFCore/trunk/Products/CMFCore/TypesTool.py 2009-12-09 11:36:40 UTC (rev 106326)
@@ -747,13 +747,6 @@
ob = getattr( self, contentType, None )
if ITypeInformation.providedBy(ob):
return ob
- if getattr(aq_base(ob), '_isTypeInformation', 0):
- # BBB
- warn("The '_isTypeInformation' marker attribute is deprecated, "
- "and will be removed in CMF 2.3. Please mark the instance "
- "with the 'ITypeInformation' interface instead.",
- DeprecationWarning, stacklevel=2)
- return ob
else:
return None
@@ -770,14 +763,6 @@
# types for which the user does not have adequate permission.
if ITypeInformation.providedBy(t):
rval.append(t)
- elif getattr(aq_base(t), '_isTypeInformation', 0):
- # BBB
- warn("The '_isTypeInformation' marker attribute is "
- "deprecated, and will be removed in CMF 2.3. "
- "Please mark the instance with the 'ITypeInformation' "
- "interface instead.",
- DeprecationWarning, stacklevel=2)
- rval.append(t)
# Skip items with no ID: old signal for "not ready"
rval = [t for t in rval if t.getId()]
# check we're allowed to access the type object
Modified: Products.CMFCore/trunk/Products/CMFCore/WorkflowTool.py
===================================================================
--- Products.CMFCore/trunk/Products/CMFCore/WorkflowTool.py 2009-12-09 11:34:08 UTC (rev 106325)
+++ Products.CMFCore/trunk/Products/CMFCore/WorkflowTool.py 2009-12-09 11:36:40 UTC (rev 106326)
@@ -16,7 +16,6 @@
"""
import sys
-from warnings import warn
from AccessControl.SecurityInfo import ClassSecurityInfo
from AccessControl.requestmethod import postonly
@@ -468,14 +467,6 @@
wf = getattr(self, wf_id, None)
if IWorkflowDefinition.providedBy(wf):
return wf
- if getattr(wf, '_isAWorkflow', False):
- # BBB
- warn("The '_isAWorkflow' marker attribute for workflow "
- "definitions is deprecated and will be removed in "
- "CMF 2.3; please mark the definition with "
- "'IWorkflowDefinition' instead.",
- DeprecationWarning, stacklevel=2)
- return wf
else:
return None
@@ -494,23 +485,12 @@
security.declarePrivate('getWorkflowIds')
def getWorkflowIds(self):
-
""" Return the list of workflow ids.
"""
wf_ids = []
-
for obj_name, obj in self.objectItems():
if IWorkflowDefinition.providedBy(obj):
wf_ids.append(obj_name)
- elif getattr(obj, '_isAWorkflow', 0):
- # BBB
- warn("The '_isAWorkflow' marker attribute for workflow "
- "definitions is deprecated and will be removed in "
- "CMF 2.3; please mark the definition with "
- "'IWorkflowDefinition' instead.",
- DeprecationWarning, stacklevel=2)
- wf_ids.append(obj_name)
-
return tuple(wf_ids)
security.declareProtected(ManagePortal, 'getWorkflowsFor')
More information about the checkins
mailing list