Extending embedded python-can extensions be local to a dictionary?
mwkohout at gmail.com
Wed Aug 12 21:44:51 CEST 2009
I've got a multithreaded server-based application that I'd like to use
python to provide plugin support for. At execution time I would like
each call to the plugin/plugins to have their own implementation of
these extension methods.
Looking at http://docs.python.org/extending/embedding.html#extending-embedded-python,
I see how to add functions, but it looks like they are added at a
global scope-not in a particular environment. Is there any way to add
an extension to a local environment but not pollute the global env?
FYI, I'm embedding python 2.6, but I'm more than open to embedding
More information about the Python-list