How can I return an object from a python-script
Hy, I want to write a python script that have a object-reference of a ZopeDB (e.g. a Folder) as return value. I tried the following inside the folder 'test': # return context.this() # But this does not work? Zope returns a "Resource not found" -error: <!-- Traceback (innermost last): File /usr/src/packages/BUILD/Zope-2.3.1-src/lib/python/ZPublisher/Publish.py, line 223, in publish_module File /usr/src/packages/BUILD/Zope-2.3.1-src/lib/python/ZPublisher/Publish.py, line 187, in publish File /usr/src/packages/BUILD/Zope-2.3.1-src/lib/python/Zope/__init__.py, line 221, in zpublisher_exception_hook (Object: Traversable) File /usr/src/packages/BUILD/Zope-2.3.1-src/lib/python/ZPublisher/Publish.py, line 173, in publish File /usr/src/packages/BUILD/Zope-2.3.1-src/lib/python/ZPublisher/HTTPResponse.py, line 308, in setBody File /usr/src/packages/BUILD/Zope-2.3.1-src/lib/python/ZPublisher/HTTPResponse.py, line 547, in notFoundError NotFound: (see above) --> Is there any way to return object-refernces from python-scripts? Thanks Atti ______________________________________________________________________________ E*TRADE - neu in Deutschland. Jetzt Depot eröffnen + Prämie erhalten http://etrade.web.de
On Tuesday 08 January 2002 09:31 am, attila.keller@web.de allegedly wrote:
Hy,
I want to write a python script that have a object-reference of a ZopeDB (e.g. a Folder) as return value.
I tried the following inside the folder 'test':
# return context.this() #
You could simply do return context But I don't think there is any utilitly in that. Describe what you are trying to do in more detail. /---------------------------------------------------\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association c.duncan@nlada.org \---------------------------------------------------/
participants (2)
-
attila.keller@web.de -
Casey Duncan