Edward,
You wrote:
>Hello,
>
>I only have a handful of interpreters in my current app, but I was looking
>at the PythonInterpreter source code, and I see that it is a lightweight
>object.
>I have an implementation that might be easier in separate interpreters,
>except that I would need a few hundred! Is this a bad idea? I am more
>curious than anything, since I will probably leave things as they are.
It will work, but you might need to be careful with sys.modules.
Almost a month ago there was some discussion on isolating PythonInterpreters
and later on import being thread safe or not.
Have a look at the archives of jython-dev. The opening message of
11 Feb 2002 had the title:
"[Jython-dev] Static usage in jython - can we have less of it?"
And on 12 Feb: "[Jython-dev] Thread safeness"
Have fun,
Ype
--
|