[mod_python] This is just friggin' weird...

Jim Gallacher jg.lists at sympatico.ca
Thu Jun 23 19:14:04 EDT 2005

Graham Dumpleton wrote:
> On 24/06/2005, at 8:38 AM, Joshua Ginsberg wrote:
>> Okay, discovering new stuff all the time... I backed out my last 
>> changes to the code and it works great... the last change was that I 
>> added as the first line to my PSP page:
>> psp.set_error_page('error.psp')
>> When I comment this out, I get the error on psp.redirect() that I've 
>> already send data back to the client -- it's talking about the 
>> debugging code I put in to triage this issue.
>> Why would this make things run amok?
> Are you accessing the "session" object in the error page?
> I have no access to mod_python source code right now to check,
> but vaguely remember that if error page tries to access "session"
> object it will deadlock. This is part of the reasons for having the
> PSP object check if req.session exists and use it instead of creating
> a new one each time, as proposed in one of the JIRA bug reports
> I have posted. I'll post the JIRA link later.

This is solved with the req.get_session() code that I've checked into 
svn trunk. See http://issues.apache.org/jira/browse/MODPYTHON-59


More information about the Mod_python mailing list