From 63b4d4b494d57c90461740d0700af15ae4420618 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Wed, 29 Jan 2014 13:12:03 -0800 Subject: asyncio: _fatal_error() of _UnixWritePipeTransport and _ProactorBasePipeTransport shouldn't log BrokenPipeError nor ConnectionResetError. (Same behaviour as _SelectorTransport._fatal_error().) --- Lib/asyncio/unix_events.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Lib/asyncio/unix_events.py') diff --git a/Lib/asyncio/unix_events.py b/Lib/asyncio/unix_events.py index 219c88a0ff9..a1aff3f146a 100644 --- a/Lib/asyncio/unix_events.py +++ b/Lib/asyncio/unix_events.py @@ -363,7 +363,8 @@ class _UnixWritePipeTransport(transports.WriteTransport): def _fatal_error(self, exc): # should be called by exception handler only - logger.exception('Fatal error for %s', self) + if not isinstance(exc, (BrokenPipeError, ConnectionResetError)): + logger.exception('Fatal error for %s', self) self._close(exc) def _close(self, exc=None): -- cgit v1.2.3