[mod_python] Traceback in FilterDispatch

Graham Dumpleton graham.dumpleton at gmail.com
Mon Aug 13 19:55:05 EDT 2007


On 14/08/07, Andrew Ryan <andrewr at collab.net> wrote:
> Hi,
>
> I've seen the following traceback -- rarely -- from mod_python in my
> logs. I haven't heard of any user-reported issues with the script that's
> generating it, and I can't duplicate this problem myself. My only guess
> is that it's something related to a connection getting reset during some
> phase of the output filter that this code is running in.
>
>  Traceback (most recent call last):
>    File "/usr/lib/python2.4/site-packages/mod_python/importer.py", line
> 1389, in FilterDispatch
> filter.flush(),
>    IOError: Flush failed.
>
> The offending code is in FilterDispatch:
>             if not filter.closed:
>                 filter.flush()
>
> I'm not sure what the "right" thing to do, this might just be a
> try/"except pass" moment. This is with 3.3.1 and 2.4.3.

Would feasibly occur when the remote client (web browser) closed the
connection before response had been completely received.

Generally relatively easy to simulate by hitting reload button on
browser constantly without waiting for page to complete.

Graham


More information about the Mod_python mailing list