)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"4c26e53b06193c0de2a7a239a67b09f3d73ecd8e","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Create ports in quantum matching hypervisor MAC addresses."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"When hupervisors supply a set of MAC addresses for instances, the"},{"line_number":10,"context_line":"network driver is responsible for matching up the requested MACs and"},{"line_number":11,"context_line":"the available (or requested) networks."},{"line_number":12,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"AAAAM3%2F%2FidY%3D","line":9,"updated":"2013-01-16 20:03:13.000000000","message":"What\u0027s a hupervisor?","commit_id":"19a5fef41871470e44328e0f8861be216e5af0ea"},{"author":{"_account_id":4190,"name":"lifeless","email":"robertc@robertcollins.net","username":"lifeless"},"change_message_id":"aebf6522415db0bd4dc0ac71e06cdde7408349f3","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Create ports in quantum matching hypervisor MAC addresses."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"When hupervisors supply a set of MAC addresses for instances, the"},{"line_number":10,"context_line":"network driver is responsible for matching up the requested MACs and"},{"line_number":11,"context_line":"the available (or requested) networks."},{"line_number":12,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"AAAAM3%2F%2Fg5I%3D","line":9,"in_reply_to":"AAAAM3%2F%2FidY%3D","updated":"2013-01-17 19:07:52.000000000","message":"Done","commit_id":"19a5fef41871470e44328e0f8861be216e5af0ea"}],"nova/network/quantumv2/api.py":[{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"0f149b7b256982f5426c23070e79a5c2b7aec256","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        \"\"\""},{"line_number":120,"context_line":"        hypervisor_macs \u003d kwargs.get(\u0027macs\u0027, None)"},{"line_number":121,"context_line":"        available_macs \u003d None"},{"line_number":122,"context_line":"        if hypervisor_macs is not None:"},{"line_number":123,"context_line":"            # Make a copy we can mutate: records macs that have not been used"},{"line_number":124,"context_line":"            # to create a port on a network. If we find a mac with a"},{"line_number":125,"context_line":"            # pre-allocated port we also remove it from this set."}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAM3%2F%2Fjxg%3D","line":122,"updated":"2013-01-16 00:12:10.000000000","message":"I think if hypervisor_macs: is enough.","commit_id":"f32709c684bf38f53d9440bbbf486911d6252a2e"},{"author":{"_account_id":4190,"name":"lifeless","email":"robertc@robertcollins.net","username":"lifeless"},"change_message_id":"d161841c74b16d14837b885958f7ac9d650dd097","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        \"\"\""},{"line_number":120,"context_line":"        hypervisor_macs \u003d kwargs.get(\u0027macs\u0027, None)"},{"line_number":121,"context_line":"        available_macs \u003d None"},{"line_number":122,"context_line":"        if hypervisor_macs is not None:"},{"line_number":123,"context_line":"            # Make a copy we can mutate: records macs that have not been used"},{"line_number":124,"context_line":"            # to create a port on a network. If we find a mac with a"},{"line_number":125,"context_line":"            # pre-allocated port we also remove it from this set."}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAM3%2F%2FjtY%3D","line":122,"in_reply_to":"AAAAM3%2F%2Fjxg%3D","updated":"2013-01-16 00:44:37.000000000","message":"It is not enough, because None means \u0027do not constrain\u0027 but \u0027set()\u0027 means \u0027constrained to nothing\u0027.","commit_id":"f32709c684bf38f53d9440bbbf486911d6252a2e"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"0f149b7b256982f5426c23070e79a5c2b7aec256","unresolved":false,"context_lines":[{"line_number":147,"context_line":"                            # Don\u0027t try to use this MAC if we need to create a"},{"line_number":148,"context_line":"                            # port on the fly later. MACs can be configured by"},{"line_number":149,"context_line":"                            # users into multiple networks (for VLANs) so we"},{"line_number":150,"context_line":"                            # discard rather than popping."},{"line_number":151,"context_line":"                            available_macs.discard(port[\u0027mac_address\u0027])"},{"line_number":152,"context_line":"                    network_id \u003d port[\u0027network_id\u0027]"},{"line_number":153,"context_line":"                    ports[network_id] \u003d port"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAM3%2F%2Fjvs%3D","line":150,"updated":"2013-01-16 00:12:10.000000000","message":"I don\u0027t think the reason to use discard instead of pop is proper here.\nboth discard and pop can be used to remove a element in the set, pop removes, returns or raises if empty, discard just removes.","commit_id":"f32709c684bf38f53d9440bbbf486911d6252a2e"},{"author":{"_account_id":4190,"name":"lifeless","email":"robertc@robertcollins.net","username":"lifeless"},"change_message_id":"d161841c74b16d14837b885958f7ac9d650dd097","unresolved":false,"context_lines":[{"line_number":147,"context_line":"                            # Don\u0027t try to use this MAC if we need to create a"},{"line_number":148,"context_line":"                            # port on the fly later. MACs can be configured by"},{"line_number":149,"context_line":"                            # users into multiple networks (for VLANs) so we"},{"line_number":150,"context_line":"                            # discard rather than popping."},{"line_number":151,"context_line":"                            available_macs.discard(port[\u0027mac_address\u0027])"},{"line_number":152,"context_line":"                    network_id \u003d port[\u0027network_id\u0027]"},{"line_number":153,"context_line":"                    ports[network_id] \u003d port"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAM3%2F%2FjtU%3D","line":150,"in_reply_to":"AAAAM3%2F%2Fjvs%3D","updated":"2013-01-16 00:44:37.000000000","message":"Thats exactly why. We don\u0027t want the raise.","commit_id":"f32709c684bf38f53d9440bbbf486911d6252a2e"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"0f149b7b256982f5426c23070e79a5c2b7aec256","unresolved":false,"context_lines":[{"line_number":176,"context_line":"                    port_req_body[\u0027port\u0027][\u0027network_id\u0027] \u003d network_id"},{"line_number":177,"context_line":"                    port_req_body[\u0027port\u0027][\u0027admin_state_up\u0027] \u003d True"},{"line_number":178,"context_line":"                    port_req_body[\u0027port\u0027][\u0027tenant_id\u0027] \u003d instance[\u0027project_id\u0027]"},{"line_number":179,"context_line":"                    if available_macs is not None:"},{"line_number":180,"context_line":"                        if not available_macs:"},{"line_number":181,"context_line":"                            raise exception.PortNotFree("},{"line_number":182,"context_line":"                                instance\u003dinstance[\u0027display_name\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAM3%2F%2FjxU%3D","line":179,"updated":"2013-01-16 00:12:10.000000000","message":"if available_macs:","commit_id":"f32709c684bf38f53d9440bbbf486911d6252a2e"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"0f149b7b256982f5426c23070e79a5c2b7aec256","unresolved":false,"context_lines":[{"line_number":179,"context_line":"                    if available_macs is not None:"},{"line_number":180,"context_line":"                        if not available_macs:"},{"line_number":181,"context_line":"                            raise exception.PortNotFree("},{"line_number":182,"context_line":"                                instance\u003dinstance[\u0027display_name\u0027])"},{"line_number":183,"context_line":"                        mac_address \u003d available_macs.pop()"},{"line_number":184,"context_line":"                        port_req_body[\u0027port\u0027][\u0027mac_address\u0027] \u003d mac_address"},{"line_number":185,"context_line":"                    created_port_ids.append("}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAM3%2F%2Fjwc%3D","line":182,"updated":"2013-01-16 00:12:10.000000000","message":"are lines 181-182 reachable?","commit_id":"f32709c684bf38f53d9440bbbf486911d6252a2e"},{"author":{"_account_id":4190,"name":"lifeless","email":"robertc@robertcollins.net","username":"lifeless"},"change_message_id":"d161841c74b16d14837b885958f7ac9d650dd097","unresolved":false,"context_lines":[{"line_number":179,"context_line":"                    if available_macs is not None:"},{"line_number":180,"context_line":"                        if not available_macs:"},{"line_number":181,"context_line":"                            raise exception.PortNotFree("},{"line_number":182,"context_line":"                                instance\u003dinstance[\u0027display_name\u0027])"},{"line_number":183,"context_line":"                        mac_address \u003d available_macs.pop()"},{"line_number":184,"context_line":"                        port_req_body[\u0027port\u0027][\u0027mac_address\u0027] \u003d mac_address"},{"line_number":185,"context_line":"                    created_port_ids.append("}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAM3%2F%2FjtQ%3D","line":182,"in_reply_to":"AAAAM3%2F%2Fjwc%3D","updated":"2013-01-16 00:44:37.000000000","message":"Yes, tests confirm they are reachable. Your suggestions above would make them unreachable :)","commit_id":"f32709c684bf38f53d9440bbbf486911d6252a2e"}]}
