[Zope-dev] PythonMethods: Can't Slice context.REQUEST.PARENTS

Evan Simpson evan@4-am.com
Mon, 13 Nov 2000 10:44:42 -0500


From: The Doctor What <docwhat@gerf.org>
> Using context.this().id, self.this().id, m_self.this().id
all get me
> the same things:
> Folder, Zope, and my method.  None give me the DTML
Document
> foo_html.
>
> This would seem to be an important thing.

The only information about your caller that you can get is
the contents of their namespace.  So, in the final release,
you would be able to bind the caller's namespace to "_" and
write _.this().id.  That requires a change to Zope, though,
so it doesn't work yet.  You *could* work around this by
explicitly passing the namespace (or this(), for that
matter).

Cheers,

Evan @ digicool & 4-am