[Zope-Checkins] CVS: Zope2 - Property.py:1.32

shane@digicool.com shane@digicool.com
Thu, 7 Jun 2001 18:18:47 -0400 (EDT)


Update of /cvs-repository/Zope2/lib/python/ZClasses
In directory korak.digicool.com:/tmp/cvs-serv16812/ZClasses

Modified Files:
	Property.py 
Log Message:
The _need__name__ protocol assigns a name to DTMLMethods implicitly
so that ExtensionClass can find the correct <name>__roles__ attribute
of the method's class.  However it was discovered that this protocol
has a flaw: if a DTMLMethod is bound to multiple names, there is no
way for default__class_init__ to tell which name is the right one.

This change adds code that detects the condition and makes the name
explicit in all places where it occurs in the Zope core.  There are
likely products out there that have the same condition so they will
need a small correction.  For now this is a warning but it might be
appropriate to later make the condition an error.



--- Updated File Property.py in package Zope2 --
--- Property.py	2001/04/16 20:43:13	1.31
+++ Property.py	2001/06/07 22:18:46	1.32
@@ -388,6 +388,7 @@
     manage=Globals.DTMLFile('OFS/dtml/main',
                             management_view='Property Sheets')
     manage_main = manage
+    manage_main._setName('manage_main')
     manage_addCommonSheetForm=Globals.DTMLFile('dtml/addCommonSheet',
                                                globals())