View Single Post
Old 03-01-2010, 01:38 PM   #11
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,440
Karma: 27757438
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Stick the

from TestModule import TestFunction

into the run method

(the module will be in sys.path only during invocation of run, not during adding the plugin, etc.) and dont worry about run_plugins_on_import, in this case it is used automatically.

Also just so you know, the next release of calibre will automatically handle the case of plugins with compiled code as well as plugins with only python code.
kovidgoyal is offline   Reply With Quote