[SPAM] Re: [mod_python] processing py-scripts with apache 1.3 and mod_python

Nicolas Lehuen nicolas at lehuen.com
Tue Apr 4 15:11:44 EDT 2006


The mod_python version is definitely too old. There are been a LOT of bug
fixes since 2.7.11. Unfortunately the 3.x branch from which the latest
version (3.2.8) is issued requires Apache 2.0.47 or later. If you can
upgrade, then I'd advise you do it now. If you cannot, then be prepared to
use a very deprecated version of mod_python, which is not longer developed
or maintained.

Regards,
Nicolas

2006/4/4, Emanuel Rumpf <x at branwelt.de>:
>
> Colin Bean wrote:
>
> >For starters, try putting quotes around the path in the "Directory"
> section,
> >so:
> >    <Directory "/anydir/py/">
> >
> >Also, chage "PythonHandler mod_python.publisher" to "SetHandler
> >mod_python.publisher".
> >Once you've done this, I don't beleive that you need the PythonPath
> >directive (since it is the same path as the publisher directory), nor the
> >"SetHandler python-program".
> >
> >This doesn't really answer your question in depth, but I beleive that the
> >"SetHandler python-program" directive is only necessisary in older
> >versions(?) of mod_python, in which case you also needed to specify a
> >"PythonHandler" directive.  In your case, the line "SetHandler
> >mod_python.publisher" should be all that's needed.
> >
> >Also, posting relevant snippets of your error logs will help us to
> diagnose
> >further problems.
> >
> >HTH,
> >-Colin
> >
> >
> >On 4/4/06, Emanuel Rumpf <x at branwelt.de> wrote:
> >
> >
> >>Hello,
> >>
> >>I wanted /anydir/py/test.py to be processed by mod_python
> >>on apache 1.3 server, when requesting http://domain.org/py/test.py
> >>(where /anydir/ is the DocumentRoot)
> >>
> >>
> >>No matter, what I tried, there was no success,
> >>either the file was delivered as textfile-download,
> >>or I got a "File not Found" error.
> >>
> >>my current config, which is inside a virtual host:
> >>
> >><Directory /anydir/py/>
> >>                Options -FollowSymLinks +Indexes
> >>                Order allow,deny
> >>                Allow from all
> >>
> >>                PythonPath "sys.path+['/anydir/py/']"
> >>
> >>                #PythonHandler handler_script
> >>                PythonHandler mod_python.publisher
> >>
> >>                PythonDebug On
> >>                PythonInterpreter pi01
> >>
> >>                #excecute those with .py extension
> >>                #AddHandler mod_python .py
> >>
> >>                #excecute those with any extension
> >>                #SetHandler mod_python
> >>                # the same (?):
> >>                SetHandler python-program
> >>
> >></Directory>
> >>
> >>
> >>Any hints, how to make it working?
> >>
> >>Thanks,
> >>Emanuel
> >>
> >>
> >>btw:
> >>What's the diffence between:
> >>SetHandler mod_python
> >>and:
> >>SetHandler python-program
> >>
> >>
> >>
>
>
> SetHandler mod_python.publisher
> Doesn't seem to work. So maybe the mod_python version is too old? (
> mod_python-2.7.11 )
>
> With the following construct, mod_python seems
> to create a directory-index (the view changes of the directory list,
> that's why I assume it),
> but the files still are delivered as plain-text.
>
>
> <FilesMatch "(.*)">
>         Options -FollowSymLinks +Indexes
>         Order allow,deny
>         Allow from all
>
>         #excecute those with .py extension
>         #AddHandler mod_python .py
>
>         PythonHandler mod_python.publisher
>         SetHandler python-program
>         PythonDebug On
>
> </FilesMatch>
>
> There's a message in /var/log/apache/error.log :
> [Tue Apr  4 18:37:57 2006] [notice] mod_python: (Re)importing
> mod_python.publisher from None
>
> Emanuel
>
>
>
>
>
>
> _______________________________________________
> Mod_python mailing list
> Mod_python at modpython.org
> http://mailman.modpython.org/mailman/listinfo/mod_python
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mm_cfg_has_not_been_edited_to_set_host_domains/pipermail/mod_python/attachments/20060404/794a10ac/attachment.html


More information about the Mod_python mailing list