def iterOnCommands(self):
        """
        Cancel each command in a node hierarchy (command is given by a generator on the node)
        Each command might be blocked by network pb (or machine swapping) but asynchronous mecanism will
        allow other request to be treated between each command cancelation.
        """
        try:
            # Get next command in generator
            cmd = self.gen.next()
            cmd.cancel()
            tornado.ioloop.IOLoop.instance().add_callback(self.iterOnCommands)
        except __HOLE__:
            self.finish()
dataset/ETHPy150Open mikrosimage/OpenRenderManagement/src/octopus/dispatcher/webservice/nodes.py/NodeStatusResource.iterOnCommands