

def close(self):
    if self._closed:
        return
    snames = [n for n in dir(self) if n.endswith('socket')]
    for socket in [getattr(socket, name) for name in snames]:
        if (isinstance(socket, zmq.Socket) and (not socket.closed)):
            socket.close()
    self._closed = True

dataset/ETHPy150Open ipython/ipython-py3k/IPython/parallel/client/client.py Client.close/VarMisuse@46/52 `self`->`socket`