[Zope] Python calling files from ancestor directories?
Wed, 12 Jun 2002 20:44:32 +0200
Alec Munro writes:
> Any idea how I can use Python to call a file two directories up?
> So if my python script is at:
> And I want it to return the file:
What do you mean with "call" or "return"?
I assume you are in a Python Script. Then you can (usually) access
"root.nah.someFile" by "context.nah.someFile".
In order for this to work, "/root/nah" must be "nearest" (with respect to
acquisition search order) "nah" to "context".
It would, e.g., not work from "/root/blah/nah/someScript".