code: def _read_result(self, num_retries):
          '''Read an object from a channel, possibly retrying if the attempt
          is interrupted by a signal from the operating system.'''
          for i in range(num_retries):
              self._assert_alive()
              try:
                  return self._result_channel.get()
              except IOError as ex:
                  if ex.errno == 4:
                      # errno=4 corresponds to "System call interrupted",
                      # which means a signal was recieved before any data
                      # was sent. For now I think it's safe to ignore this
                      # and continue.
                      logger.exception('attempt to read from channel was interrupted by something')
                      sys.exc_clear()
                  else:
                      # Something else went wrong - raise the exception as usual
                      raise ex
  
          raise ChannelError('failed to read from channel after %d retries' % num_retriesf _read_result(self, num_retries):
          '''Read an object from a channel, possibly retrying if the attempt
          is interrupted by a signal from the operating system.'''
          for i in range(num_retries):
              self._assert_alive()
              try:
                  return self._result_channel.get()
              except IOError as ex:
                  if ex.errno == 4:
                      # errno=4 corresponds to "System call interrupted",
                      # which means a signal was recieved before any data
                      # was sent. For now I think it's safe to ignore this
                      # and continue.
                      logger.exception('attempt to read from channel was interrupted by something')
                      sys.exc_clear()
                  else:
                      # Something else went wrong - raise the exception as usual
                      raise ex
  
          raise ChannelError('failed to read from channel after %d retries' % num_retries)
docs: Read an object from a channel, possibly retrying if the attempt
          is interrupted by a signal from the operating system.