Unload Modules
Mark Hammond
MarkH at ActiveState.com
Thu Nov 9 22:28:37 EST 2000
Curtis Jensen wrote:
> I can't seem to find a clear answer on this, but how do I remove an
> imported module? I have some C modules that I import, the modules only
> contain function calls. However, they are pretty big, and I'd like to
> unload these modules after I am done with them, in order to save on
> memory. I don't have the source for these modules.
>
> How can I unload these modules from within Python? Thanks.
You can't. If you search deja, you will find a novel trick by Christian
Tismer that will work on Windows, if you are lucky, and nothing in
Python has changed recently, and the day doesnt have a T in it...
Mark.
More information about the Python-list
mailing list