Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > special case loading modules with imp

Reply
Thread Tools

special case loading modules with imp

 
 
Erendil@aol.com
Guest
Posts: n/a
 
      07-30-2003
Alright, this is my first post here. =) Let's try to get this right?

I have a slight problem right now. I wrote a plugin architecture in Python,
allowing any python app or python using app to use plugins. It's very flexible
and open-ended, except for one thing: It has to use imp to load python source
from files. Now, using imp is not the problem really. The plugin module works
very well as of now, and I've used it lots of my other projects. What I need
to do now is I've read Python code out of an SQLite database into a string, and
I need my plugin module to use imp to load that string of code as a module.
(I don't use import because I simply store the module object in an array. makes
it unloadable later.)

So, I just want to switch from using real files to being able to use strings.
The goal is to get a module object that I can place in an array.

Thanks, Rob.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Imp =?Utf-8?B?U21pbGU=?= Microsoft Certification 0 04-25-2006 05:54 AM
Code Coverage in Verification..IMP Abs VHDL 6 03-07-2006 11:03 AM
Plugin system; imp module head scratch Dave Python 2 12-19-2004 06:41 AM
IMP:ValidationSummary/CustomValidator/ResetBtn SMG ASP .Net 1 07-26-2004 05:06 PM



Advertisments