)]}'
{"neutron/common/utils.py":[{"author":{"_account_id":11975,"name":"Slawek Kaplonski","email":"skaplons@redhat.com","username":"slaweq"},"change_message_id":"d6feefff63c4a208157dcc8d55a04fa1ab0c635b","unresolved":false,"context_lines":[{"line_number":794,"context_line":"                 \u0027%s.\u0027, service_plugin.__class__.__name__)"},{"line_number":795,"context_line":""},{"line_number":796,"context_line":""},{"line_number":797,"context_line":"def get_port_ip_set(port):"},{"line_number":798,"context_line":"    return set([ip[\"ip_address\"] for ip in port.get(\"fixed_ips\", [])])"},{"line_number":799,"context_line":""},{"line_number":800,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"3f79a3b5_829262fb","line":797,"updated":"2018-10-01 07:52:28.000000000","message":"nit: I would name it \"get_fixed_ips_set\"","commit_id":"b76bfcc48d28b5bf9c86311dfd19a690e1928fd6"},{"author":{"_account_id":11975,"name":"Slawek Kaplonski","email":"skaplons@redhat.com","username":"slaweq"},"change_message_id":"d6feefff63c4a208157dcc8d55a04fa1ab0c635b","unresolved":false,"context_lines":[{"line_number":806,"context_line":"            len(original_port.get(\"fixed_ips\", []))):"},{"line_number":807,"context_line":"        return True"},{"line_number":808,"context_line":""},{"line_number":809,"context_line":"    if (get_port_ip_set(new_port) !\u003d get_port_ip_set(original_port)):"},{"line_number":810,"context_line":"        return True"},{"line_number":811,"context_line":""},{"line_number":812,"context_line":"    return False"}],"source_content_type":"text/x-python","patch_set":3,"id":"3f79a3b5_a2975eeb","line":809,"updated":"2018-10-01 07:52:28.000000000","message":"How it can be that fixed_ips lists of new_port and original_port will be the same in L805-806 but sets of IPs will be different?","commit_id":"b76bfcc48d28b5bf9c86311dfd19a690e1928fd6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"e611f7c1d4f4510715951344e60850c594a602b3","unresolved":false,"context_lines":[{"line_number":806,"context_line":"            len(original_port.get(\"fixed_ips\", []))):"},{"line_number":807,"context_line":"        return True"},{"line_number":808,"context_line":""},{"line_number":809,"context_line":"    if (get_port_ip_set(new_port) !\u003d get_port_ip_set(original_port)):"},{"line_number":810,"context_line":"        return True"},{"line_number":811,"context_line":""},{"line_number":812,"context_line":"    return False"}],"source_content_type":"text/x-python","patch_set":3,"id":"3f79a3b5_632865ed","line":809,"in_reply_to":"3f79a3b5_a2975eeb","updated":"2018-10-01 13:24:02.000000000","message":"[1, 2] is not equal to [2, 1]. And [1, 2] is not equal to [3, 4].","commit_id":"b76bfcc48d28b5bf9c86311dfd19a690e1928fd6"},{"author":{"_account_id":27654,"name":"Hongbin Lu","email":"kira034@163.com","username":"hongbin.lu"},"change_message_id":"4942c9f2dcee35cda52762ac56732be2a5e429c1","unresolved":false,"context_lines":[{"line_number":802,"context_line":"    if not new_port or not original_port:"},{"line_number":803,"context_line":"        return False"},{"line_number":804,"context_line":""},{"line_number":805,"context_line":"    # Quantity is not same, so it is changed."},{"line_number":806,"context_line":"    if (len(new_port.get(\"fixed_ips\", [])) !\u003d"},{"line_number":807,"context_line":"            len(original_port.get(\"fixed_ips\", []))):"},{"line_number":808,"context_line":"        return True"},{"line_number":809,"context_line":""},{"line_number":810,"context_line":"    # IPs can be placed in any order, so use python set to verify the"},{"line_number":811,"context_line":"    # fixed IP addresses."}],"source_content_type":"text/x-python","patch_set":4,"id":"3f79a3b5_b893e65b","line":808,"range":{"start_line":805,"start_character":0,"end_line":808,"end_character":19},"updated":"2018-10-02 20:27:23.000000000","message":"nit: it looks this can be removed since the set comparison below should handle the inequality of the quantity?","commit_id":"3c7e3735a1c21f1543c2ef7d6838eba35c2ad131"},{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"8766efdf0159e1906b7e6b87a2661094e14e6866","unresolved":false,"context_lines":[{"line_number":802,"context_line":"    if not new_port or not original_port:"},{"line_number":803,"context_line":"        return False"},{"line_number":804,"context_line":""},{"line_number":805,"context_line":"    # Quantity is not same, so it is changed."},{"line_number":806,"context_line":"    if (len(new_port.get(\"fixed_ips\", [])) !\u003d"},{"line_number":807,"context_line":"            len(original_port.get(\"fixed_ips\", []))):"},{"line_number":808,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_c65e8b50","line":805,"range":{"start_line":805,"start_character":4,"end_line":805,"end_character":45},"updated":"2018-10-09 03:16:35.000000000","message":"Is there a possible that the new updated port contains two or more fixed ips same as original port? And IMO compared as a set can cover this case.","commit_id":"0a95e97a4abe45aa7f62c75b9fa6270d001f7b37"},{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"780dfcc4ba9cc7a2aab935990cc51c8ae7cb1c9c","unresolved":false,"context_lines":[{"line_number":802,"context_line":"    if not new_port or not original_port:"},{"line_number":803,"context_line":"        return False"},{"line_number":804,"context_line":""},{"line_number":805,"context_line":"    # Quantity is not same, so it is changed."},{"line_number":806,"context_line":"    if (len(new_port.get(\"fixed_ips\", [])) !\u003d"},{"line_number":807,"context_line":"            len(original_port.get(\"fixed_ips\", []))):"},{"line_number":808,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_97fbdb79","line":805,"range":{"start_line":805,"start_character":4,"end_line":805,"end_character":45},"in_reply_to":"3f79a3b5_9cb6a289","updated":"2018-10-09 05:20:27.000000000","message":"Done","commit_id":"0a95e97a4abe45aa7f62c75b9fa6270d001f7b37"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"be462c62a6adbda7e11df2d436640d60038ec413","unresolved":false,"context_lines":[{"line_number":802,"context_line":"    if not new_port or not original_port:"},{"line_number":803,"context_line":"        return False"},{"line_number":804,"context_line":""},{"line_number":805,"context_line":"    # Quantity is not same, so it is changed."},{"line_number":806,"context_line":"    if (len(new_port.get(\"fixed_ips\", [])) !\u003d"},{"line_number":807,"context_line":"            len(original_port.get(\"fixed_ips\", []))):"},{"line_number":808,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_9cb6a289","line":805,"range":{"start_line":805,"start_character":4,"end_line":805,"end_character":45},"in_reply_to":"3f79a3b5_c65e8b50","updated":"2018-10-09 04:45:54.000000000","message":"No, ml2 will ensure no duplicated IP in the fixed_ips. And length is simple and well-understanding.","commit_id":"0a95e97a4abe45aa7f62c75b9fa6270d001f7b37"},{"author":{"_account_id":1131,"name":"Brian Haley","email":"haleyb.dev@gmail.com","username":"brian-haley"},"change_message_id":"a53da0ce3fdbe16ed4e537eab564ade474cf0b9d","unresolved":false,"context_lines":[{"line_number":795,"context_line":""},{"line_number":796,"context_line":""},{"line_number":797,"context_line":"def get_port_fixed_ips_set(port):"},{"line_number":798,"context_line":"    return set([ip[\"ip_address\"] for ip in port.get(\"fixed_ips\", [])])"},{"line_number":799,"context_line":""},{"line_number":800,"context_line":""},{"line_number":801,"context_line":"def port_ip_changed(new_port, original_port):"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f79a3b5_b464bcb4","line":798,"range":{"start_line":798,"start_character":19,"end_line":798,"end_character":20},"updated":"2018-10-10 00:12:18.000000000","message":"super nit: there\u0027s very few occurrences of \" in the tree, most use \u0027","commit_id":"452b2824125641128b5297fcf84de090e0763740"},{"author":{"_account_id":17120,"name":"Manjeet Singh Bhatia","email":"manjeet.s.bhatia@intel.com","username":"manjeets"},"change_message_id":"d28e607f6a42584381730193ab1a7cf7d7a01868","unresolved":false,"context_lines":[{"line_number":802,"context_line":"    if not new_port or not original_port:"},{"line_number":803,"context_line":"        return False"},{"line_number":804,"context_line":""},{"line_number":805,"context_line":"    # Quantity is not same, so it is changed."},{"line_number":806,"context_line":"    if (len(new_port.get(\"fixed_ips\", [])) !\u003d"},{"line_number":807,"context_line":"            len(original_port.get(\"fixed_ips\", []))):"},{"line_number":808,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f79a3b5_77bcff06","line":805,"range":{"start_line":805,"start_character":5,"end_line":805,"end_character":26},"updated":"2018-10-09 05:03:34.000000000","message":"rephrase: if length of the fixed ip\u0027s different then there\u0027s an update.","commit_id":"452b2824125641128b5297fcf84de090e0763740"}],"neutron/db/l3_dvrscheduler_db.py":[{"author":{"_account_id":11975,"name":"Slawek Kaplonski","email":"skaplons@redhat.com","username":"slaweq"},"change_message_id":"d6feefff63c4a208157dcc8d55a04fa1ab0c635b","unresolved":false,"context_lines":[{"line_number":524,"context_line":"        is_fixed_ips_changed \u003d ("},{"line_number":525,"context_line":"            \u0027fixed_ips\u0027 in new_port and"},{"line_number":526,"context_line":"            \u0027fixed_ips\u0027 in original_port and"},{"line_number":527,"context_line":"            new_port[\u0027fixed_ips\u0027] !\u003d original_port[\u0027fixed_ips\u0027])"},{"line_number":528,"context_line":"        if kwargs.get(\u0027mac_address_updated\u0027) or is_fixed_ips_changed:"},{"line_number":529,"context_line":"            l3plugin.update_arp_entry_for_dvr_service_port("},{"line_number":530,"context_line":"                context, new_port)"}],"source_content_type":"text/x-python","patch_set":3,"id":"3f79a3b5_4298ca18","side":"PARENT","line":527,"updated":"2018-10-01 07:52:28.000000000","message":"Isn\u0027t this check enough (only move it to L436)? Do we really need those 2 additional functions in common.utils?","commit_id":"bf6844fba11ee90066d3783b45ef735f8db6f827"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"e611f7c1d4f4510715951344e60850c594a602b3","unresolved":false,"context_lines":[{"line_number":524,"context_line":"        is_fixed_ips_changed \u003d ("},{"line_number":525,"context_line":"            \u0027fixed_ips\u0027 in new_port and"},{"line_number":526,"context_line":"            \u0027fixed_ips\u0027 in original_port and"},{"line_number":527,"context_line":"            new_port[\u0027fixed_ips\u0027] !\u003d original_port[\u0027fixed_ips\u0027])"},{"line_number":528,"context_line":"        if kwargs.get(\u0027mac_address_updated\u0027) or is_fixed_ips_changed:"},{"line_number":529,"context_line":"            l3plugin.update_arp_entry_for_dvr_service_port("},{"line_number":530,"context_line":"                context, new_port)"}],"source_content_type":"text/x-python","patch_set":3,"id":"3f79a3b5_c3d059f7","side":"PARENT","line":527,"in_reply_to":"3f79a3b5_4298ca18","updated":"2018-10-01 13:24:02.000000000","message":"No, current check is not enough, because such python list, [1, 2] and [2, 1] is not the same. But for gateway port, we can treat this as IP not changed.","commit_id":"bf6844fba11ee90066d3783b45ef735f8db6f827"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a5ab755292093fd6d864593c05824ba02bc3839e","unresolved":false,"context_lines":[{"line_number":524,"context_line":"        is_fixed_ips_changed \u003d ("},{"line_number":525,"context_line":"            \u0027fixed_ips\u0027 in new_port and"},{"line_number":526,"context_line":"            \u0027fixed_ips\u0027 in original_port and"},{"line_number":527,"context_line":"            new_port[\u0027fixed_ips\u0027] !\u003d original_port[\u0027fixed_ips\u0027])"},{"line_number":528,"context_line":"        if kwargs.get(\u0027mac_address_updated\u0027) or is_fixed_ips_changed:"},{"line_number":529,"context_line":"            l3plugin.update_arp_entry_for_dvr_service_port("},{"line_number":530,"context_line":"                context, new_port)"}],"source_content_type":"text/x-python","patch_set":3,"id":"3f79a3b5_63edc58c","side":"PARENT","line":527,"in_reply_to":"3f79a3b5_c3d059f7","updated":"2018-10-01 13:32:40.000000000","message":"A follow up patch set will use the same utils function, and small and simple function is my favourite.","commit_id":"bf6844fba11ee90066d3783b45ef735f8db6f827"},{"author":{"_account_id":27654,"name":"Hongbin Lu","email":"kira034@163.com","username":"hongbin.lu"},"change_message_id":"4942c9f2dcee35cda52762ac56732be2a5e429c1","unresolved":false,"context_lines":[{"line_number":435,"context_line":""},{"line_number":436,"context_line":"    is_fixed_ips_changed \u003d n_utils.port_ip_changed(new_port, original_port)"},{"line_number":437,"context_line":""},{"line_number":438,"context_line":"    if (original_port[\u0027device_owner\u0027] in"},{"line_number":439,"context_line":"            [n_const.DEVICE_OWNER_HA_REPLICATED_INT,"},{"line_number":440,"context_line":"             n_const.DEVICE_OWNER_ROUTER_SNAT,"},{"line_number":441,"context_line":"             n_const.DEVICE_OWNER_ROUTER_GW] and"},{"line_number":442,"context_line":"            not is_fixed_ips_changed):"},{"line_number":443,"context_line":"        return"},{"line_number":444,"context_line":""},{"line_number":445,"context_line":"    if new_port and original_port:"},{"line_number":446,"context_line":"        l3plugin \u003d directory.get_plugin(plugin_constants.L3)"}],"source_content_type":"text/x-python","patch_set":4,"id":"3f79a3b5_5878928d","line":443,"range":{"start_line":438,"start_character":0,"end_line":443,"end_character":14},"updated":"2018-10-02 20:27:23.000000000","message":"nit: it read better to me if the code is re-written as:\n\n    router_device_owners \u003d [n_const.DEVICE_OWNER_HA_REPLICATED_INT,\n             n_const.DEVICE_OWNER_ROUTER_SNAT,\n             n_const.DEVICE_OWNER_ROUTER_GW]\n    if (original_port[\u0027device_owner\u0027] in router_device_owners and\n            not is_fixed_ips_changed):\n        return","commit_id":"3c7e3735a1c21f1543c2ef7d6838eba35c2ad131"}],"neutron/tests/unit/scheduler/test_l3_agent_scheduler.py":[{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"8766efdf0159e1906b7e6b87a2661094e14e6866","unresolved":false,"context_lines":[{"line_number":1035,"context_line":"                \u0027fixed_ips\u0027: [{\u0027ip_address\u0027: \u00272.2.2.2\u0027}],"},{"line_number":1036,"context_line":"                \u0027mac_address\u0027: \u002702:04:05:17:18:29\u0027"},{"line_number":1037,"context_line":"            },"},{"line_number":1038,"context_line":"            \u0027mac_address_updated\u0027: True"},{"line_number":1039,"context_line":"        }"},{"line_number":1040,"context_line":"        l3plugin \u003d mock.Mock()"},{"line_number":1041,"context_line":"        directory.add_plugin(plugin_constants.L3, l3plugin)"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_f9548824","line":1038,"range":{"start_line":1038,"start_character":12,"end_line":1038,"end_character":39},"updated":"2018-10-09 03:16:35.000000000","message":"It\u0027s better to modify this to False, only cover the fixed ips changed case. We didn\u0027t know the mac_add_updated or is_fixed_ips_changed will call l3plugin.update_arp_entry_for_dvr_service_port.","commit_id":"0a95e97a4abe45aa7f62c75b9fa6270d001f7b37"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"be462c62a6adbda7e11df2d436640d60038ec413","unresolved":false,"context_lines":[{"line_number":1035,"context_line":"                \u0027fixed_ips\u0027: [{\u0027ip_address\u0027: \u00272.2.2.2\u0027}],"},{"line_number":1036,"context_line":"                \u0027mac_address\u0027: \u002702:04:05:17:18:29\u0027"},{"line_number":1037,"context_line":"            },"},{"line_number":1038,"context_line":"            \u0027mac_address_updated\u0027: True"},{"line_number":1039,"context_line":"        }"},{"line_number":1040,"context_line":"        l3plugin \u003d mock.Mock()"},{"line_number":1041,"context_line":"        directory.add_plugin(plugin_constants.L3, l3plugin)"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_77371fdd","line":1038,"range":{"start_line":1038,"start_character":12,"end_line":1038,"end_character":39},"in_reply_to":"3f79a3b5_f9548824","updated":"2018-10-09 04:45:54.000000000","message":"Done","commit_id":"0a95e97a4abe45aa7f62c75b9fa6270d001f7b37"},{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"8766efdf0159e1906b7e6b87a2661094e14e6866","unresolved":false,"context_lines":[{"line_number":1062,"context_line":"                \u0027fixed_ips\u0027: [{\u0027ip_address\u0027: \u00271.1.1.1\u0027}],"},{"line_number":1063,"context_line":"                \u0027mac_address\u0027: \u002702:04:05:17:18:29\u0027"},{"line_number":1064,"context_line":"            },"},{"line_number":1065,"context_line":"            \u0027mac_address_updated\u0027: True"},{"line_number":1066,"context_line":"        }"},{"line_number":1067,"context_line":"        l3plugin \u003d mock.Mock()"},{"line_number":1068,"context_line":"        directory.add_plugin(plugin_constants.L3, l3plugin)"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_1925c4bf","line":1065,"range":{"start_line":1065,"start_character":12,"end_line":1065,"end_character":39},"updated":"2018-10-09 03:16:35.000000000","message":"ditto","commit_id":"0a95e97a4abe45aa7f62c75b9fa6270d001f7b37"},{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"780dfcc4ba9cc7a2aab935990cc51c8ae7cb1c9c","unresolved":false,"context_lines":[{"line_number":1062,"context_line":"                \u0027fixed_ips\u0027: [{\u0027ip_address\u0027: \u00271.1.1.1\u0027}],"},{"line_number":1063,"context_line":"                \u0027mac_address\u0027: \u002702:04:05:17:18:29\u0027"},{"line_number":1064,"context_line":"            },"},{"line_number":1065,"context_line":"            \u0027mac_address_updated\u0027: True"},{"line_number":1066,"context_line":"        }"},{"line_number":1067,"context_line":"        l3plugin \u003d mock.Mock()"},{"line_number":1068,"context_line":"        directory.add_plugin(plugin_constants.L3, l3plugin)"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_17d6ebf3","line":1065,"range":{"start_line":1065,"start_character":12,"end_line":1065,"end_character":39},"in_reply_to":"3f79a3b5_1746eb51","updated":"2018-10-09 05:20:27.000000000","message":"Yes.","commit_id":"0a95e97a4abe45aa7f62c75b9fa6270d001f7b37"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"be462c62a6adbda7e11df2d436640d60038ec413","unresolved":false,"context_lines":[{"line_number":1062,"context_line":"                \u0027fixed_ips\u0027: [{\u0027ip_address\u0027: \u00271.1.1.1\u0027}],"},{"line_number":1063,"context_line":"                \u0027mac_address\u0027: \u002702:04:05:17:18:29\u0027"},{"line_number":1064,"context_line":"            },"},{"line_number":1065,"context_line":"            \u0027mac_address_updated\u0027: True"},{"line_number":1066,"context_line":"        }"},{"line_number":1067,"context_line":"        l3plugin \u003d mock.Mock()"},{"line_number":1068,"context_line":"        directory.add_plugin(plugin_constants.L3, l3plugin)"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_1746eb51","line":1065,"range":{"start_line":1065,"start_character":12,"end_line":1065,"end_character":39},"in_reply_to":"3f79a3b5_1925c4bf","updated":"2018-10-09 04:45:54.000000000","message":"This has nothing to do with the check here:\nhttps://review.openstack.org/#/c/606385/5/neutron/db/l3_dvrscheduler_db.py@436 - 422. And if check return False, no code will be run further.\n\nSo removed.","commit_id":"0a95e97a4abe45aa7f62c75b9fa6270d001f7b37"}]}
