You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mod_python-dev@quetz.apache.org by Geert Jansen <ge...@boskant.nl> on 2003/01/18 12:53:36 UTC

Re: [mod_python] mod_python and Python 2.3

On Fri, Jan 17, 2003 at 03:44:09PM -0800, Josh Hoyt wrote:
> Hello,
> 
> I'm trying to get mod_python working with python 2.3, and I've run into
> some problems related to module importing. For some reason, it fails to
> import the site module. The same setup works with Python 2.2, so I'm
> pretty sure that it has something to do with the Python version and not
> the configuration. Running with Python in verbose mode, the following
> shows up in the apache error log file:

This is a Python bug in Py_NewInterpreter() (or in some other place that
makes Py_NewInterpreter() fail). I sumbitted it to the Python developers
but I got no reply yet. The bug is described here:

http://sourceforge.net/tracker/index.php?func=detail&aid=668708&group_id=5470&atid=105470

Greetings,
Geert

Re: [mod_python] mod_python and Python 2.3

Posted by Josh Hoyt <jo...@janrain.com>.
> This is a Python bug in Py_NewInterpreter() (or in some other place that
> makes Py_NewInterpreter() fail). I sumbitted it to the Python developers
> but I got no reply yet. The bug is described here:
> 
> http://sourceforge.net/tracker/index.php?func=detail&aid=668708&group_id=5470&atid=105470

The problem appears to be that meta_path is not being
initialized in the new interpreter. Adding
_PyImportHooks_Init to Py_NewInterpreter seems to fix the
problem, initializing the new import hooks before trying to
import modules into the new interpreter.

Patch 671459 contains this fix.

Yeah for mod_python in Python 2.3!

Josh