[Zope] Draft CatalogAware Howto and ZClass question
Alexandre Ratti
ratti@dial.oleane.com
Sun, 17 Oct 1999 20:16:29 +0100
Hello,
I started putting together a Howto on creating a CatalogAware ZClass. I
mainly cut and pasted information from this list.
The 1st draft can be viewed on
<http://www.zope.org/Members/AlexR/CatalogAware/>. If you find inaccuracies
or can offer additional information, please get in touch. This howto hasn't
been submitted for cataloging yet.
The process described in this howto seems to work. New object instances are
indexed correctly when created and updated. They are deindexed when deleted.
However, I run into the following error when trying to cut and paste an
object instance.
Error Type: AttributeError
Error Value: REQUEST
Traceback (innermost last):
File D:\ZOPE\GISTI\lib\python\ZPublisher\Publish.py, line 214, in
publish_module
File D:\ZOPE\GISTI\lib\python\ZPublisher\Publish.py, line 179, in publish
File D:\ZOPE\GISTI\lib\python\Zope\__init__.py, line 201, in
zpublisher_exception_hook
(Object: ElementWithAttributes)
File D:\ZOPE\GISTI\lib\python\ZPublisher\Publish.py, line 165, in publish
File D:\ZOPE\GISTI\lib\python\ZPublisher\mapply.py, line 160, in mapply
(Object: manage_pasteObjects)
File D:\ZOPE\GISTI\lib\python\ZPublisher\Publish.py, line 102, in
call_object
(Object: manage_pasteObjects)
File D:\ZOPE\GISTI\lib\python\OFS\CopySupport.py, line 225, in
manage_pasteObjects
(Object: ElementWithAttributes)
File D:\ZOPE\GISTI\lib\python\OFS\ObjectManager.py, line 264, in _delObject
(Object: ElementWithAttributes)
File D:\Zope\Gisti\lib\python\Products\ZCatalog\CatalogAwareness.py,
line 130, in manage_beforeDelete
(Object: testPDF1)
File D:\Zope\Gisti\lib\python\Products\ZCatalog\CatalogAwareness.py,
line 187, in unindex_object
(Object: testPDF1)
File D:\Zope\Gisti\lib\python\Products\ZCatalog\CatalogAwareness.py,
line 157, in url
(Object: testPDF1)
File D:\ZOPE\GISTI\lib\python\OFS\SimpleItem.py, line 316, in absolute_url
(Object: testPDF1)
AttributeError: (see above)
The error occurs on this line in the Python module:
if not relative: url.append(self.aq_acquire('REQUEST').script)
Something seems wrong in the absolute_url. Can anyone help?
Thanks.
Alexandre