[Zope] strange namespace behaviour (was: Re: ZClass Bug)

Dieter Maurer dieter@handshake.de
Fri, 8 Sep 2000 20:24:44 +0200 (CEST)

Hi Tim,

Tim Hicks writes:
 > ....
 > The "theatre_class" ZClass constructor "theatre_class_add"
 > raises a NameError "theatre_class" in
 > <dtml-with "theatre_class.createInObjectManager(REQUEST['id'],
 > if called in some folders but not in other folders ....

 > When I try to copy and paste a zclass in these folders,
 > I get the error ...
 > "One or more items referred to in the clipboard data was not found.
 > The item may have been moved or deleted after you copied it."
 > ... In the other folders, everything is fine ....

 > When I try to rename a class in these folders, it raises an
 > AttributeError in "ObjectManager(236)._getOb", Object "Traversable".
 > ... In the other folders, everything is fine ....

I tried to reproduce the behavior in my vanilla Zope 2.2.1.
Not only, I was unable to do that (as I expected).
I was also unable to reproduce your original "id" problem!
Zope 2.2.1 apparently no longer has the bug, I analysed for
Zope 2.1.6.

Did you do your 2.2.1 check by exporting your site from 2.1.6
and importing it into Zope 2.2.1? If so, then probably
Zope 2.2.1 is very confused by the strange Zope 2.1.6 ZClasses.

Please rebuild your "theatre_class" ZClass from scratch in
Zope 2.2.1 (at the same place, it is in Zope 2.1.6!).
Create an instance and check whether the id bug
is still present -- as I said, I do no longer see this bug.
If the bug is no longer there, give your ZInstances Id's
in Zope 2.1.6 (by renaming). Then export them and reimport
into Zope 2.2.1 (you may try with a single one; if it works
do it with all).

If you still see this strange folder dependent behavior, then,
you may have lost parts of your site.
Maybe, DC can help you in this case as sites exported from
2.1.6 should be importable into 2.2.1.
I will not analyse such an export/import problem
(unless I get myself hit).
If you *rebuild* your ZInstances *from scratch* in 2.2.1
(start with a few) and you continue to see the strange
folder dependent behavior, you may contact me again.
Obviously, such a thing should not happen.