<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _SendItem(self, zmq_socket, item, block=True):
 """Attempts to send an item to a ZeroMQ socket. Args: zmq_socket (zmq.Socket):
 used to the send the item. item (object):
 sent on the queue. Will be pickled prior to sending. block (Optional[bool]):
 whether the push should be performed in blocking or non-blocking mode. Returns: bool: whether the item was sent successfully. """

    try:
      logger.debug('{0:s} sending item'.format(self.name))
      if block:
        zmq_socket.send_pyobj(item)
      else:
        zmq_socket.send_pyobj(item, zmq.DONTWAIT)
      logger.debug('{0:s} sent item'.format(self.name))
      return True

    except zmq.error.Again:
      logger.debug('{0:s} could not send an item'.format(self.name))

    except zmq.error.ZMQError as exception:
      if exception.errno == errno.EINTR:
        logger.error(
            'ZMQ syscall interrupted in {0:s}.'.format(
                self.name))

    return False