[Zope] problem with External Methods

marc lindahl marc@bowery.com
Mon, 30 Apr 2001 23:27:11 -0400


Hi Chris,

> You can't use a class object as a function... in this case, you're defining
> the function name in the external method as "mp3info", which is a class,
> which is why you're getting this error.
> 
> I don't see any functions at all in the file you posted.  An external method
> wraps a Python function.  Passing instances of classes defined in an
> external method is tricky as well, even if you are using a function.

Yeah, the file is just a class.  So if I put this line in the file:

m = mp3info()

Then I could import m?

> 
> It seems like you really want to be building a Product.  See the Zope
> Developer's Guide at http://www.zope.org/Documentation/ZDG for information
> on how to do this.

Yeah, that's what I'm working on...  I was trying to do it with ZClasses, to
make dealing with the property sheets easier, but I kinda figured out how to
do that in python, so I'm just doing the whole thing in python.

I'm sure I'll have lots more questions before I'm done :)