@inlineCallbacks<EOL><INDENT>def wait_for_service(self, name):<DEDENT>
client = self.get_client()<EOL>from pop.utils import local_machine_uuid<EOL>uuid = local_machine_uuid()<EOL>yield client.connect()<EOL>path = self.path + "<STR_LIT>" + name + "<STR_LIT>"<EOL>value, metadata = yield client.get_or_wait(<EOL>path, str(uuid)<EOL>)<EOL>yield client.close()<EOL>state = json.loads(value)<EOL>returnValue(state)<EOL>
Wait for a service to appear and return state.