)]}'
{"neutron/plugins/ml2/drivers/openvswitch/agent/ovs_neutron_agent.py":[{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"2ecc1651e3f7861b31e5bc669f8e108b3edf630f","unresolved":false,"context_lines":[{"line_number":784,"context_line":"                self.conf.host)"},{"line_number":785,"context_line":"            for dev in devices_set.get(\u0027failed_devices_up\u0027):"},{"line_number":786,"context_line":"                failed_devices[\u0027added\u0027].add(dev)"},{"line_number":787,"context_line":"                LOG.error(_LE(\"Configuration for device %s failed!\"),"},{"line_number":788,"context_line":"                          dev)"},{"line_number":789,"context_line":"            for dev in devices_set.get(\u0027failed_devices_down\u0027):"},{"line_number":790,"context_line":"                failed_devices[\u0027removed\u0027].add(dev)"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_e9a152f9","line":787,"updated":"2015-08-11 21:04:55.000000000","message":"Maybe say \"for up device\" here and \"for down device\" on L791, so user knows which type of failure?","commit_id":"cbc98b9a122732d1a7193797f3cf56db52096c53"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"3470e0426fbf852340f0cd68c0ee7034a55896e0","unresolved":false,"context_lines":[{"line_number":784,"context_line":"                self.conf.host)"},{"line_number":785,"context_line":"            for dev in devices_set.get(\u0027failed_devices_up\u0027):"},{"line_number":786,"context_line":"                failed_devices[\u0027added\u0027].add(dev)"},{"line_number":787,"context_line":"                LOG.error(_LE(\"Configuration for device %s failed!\"),"},{"line_number":788,"context_line":"                          dev)"},{"line_number":789,"context_line":"            for dev in devices_set.get(\u0027failed_devices_down\u0027):"},{"line_number":790,"context_line":"                failed_devices[\u0027removed\u0027].add(dev)"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_6c145e43","line":787,"in_reply_to":"1a4dcd0f_e9a152f9","updated":"2015-08-12 08:43:35.000000000","message":"Good idea","commit_id":"cbc98b9a122732d1a7193797f3cf56db52096c53"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"2ecc1651e3f7861b31e5bc669f8e108b3edf630f","unresolved":false,"context_lines":[{"line_number":1344,"context_line":"                                               self.conf.host))"},{"line_number":1345,"context_line":"        failed_devices.extend(devices_set_up.get(\u0027failed_devices_up\u0027))"},{"line_number":1346,"context_line":"        LOG.info(_LI(\"Ancillary Ports %(added)s added, failed devices\""},{"line_number":1347,"context_line":"                     \"  %(failed)s\"), {\u0027added\u0027: devices,"},{"line_number":1348,"context_line":"                                       \u0027failed\u0027: failed_devices})"},{"line_number":1349,"context_line":"        return failed_devices"},{"line_number":1350,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_89f0cefe","line":1347,"updated":"2015-08-11 21:04:55.000000000","message":"nit: extra space","commit_id":"cbc98b9a122732d1a7193797f3cf56db52096c53"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"3470e0426fbf852340f0cd68c0ee7034a55896e0","unresolved":false,"context_lines":[{"line_number":1344,"context_line":"                                               self.conf.host))"},{"line_number":1345,"context_line":"        failed_devices.extend(devices_set_up.get(\u0027failed_devices_up\u0027))"},{"line_number":1346,"context_line":"        LOG.info(_LI(\"Ancillary Ports %(added)s added, failed devices\""},{"line_number":1347,"context_line":"                     \"  %(failed)s\"), {\u0027added\u0027: devices,"},{"line_number":1348,"context_line":"                                       \u0027failed\u0027: failed_devices})"},{"line_number":1349,"context_line":"        return failed_devices"},{"line_number":1350,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_0c883a70","line":1347,"in_reply_to":"1a4dcd0f_89f0cefe","updated":"2015-08-12 08:43:35.000000000","message":"Done","commit_id":"cbc98b9a122732d1a7193797f3cf56db52096c53"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"2ecc1651e3f7861b31e5bc669f8e108b3edf630f","unresolved":false,"context_lines":[{"line_number":1444,"context_line":""},{"line_number":1445,"context_line":"    def process_ancillary_network_ports(self, port_info):"},{"line_number":1446,"context_line":"        failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1447,"context_line":"        if \u0027added\u0027 in port_info and port_info[\u0027added\u0027]:"},{"line_number":1448,"context_line":"            start \u003d time.time()"},{"line_number":1449,"context_line":"            failed_added \u003d self.treat_ancillary_devices_added("},{"line_number":1450,"context_line":"                port_info[\u0027added\u0027])"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_09183e1d","line":1447,"updated":"2015-08-11 21:04:55.000000000","message":"Lots of similar code in the added and removed if clauses. Consider a helper function that is passed \u0027added\u0027/\u0027removed\u0027 string as well and call with each having it update the corresponding failed_devices entry.","commit_id":"cbc98b9a122732d1a7193797f3cf56db52096c53"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"3470e0426fbf852340f0cd68c0ee7034a55896e0","unresolved":false,"context_lines":[{"line_number":1444,"context_line":""},{"line_number":1445,"context_line":"    def process_ancillary_network_ports(self, port_info):"},{"line_number":1446,"context_line":"        failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1447,"context_line":"        if \u0027added\u0027 in port_info and port_info[\u0027added\u0027]:"},{"line_number":1448,"context_line":"            start \u003d time.time()"},{"line_number":1449,"context_line":"            failed_added \u003d self.treat_ancillary_devices_added("},{"line_number":1450,"context_line":"                port_info[\u0027added\u0027])"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_acd90658","line":1447,"in_reply_to":"1a4dcd0f_09183e1d","updated":"2015-08-12 08:43:35.000000000","message":"the symmetry was there before this patch. I\u0027d leave this kind of cleanup for later if you agree, don\u0027t want to make this diff bigger.","commit_id":"cbc98b9a122732d1a7193797f3cf56db52096c53"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"2ecc1651e3f7861b31e5bc669f8e108b3edf630f","unresolved":false,"context_lines":[{"line_number":1455,"context_line":"                       \u0027elapsed\u0027: time.time() - start})"},{"line_number":1456,"context_line":"            for dev in failed_added:"},{"line_number":1457,"context_line":"                failed_devices[\u0027added\u0027].add(dev)"},{"line_number":1458,"context_line":"            #port_info[\u0027current\u0027] \u003d (port_info[\u0027current\u0027] -"},{"line_number":1459,"context_line":"            #                        set(failed_added))"},{"line_number":1460,"context_line":""},{"line_number":1461,"context_line":"        if \u0027removed\u0027 in port_info and port_info[\u0027removed\u0027]:"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_29b97a15","line":1458,"updated":"2015-08-11 21:04:55.000000000","message":"dead code","commit_id":"cbc98b9a122732d1a7193797f3cf56db52096c53"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"3470e0426fbf852340f0cd68c0ee7034a55896e0","unresolved":false,"context_lines":[{"line_number":1455,"context_line":"                       \u0027elapsed\u0027: time.time() - start})"},{"line_number":1456,"context_line":"            for dev in failed_added:"},{"line_number":1457,"context_line":"                failed_devices[\u0027added\u0027].add(dev)"},{"line_number":1458,"context_line":"            #port_info[\u0027current\u0027] \u003d (port_info[\u0027current\u0027] -"},{"line_number":1459,"context_line":"            #                        set(failed_added))"},{"line_number":1460,"context_line":""},{"line_number":1461,"context_line":"        if \u0027removed\u0027 in port_info and port_info[\u0027removed\u0027]:"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_cc7d726e","line":1458,"in_reply_to":"1a4dcd0f_29b97a15","updated":"2015-08-12 08:43:35.000000000","message":"Done","commit_id":"cbc98b9a122732d1a7193797f3cf56db52096c53"},{"author":{"_account_id":8976,"name":"shihanzhang","email":"ayshihanzhang@gmail.com","username":"shihanzhang"},"change_message_id":"ed452b4a3bd7eb5fe84df3592618ffd87aba31da","unresolved":false,"context_lines":[{"line_number":1698,"context_line":"                    LOG.exception(_LE(\"Error while synchronizing tunnels\"))"},{"line_number":1699,"context_line":"                    tunnel_sync \u003d True"},{"line_number":1700,"context_line":"            ovs_restarted |\u003d (ovs_status \u003d\u003d constants.OVS_RESTARTED)"},{"line_number":1701,"context_line":"            resync_devices \u003d (failed_devices or failed_ancillary_devices or"},{"line_number":1702,"context_line":"                              devices_not_ready_yet)"},{"line_number":1703,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"},{"line_number":1704,"context_line":"                    or resync_devices):"}],"source_content_type":"text/x-python","patch_set":13,"id":"da20952f_b2ec5290","line":1701,"updated":"2015-08-28 09:00:54.000000000","message":"failed_devices, failed_ancillary_devices are all not empty dict, so resync_devices will always be True","commit_id":"5d6d68d30d39445f68b92ba267f1c8e46615773f"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"fb3aa10c072ab376ae91375735e78ec35f0146a8","unresolved":false,"context_lines":[{"line_number":1698,"context_line":"                    LOG.exception(_LE(\"Error while synchronizing tunnels\"))"},{"line_number":1699,"context_line":"                    tunnel_sync \u003d True"},{"line_number":1700,"context_line":"            ovs_restarted |\u003d (ovs_status \u003d\u003d constants.OVS_RESTARTED)"},{"line_number":1701,"context_line":"            resync_devices \u003d (failed_devices or failed_ancillary_devices or"},{"line_number":1702,"context_line":"                              devices_not_ready_yet)"},{"line_number":1703,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"},{"line_number":1704,"context_line":"                    or resync_devices):"}],"source_content_type":"text/x-python","patch_set":13,"id":"da20952f_5a5b8854","line":1701,"in_reply_to":"da20952f_b2ec5290","updated":"2015-08-28 10:42:09.000000000","message":"thanks","commit_id":"5d6d68d30d39445f68b92ba267f1c8e46615773f"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"9b637a1aa72670ce790af72c59b4312acb5289c4","unresolved":false,"context_lines":[{"line_number":1087,"context_line":"                br.set_db_attribute(\u0027Interface\u0027, phys_if_name,"},{"line_number":1088,"context_line":"                                    \u0027options:peer\u0027, int_if_name)"},{"line_number":1089,"context_line":""},{"line_number":1090,"context_line":"    def update_stale_ofport_rules(self, failed_devices):"},{"line_number":1091,"context_line":"        # right now the ARP spoofing rules are the only thing that utilizes"},{"line_number":1092,"context_line":"        # ofport-based rules, so make arp_spoofing protection a conditional"},{"line_number":1093,"context_line":"        # until something else uses ofport"}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_7af7ded2","line":1090,"updated":"2015-09-01 12:10:41.000000000","message":"unused argument?","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"599a16ba8e5f924ef9338c596dab06990cf6415d","unresolved":false,"context_lines":[{"line_number":1087,"context_line":"                br.set_db_attribute(\u0027Interface\u0027, phys_if_name,"},{"line_number":1088,"context_line":"                                    \u0027options:peer\u0027, int_if_name)"},{"line_number":1089,"context_line":""},{"line_number":1090,"context_line":"    def update_stale_ofport_rules(self, failed_devices):"},{"line_number":1091,"context_line":"        # right now the ARP spoofing rules are the only thing that utilizes"},{"line_number":1092,"context_line":"        # ofport-based rules, so make arp_spoofing protection a conditional"},{"line_number":1093,"context_line":"        # until something else uses ofport"}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_c5db9d4e","line":1090,"in_reply_to":"da20952f_7af7ded2","updated":"2015-09-01 16:22:18.000000000","message":"it is used, check line 1753","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"9b637a1aa72670ce790af72c59b4312acb5289c4","unresolved":false,"context_lines":[{"line_number":1422,"context_line":"                                               self.conf.host))"},{"line_number":1423,"context_line":"        failed_devices.extend(devices_set_up.get(\u0027failed_devices_up\u0027))"},{"line_number":1424,"context_line":"        LOG.info(_LI(\"Ancillary Ports %(added)s added, failed devices\""},{"line_number":1425,"context_line":"                     \" %(failed)s\"), {\u0027added\u0027: devices,"},{"line_number":1426,"context_line":"                                      \u0027failed\u0027: failed_devices})"},{"line_number":1427,"context_line":"        return failed_devices"},{"line_number":1428,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_bab1f6e1","line":1425,"updated":"2015-09-01 12:10:41.000000000","message":"iirc, we commonly cut strings AFTER a space:\n\n  LOG.info(_LI(\"Ancillary Ports %(added)s added, failed devices \"\n                     \"%(failed)s\"), ...)","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"599a16ba8e5f924ef9338c596dab06990cf6415d","unresolved":false,"context_lines":[{"line_number":1422,"context_line":"                                               self.conf.host))"},{"line_number":1423,"context_line":"        failed_devices.extend(devices_set_up.get(\u0027failed_devices_up\u0027))"},{"line_number":1424,"context_line":"        LOG.info(_LI(\"Ancillary Ports %(added)s added, failed devices\""},{"line_number":1425,"context_line":"                     \" %(failed)s\"), {\u0027added\u0027: devices,"},{"line_number":1426,"context_line":"                                      \u0027failed\u0027: failed_devices})"},{"line_number":1427,"context_line":"        return failed_devices"},{"line_number":1428,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_45f1cd94","line":1425,"in_reply_to":"da20952f_bab1f6e1","updated":"2015-09-01 16:22:18.000000000","message":"Done","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"9b637a1aa72670ce790af72c59b4312acb5289c4","unresolved":false,"context_lines":[{"line_number":1436,"context_line":"                                                          self.conf.host)"},{"line_number":1437,"context_line":"        for dev in devices_down.get(\u0027failed_devices_down\u0027):"},{"line_number":1438,"context_line":"            failed_devices[\u0027removed\u0027].add(dev)"},{"line_number":1439,"context_line":"            LOG.debug(\"Port removal failed for %(devices)s \", dev)"},{"line_number":1440,"context_line":"        for device in devices:"},{"line_number":1441,"context_line":"            self.port_unbound(device)"},{"line_number":1442,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_5ad45aea","line":1439,"updated":"2015-09-01 12:10:41.000000000","message":"it should be %s instead of %(devices)s","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"599a16ba8e5f924ef9338c596dab06990cf6415d","unresolved":false,"context_lines":[{"line_number":1436,"context_line":"                                                          self.conf.host)"},{"line_number":1437,"context_line":"        for dev in devices_down.get(\u0027failed_devices_down\u0027):"},{"line_number":1438,"context_line":"            failed_devices[\u0027removed\u0027].add(dev)"},{"line_number":1439,"context_line":"            LOG.debug(\"Port removal failed for %(devices)s \", dev)"},{"line_number":1440,"context_line":"        for device in devices:"},{"line_number":1441,"context_line":"            self.port_unbound(device)"},{"line_number":1442,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_251619a8","line":1439,"in_reply_to":"da20952f_5ad45aea","updated":"2015-09-01 16:22:18.000000000","message":"Done","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"d765fd33dbe59442a973347bfa08bc52554088ac","unresolved":false,"context_lines":[{"line_number":1701,"context_line":"            resync_devices \u003d ("},{"line_number":1702,"context_line":"                failed_devices[\u0027added\u0027] or failed_devices[\u0027removed\u0027] or"},{"line_number":1703,"context_line":"                failed_ancillary_devices[\u0027added\u0027] or failed_ancillary_devices["},{"line_number":1704,"context_line":"                    \u0027removed\u0027] or devices_not_ready_yet[\u0027devices\u0027] or"},{"line_number":1705,"context_line":"                devices_not_ready_yet[\u0027ancillary_devices\u0027])"},{"line_number":1706,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"},{"line_number":1707,"context_line":"                    or resync_devices):"}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_0662493e","line":1704,"updated":"2015-08-31 12:14:29.000000000","message":"May be more readable, with one condition per line...\n\n    resync_devices \u003d (failed_devices[\u0027added\u0027] or\n                      failed_devices[\u0027removed\u0027] or\n                      ...)","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"9b637a1aa72670ce790af72c59b4312acb5289c4","unresolved":false,"context_lines":[{"line_number":1701,"context_line":"            resync_devices \u003d ("},{"line_number":1702,"context_line":"                failed_devices[\u0027added\u0027] or failed_devices[\u0027removed\u0027] or"},{"line_number":1703,"context_line":"                failed_ancillary_devices[\u0027added\u0027] or failed_ancillary_devices["},{"line_number":1704,"context_line":"                    \u0027removed\u0027] or devices_not_ready_yet[\u0027devices\u0027] or"},{"line_number":1705,"context_line":"                devices_not_ready_yet[\u0027ancillary_devices\u0027])"},{"line_number":1706,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"},{"line_number":1707,"context_line":"                    or resync_devices):"}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_fa09ae95","line":1704,"in_reply_to":"da20952f_0662493e","updated":"2015-09-01 12:10:41.000000000","message":"+1 :)","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"599a16ba8e5f924ef9338c596dab06990cf6415d","unresolved":false,"context_lines":[{"line_number":1701,"context_line":"            resync_devices \u003d ("},{"line_number":1702,"context_line":"                failed_devices[\u0027added\u0027] or failed_devices[\u0027removed\u0027] or"},{"line_number":1703,"context_line":"                failed_ancillary_devices[\u0027added\u0027] or failed_ancillary_devices["},{"line_number":1704,"context_line":"                    \u0027removed\u0027] or devices_not_ready_yet[\u0027devices\u0027] or"},{"line_number":1705,"context_line":"                devices_not_ready_yet[\u0027ancillary_devices\u0027])"},{"line_number":1706,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"},{"line_number":1707,"context_line":"                    or resync_devices):"}],"source_content_type":"text/x-python","patch_set":14,"id":"da20952f_055f5576","line":1704,"in_reply_to":"da20952f_fa09ae95","updated":"2015-09-01 16:22:18.000000000","message":"Done","commit_id":"e4c61962e4cf5e50d689b9bfa7f3984f3c5fd3e8"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"082fa05f54156dc761cdbb342e75e0c65b23184c","unresolved":false,"context_lines":[{"line_number":1698,"context_line":"                    LOG.exception(_LE(\"Error while synchronizing tunnels\"))"},{"line_number":1699,"context_line":"                    tunnel_sync \u003d True"},{"line_number":1700,"context_line":"            ovs_restarted |\u003d (ovs_status \u003d\u003d constants.OVS_RESTARTED)"},{"line_number":1701,"context_line":"            resync_devices \u003d ("},{"line_number":1702,"context_line":"                failed_devices[\u0027added\u0027] or"},{"line_number":1703,"context_line":"                failed_devices[\u0027removed\u0027] or"},{"line_number":1704,"context_line":"                failed_ancillary_devices[\u0027added\u0027] or"}],"source_content_type":"text/x-python","patch_set":15,"id":"da20952f_9e0019ad","line":1701,"updated":"2015-09-03 21:00:33.000000000","message":"can you convert this into an any() call instead of a bunch of \u0027ors\u0027?","commit_id":"54d456233c28c0a7a49005f3c43a26d6cbd2ea8f"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"feed86dc95eda3f4901890d8cceca4f4c8688c5a","unresolved":false,"context_lines":[{"line_number":1698,"context_line":"                    LOG.exception(_LE(\"Error while synchronizing tunnels\"))"},{"line_number":1699,"context_line":"                    tunnel_sync \u003d True"},{"line_number":1700,"context_line":"            ovs_restarted |\u003d (ovs_status \u003d\u003d constants.OVS_RESTARTED)"},{"line_number":1701,"context_line":"            resync_devices \u003d ("},{"line_number":1702,"context_line":"                failed_devices[\u0027added\u0027] or"},{"line_number":1703,"context_line":"                failed_devices[\u0027removed\u0027] or"},{"line_number":1704,"context_line":"                failed_ancillary_devices[\u0027added\u0027] or"}],"source_content_type":"text/x-python","patch_set":15,"id":"da20952f_0fe03e95","line":1701,"in_reply_to":"da20952f_9e0019ad","updated":"2015-09-04 11:26:23.000000000","message":"I changed that, hope I got what you meant.","commit_id":"54d456233c28c0a7a49005f3c43a26d6cbd2ea8f"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"2ed426712baa558c5ffa1d1186bc7979a9d4c9eb","unresolved":false,"context_lines":[{"line_number":1119,"context_line":"                br.set_db_attribute(\u0027Interface\u0027, phys_if_name,"},{"line_number":1120,"context_line":"                                    \u0027options:peer\u0027, int_if_name)"},{"line_number":1121,"context_line":""},{"line_number":1122,"context_line":"    def update_stale_ofport_rules(self, failed_devices):"},{"line_number":1123,"context_line":"        # right now the ARP spoofing rules are the only thing that utilizes"},{"line_number":1124,"context_line":"        # ofport-based rules, so make arp_spoofing protection a conditional"},{"line_number":1125,"context_line":"        # until something else uses ofport"}],"source_content_type":"text/x-python","patch_set":18,"id":"da20952f_b2e32da4","line":1122,"updated":"2015-09-09 06:01:21.000000000","message":"this argument seems no longer necessary.","commit_id":"bf0b777a17ee6784fa836d28485af1e5f668f603"},{"author":{"_account_id":4395,"name":"Aaron Rosen","email":"aaronorosen@gmail.com","username":"arosen"},"change_message_id":"f34ba9ce7ca5ad0eae21f14438ecfc563371fbaa","unresolved":false,"context_lines":[{"line_number":1174,"context_line":"        port_info[\u0027removed\u0027] \u003d registered_ports - cur_ports"},{"line_number":1175,"context_line":"        return port_info"},{"line_number":1176,"context_line":""},{"line_number":1177,"context_line":"    def _process_port_info(self, port_info, failed_devices):"},{"line_number":1178,"context_line":"        #remove failed devices that don\u0027t need to be retried"},{"line_number":1179,"context_line":"        failed_devices[\u0027added\u0027] -\u003d port_info[\u0027removed\u0027]"},{"line_number":1180,"context_line":"        failed_devices[\u0027removed\u0027] -\u003d port_info[\u0027added\u0027]"}],"source_content_type":"text/x-python","patch_set":20,"id":"da20952f_3dd1fbfb","line":1177,"updated":"2015-09-10 07:57:59.000000000","message":"nit: I think this method would be better called: _update_port_info_failed_devices_stats() or something like that.","commit_id":"f0d252bdc4e2645e86208127cf19885182891e99"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"13bf5a5b3ef614f740cf4c67a548b8fa2eb87f28","unresolved":false,"context_lines":[{"line_number":1174,"context_line":"        port_info[\u0027removed\u0027] \u003d registered_ports - cur_ports"},{"line_number":1175,"context_line":"        return port_info"},{"line_number":1176,"context_line":""},{"line_number":1177,"context_line":"    def _process_port_info(self, port_info, failed_devices):"},{"line_number":1178,"context_line":"        #remove failed devices that don\u0027t need to be retried"},{"line_number":1179,"context_line":"        failed_devices[\u0027added\u0027] -\u003d port_info[\u0027removed\u0027]"},{"line_number":1180,"context_line":"        failed_devices[\u0027removed\u0027] -\u003d port_info[\u0027added\u0027]"}],"source_content_type":"text/x-python","patch_set":20,"id":"da20952f_3f40fd06","line":1177,"in_reply_to":"da20952f_3dd1fbfb","updated":"2015-09-10 16:58:35.000000000","message":"Done","commit_id":"f0d252bdc4e2645e86208127cf19885182891e99"},{"author":{"_account_id":4395,"name":"Aaron Rosen","email":"aaronorosen@gmail.com","username":"arosen"},"change_message_id":"f34ba9ce7ca5ad0eae21f14438ecfc563371fbaa","unresolved":false,"context_lines":[{"line_number":1175,"context_line":"        return port_info"},{"line_number":1176,"context_line":""},{"line_number":1177,"context_line":"    def _process_port_info(self, port_info, failed_devices):"},{"line_number":1178,"context_line":"        #remove failed devices that don\u0027t need to be retried"},{"line_number":1179,"context_line":"        failed_devices[\u0027added\u0027] -\u003d port_info[\u0027removed\u0027]"},{"line_number":1180,"context_line":"        failed_devices[\u0027removed\u0027] -\u003d port_info[\u0027added\u0027]"},{"line_number":1181,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"da20952f_1dbf57ab","line":1178,"updated":"2015-09-10 07:57:59.000000000","message":"nit: add space after #","commit_id":"f0d252bdc4e2645e86208127cf19885182891e99"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"13bf5a5b3ef614f740cf4c67a548b8fa2eb87f28","unresolved":false,"context_lines":[{"line_number":1175,"context_line":"        return port_info"},{"line_number":1176,"context_line":""},{"line_number":1177,"context_line":"    def _process_port_info(self, port_info, failed_devices):"},{"line_number":1178,"context_line":"        #remove failed devices that don\u0027t need to be retried"},{"line_number":1179,"context_line":"        failed_devices[\u0027added\u0027] -\u003d port_info[\u0027removed\u0027]"},{"line_number":1180,"context_line":"        failed_devices[\u0027removed\u0027] -\u003d port_info[\u0027added\u0027]"},{"line_number":1181,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"da20952f_5f437113","line":1178,"in_reply_to":"da20952f_1dbf57ab","updated":"2015-09-10 16:58:35.000000000","message":"Done","commit_id":"f0d252bdc4e2645e86208127cf19885182891e99"},{"author":{"_account_id":4395,"name":"Aaron Rosen","email":"aaronorosen@gmail.com","username":"arosen"},"change_message_id":"f34ba9ce7ca5ad0eae21f14438ecfc563371fbaa","unresolved":false,"context_lines":[{"line_number":1377,"context_line":"                    br.cleanup_tunnel_port(ofport)"},{"line_number":1378,"context_line":"                    self.tun_br_ofports[tunnel_type].pop(remote_ip, None)"},{"line_number":1379,"context_line":""},{"line_number":1380,"context_line":"    def treat_devices_added_or_updated(self, devices, failed_devices,"},{"line_number":1381,"context_line":"                                       ovs_restarted):"},{"line_number":1382,"context_line":"        skipped_devices \u003d []"},{"line_number":1383,"context_line":"        need_binding_devices \u003d []"}],"source_content_type":"text/x-python","patch_set":20,"id":"da20952f_1ded17b7","line":1380,"updated":"2015-09-10 07:57:59.000000000","message":"I think this method should return failed_devices at the bottom like all the other devices rather than doing it by pass by value.","commit_id":"f0d252bdc4e2645e86208127cf19885182891e99"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"13bf5a5b3ef614f740cf4c67a548b8fa2eb87f28","unresolved":false,"context_lines":[{"line_number":1377,"context_line":"                    br.cleanup_tunnel_port(ofport)"},{"line_number":1378,"context_line":"                    self.tun_br_ofports[tunnel_type].pop(remote_ip, None)"},{"line_number":1379,"context_line":""},{"line_number":1380,"context_line":"    def treat_devices_added_or_updated(self, devices, failed_devices,"},{"line_number":1381,"context_line":"                                       ovs_restarted):"},{"line_number":1382,"context_line":"        skipped_devices \u003d []"},{"line_number":1383,"context_line":"        need_binding_devices \u003d []"}],"source_content_type":"text/x-python","patch_set":20,"id":"da20952f_5f5a91f3","line":1380,"in_reply_to":"da20952f_1ded17b7","updated":"2015-09-10 16:58:35.000000000","message":"good point","commit_id":"f0d252bdc4e2645e86208127cf19885182891e99"},{"author":{"_account_id":8976,"name":"shihanzhang","email":"ayshihanzhang@gmail.com","username":"shihanzhang"},"change_message_id":"f126a40f00a896b1d73443ba57d3f2d3ccc888e1","unresolved":false,"context_lines":[{"line_number":1556,"context_line":""},{"line_number":1557,"context_line":"        if \u0027removed\u0027 in port_info and port_info[\u0027removed\u0027]:"},{"line_number":1558,"context_line":"            start \u003d time.time()"},{"line_number":1559,"context_line":"            failed_devices[\u0027removed\u0027] \u003d self.treat_devices_removed("},{"line_number":1560,"context_line":"                port_info[\u0027removed\u0027])"},{"line_number":1561,"context_line":"            LOG.debug(\"process_network_ports - iteration:%(iter_num)d - \""},{"line_number":1562,"context_line":"                      \"treat_devices_removed completed in %(elapsed).3f\","}],"source_content_type":"text/x-python","patch_set":21,"id":"da20952f_c12b0d94","line":1559,"updated":"2015-09-11 07:05:50.000000000","message":"maybe it will overwrite the failed_devices[\u0027removed\u0027] in funciton line#1555 self._bind_devices","commit_id":"7c8142053c22641952d1b0a2aa1ff7bf39a744bd"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"085541a2476177e11d4c4b9233022b7cb0e6b743","unresolved":false,"context_lines":[{"line_number":1556,"context_line":""},{"line_number":1557,"context_line":"        if \u0027removed\u0027 in port_info and port_info[\u0027removed\u0027]:"},{"line_number":1558,"context_line":"            start \u003d time.time()"},{"line_number":1559,"context_line":"            failed_devices[\u0027removed\u0027] \u003d self.treat_devices_removed("},{"line_number":1560,"context_line":"                port_info[\u0027removed\u0027])"},{"line_number":1561,"context_line":"            LOG.debug(\"process_network_ports - iteration:%(iter_num)d - \""},{"line_number":1562,"context_line":"                      \"treat_devices_removed completed in %(elapsed).3f\","}],"source_content_type":"text/x-python","patch_set":21,"id":"9a1a9d01_e2cdd731","line":1559,"in_reply_to":"da20952f_c12b0d94","updated":"2015-09-29 17:11:02.000000000","message":"Right","commit_id":"7c8142053c22641952d1b0a2aa1ff7bf39a744bd"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"dfc5e0791b57270f987768bea74266de8056e0f3","unresolved":false,"context_lines":[{"line_number":845,"context_line":"                LOG.error(_LE(\"Configuration for up device %s failed!\"),"},{"line_number":846,"context_line":"                          dev)"},{"line_number":847,"context_line":"            for dev in devices_set.get(\u0027failed_devices_down\u0027):"},{"line_number":848,"context_line":"                failed_devices[\u0027removed\u0027].add(dev)"},{"line_number":849,"context_line":"                LOG.error(_LE(\"Configuration for down device %s failed!\"),"},{"line_number":850,"context_line":"                          dev)"},{"line_number":851,"context_line":"        LOG.info(_LI(\"Configuration for devices up %(up)s and devices \""}],"source_content_type":"text/x-python","patch_set":24,"id":"5a2ca52d_2628c999","line":848,"updated":"2015-10-16 05:32:54.000000000","message":"why you add this to removed list, not added?","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"d68452da224a0bf4426f52e7c426a609e40f7f2e","unresolved":false,"context_lines":[{"line_number":845,"context_line":"                LOG.error(_LE(\"Configuration for up device %s failed!\"),"},{"line_number":846,"context_line":"                          dev)"},{"line_number":847,"context_line":"            for dev in devices_set.get(\u0027failed_devices_down\u0027):"},{"line_number":848,"context_line":"                failed_devices[\u0027removed\u0027].add(dev)"},{"line_number":849,"context_line":"                LOG.error(_LE(\"Configuration for down device %s failed!\"),"},{"line_number":850,"context_line":"                          dev)"},{"line_number":851,"context_line":"        LOG.info(_LI(\"Configuration for devices up %(up)s and devices \""}],"source_content_type":"text/x-python","patch_set":24,"id":"3a29b11f_ee721c7c","line":848,"in_reply_to":"5a2ca52d_2628c999","updated":"2015-10-19 14:05:22.000000000","message":"good point","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"dfc5e0791b57270f987768bea74266de8056e0f3","unresolved":false,"context_lines":[{"line_number":1499,"context_line":"        LOG.info(_LI(\"Devices down  %s \"), devices_down)"},{"line_number":1500,"context_line":"        failed_devices \u003d devices_down.get(\u0027failed_devices_down\u0027)"},{"line_number":1501,"context_line":"        if failed_devices:"},{"line_number":1502,"context_line":"            LOG.info(_LI(\"Port removal failed for %s\"), failed_devices)"},{"line_number":1503,"context_line":"        for detail in devices_down.get(\u0027devices_down\u0027):"},{"line_number":1504,"context_line":"            if detail[\u0027exists\u0027]:"},{"line_number":1505,"context_line":"                LOG.info(_LI(\"Port %s updated.\"), detail[\u0027device\u0027])"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a2ca52d_465e2545","line":1502,"updated":"2015-10-16 05:32:54.000000000","message":"unrelated change?","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"d68452da224a0bf4426f52e7c426a609e40f7f2e","unresolved":false,"context_lines":[{"line_number":1499,"context_line":"        LOG.info(_LI(\"Devices down  %s \"), devices_down)"},{"line_number":1500,"context_line":"        failed_devices \u003d devices_down.get(\u0027failed_devices_down\u0027)"},{"line_number":1501,"context_line":"        if failed_devices:"},{"line_number":1502,"context_line":"            LOG.info(_LI(\"Port removal failed for %s\"), failed_devices)"},{"line_number":1503,"context_line":"        for detail in devices_down.get(\u0027devices_down\u0027):"},{"line_number":1504,"context_line":"            if detail[\u0027exists\u0027]:"},{"line_number":1505,"context_line":"                LOG.info(_LI(\"Port %s updated.\"), detail[\u0027device\u0027])"}],"source_content_type":"text/x-python","patch_set":24,"id":"3a29b11f_ce69608d","line":1502,"in_reply_to":"5a2ca52d_465e2545","updated":"2015-10-19 14:05:22.000000000","message":"yeah","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"dfc5e0791b57270f987768bea74266de8056e0f3","unresolved":false,"context_lines":[{"line_number":1506,"context_line":"                # Nothing to do regarding local networking"},{"line_number":1507,"context_line":"            else:"},{"line_number":1508,"context_line":"                LOG.info(_LI(\"Device %s not defined on plugin\"),"},{"line_number":1509,"context_line":"                         detail[\u0027device\u0027])"},{"line_number":1510,"context_line":"        return failed_devices"},{"line_number":1511,"context_line":""},{"line_number":1512,"context_line":"    def process_network_ports(self, port_info, ovs_restarted):"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a2ca52d_2661a905","line":1509,"updated":"2015-10-16 05:32:54.000000000","message":"unrelated change?","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"d68452da224a0bf4426f52e7c426a609e40f7f2e","unresolved":false,"context_lines":[{"line_number":1506,"context_line":"                # Nothing to do regarding local networking"},{"line_number":1507,"context_line":"            else:"},{"line_number":1508,"context_line":"                LOG.info(_LI(\"Device %s not defined on plugin\"),"},{"line_number":1509,"context_line":"                         detail[\u0027device\u0027])"},{"line_number":1510,"context_line":"        return failed_devices"},{"line_number":1511,"context_line":""},{"line_number":1512,"context_line":"    def process_network_ports(self, port_info, ovs_restarted):"}],"source_content_type":"text/x-python","patch_set":24,"id":"3a29b11f_8e0a88d1","line":1509,"in_reply_to":"5a2ca52d_2661a905","updated":"2015-10-19 14:05:22.000000000","message":"yeah","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"dfc5e0791b57270f987768bea74266de8056e0f3","unresolved":false,"context_lines":[{"line_number":1700,"context_line":"                LOG.info(_LI(\"Agent out of sync with plugin!\"))"},{"line_number":1701,"context_line":"                consecutive_resyncs \u003d consecutive_resyncs + 1"},{"line_number":1702,"context_line":"                failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1703,"context_line":"                failed_ancillary_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1704,"context_line":"                if (consecutive_resyncs \u003e\u003d"},{"line_number":1705,"context_line":"                        constants.MAX_DEVICE_RETRIES):"},{"line_number":1706,"context_line":"                    LOG.warn(_LW("}],"source_content_type":"text/x-python","patch_set":24,"id":"5a2ca52d_21c75397","line":1703,"updated":"2015-10-16 05:32:54.000000000","message":"these seems unused.","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"3a0e48308c1bbd9571df51fc9c6ff9d411c650bd","unresolved":false,"context_lines":[{"line_number":1700,"context_line":"                LOG.info(_LI(\"Agent out of sync with plugin!\"))"},{"line_number":1701,"context_line":"                consecutive_resyncs \u003d consecutive_resyncs + 1"},{"line_number":1702,"context_line":"                failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1703,"context_line":"                failed_ancillary_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1704,"context_line":"                if (consecutive_resyncs \u003e\u003d"},{"line_number":1705,"context_line":"                        constants.MAX_DEVICE_RETRIES):"},{"line_number":1706,"context_line":"                    LOG.warn(_LW("}],"source_content_type":"text/x-python","patch_set":24,"id":"3a29b11f_1597d5ec","line":1703,"in_reply_to":"3a29b11f_8e792896","updated":"2015-10-22 01:08:34.000000000","message":"how can we reach L1747-1748 after executing L1702-1703?","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"d68452da224a0bf4426f52e7c426a609e40f7f2e","unresolved":false,"context_lines":[{"line_number":1700,"context_line":"                LOG.info(_LI(\"Agent out of sync with plugin!\"))"},{"line_number":1701,"context_line":"                consecutive_resyncs \u003d consecutive_resyncs + 1"},{"line_number":1702,"context_line":"                failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1703,"context_line":"                failed_ancillary_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1704,"context_line":"                if (consecutive_resyncs \u003e\u003d"},{"line_number":1705,"context_line":"                        constants.MAX_DEVICE_RETRIES):"},{"line_number":1706,"context_line":"                    LOG.warn(_LW("}],"source_content_type":"text/x-python","patch_set":24,"id":"3a29b11f_8e792896","line":1703,"in_reply_to":"5a2ca52d_21c75397","updated":"2015-10-19 14:05:22.000000000","message":"see line 1747, 1748. These are used and need to be reset when the agent perform a full resync since all failed devices will be resynced too :)","commit_id":"51001677376ceb0d8b02faa8c7b9e48d46bafca9"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"88b3c6e2b7526b32086dd401a9883a3a03fd4a9d","unresolved":false,"context_lines":[{"line_number":1698,"context_line":"                LOG.info(_LI(\"Agent out of sync with plugin!\"))"},{"line_number":1699,"context_line":"                consecutive_resyncs \u003d consecutive_resyncs + 1"},{"line_number":1700,"context_line":"                failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1701,"context_line":"                failed_ancillary_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1702,"context_line":"                if (consecutive_resyncs \u003e\u003d"},{"line_number":1703,"context_line":"                        constants.MAX_DEVICE_RETRIES):"},{"line_number":1704,"context_line":"                    LOG.warn(_LW("}],"source_content_type":"text/x-python","patch_set":25,"id":"3a29b11f_356a11ef","line":1701,"updated":"2015-10-22 01:11:07.000000000","message":"commented in PS24","commit_id":"547a4e1bbaa13a10697d7ec88e84d0f2d922aff0"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"6a82333d789eeb157f605cfbb501b86d1a339641","unresolved":false,"context_lines":[{"line_number":1698,"context_line":"                LOG.info(_LI(\"Agent out of sync with plugin!\"))"},{"line_number":1699,"context_line":"                consecutive_resyncs \u003d consecutive_resyncs + 1"},{"line_number":1700,"context_line":"                failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1701,"context_line":"                failed_ancillary_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":1702,"context_line":"                if (consecutive_resyncs \u003e\u003d"},{"line_number":1703,"context_line":"                        constants.MAX_DEVICE_RETRIES):"},{"line_number":1704,"context_line":"                    LOG.warn(_LW("}],"source_content_type":"text/x-python","patch_set":25,"id":"3a29b11f_4a5a6af3","line":1701,"in_reply_to":"3a29b11f_356a11ef","updated":"2015-10-22 16:56:05.000000000","message":"got your point now","commit_id":"547a4e1bbaa13a10697d7ec88e84d0f2d922aff0"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1a842184b3517932a8eb9b8a7d2d099b4444085a","unresolved":false,"context_lines":[{"line_number":1224,"context_line":""},{"line_number":1225,"context_line":"    def process_ports_events(self, events, registered_ports, ancillary_ports,"},{"line_number":1226,"context_line":"                             failed_devices, failed_ancillary_devices,"},{"line_number":1227,"context_line":"                             old_devices_not_ready, updated_ports\u003dNone):"},{"line_number":1228,"context_line":"        port_info \u003d {}"},{"line_number":1229,"context_line":"        port_info[\u0027added\u0027] \u003d set()"},{"line_number":1230,"context_line":"        port_info[\u0027removed\u0027] \u003d set()"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_443bfed1","line":1227,"updated":"2015-11-09 14:01:16.000000000","message":"mixing ports and devices in a method doesn\u0027t look neat.","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":1224,"context_line":""},{"line_number":1225,"context_line":"    def process_ports_events(self, events, registered_ports, ancillary_ports,"},{"line_number":1226,"context_line":"                             failed_devices, failed_ancillary_devices,"},{"line_number":1227,"context_line":"                             old_devices_not_ready, updated_ports\u003dNone):"},{"line_number":1228,"context_line":"        port_info \u003d {}"},{"line_number":1229,"context_line":"        port_info[\u0027added\u0027] \u003d set()"},{"line_number":1230,"context_line":"        port_info[\u0027removed\u0027] \u003d set()"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_6634ebdd","line":1227,"in_reply_to":"da85f559_443bfed1","updated":"2015-12-10 16:09:52.000000000","message":"I agree. Look at next patch please...the confusion port vs device is not solved. I can rename failed_devices failed_ports but it would be still confusing because the RPC calls use the word \u0027device\u0027 and the methods \u0027treat_devices_added_or_updated\u0027..any suggestion?","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1a842184b3517932a8eb9b8a7d2d099b4444085a","unresolved":false,"context_lines":[{"line_number":1234,"context_line":"        ancillary_port_info[\u0027removed\u0027] \u003d set()"},{"line_number":1235,"context_line":"        ancillary_port_info[\u0027current\u0027] \u003d ("},{"line_number":1236,"context_line":"            ancillary_ports - failed_ancillary_devices.get(\u0027added\u0027))"},{"line_number":1237,"context_line":"        devices_not_ready_yet \u003d []"},{"line_number":1238,"context_line":""},{"line_number":1239,"context_line":"        # if a port was added and then removed or viceversa since the agent"},{"line_number":1240,"context_line":"        # can\u0027t know the order of the operations, check the status of the port"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_44977e90","line":1237,"updated":"2015-11-09 14:01:16.000000000","message":"why this is a list rather than a set?","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":1234,"context_line":"        ancillary_port_info[\u0027removed\u0027] \u003d set()"},{"line_number":1235,"context_line":"        ancillary_port_info[\u0027current\u0027] \u003d ("},{"line_number":1236,"context_line":"            ancillary_ports - failed_ancillary_devices.get(\u0027added\u0027))"},{"line_number":1237,"context_line":"        devices_not_ready_yet \u003d []"},{"line_number":1238,"context_line":""},{"line_number":1239,"context_line":"        # if a port was added and then removed or viceversa since the agent"},{"line_number":1240,"context_line":"        # can\u0027t know the order of the operations, check the status of the port"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_2326d5ba","line":1237,"in_reply_to":"da85f559_44977e90","updated":"2015-12-10 16:09:52.000000000","message":"addressed in another PS","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1a842184b3517932a8eb9b8a7d2d099b4444085a","unresolved":false,"context_lines":[{"line_number":1266,"context_line":"                    if device[\u0027ofport\u0027] \u003d\u003d ovs_lib.UNASSIGNED_OFPORT:"},{"line_number":1267,"context_line":"                        LOG.info(_LI(\"Port %s not ready yet on the bridge\"),"},{"line_number":1268,"context_line":"                                 iface_id)"},{"line_number":1269,"context_line":"                        devices_not_ready_yet.append(device[\u0027name\u0027])"},{"line_number":1270,"context_line":"                        return"},{"line_number":1271,"context_line":"                    # check if device belong to ancillary bridge"},{"line_number":1272,"context_line":"                    if iface_id in cur_ancillary_ports:"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_64496231","line":1269,"updated":"2015-11-09 14:01:16.000000000","message":"assuming it was \u0027added\u0027?","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":1266,"context_line":"                    if device[\u0027ofport\u0027] \u003d\u003d ovs_lib.UNASSIGNED_OFPORT:"},{"line_number":1267,"context_line":"                        LOG.info(_LI(\"Port %s not ready yet on the bridge\"),"},{"line_number":1268,"context_line":"                                 iface_id)"},{"line_number":1269,"context_line":"                        devices_not_ready_yet.append(device[\u0027name\u0027])"},{"line_number":1270,"context_line":"                        return"},{"line_number":1271,"context_line":"                    # check if device belong to ancillary bridge"},{"line_number":1272,"context_line":"                    if iface_id in cur_ancillary_ports:"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_032399a8","line":1269,"in_reply_to":"da85f559_64496231","updated":"2015-12-10 16:09:52.000000000","message":"yes only added port can be not ready","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1a842184b3517932a8eb9b8a7d2d099b4444085a","unresolved":false,"context_lines":[{"line_number":1489,"context_line":"        self.network_ports[network_id].add(port_id)"},{"line_number":1490,"context_line":""},{"line_number":1491,"context_line":"    def treat_ancillary_devices_added(self, devices):"},{"line_number":1492,"context_line":"        failed_devices \u003d []"},{"line_number":1493,"context_line":"        devices_details_list \u003d ("},{"line_number":1494,"context_line":"            self.plugin_rpc.get_devices_details_list_and_failed_devices("},{"line_number":1495,"context_line":"                self.context,"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_a4b98aeb","line":1492,"updated":"2015-11-09 14:01:16.000000000","message":"set() would be more consistent with treat_devices_added_or_updated","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":1489,"context_line":"        self.network_ports[network_id].add(port_id)"},{"line_number":1490,"context_line":""},{"line_number":1491,"context_line":"    def treat_ancillary_devices_added(self, devices):"},{"line_number":1492,"context_line":"        failed_devices \u003d []"},{"line_number":1493,"context_line":"        devices_details_list \u003d ("},{"line_number":1494,"context_line":"            self.plugin_rpc.get_devices_details_list_and_failed_devices("},{"line_number":1495,"context_line":"                self.context,"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_e340cd09","line":1492,"in_reply_to":"da85f559_a4b98aeb","updated":"2015-12-10 16:09:52.000000000","message":"agreed","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1a842184b3517932a8eb9b8a7d2d099b4444085a","unresolved":false,"context_lines":[{"line_number":1586,"context_line":""},{"line_number":1587,"context_line":"        # Ports are bound before calling the sg_agent setup. This function"},{"line_number":1588,"context_line":"        # fulfill the information needed by the sg_agent setup."},{"line_number":1589,"context_line":"        self._bind_devices(need_binding_devices, failed_devices)"},{"line_number":1590,"context_line":"        # TODO(salv-orlando): Optimize avoiding applying filters"},{"line_number":1591,"context_line":"        # unnecessarily, (eg: when there are no IP address changes)"},{"line_number":1592,"context_line":"        added_ports \u003d port_info.get(\u0027added\u0027, set())"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_64cc028a","line":1589,"updated":"2015-11-09 14:01:16.000000000","message":"it would be more consistent to pass failed_devices[\u0027added\u0027]","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":1586,"context_line":""},{"line_number":1587,"context_line":"        # Ports are bound before calling the sg_agent setup. This function"},{"line_number":1588,"context_line":"        # fulfill the information needed by the sg_agent setup."},{"line_number":1589,"context_line":"        self._bind_devices(need_binding_devices, failed_devices)"},{"line_number":1590,"context_line":"        # TODO(salv-orlando): Optimize avoiding applying filters"},{"line_number":1591,"context_line":"        # unnecessarily, (eg: when there are no IP address changes)"},{"line_number":1592,"context_line":"        added_ports \u003d port_info.get(\u0027added\u0027, set())"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_831b09ca","line":1589,"in_reply_to":"da85f559_64cc028a","updated":"2015-12-10 16:09:52.000000000","message":"actually failed_devices should be what\u0027s returned by this method. Thanks for making look into it","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1a842184b3517932a8eb9b8a7d2d099b4444085a","unresolved":false,"context_lines":[{"line_number":1849,"context_line":"                    LOG.exception(_LE(\"Error while synchronizing tunnels\"))"},{"line_number":1850,"context_line":"                    tunnel_sync \u003d True"},{"line_number":1851,"context_line":"            ovs_restarted |\u003d (ovs_status \u003d\u003d constants.OVS_RESTARTED)"},{"line_number":1852,"context_line":"            resync_devices \u003d (any(failed_devices.values()) or"},{"line_number":1853,"context_line":"                any(failed_ancillary_devices.values()) or"},{"line_number":1854,"context_line":"                any(devices_not_ready_yet))"},{"line_number":1855,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_845a4682","line":1852,"range":{"start_line":1852,"start_character":12,"end_line":1852,"end_character":26},"updated":"2015-11-09 14:01:16.000000000","message":"the term (re)sync is already heavily overloaded.\ni\u0027d suggest needs_retry or something like that.","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":1849,"context_line":"                    LOG.exception(_LE(\"Error while synchronizing tunnels\"))"},{"line_number":1850,"context_line":"                    tunnel_sync \u003d True"},{"line_number":1851,"context_line":"            ovs_restarted |\u003d (ovs_status \u003d\u003d constants.OVS_RESTARTED)"},{"line_number":1852,"context_line":"            resync_devices \u003d (any(failed_devices.values()) or"},{"line_number":1853,"context_line":"                any(failed_ancillary_devices.values()) or"},{"line_number":1854,"context_line":"                any(devices_not_ready_yet))"},{"line_number":1855,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_63937dfb","line":1852,"in_reply_to":"da85f559_845a4682","updated":"2015-12-10 16:09:52.000000000","message":"I changed it, \"devices_need_retry\", hope it\u0027s clear enough","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1a842184b3517932a8eb9b8a7d2d099b4444085a","unresolved":false,"context_lines":[{"line_number":1851,"context_line":"            ovs_restarted |\u003d (ovs_status \u003d\u003d constants.OVS_RESTARTED)"},{"line_number":1852,"context_line":"            resync_devices \u003d (any(failed_devices.values()) or"},{"line_number":1853,"context_line":"                any(failed_ancillary_devices.values()) or"},{"line_number":1854,"context_line":"                any(devices_not_ready_yet))"},{"line_number":1855,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"},{"line_number":1856,"context_line":"                    or resync_devices):"},{"line_number":1857,"context_line":"                try:"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_e47eb2e3","line":1854,"updated":"2015-11-09 14:01:16.000000000","message":"you don\u0027t need any() for devices_not_ready_yet","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":1851,"context_line":"            ovs_restarted |\u003d (ovs_status \u003d\u003d constants.OVS_RESTARTED)"},{"line_number":1852,"context_line":"            resync_devices \u003d (any(failed_devices.values()) or"},{"line_number":1853,"context_line":"                any(failed_ancillary_devices.values()) or"},{"line_number":1854,"context_line":"                any(devices_not_ready_yet))"},{"line_number":1855,"context_line":"            if (self._agent_has_updates(polling_manager) or sync"},{"line_number":1856,"context_line":"                    or resync_devices):"},{"line_number":1857,"context_line":"                try:"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_c3683124","line":1854,"in_reply_to":"da85f559_e47eb2e3","updated":"2015-12-10 16:09:52.000000000","message":"Done","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1a842184b3517932a8eb9b8a7d2d099b4444085a","unresolved":false,"context_lines":[{"line_number":1915,"context_line":"                    polling_manager.polling_completed()"},{"line_number":1916,"context_line":"                    # Keep this flag in the last line of \"try\" block,"},{"line_number":1917,"context_line":"                    # so we can sure that no other Exception occurred."},{"line_number":1918,"context_line":"                    if not sync:"},{"line_number":1919,"context_line":"                        ovs_restarted \u003d False"},{"line_number":1920,"context_line":"                        self._dispose_local_vlan_hints()"},{"line_number":1921,"context_line":"                except Exception:"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_04309600","line":1918,"updated":"2015-11-09 14:01:16.000000000","message":"needs an update?","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"9fd7cee2369e87edd972c8bda2989830ea7181ad","unresolved":false,"context_lines":[{"line_number":1915,"context_line":"                    polling_manager.polling_completed()"},{"line_number":1916,"context_line":"                    # Keep this flag in the last line of \"try\" block,"},{"line_number":1917,"context_line":"                    # so we can sure that no other Exception occurred."},{"line_number":1918,"context_line":"                    if not sync:"},{"line_number":1919,"context_line":"                        ovs_restarted \u003d False"},{"line_number":1920,"context_line":"                        self._dispose_local_vlan_hints()"},{"line_number":1921,"context_line":"                except Exception:"}],"source_content_type":"text/x-python","patch_set":29,"id":"5a710552_3a606a35","line":1918,"in_reply_to":"7a740942_63aa9d1b","updated":"2015-12-15 03:58:13.000000000","message":"how can we reach here with sync\u003dTrue?","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":1915,"context_line":"                    polling_manager.polling_completed()"},{"line_number":1916,"context_line":"                    # Keep this flag in the last line of \"try\" block,"},{"line_number":1917,"context_line":"                    # so we can sure that no other Exception occurred."},{"line_number":1918,"context_line":"                    if not sync:"},{"line_number":1919,"context_line":"                        ovs_restarted \u003d False"},{"line_number":1920,"context_line":"                        self._dispose_local_vlan_hints()"},{"line_number":1921,"context_line":"                except Exception:"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_63aa9d1b","line":1918,"in_reply_to":"da85f559_04309600","updated":"2015-12-10 16:09:52.000000000","message":"why? sync is still set when there\u0027s an uncaught exception","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"fd3f4901fbbe09022538e9241cdc9109ed6715ed","unresolved":false,"context_lines":[{"line_number":1873,"context_line":"                                  port_info)"},{"line_number":1874,"context_line":"                        failed_devices \u003d self.process_network_ports("},{"line_number":1875,"context_line":"                            port_info, ovs_restarted)"},{"line_number":1876,"context_line":"                        if not sync and need_clean_stale_flow:"},{"line_number":1877,"context_line":"                            self.cleanup_stale_flows()"},{"line_number":1878,"context_line":"                            need_clean_stale_flow \u003d False"},{"line_number":1879,"context_line":"                        LOG.debug(\"Agent rpc_loop - iteration:%(iter_num)d - \""}],"source_content_type":"text/x-python","patch_set":31,"id":"5a710552_3aee2a8c","line":1876,"range":{"start_line":1876,"start_character":31,"end_line":1876,"end_character":35},"updated":"2015-12-15 03:59:55.000000000","message":"sync seems to be always False here.","commit_id":"1477ef0ac27f3959765a10e2c49891d7a583d79b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"8f9bfaab3674f4ff834d00ce8135c438774bdd8f","unresolved":false,"context_lines":[{"line_number":1873,"context_line":"                                  port_info)"},{"line_number":1874,"context_line":"                        failed_devices \u003d self.process_network_ports("},{"line_number":1875,"context_line":"                            port_info, ovs_restarted)"},{"line_number":1876,"context_line":"                        if not sync and need_clean_stale_flow:"},{"line_number":1877,"context_line":"                            self.cleanup_stale_flows()"},{"line_number":1878,"context_line":"                            need_clean_stale_flow \u003d False"},{"line_number":1879,"context_line":"                        LOG.debug(\"Agent rpc_loop - iteration:%(iter_num)d - \""}],"source_content_type":"text/x-python","patch_set":31,"id":"1a7b0d38_8e9e1b06","line":1876,"range":{"start_line":1876,"start_character":31,"end_line":1876,"end_character":35},"in_reply_to":"5a710552_3aee2a8c","updated":"2015-12-22 15:15:21.000000000","message":"good point","commit_id":"1477ef0ac27f3959765a10e2c49891d7a583d79b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"fd3f4901fbbe09022538e9241cdc9109ed6715ed","unresolved":false,"context_lines":[{"line_number":1897,"context_line":"                    polling_manager.polling_completed()"},{"line_number":1898,"context_line":"                    # Keep this flag in the last line of \"try\" block,"},{"line_number":1899,"context_line":"                    # so we can sure that no other Exception occurred."},{"line_number":1900,"context_line":"                    if not sync:"},{"line_number":1901,"context_line":"                        ovs_restarted \u003d False"},{"line_number":1902,"context_line":"                        self._dispose_local_vlan_hints()"},{"line_number":1903,"context_line":"                except Exception:"}],"source_content_type":"text/x-python","patch_set":31,"id":"5a710552_fae742aa","line":1900,"range":{"start_line":1900,"start_character":27,"end_line":1900,"end_character":31},"updated":"2015-12-15 03:59:55.000000000","message":"sync seems to be always False here.","commit_id":"1477ef0ac27f3959765a10e2c49891d7a583d79b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"8f9bfaab3674f4ff834d00ce8135c438774bdd8f","unresolved":false,"context_lines":[{"line_number":1897,"context_line":"                    polling_manager.polling_completed()"},{"line_number":1898,"context_line":"                    # Keep this flag in the last line of \"try\" block,"},{"line_number":1899,"context_line":"                    # so we can sure that no other Exception occurred."},{"line_number":1900,"context_line":"                    if not sync:"},{"line_number":1901,"context_line":"                        ovs_restarted \u003d False"},{"line_number":1902,"context_line":"                        self._dispose_local_vlan_hints()"},{"line_number":1903,"context_line":"                except Exception:"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a7b0d38_4e8913ca","line":1900,"range":{"start_line":1900,"start_character":27,"end_line":1900,"end_character":31},"in_reply_to":"5a710552_fae742aa","updated":"2015-12-22 15:15:21.000000000","message":"right","commit_id":"1477ef0ac27f3959765a10e2c49891d7a583d79b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"120d60186002dd5d75514774ba7f2ad93a6f2db0","unresolved":false,"context_lines":[{"line_number":793,"context_line":"    def _bind_devices(self, need_binding_ports):"},{"line_number":794,"context_line":"        devices_up \u003d []"},{"line_number":795,"context_line":"        devices_down \u003d []"},{"line_number":796,"context_line":"        failed_devices \u003d set()"},{"line_number":797,"context_line":"        port_names \u003d [p[\u0027vif_port\u0027].port_name for p in need_binding_ports]"},{"line_number":798,"context_line":"        port_info \u003d self.int_br.get_ports_attributes("},{"line_number":799,"context_line":"            \"Port\", columns\u003d[\"name\", \"tag\"], ports\u003dport_names, if_exists\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":34,"id":"da6ed579_69b0ea8a","line":796,"updated":"2016-01-14 09:56:54.000000000","message":"why you moved this here?\n\nin other place (L.839) it\u0027s a list.\nit\u0027s better to use a consistent type for a variable.","commit_id":"b54ac3e29e0123dec5e62de45cee0fa076f4be80"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"1cd32d7726cb41dbf163403eb6840aa019340967","unresolved":false,"context_lines":[{"line_number":793,"context_line":"    def _bind_devices(self, need_binding_ports):"},{"line_number":794,"context_line":"        devices_up \u003d []"},{"line_number":795,"context_line":"        devices_down \u003d []"},{"line_number":796,"context_line":"        failed_devices \u003d set()"},{"line_number":797,"context_line":"        port_names \u003d [p[\u0027vif_port\u0027].port_name for p in need_binding_ports]"},{"line_number":798,"context_line":"        port_info \u003d self.int_br.get_ports_attributes("},{"line_number":799,"context_line":"            \"Port\", columns\u003d[\"name\", \"tag\"], ports\u003dport_names, if_exists\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":34,"id":"da6ed579_25634e1c","line":796,"in_reply_to":"da6ed579_1a9bae73","updated":"2016-01-18 13:26:07.000000000","message":"Done","commit_id":"b54ac3e29e0123dec5e62de45cee0fa076f4be80"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"195a69df67d6846c9f104a12033d80efc630c5cd","unresolved":false,"context_lines":[{"line_number":793,"context_line":"    def _bind_devices(self, need_binding_ports):"},{"line_number":794,"context_line":"        devices_up \u003d []"},{"line_number":795,"context_line":"        devices_down \u003d []"},{"line_number":796,"context_line":"        failed_devices \u003d set()"},{"line_number":797,"context_line":"        port_names \u003d [p[\u0027vif_port\u0027].port_name for p in need_binding_ports]"},{"line_number":798,"context_line":"        port_info \u003d self.int_br.get_ports_attributes("},{"line_number":799,"context_line":"            \"Port\", columns\u003d[\"name\", \"tag\"], ports\u003dport_names, if_exists\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":34,"id":"da6ed579_1a9bae73","line":796,"in_reply_to":"da6ed579_69b0ea8a","updated":"2016-01-14 10:38:30.000000000","message":"Oh right, it\u0027s better to make it a list as it was. It\u0027s not really important if you look at the code using it.","commit_id":"b54ac3e29e0123dec5e62de45cee0fa076f4be80"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"120d60186002dd5d75514774ba7f2ad93a6f2db0","unresolved":false,"context_lines":[{"line_number":1508,"context_line":"                                                          self.agent_id,"},{"line_number":1509,"context_line":"                                                          self.conf.host)"},{"line_number":1510,"context_line":"        LOG.info(_LI(\"Devices down  %s \"), devices_down)"},{"line_number":1511,"context_line":"        failed_devices \u003d devices_down.get(\u0027failed_devices_down\u0027)"},{"line_number":1512,"context_line":"        if failed_devices:"},{"line_number":1513,"context_line":"            LOG.debug(\"Port removal failed for %(devices)s\", failed_devices)"},{"line_number":1514,"context_line":"        for detail in devices_down.get(\u0027devices_down\u0027):"}],"source_content_type":"text/x-python","patch_set":34,"id":"da6ed579_c439bda5","line":1511,"updated":"2016-01-14 09:56:54.000000000","message":"please make this a set to be consistent with treat_devices_removed.","commit_id":"b54ac3e29e0123dec5e62de45cee0fa076f4be80"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"1cd32d7726cb41dbf163403eb6840aa019340967","unresolved":false,"context_lines":[{"line_number":1508,"context_line":"                                                          self.agent_id,"},{"line_number":1509,"context_line":"                                                          self.conf.host)"},{"line_number":1510,"context_line":"        LOG.info(_LI(\"Devices down  %s \"), devices_down)"},{"line_number":1511,"context_line":"        failed_devices \u003d devices_down.get(\u0027failed_devices_down\u0027)"},{"line_number":1512,"context_line":"        if failed_devices:"},{"line_number":1513,"context_line":"            LOG.debug(\"Port removal failed for %(devices)s\", failed_devices)"},{"line_number":1514,"context_line":"        for detail in devices_down.get(\u0027devices_down\u0027):"}],"source_content_type":"text/x-python","patch_set":34,"id":"da6ed579_9a261915","line":1511,"in_reply_to":"da6ed579_c439bda5","updated":"2016-01-18 13:26:07.000000000","message":"Done","commit_id":"b54ac3e29e0123dec5e62de45cee0fa076f4be80"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"120d60186002dd5d75514774ba7f2ad93a6f2db0","unresolved":false,"context_lines":[{"line_number":1589,"context_line":"                      {\u0027iter_num\u0027: self.iter_num,"},{"line_number":1590,"context_line":"                       \u0027elapsed\u0027: time.time() - start})"},{"line_number":1591,"context_line":"            for dev in failed_added:"},{"line_number":1592,"context_line":"                failed_devices[\u0027added\u0027].add(dev)"},{"line_number":1593,"context_line":""},{"line_number":1594,"context_line":"        if \u0027removed\u0027 in port_info and port_info[\u0027removed\u0027]:"},{"line_number":1595,"context_line":"            start \u003d time.time()"}],"source_content_type":"text/x-python","patch_set":34,"id":"da6ed579_44d14d22","line":1592,"updated":"2016-01-14 09:56:54.000000000","message":"failed_devices[\u0027added\u0027] \u003d failed_added","commit_id":"b54ac3e29e0123dec5e62de45cee0fa076f4be80"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"1cd32d7726cb41dbf163403eb6840aa019340967","unresolved":false,"context_lines":[{"line_number":1589,"context_line":"                      {\u0027iter_num\u0027: self.iter_num,"},{"line_number":1590,"context_line":"                       \u0027elapsed\u0027: time.time() - start})"},{"line_number":1591,"context_line":"            for dev in failed_added:"},{"line_number":1592,"context_line":"                failed_devices[\u0027added\u0027].add(dev)"},{"line_number":1593,"context_line":""},{"line_number":1594,"context_line":"        if \u0027removed\u0027 in port_info and port_info[\u0027removed\u0027]:"},{"line_number":1595,"context_line":"            start \u003d time.time()"}],"source_content_type":"text/x-python","patch_set":34,"id":"da6ed579_e5b5367e","line":1592,"in_reply_to":"da6ed579_44d14d22","updated":"2016-01-18 13:26:07.000000000","message":"Done","commit_id":"b54ac3e29e0123dec5e62de45cee0fa076f4be80"}],"neutron/tests/functional/agent/test_l2_ovs_agent.py":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"8767032c92129fbd859a140dbd349de1d85c42cf","unresolved":false,"context_lines":[{"line_number":74,"context_line":"            failed_dev_up\u003dTrue)"},{"line_number":75,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":76,"context_line":"        # be re-synced"},{"line_number":77,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":78,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dTrue)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def test_resync_dev_down_after_failure(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa1b9901_7dee41ee","line":77,"updated":"2015-08-26 11:08:42.000000000","message":"why do you need to add self.ports[0] again? \n\nI think that\u0027s not necessary to wait for the port up state :), but I could be missing something.","commit_id":"023bb66d2cd2fd5497792ddf84d6d112b136e7a3"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"33df5575227d3a52f9a25866e6e518bfbaad88c7","unresolved":false,"context_lines":[{"line_number":74,"context_line":"            failed_dev_up\u003dTrue)"},{"line_number":75,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":76,"context_line":"        # be re-synced"},{"line_number":77,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":78,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dTrue)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def test_resync_dev_down_after_failure(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"da20952f_10b54ccc","line":77,"in_reply_to":"fa1b9901_7dee41ee","updated":"2015-08-26 22:49:26.000000000","message":"Because that device is failing...so it needs to be resynced. If you look at what\u0027s returned by the rpc mock, you\u0027ll see it in the list of the failed devices. Maybe the comment is not clear enough?","commit_id":"023bb66d2cd2fd5497792ddf84d6d112b136e7a3"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"8767032c92129fbd859a140dbd349de1d85c42cf","unresolved":false,"context_lines":[{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":89,"context_line":"        # be re-synced"},{"line_number":90,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":91,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dFalse)"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    def test_ancillary_port_creation_and_deletion(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa1b9901_5d8edd2e","line":90,"updated":"2015-08-26 11:08:42.000000000","message":"ditto.","commit_id":"023bb66d2cd2fd5497792ddf84d6d112b136e7a3"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"8767032c92129fbd859a140dbd349de1d85c42cf","unresolved":false,"context_lines":[{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":144,"context_line":"        # be re-synced"},{"line_number":145,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":146,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dFalse)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"    def test_port_vlan_tags(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa1b9901_fdac9189","line":145,"updated":"2015-08-26 11:08:42.000000000","message":"ditto.","commit_id":"023bb66d2cd2fd5497792ddf84d6d112b136e7a3"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"ad4a5ded9a610fc41391ef194a4c3b6b272a3bc2","unresolved":false,"context_lines":[{"line_number":74,"context_line":"            failed_dev_up\u003dTrue)"},{"line_number":75,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":76,"context_line":"        # be re-synced"},{"line_number":77,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":78,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dTrue)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def test_resync_dev_down_after_failure(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"da20952f_6c44cc73","line":77,"updated":"2015-08-27 13:52:44.000000000","message":"Hmm, that expected_ports is finally rendered into a set, so any duplicates will be out:\n\nhttps://github.com/openstack/neutron/blob/master/neutron/tests/functional/agent/l2/base.py#L230\n\nOtherwise the wait_until_ports_state call would be very confusing itself.\n\nCan you check without adding that final self.ports[0] ? I believe it should work.","commit_id":"e8f94c785f5c5192a7f925ba5698620ab6f40195"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ce14c53699c2e6f6a397f934c78abd405b5e76dd","unresolved":false,"context_lines":[{"line_number":74,"context_line":"            failed_dev_up\u003dTrue)"},{"line_number":75,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":76,"context_line":"        # be re-synced"},{"line_number":77,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":78,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dTrue)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def test_resync_dev_down_after_failure(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"da20952f_ef4e8ec0","line":77,"in_reply_to":"da20952f_6c44cc73","updated":"2015-08-27 14:06:32.000000000","message":"it\u0027s not transformed into a set, I had to modify that line in this patch for this case (port that fails and is retried), see previous file lines 260-265 . I don\u0027t like that either. At first I have just added another wait_until_ports_state only for the failed port. Unfortunately that doesn\u0027t work, since there\u0027s no order guarantee...I mean the agent could send the update for port1, port2 and retry port1 and then send the update for port3...can\u0027t find any better way.","commit_id":"e8f94c785f5c5192a7f925ba5698620ab6f40195"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"e8a4a73d41b96b58cc2c16fa86e3a4afb1c21a2b","unresolved":false,"context_lines":[{"line_number":74,"context_line":"            failed_dev_up\u003dTrue)"},{"line_number":75,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":76,"context_line":"        # be re-synced"},{"line_number":77,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":78,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dTrue)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def test_resync_dev_down_after_failure(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"da20952f_d5feb437","line":77,"in_reply_to":"da20952f_ef4e8ec0","updated":"2015-08-27 17:20:46.000000000","message":"Yikes, silly me!,\n\nYou\u0027re right, I missed that change somehow.\n\nCould we update the docstrings of such methods to explain that if a port is more than once in the list, that means we expect the event to happen twice, or three or N times?.\n\nI guess that\u0027s the current behaviour, right?.\n\nThanks for the patience Rossella....","commit_id":"e8f94c785f5c5192a7f925ba5698620ab6f40195"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"ad4a5ded9a610fc41391ef194a4c3b6b272a3bc2","unresolved":false,"context_lines":[{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":89,"context_line":"        # be re-synced"},{"line_number":90,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":91,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dFalse)"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    def test_ancillary_port_creation_and_deletion(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"da20952f_8c49208e","line":90,"updated":"2015-08-27 13:52:44.000000000","message":"ditto :)","commit_id":"e8f94c785f5c5192a7f925ba5698620ab6f40195"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"e8a4a73d41b96b58cc2c16fa86e3a4afb1c21a2b","unresolved":false,"context_lines":[{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":89,"context_line":"        # be re-synced"},{"line_number":90,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":91,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dFalse)"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    def test_ancillary_port_creation_and_deletion(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"da20952f_15a3cc50","line":90,"in_reply_to":"da20952f_8c49208e","updated":"2015-08-27 17:20:46.000000000","message":"dittosorry ;)","commit_id":"e8f94c785f5c5192a7f925ba5698620ab6f40195"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"ad4a5ded9a610fc41391ef194a4c3b6b272a3bc2","unresolved":false,"context_lines":[{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":144,"context_line":"        # be re-synced"},{"line_number":145,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":146,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dFalse)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"    def test_port_vlan_tags(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"da20952f_cc363803","line":145,"updated":"2015-08-27 13:52:44.000000000","message":"ditto. :)","commit_id":"e8f94c785f5c5192a7f925ba5698620ab6f40195"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"e8a4a73d41b96b58cc2c16fa86e3a4afb1c21a2b","unresolved":false,"context_lines":[{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # in the RPC mock the first port fails and should"},{"line_number":144,"context_line":"        # be re-synced"},{"line_number":145,"context_line":"        expected_ports \u003d self.ports + [self.ports[0]]"},{"line_number":146,"context_line":"        self.wait_until_ports_state(expected_ports, up\u003dFalse)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"    def test_port_vlan_tags(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"da20952f_55c064e0","line":145,"in_reply_to":"da20952f_cc363803","updated":"2015-08-27 17:20:46.000000000","message":"dittosorry.","commit_id":"e8f94c785f5c5192a7f925ba5698620ab6f40195"}],"neutron/tests/unit/plugins/ml2/drivers/openvswitch/agent/test_ovs_neutron_agent.py":[{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"c2fedda285a423ee1191e15aa4e33ca47d74d98a","unresolved":false,"context_lines":[{"line_number":411,"context_line":"                              \u0027removed\u0027: set()}"},{"line_number":412,"context_line":"            expected_ancillary \u003d {\u0027current\u0027: ancillary_ports, \u0027added\u0027: set(),"},{"line_number":413,"context_line":"                                  \u0027removed\u0027: set()}"},{"line_number":414,"context_line":"            failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":415,"context_line":"            failed_ancillary_devices \u003d {"},{"line_number":416,"context_line":"                \u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":417,"context_line":"            devices_not_ready_yet \u003d []"}],"source_content_type":"text/x-python","patch_set":29,"id":"da85f559_a1bbbc71","line":414,"updated":"2015-11-09 13:35:01.000000000","message":"This initialization code L414-417 is repeated a lot in the tests (7). Could create a helper method with a descriptive name and use member variables. Alternatively, could consider placing init in setUp() or breacking tests out into a new class with init in setUp.","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"ff076c8e6f15a8e841435a4410932794ebf64505","unresolved":false,"context_lines":[{"line_number":411,"context_line":"                              \u0027removed\u0027: set()}"},{"line_number":412,"context_line":"            expected_ancillary \u003d {\u0027current\u0027: ancillary_ports, \u0027added\u0027: set(),"},{"line_number":413,"context_line":"                                  \u0027removed\u0027: set()}"},{"line_number":414,"context_line":"            failed_devices \u003d {\u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":415,"context_line":"            failed_ancillary_devices \u003d {"},{"line_number":416,"context_line":"                \u0027added\u0027: set(), \u0027removed\u0027: set()}"},{"line_number":417,"context_line":"            devices_not_ready_yet \u003d []"}],"source_content_type":"text/x-python","patch_set":29,"id":"7a740942_486d3531","line":414,"in_reply_to":"da85f559_a1bbbc71","updated":"2015-12-10 16:09:52.000000000","message":"I refactored a bit","commit_id":"97293737d0192a874f07f2825f17309ab6f1008b"}]}
