[Zope] Python Method to Update ZCatalog

Williams, Rhian Rhian.Williams@commerzbankib.com
Fri, 2 May 2003 10:28:26 +0200

I am trying to write a python script to update a Zcatalog object which I can
then run automatically via Xron.
Below is the method I am trying to call, I do not know how to set the
parameters properly
manage_catalogReindex(REQUEST, RESPONSE, URL1) 
Below is my attempt and the resultant errors

context.myCatalog.manage_catalogReindex(context.REQUEST, context.RESPONSE,
return "completed"

myCatalog = ZCatalog object, myFolder = the folder in which the catalog
object is saved

I receive the following error

Error Type: AttributeError
Error Value: RESPONSE

Traceback (innermost last):
  File D:\Zope\lib\python\ZPublisher\Publish.py, line 150, in publish_module
  File D:\Zope\lib\python\ZPublisher\Publish.py, line 114, in publish
  File D:\Zope\lib\python\Zope\__init__.py, line 158, in
    (Object: rhian)
  File D:\Zope\lib\python\ZPublisher\Publish.py, line 98, in publish
  File D:\Zope\lib\python\ZPublisher\mapply.py, line 88, in mapply
    (Object: test)
  File D:\Zope\lib\python\ZPublisher\Publish.py, line 39, in call_object
    (Object: test)
  File D:\Zope\lib\python\Shared\DC\Scripts\Bindings.py, line 252, in
    (Object: test)
  File D:\Zope\lib\python\Shared\DC\Scripts\Bindings.py, line 283, in
    (Object: test)
  File D:\Zope\lib\python\Products\PythonScripts\PythonScript.py, line 291,
in _exec
    (Object: test)
    (Info: ({'script': &lt;PythonScript instance at 104209B0&gt;, 'context':
&lt;Folder instance at 10292250&gt;, 'container': &lt;Folder instance at
10292250&gt;, 'traverse_subpath': []}, (), {}, None))
  File Script (Python), line 1, in test
  File D:\Zope\lib\python\AccessControl\ZopeGuards.py, line 47, in
    (Object: rhian)
AttributeError: (see above)

Any help greatly appreciated
Rhian Williams
ZIT IB Securities
DLZ 2 01.57.0440
Mainzer Landstr. 153
60327 Frankfurt
Tel: +49 69 136 48319
Fax:+49 69 136 42540