IOError: [Errno 32] Broken pipe

Vinay Sajip vinay_sajip at yahoo.co.uk
Tue Oct 5 09:15:30 EDT 2004


Nigel King <nigel.king at orthogonsystems.com> wrote in message news:<mailman.4079.1096469961.5135.python-list at python.org>...
> I have a problem with the logging module.
> 
> It reports a Broken Pipe error after outputing to the log file 
> occasionally (5%). This does not appear to happen on Mac OSX using 
> current finked python (2.3.3) but does appear to occur on Python 2.3.4 
> running on a very old Redhat Linux xxxxx 2.2.14-5.0 #1 Tue Mar 7 
> 21:07:39 EST 2000 i686. The actual logged error follows my signature. 
> Note that "files used:-" has been sent to the file.
[snip]

This does not seem to be an error with the logging module itself, but
due to the fact that a write to sys.stderr (from the traceback module)
causes the error to be raised. Are you sure that all you need to do is
to set default signal handling for SIGPIPE?

If you set raiseExceptions to false in the logging module, no
exceptions will be raised by the logging module. Otherwise, you can
subclass the handler and override handleError() to treat EPIPE
appropriately.

Regards,


Vinay Sajip



More information about the Python-list mailing list