Example #1
0
def ignore_broken_pipes(self):
    """Ignores unused error message about broken pipe."""
    try:
        ex = BrokenPipeError
    except NameError:
        ex = socket.error
    if sys.exc_info()[0] != ex:
        BaseHandler.__handle_error_original_(self)
Example #2
0
def ignore_broken_pipes(self):
    # pylint: disable=protected-access
    if sys.version_info[0] > 2:
        # pylint: disable=undefined-variable
        if sys.exc_info()[0] != BrokenPipeError:  # noqa
            BaseHandler.__handle_error_original_(self)