)]}'
{"neutron/tests/fullstack/test_l3_agent.py":[{"author":{"_account_id":8313,"name":"Lajos Katona","display_name":"lajoskatona","email":"katonalala@gmail.com","username":"elajkat","status":"Ericsson Software Technology"},"change_message_id":"4aa73deb9539943dde47a3c24561589a35cd09a0","unresolved":false,"context_lines":[{"line_number":235,"context_line":"        else:"},{"line_number":236,"context_line":"            qrouter_ns \u003d self._get_namespace(router[\u0027id\u0027])"},{"line_number":237,"context_line":"        ip \u003d ip_lib.IPWrapper(qrouter_ns)"},{"line_number":238,"context_line":"        common_utils.wait_until_true(lambda: ip.get_devices())"},{"line_number":239,"context_line":""},{"line_number":240,"context_line":"        interface_name \u003d None"},{"line_number":241,"context_line":"        devices \u003d ip.get_devices()"}],"source_content_type":"text/x-python","patch_set":1,"id":"3fa7e38b_a273044f","line":238,"range":{"start_line":238,"start_character":37,"end_line":238,"end_character":61},"updated":"2020-01-20 09:49:47.000000000","message":"Just thinking aloud....\n\nanother way should be to change this lambda to a method which returns True if the returned device list (ip.get_devices()) has at least 1 interface which starts with \"qg-\", then the next check is not necessary.\n\nPerhaps another method wait_until_true_and_return method would be the best to avoid calling once again get_devices()","commit_id":"098bf12c2a12905d681e3b358b6443ee7598db47"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"310772a8194ed1ce1a9dc6b06617d5d8e1e37223","unresolved":false,"context_lines":[{"line_number":235,"context_line":"        else:"},{"line_number":236,"context_line":"            qrouter_ns \u003d self._get_namespace(router[\u0027id\u0027])"},{"line_number":237,"context_line":"        ip \u003d ip_lib.IPWrapper(qrouter_ns)"},{"line_number":238,"context_line":"        common_utils.wait_until_true(lambda: ip.get_devices())"},{"line_number":239,"context_line":""},{"line_number":240,"context_line":"        interface_name \u003d None"},{"line_number":241,"context_line":"        devices \u003d ip.get_devices()"}],"source_content_type":"text/x-python","patch_set":1,"id":"3fa7e38b_a2030411","line":238,"range":{"start_line":238,"start_character":37,"end_line":238,"end_character":61},"in_reply_to":"3fa7e38b_a273044f","updated":"2020-01-20 10:21:51.000000000","message":"With this logic we can specifically wait for the needed interface. I prefer the logic you proposed.\n\nThanks!","commit_id":"098bf12c2a12905d681e3b358b6443ee7598db47"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"13356682eb4b4442500a7246a7c4e1037c7ee14e","unresolved":false,"context_lines":[{"line_number":189,"context_line":"        return found_agents"},{"line_number":190,"context_line":""},{"line_number":191,"context_line":"    def _router_fip_qos_after_admin_state_down_up(self, ha\u003dFalse):"},{"line_number":192,"context_line":"        interface_name \u003d []"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"        def get_router_gw_interface(interface_name):"},{"line_number":195,"context_line":"            devices \u003d ip.get_devices()"}],"source_content_type":"text/x-python","patch_set":2,"id":"3fa7e38b_3d23a3bd","line":192,"range":{"start_line":192,"start_character":8,"end_line":192,"end_character":22},"updated":"2020-01-21 10:43:20.000000000","message":"This is an array, so \u0027interface_names\u0027 sounds better (though we expect only one member in the array).","commit_id":"668a3ced51d13d184d543d76e9b7e95a2eefd951"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"7af38adb6cd9fb87c3645a99dbe43a5d0bd4ac44","unresolved":false,"context_lines":[{"line_number":189,"context_line":"        return found_agents"},{"line_number":190,"context_line":""},{"line_number":191,"context_line":"    def _router_fip_qos_after_admin_state_down_up(self, ha\u003dFalse):"},{"line_number":192,"context_line":"        interface_name \u003d []"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"        def get_router_gw_interface(interface_name):"},{"line_number":195,"context_line":"            devices \u003d ip.get_devices()"}],"source_content_type":"text/x-python","patch_set":2,"id":"3fa7e38b_c38070f9","line":192,"range":{"start_line":192,"start_character":8,"end_line":192,"end_character":22},"in_reply_to":"3fa7e38b_3d23a3bd","updated":"2020-01-21 12:11:18.000000000","message":"You are right.","commit_id":"668a3ced51d13d184d543d76e9b7e95a2eefd951"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"13356682eb4b4442500a7246a7c4e1037c7ee14e","unresolved":false,"context_lines":[{"line_number":191,"context_line":"    def _router_fip_qos_after_admin_state_down_up(self, ha\u003dFalse):"},{"line_number":192,"context_line":"        interface_name \u003d []"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"        def get_router_gw_interface(interface_name):"},{"line_number":195,"context_line":"            devices \u003d ip.get_devices()"},{"line_number":196,"context_line":"            for dev in (dev for dev in devices if dev.name.startswith(\"qg-\")):"},{"line_number":197,"context_line":"                interface_name.append(dev.name)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3fa7e38b_dd5e0f50","line":194,"range":{"start_line":194,"start_character":36,"end_line":194,"end_character":50},"updated":"2020-01-21 10:43:20.000000000","message":"This hides \u0027interface_name\u0027 at L.192. It is better to use a different name.\n\nThe only code which uses this function is functools.partial below, so I think we don\u0027t need to pass \"interface_name\" at L.249. This function modifies \"interface_name\" defined above at L.192 and it is defined in a same (outer) function. Thus I think we can drop \u0027interface_name\" from the argument.","commit_id":"668a3ced51d13d184d543d76e9b7e95a2eefd951"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"7af38adb6cd9fb87c3645a99dbe43a5d0bd4ac44","unresolved":false,"context_lines":[{"line_number":191,"context_line":"    def _router_fip_qos_after_admin_state_down_up(self, ha\u003dFalse):"},{"line_number":192,"context_line":"        interface_name \u003d []"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"        def get_router_gw_interface(interface_name):"},{"line_number":195,"context_line":"            devices \u003d ip.get_devices()"},{"line_number":196,"context_line":"            for dev in (dev for dev in devices if dev.name.startswith(\"qg-\")):"},{"line_number":197,"context_line":"                interface_name.append(dev.name)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3fa7e38b_a37bf428","line":194,"range":{"start_line":194,"start_character":36,"end_line":194,"end_character":50},"in_reply_to":"3fa7e38b_dd5e0f50","updated":"2020-01-21 12:11:18.000000000","message":"That\u0027s correct. The inner method will read the declared variable in the outer function.","commit_id":"668a3ced51d13d184d543d76e9b7e95a2eefd951"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"13356682eb4b4442500a7246a7c4e1037c7ee14e","unresolved":false,"context_lines":[{"line_number":196,"context_line":"            for dev in (dev for dev in devices if dev.name.startswith(\"qg-\")):"},{"line_number":197,"context_line":"                interface_name.append(dev.name)"},{"line_number":198,"context_line":"                return True"},{"line_number":199,"context_line":"            return False"},{"line_number":200,"context_line":""},{"line_number":201,"context_line":"        tenant_id \u003d uuidutils.generate_uuid()"},{"line_number":202,"context_line":"        ext_net, ext_sub \u003d self._create_external_network_and_subnet(tenant_id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3fa7e38b_880b7720","line":199,"updated":"2020-01-21 10:43:20.000000000","message":"The tricky point of this function is that it returns a boolean but it changes a variable \"interface_name\" defined in the outer function.\n\nI explored a better/simpler logic a while.\ncommon_utils.wait_until_true() evaluate a return value of \u0027predicate\" as boolean, so we can just return a list of gateway devices (which starts \u0027qg-\u0027).\nHow about the following?\n\n  def get_router_gw_interface():\n      devices \u003d ip.get_devices()\n      return [dev.name for dev in devices if dev.name.stratswith(\u0027qg-\u0027)]\n\nif so, L.247-253 would be:\n\n  try:\n      common_utils.wait_until_true(get_router_gw_interface)\n  except common_utils.WaitTimeout:\n      ...\n\n  interface_name \u003d get_router_gw_interface()\n  tc_wrapper \u003d l3_tc_lib.FloatingIPTcCommand(interface_name[0], ...)\n   ...\n\nThe negative side is that we need one extra call of get_router_gw_interface, but wait_until_true() calls it multiple times, so I think it doesn\u0027t matter.\n\nThought?","commit_id":"668a3ced51d13d184d543d76e9b7e95a2eefd951"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"7af38adb6cd9fb87c3645a99dbe43a5d0bd4ac44","unresolved":false,"context_lines":[{"line_number":196,"context_line":"            for dev in (dev for dev in devices if dev.name.startswith(\"qg-\")):"},{"line_number":197,"context_line":"                interface_name.append(dev.name)"},{"line_number":198,"context_line":"                return True"},{"line_number":199,"context_line":"            return False"},{"line_number":200,"context_line":""},{"line_number":201,"context_line":"        tenant_id \u003d uuidutils.generate_uuid()"},{"line_number":202,"context_line":"        ext_net, ext_sub \u003d self._create_external_network_and_subnet(tenant_id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3fa7e38b_839b5862","line":199,"in_reply_to":"3fa7e38b_880b7720","updated":"2020-01-21 12:11:18.000000000","message":"I though about this idea and I implemented the current solution to avoid the extra call.\n\nBut this solution is cleaner and the extra call time is irrelevant. Also the result from the last two calls (the one exiting the wait and the last one retrieving the interface name) must be the same.","commit_id":"668a3ced51d13d184d543d76e9b7e95a2eefd951"},{"author":{"_account_id":11975,"name":"Slawek Kaplonski","email":"skaplons@redhat.com","username":"slaweq"},"change_message_id":"b34f308b95249eceaa6f1e190bf5f7701c462e86","unresolved":false,"context_lines":[{"line_number":191,"context_line":"    def _router_fip_qos_after_admin_state_down_up(self, ha\u003dFalse):"},{"line_number":192,"context_line":"        def get_router_gw_interface():"},{"line_number":193,"context_line":"            devices \u003d ip.get_devices()"},{"line_number":194,"context_line":"            return [dev.name for dev in devices if dev.name.stratswith(\u0027qg-\u0027)]"},{"line_number":195,"context_line":""},{"line_number":196,"context_line":"        tenant_id \u003d uuidutils.generate_uuid()"},{"line_number":197,"context_line":"        ext_net, ext_sub \u003d self._create_external_network_and_subnet(tenant_id)"}],"source_content_type":"text/x-python","patch_set":3,"id":"3fa7e38b_7b6b511b","line":194,"range":{"start_line":194,"start_character":60,"end_line":194,"end_character":70},"updated":"2020-01-22 08:25:22.000000000","message":"here is the typo which is causing fullstack tests failure :)","commit_id":"6db32df5359f3e69daccab80ab62f67a0d5f4a92"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"9e4eec6a11025b38bd45023e40fdbe4cf26d76f0","unresolved":false,"context_lines":[{"line_number":191,"context_line":"    def _router_fip_qos_after_admin_state_down_up(self, ha\u003dFalse):"},{"line_number":192,"context_line":"        def get_router_gw_interface():"},{"line_number":193,"context_line":"            devices \u003d ip.get_devices()"},{"line_number":194,"context_line":"            return [dev.name for dev in devices if dev.name.stratswith(\u0027qg-\u0027)]"},{"line_number":195,"context_line":""},{"line_number":196,"context_line":"        tenant_id \u003d uuidutils.generate_uuid()"},{"line_number":197,"context_line":"        ext_net, ext_sub \u003d self._create_external_network_and_subnet(tenant_id)"}],"source_content_type":"text/x-python","patch_set":3,"id":"3fa7e38b_9014e743","line":194,"range":{"start_line":194,"start_character":60,"end_line":194,"end_character":70},"in_reply_to":"3fa7e38b_7b6b511b","updated":"2020-01-22 10:08:07.000000000","message":"Thanks!","commit_id":"6db32df5359f3e69daccab80ab62f67a0d5f4a92"}]}
