[mod_python] mod_python + apache + winxp => could not import mod_python.apache

Jim Gallacher jpg at jgassociates.ca
Mon Apr 10 11:08:00 EDT 2006


cyberco wrote:
>   On my system:
> 
> =============
> mod_python 3.2.8
> apache 2.0.55
> python2.4
> winxp
> =============
> 
> When I try to load a .py file I get the error:
> ==============
> [Sun Apr 09 14:03:46 2006] [error] make_obcallback: could not import
> mod_python.apache.\n
> [Sun Apr 09 14:03:46 2006] [error] python_handler: no interpreter callback
> found.
> [Sun Apr 09 14:03:46 2006] [error] [client 192.168.2.100] python_handler:
> Can't get/create interpreter., referer:
> http://myserver/test/
> ==============
> 

<snip>

> where mptest.py contains:
> ==============
> from mod_python import _apache
> def handler(req):
>     req.content_type = 'text/plain'
>     req.write("Hello World!")
>     return apache.OK
> ==============
> 

Unrelated, but when you do get mod_python working, your mptest.py script 
will fail. There is no mod_python._apache module. It should read

from mod_python import apache.

Jim


More information about the Mod_python mailing list