[Python-Dev] multiple interpreters and extension modules

Josiah Carlson jcarlson at uci.edu
Sat Dec 23 01:02:32 CET 2006


Jeremy Kloth <jeremy.kloth at 4suite.org> wrote:
> [[ This may be somewhat c.l.p.-ish but I feel that this crossed into CPython 
> development enough to merit posting here ]]
> 
> I have received a bug report for 4Suite that involves a PyObject_IsInstance 
> check failing for what appears to be the correct class, that is, the class 
> names match.  With some investigating, I have found that the true problem is 
> with multiple interpreters.  The reason for this is that each sub-interpreter 
> has a "new" copy of any pure Python module. The following issues are also 
> true for modules that have been reloaded, but I think that is common 
> knowledge.  I mention it only for completeness.

If I remember correctly, Python allows you to use multiple interpreters
in the same process, but it makes no guarantees as to their correctness
when running.

See this post for further discussion on the issue:
http://mail.python.org/pipermail/python-list/2004-January/244343.html

You can also search for 'multiple python interpreters single process' in
google without quotes to hear people lament over the (generally broken)
multiple Python interpreter support.


 - Josiah



More information about the Python-Dev mailing list