'thorough check of whether the socket has been closed,
even if by another entity (e.g. ctx.destroy).
Only used by the `closed` property.
returns True if closed, False otherwise'

def _check_closed_deep(self):

    if self._closed:
        return True
    try:
        self.get(zmq.TYPE)
    except ZMQError as e:
        if (e.errno == zmq.ENOTSOCK):
            self._closed = True
            return True
        else:
            raise
    return False
