mod_python + publisher + psp + session problems

exhuma.twn exhuma at gmail.com
Mon Mar 20 15:40:22 CET 2006


grahamd at dscpl.com.au wrote:
> exhuma.twn wrote:
> > Hi again,
> >
> > as soon as I try to make use of the "session" object inside a
> > psp-template file, I get the following error:
> >
> > Mod_python error: "PythonHandler mod_python.publisher"
> >
> > Traceback (most recent call last):
> >
> >   File "/usr/lib/python2.4/site-packages/mod_python/apache.py", line
> > 299, in HandlerDispatch
> >     result = object(req)
> >
> >   File "/usr/lib/python2.4/site-packages/mod_python/publisher.py", line
> > 143, in handler
> >     result = str(result)
> >
> >   File "/usr/lib/python2.4/site-packages/mod_python/psp.py", line 228,
> > in __str__
> >     self.run()
> >
> >   File "/usr/lib/python2.4/site-packages/mod_python/psp.py", line 191,
> > in run
> >     session = Session.Session(req)
> >
> >   File "/usr/lib/python2.4/site-packages/mod_python/Session.py", line
> > 389, in Session
> >     timeout=timeout, lock=lock)
> >
> >   File "/usr/lib/python2.4/site-packages/mod_python/Session.py", line
> > 294, in __init__
> >     timeout=timeout, lock=lock)
> >
> >   File "/usr/lib/python2.4/site-packages/mod_python/Session.py", line
> > 132, in __init__
> >     Cookie.add_cookie(self._req, self.make_cookie())
> >
> >   File "/usr/lib/python2.4/site-packages/mod_python/Session.py", line
> > 160, in make_cookie
> >     c.path = dirpath[len(docroot):]
> >
> > TypeError: unsubscriptable object
> >
> > Any ideas?
>
> Upgrade to mod_python 3.2.8 and your problem will go away.
>
> See:
>
>   http://issues.apache.org/jira/browse/MODPYTHON-50
>
> I suggest that in future you use the mod_python mailing list for
> questions
> as that is where most knowledgeable people on mod_python hang out.
> 
> Graham

Thanks a lot Graham. This solved the problem.




More information about the Python-list mailing list