[Zope] importing an existing python module into Zope python script?
Rachel Willmer
rachel_lists at willmer.org
Wed Jan 28 11:38:56 EST 2004
This *must* be a FAQ, but I haven't found the answer anywhere despite
all day looking...
I've got an existing python module with a large amount of code in it
which I want to use both inside Zope and outside in existing python
programs. The module is still under development so will change frequently.
Two burning questions:
a) How do I get access to the module within Zope ?
b) What do I then need to do to keep the versions in sync?
As far as I can see, I have at least 3 alternatives to question (a).
i) Copy it all into Zope, each function as a separate Zope python script
(Ugh! and this then makes keeping it in sync outside Zope pretty darned
difficult...)
ii) Keep the module as-is and add an External Method in Zope for each
function that will be called from a Zope script. Pretty awful but
do-able. But then I think I need to do something else in the Zope
Management Interface each time I change the module? Is that right?
iii) Rewrite it all as a Zope Product?
There must be an easier answer that has eluded me to date....
Any answers appreciated...
Rachel
More information about the Zope
mailing list