)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This patch adds a virtual network interface API in order to abstract the"},{"line_number":10,"context_line":"task of assigning logical network interfaces to physical network"},{"line_number":11,"context_line":"interfaces. Since Newton Ironic provides an interface for pluggable"},{"line_number":12,"context_line":"network implementations. Different network implementations may want to"},{"line_number":13,"context_line":"handle how logical to physical network interface assignment happens. To"},{"line_number":14,"context_line":"do this the new API calls into new functions on the network"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":26,"id":"5a74a57a_6667eeea","line":11,"updated":"2016-11-30 02:19:25.000000000","message":"nit, the sentence that starts with \u0027Since...\u0027 isn\u0027t complete.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This patch adds a virtual network interface API in order to abstract the"},{"line_number":10,"context_line":"task of assigning logical network interfaces to physical network"},{"line_number":11,"context_line":"interfaces. Since Newton Ironic provides an interface for pluggable"},{"line_number":12,"context_line":"network implementations. Different network implementations may want to"},{"line_number":13,"context_line":"handle how logical to physical network interface assignment happens. To"},{"line_number":14,"context_line":"do this the new API calls into new functions on the network"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":26,"id":"5a74a57a_5648c05b","line":11,"in_reply_to":"5a74a57a_6667eeea","updated":"2016-11-30 16:12:57.000000000","message":"Done","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Since the OpenStack Newton release, Ironic provides an interface for"},{"line_number":14,"context_line":"pluggable network implementations. Different network implementations may"},{"line_number":15,"context_line":"want to handle how logical to physical network interface assignment"},{"line_number":16,"context_line":"happens. To do this the new API calls into new functions on the network"},{"line_number":17,"context_line":"implementation loaded for the specified node."},{"line_number":18,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":27,"id":"3a71b18c_02afc494","line":15,"updated":"2016-12-02 13:58:52.000000000","message":"Please update commit message to reflect this patch changes.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":19,"context_line":"This is part 1 of 3, and adds four new functions vif_attach, vif_detach,"},{"line_number":20,"context_line":"vif_list and port_changed, to the base network interface class, which"},{"line_number":21,"context_line":"should be overridden by network interface implementations."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Change-Id: I0b84cfd85557d18254697f2e539c583ea0f8e88c"},{"line_number":24,"context_line":"Partial-Bug: #1582188"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":27,"id":"5a74a57a_d2a5aa47","line":22,"updated":"2016-11-30 22:09:24.000000000","message":"If something has been deprecated, we should mention it here.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4f78464056c02c4452224e4f69e3488d1709f5e0","unresolved":false,"context_lines":[{"line_number":19,"context_line":"This is part 1 of 3, and adds four new functions vif_attach, vif_detach,"},{"line_number":20,"context_line":"vif_list and port_changed, to the base network interface class, which"},{"line_number":21,"context_line":"should be overridden by network interface implementations."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Change-Id: I0b84cfd85557d18254697f2e539c583ea0f8e88c"},{"line_number":24,"context_line":"Partial-Bug: #1582188"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":27,"id":"3a71b18c_ff764fa2","line":22,"in_reply_to":"3a71b18c_6554c2fe","updated":"2016-12-06 22:36:28.000000000","message":"Not sure. I guess the clock would start ticking when the release note lands...\n\nAlthough I think what I was thinking about (it was a few days ago) is that if we deprecate anything in the code patch here, that it ought to be mentioned in the commit msg.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":19,"context_line":"This is part 1 of 3, and adds four new functions vif_attach, vif_detach,"},{"line_number":20,"context_line":"vif_list and port_changed, to the base network interface class, which"},{"line_number":21,"context_line":"should be overridden by network interface implementations."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Change-Id: I0b84cfd85557d18254697f2e539c583ea0f8e88c"},{"line_number":24,"context_line":"Partial-Bug: #1582188"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":27,"id":"3a71b18c_6554c2fe","line":22,"in_reply_to":"5a74a57a_d2a5aa47","updated":"2016-12-06 11:43:59.000000000","message":"I don\u0027t think anything is deprecated until the REST API part lands right?, or should I include it in all 3 commit messages?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"}],"ironic/api/controllers/v1/node.py":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":1045,"context_line":"    @expose.expose(types.jsontype)"},{"line_number":1046,"context_line":"    def get_all(self):"},{"line_number":1047,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1048,"context_line":"        print(rpc_node)"},{"line_number":1049,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1050,"context_line":"        print(topic)"},{"line_number":1051,"context_line":"        vifs \u003d pecan.request.rpcapi.vif_list(pecan.request.context,"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_112afc2c","line":1048,"updated":"2016-11-13 22:17:58.000000000","message":"Prints should not be here :)","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":1045,"context_line":"    @expose.expose(types.jsontype)"},{"line_number":1046,"context_line":"    def get_all(self):"},{"line_number":1047,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1048,"context_line":"        print(rpc_node)"},{"line_number":1049,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1050,"context_line":"        print(topic)"},{"line_number":1051,"context_line":"        vifs \u003d pecan.request.rpcapi.vif_list(pecan.request.context,"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_d2d798eb","line":1048,"in_reply_to":"9a629dbe_112afc2c","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":1052,"context_line":"                                             rpc_node.uuid, topic\u003dtopic)"},{"line_number":1053,"context_line":"        return {\"vifs\": vifs}"},{"line_number":1054,"context_line":""},{"line_number":1055,"context_line":"    @expose.expose(None, body\u003dtypes.jsontype)"},{"line_number":1056,"context_line":"    def post(self, vif):"},{"line_number":1057,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1058,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_311f000b","line":1055,"range":{"start_line":1055,"start_character":30,"end_line":1055,"end_character":44},"updated":"2016-11-13 22:17:58.000000000","message":"Do we want to define a type for it?","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":1061,"context_line":"        return pecan.request.rpcapi.vif_attach("},{"line_number":1062,"context_line":"            pecan.request.context, rpc_node.uuid, vif\u003dvif, topic\u003dtopic)"},{"line_number":1063,"context_line":""},{"line_number":1064,"context_line":"    @expose.expose(None, types.uuid_or_name)"},{"line_number":1065,"context_line":"    def delete(self, vif_id):"},{"line_number":1066,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1067,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_69aee7e8","line":1064,"updated":"2016-11-14 09:13:18.000000000","message":"vif_id should be UUID like.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":1061,"context_line":"        return pecan.request.rpcapi.vif_attach("},{"line_number":1062,"context_line":"            pecan.request.context, rpc_node.uuid, vif\u003dvif, topic\u003dtopic)"},{"line_number":1063,"context_line":""},{"line_number":1064,"context_line":"    @expose.expose(None, types.uuid_or_name)"},{"line_number":1065,"context_line":"    def delete(self, vif_id):"},{"line_number":1066,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1067,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_12baf0c0","line":1064,"in_reply_to":"9a629dbe_69aee7e8","updated":"2016-11-14 14:21:30.000000000","message":"vif_id can be any string to allow for ironic standalone cases when they might use an arbitrary name as to identify a vif","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":1107,"context_line":"    _subcontroller_map \u003d {"},{"line_number":1108,"context_line":"        \u0027ports\u0027: port.PortsController,"},{"line_number":1109,"context_line":"        \u0027portgroups\u0027: portgroup.PortgroupsController,"},{"line_number":1110,"context_line":"        \u0027vifs\u0027: NodeVIFController,"},{"line_number":1111,"context_line":"    }"},{"line_number":1112,"context_line":""},{"line_number":1113,"context_line":"    @pecan.expose()"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_09780b8f","line":1110,"updated":"2016-11-14 09:13:18.000000000","message":"We should bump API version and show vifs subcontroller only when request uses right API version.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a0a505cab77f790e81f3d319d0a0d7daf28b75c2","unresolved":false,"context_lines":[{"line_number":1107,"context_line":"    _subcontroller_map \u003d {"},{"line_number":1108,"context_line":"        \u0027ports\u0027: port.PortsController,"},{"line_number":1109,"context_line":"        \u0027portgroups\u0027: portgroup.PortgroupsController,"},{"line_number":1110,"context_line":"        \u0027vifs\u0027: NodeVIFController,"},{"line_number":1111,"context_line":"    }"},{"line_number":1112,"context_line":""},{"line_number":1113,"context_line":"    @pecan.expose()"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_7dc69d4a","line":1110,"in_reply_to":"9a629dbe_09780b8f","updated":"2016-11-14 10:28:15.000000000","message":"Oh, right, there is no api microversion bump :( note to self: do not review things at night.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":1107,"context_line":"    _subcontroller_map \u003d {"},{"line_number":1108,"context_line":"        \u0027ports\u0027: port.PortsController,"},{"line_number":1109,"context_line":"        \u0027portgroups\u0027: portgroup.PortgroupsController,"},{"line_number":1110,"context_line":"        \u0027vifs\u0027: NodeVIFController,"},{"line_number":1111,"context_line":"    }"},{"line_number":1112,"context_line":""},{"line_number":1113,"context_line":"    @pecan.expose()"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_f89e3bb7","line":1110,"in_reply_to":"9a629dbe_7dc69d4a","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":1054,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1055,"context_line":"        if vif.get(\u0027id\u0027) is None:"},{"line_number":1056,"context_line":"            raise exception.MissingParameterValue(_(\"VIF id not specified.\"))"},{"line_number":1057,"context_line":"        return pecan.request.rpcapi.vif_attach("},{"line_number":1058,"context_line":"            pecan.request.context, rpc_node.uuid, vif\u003dvif, topic\u003dtopic)"},{"line_number":1059,"context_line":""},{"line_number":1060,"context_line":"    @expose.expose(None, types.uuid_or_name)"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_0bfaa642","line":1057,"updated":"2016-11-15 15:52:26.000000000","message":"We should check that vif_id is valid uuid or name.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5141d24a4ca5c81c5e1679a9ea6fb43fb4d6f582","unresolved":false,"context_lines":[{"line_number":1054,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1055,"context_line":"        if vif.get(\u0027id\u0027) is None:"},{"line_number":1056,"context_line":"            raise exception.MissingParameterValue(_(\"VIF id not specified.\"))"},{"line_number":1057,"context_line":"        return pecan.request.rpcapi.vif_attach("},{"line_number":1058,"context_line":"            pecan.request.context, rpc_node.uuid, vif\u003dvif, topic\u003dtopic)"},{"line_number":1059,"context_line":""},{"line_number":1060,"context_line":"    @expose.expose(None, types.uuid_or_name)"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_6659685a","line":1057,"in_reply_to":"7a77a97e_0bfaa642","updated":"2016-11-16 12:15:22.000000000","message":"Done","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"7a1ebf55804878f65759a80a04991bed9c9366f5","unresolved":false,"context_lines":[{"line_number":1041,"context_line":"        self.node_ident \u003d node_ident"},{"line_number":1042,"context_line":""},{"line_number":1043,"context_line":"    @expose.expose(types.jsontype)"},{"line_number":1044,"context_line":"    def get_all(self):"},{"line_number":1045,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1046,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1047,"context_line":"        vifs \u003d pecan.request.rpcapi.vif_list(pecan.request.context,"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_b2e414ac","line":1044,"updated":"2016-11-18 19:33:55.000000000","message":"Can you add docstrings defining any parameters, return value, and what exceptions may be raised? For example, it\u0027s not clear here that NodeNotFound may be raised, even though that\u0027s a possible result when calling get_rpc_node.\n\nI also wonder whether any particular pecan calls need to be made for NodeNotFound exceptions, or if that will be done by the supercontroller","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":1041,"context_line":"        self.node_ident \u003d node_ident"},{"line_number":1042,"context_line":""},{"line_number":1043,"context_line":"    @expose.expose(types.jsontype)"},{"line_number":1044,"context_line":"    def get_all(self):"},{"line_number":1045,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1046,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1047,"context_line":"        vifs \u003d pecan.request.rpcapi.vif_list(pecan.request.context,"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_ed359ba8","line":1044,"in_reply_to":"7a77a97e_b2e414ac","updated":"2016-11-21 17:37:45.000000000","message":"Handling of the exceptions is in the Ironic API middleware, each IronicException has a status code and message and that gets used by the middleware to generate a response.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"657457cee00d3471cdcf8cf0c5fba69b54700335","unresolved":false,"context_lines":[{"line_number":1119,"context_line":"            pecan.abort(http_client.BAD_REQUEST, e.args[0])"},{"line_number":1120,"context_line":"        if not remainder:"},{"line_number":1121,"context_line":"            return"},{"line_number":1122,"context_line":"        if (remainder[0] not in self._subcontroller_map or"},{"line_number":1123,"context_line":"            (remainder[0] \u003d\u003d \u0027portgroups\u0027 and"},{"line_number":1124,"context_line":"                not api_utils.allow_portgroups_subcontrollers()) or"},{"line_number":1125,"context_line":"            (remainder[0] \u003d\u003d \u0027vifs\u0027 and"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_387dc81c","line":1122,"updated":"2016-11-16 13:20:11.000000000","message":"this breaks access to v1/nodes/{node_ident}/validate subcontroller as\n remainder[0] not in self._subcontroller_map is True in this case and API return 404.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"016cb2c86d3ca2454046c49fad539cf799a88169","unresolved":false,"context_lines":[{"line_number":1119,"context_line":"            pecan.abort(http_client.BAD_REQUEST, e.args[0])"},{"line_number":1120,"context_line":"        if not remainder:"},{"line_number":1121,"context_line":"            return"},{"line_number":1122,"context_line":"        if (remainder[0] not in self._subcontroller_map or"},{"line_number":1123,"context_line":"            (remainder[0] \u003d\u003d \u0027portgroups\u0027 and"},{"line_number":1124,"context_line":"                not api_utils.allow_portgroups_subcontrollers()) or"},{"line_number":1125,"context_line":"            (remainder[0] \u003d\u003d \u0027vifs\u0027 and"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_fb04f24a","line":1122,"in_reply_to":"7a77a97e_387dc81c","updated":"2016-11-17 12:33:41.000000000","message":"According to our unit tests we don\u0027t support that API, validate is only valid on /nodes/validate?node\u003d https://github.com/openstack/ironic/blob/master/ironic/tests/unit/api/v1/test_nodes.py#L1015 \n\nbut then we\u0027ve documented it the other way \nhttp://developer.openstack.org/api-ref/baremetal/#validate-node\n\nif we want /nodes/\u003cnode_ident\u003e/validate not /nodes/validate?node\u003d then we need to change the function definition of validate below to have one not optional parameter. IMO this is a bug with validate.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":1119,"context_line":"            pecan.abort(http_client.BAD_REQUEST, e.args[0])"},{"line_number":1120,"context_line":"        if not remainder:"},{"line_number":1121,"context_line":"            return"},{"line_number":1122,"context_line":"        if (remainder[0] not in self._subcontroller_map or"},{"line_number":1123,"context_line":"            (remainder[0] \u003d\u003d \u0027portgroups\u0027 and"},{"line_number":1124,"context_line":"                not api_utils.allow_portgroups_subcontrollers()) or"},{"line_number":1125,"context_line":"            (remainder[0] \u003d\u003d \u0027vifs\u0027 and"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_ed03dbbc","line":1122,"in_reply_to":"7a77a97e_d01fd6b4","updated":"2016-11-21 17:37:45.000000000","message":"We really need to change/add unit tests for this then, because otherwise the only tests that catch this is the tempest plugin. I have created a bug for this: https://bugs.launchpad.net/ironic/+bug/1643567","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":1119,"context_line":"            pecan.abort(http_client.BAD_REQUEST, e.args[0])"},{"line_number":1120,"context_line":"        if not remainder:"},{"line_number":1121,"context_line":"            return"},{"line_number":1122,"context_line":"        if (remainder[0] not in self._subcontroller_map or"},{"line_number":1123,"context_line":"            (remainder[0] \u003d\u003d \u0027portgroups\u0027 and"},{"line_number":1124,"context_line":"                not api_utils.allow_portgroups_subcontrollers()) or"},{"line_number":1125,"context_line":"            (remainder[0] \u003d\u003d \u0027vifs\u0027 and"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_d01fd6b4","line":1122,"in_reply_to":"7a77a97e_fb04f24a","updated":"2016-11-18 14:46:16.000000000","message":"/node/\u003cnode-dent\u003e/validate is documented method to start validate() on node, ironicclient uses it also [0], we can\u0027t just drop it.\n\n[0] https://github.com/openstack/python-ironicclient/blob/master/ironicclient/v1/node.py#L293","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":1042,"context_line":""},{"line_number":1043,"context_line":"    @expose.expose(types.jsontype)"},{"line_number":1044,"context_line":"    def get_all(self):"},{"line_number":1045,"context_line":"        \u0027\u0027\u0027Get a list of attach VIF IDs\u0027\u0027\u0027"},{"line_number":1046,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1047,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1048,"context_line":"        vifs \u003d pecan.request.rpcapi.vif_list(pecan.request.context,"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_ce77b99d","line":1045,"range":{"start_line":1045,"start_character":25,"end_line":1045,"end_character":31},"updated":"2016-11-24 12:15:19.000000000","message":"attached?","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":1042,"context_line":""},{"line_number":1043,"context_line":"    @expose.expose(types.jsontype)"},{"line_number":1044,"context_line":"    def get_all(self):"},{"line_number":1045,"context_line":"        \u0027\u0027\u0027Get a list of attach VIF IDs\u0027\u0027\u0027"},{"line_number":1046,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1047,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1048,"context_line":"        vifs \u003d pecan.request.rpcapi.vif_list(pecan.request.context,"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_7069b6f8","line":1045,"range":{"start_line":1045,"start_character":25,"end_line":1045,"end_character":31},"in_reply_to":"5a74a57a_ce77b99d","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":1044,"context_line":"    def get_all(self):"},{"line_number":1045,"context_line":"        \u0027\u0027\u0027Get a list of attach VIF IDs\u0027\u0027\u0027"},{"line_number":1046,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1047,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1048,"context_line":"        vifs \u003d pecan.request.rpcapi.vif_list(pecan.request.context,"},{"line_number":1049,"context_line":"                                             rpc_node.uuid, topic\u003dtopic)"},{"line_number":1050,"context_line":"        return {\"vifs\": vifs}"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_ce0899dc","line":1047,"range":{"start_line":1047,"start_character":37,"end_line":1047,"end_character":50},"updated":"2016-11-24 12:15:19.000000000","message":"seems like we need to handle NoValidHost here like we do on L1002.","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":1044,"context_line":"    def get_all(self):"},{"line_number":1045,"context_line":"        \u0027\u0027\u0027Get a list of attach VIF IDs\u0027\u0027\u0027"},{"line_number":1046,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1047,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1048,"context_line":"        vifs \u003d pecan.request.rpcapi.vif_list(pecan.request.context,"},{"line_number":1049,"context_line":"                                             rpc_node.uuid, topic\u003dtopic)"},{"line_number":1050,"context_line":"        return {\"vifs\": vifs}"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_50667a2a","line":1047,"range":{"start_line":1047,"start_character":37,"end_line":1047,"end_character":50},"in_reply_to":"5a74a57a_ce0899dc","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":1056,"context_line":"        :param vif: A VIF object to attach"},{"line_number":1057,"context_line":"        \u0027\u0027\u0027"},{"line_number":1058,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1059,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1060,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":1061,"context_line":"        if vif_id is None:"},{"line_number":1062,"context_line":"            raise exception.MissingParameterValue(_(\"VIF id not specified.\"))"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_ee0f15df","line":1059,"updated":"2016-11-24 12:15:19.000000000","message":"ditto","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":1056,"context_line":"        :param vif: A VIF object to attach"},{"line_number":1057,"context_line":"        \u0027\u0027\u0027"},{"line_number":1058,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1059,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1060,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":1061,"context_line":"        if vif_id is None:"},{"line_number":1062,"context_line":"            raise exception.MissingParameterValue(_(\"VIF id not specified.\"))"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_906c9209","line":1059,"in_reply_to":"5a74a57a_ee0f15df","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":1063,"context_line":"        try:"},{"line_number":1064,"context_line":"            types.uuid_or_name.validate(vif_id)"},{"line_number":1065,"context_line":"        except exception.InvalidUuidOrName as e:"},{"line_number":1066,"context_line":"            pecan.abort(http_client.BAD_REQUEST, e.args[0])"},{"line_number":1067,"context_line":"        return pecan.request.rpcapi.vif_attach("},{"line_number":1068,"context_line":"            pecan.request.context, rpc_node.uuid, vif\u003dvif, topic\u003dtopic)"},{"line_number":1069,"context_line":""}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_6ee86511","line":1066,"range":{"start_line":1066,"start_character":12,"end_line":1066,"end_character":59},"updated":"2016-11-24 12:15:19.000000000","message":"Please don\u0027t use the pecan.abort things outside of the _lookup, there is no need in this, as we\u0027ll have to fix all such places during the making of all ironic api errors formats the same. You could just use any ironic exception here, or at least wsme.exc.","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":1063,"context_line":"        try:"},{"line_number":1064,"context_line":"            types.uuid_or_name.validate(vif_id)"},{"line_number":1065,"context_line":"        except exception.InvalidUuidOrName as e:"},{"line_number":1066,"context_line":"            pecan.abort(http_client.BAD_REQUEST, e.args[0])"},{"line_number":1067,"context_line":"        return pecan.request.rpcapi.vif_attach("},{"line_number":1068,"context_line":"            pecan.request.context, rpc_node.uuid, vif\u003dvif, topic\u003dtopic)"},{"line_number":1069,"context_line":""}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_538be41e","line":1066,"range":{"start_line":1066,"start_character":12,"end_line":1066,"end_character":59},"in_reply_to":"5a74a57a_6ee86511","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":1074,"context_line":"        :param vif_id: The ID of a VIF to detach"},{"line_number":1075,"context_line":"        \u0027\u0027\u0027"},{"line_number":1076,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1077,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1078,"context_line":"        return pecan.request.rpcapi.vif_detach("},{"line_number":1079,"context_line":"            pecan.request.context, rpc_node.uuid, vif_id\u003dvif_id, topic\u003dtopic)"},{"line_number":1080,"context_line":""}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_4ef569c9","line":1077,"updated":"2016-11-24 12:15:19.000000000","message":"ditto","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":1074,"context_line":"        :param vif_id: The ID of a VIF to detach"},{"line_number":1075,"context_line":"        \u0027\u0027\u0027"},{"line_number":1076,"context_line":"        rpc_node \u003d api_utils.get_rpc_node(self.node_ident)"},{"line_number":1077,"context_line":"        topic \u003d pecan.request.rpcapi.get_topic_for(rpc_node)"},{"line_number":1078,"context_line":"        return pecan.request.rpcapi.vif_detach("},{"line_number":1079,"context_line":"            pecan.request.context, rpc_node.uuid, vif_id\u003dvif_id, topic\u003dtopic)"},{"line_number":1080,"context_line":""}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_9381fcfd","line":1077,"in_reply_to":"5a74a57a_4ef569c9","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"}],"ironic/api/controllers/v1/versions.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":56,"context_line":"# v1.24: Add subcontrollers: node.portgroup, portgroup.ports."},{"line_number":57,"context_line":"#        Add port.portgroup_uuid field."},{"line_number":58,"context_line":"# v1.25: Add possibility to unset chassis_uuid from node."},{"line_number":59,"context_line":"# v1.26: Add ability to attach vifs to nodes"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"MINOR_0_JUNO \u003d 0"},{"line_number":62,"context_line":"MINOR_1_INITIAL_VERSION \u003d 1"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_901425f6","line":59,"updated":"2016-11-15 15:52:26.000000000","message":"previously user had ability to add vif_port_id to extra directly.\nMight be: \"v1.26: Add vifs subcontroller to node\"","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5141d24a4ca5c81c5e1679a9ea6fb43fb4d6f582","unresolved":false,"context_lines":[{"line_number":56,"context_line":"# v1.24: Add subcontrollers: node.portgroup, portgroup.ports."},{"line_number":57,"context_line":"#        Add port.portgroup_uuid field."},{"line_number":58,"context_line":"# v1.25: Add possibility to unset chassis_uuid from node."},{"line_number":59,"context_line":"# v1.26: Add ability to attach vifs to nodes"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"MINOR_0_JUNO \u003d 0"},{"line_number":62,"context_line":"MINOR_1_INITIAL_VERSION \u003d 1"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_614cf270","line":59,"in_reply_to":"7a77a97e_901425f6","updated":"2016-11-16 12:15:22.000000000","message":"Done","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"}],"ironic/common/exception.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ec0d55c1052e46b5e33e097bc37ae9e62fb6c9dd","unresolved":false,"context_lines":[{"line_number":233,"context_line":""},{"line_number":234,"context_line":"class NoFreePhysicalPorts(Invalid):"},{"line_number":235,"context_line":"    _msg_fmt \u003d _(\"Unable to attach VIF %(vif)s, not \""},{"line_number":236,"context_line":"                 \"enough physical ports.\")"},{"line_number":237,"context_line":""},{"line_number":238,"context_line":""},{"line_number":239,"context_line":"class VifNotAttached(Invalid):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a6eadb0_67dadfe9","line":236,"updated":"2016-12-15 22:03:26.000000000","message":"there may be physical ports, just that there aren\u0027t any free/available?","commit_id":"bf1b5364da63622064678c76bef0e7bc74fd5447"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"b53aebf2711e2d6fb535c0a20b9366cdb2da4bf9","unresolved":false,"context_lines":[{"line_number":233,"context_line":""},{"line_number":234,"context_line":"class NoFreePhysicalPorts(Invalid):"},{"line_number":235,"context_line":"    _msg_fmt \u003d _(\"Unable to attach VIF %(vif)s, not \""},{"line_number":236,"context_line":"                 \"enough physical ports.\")"},{"line_number":237,"context_line":""},{"line_number":238,"context_line":""},{"line_number":239,"context_line":"class VifNotAttached(Invalid):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a6eadb0_5cbcbaba","line":236,"in_reply_to":"1a6eadb0_67dadfe9","updated":"2016-12-16 12:20:48.000000000","message":"Done","commit_id":"bf1b5364da63622064678c76bef0e7bc74fd5447"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ec0d55c1052e46b5e33e097bc37ae9e62fb6c9dd","unresolved":false,"context_lines":[{"line_number":238,"context_line":""},{"line_number":239,"context_line":"class VifNotAttached(Invalid):"},{"line_number":240,"context_line":"    _msg_fmt \u003d _(\"Unable to detach VIF: VIF %(vif)s not attached to node \""},{"line_number":241,"context_line":"                 \"%(node)s\")"},{"line_number":242,"context_line":""},{"line_number":243,"context_line":""},{"line_number":244,"context_line":"class InvalidUUID(Invalid):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a6eadb0_6701ff37","line":241,"updated":"2016-12-15 22:03:26.000000000","message":"I\u0027d probably word it something like \u0027Unable to detach VIF %(vif)s from node %(node)s because it is not attached to it.\u0027","commit_id":"bf1b5364da63622064678c76bef0e7bc74fd5447"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"b53aebf2711e2d6fb535c0a20b9366cdb2da4bf9","unresolved":false,"context_lines":[{"line_number":238,"context_line":""},{"line_number":239,"context_line":"class VifNotAttached(Invalid):"},{"line_number":240,"context_line":"    _msg_fmt \u003d _(\"Unable to detach VIF: VIF %(vif)s not attached to node \""},{"line_number":241,"context_line":"                 \"%(node)s\")"},{"line_number":242,"context_line":""},{"line_number":243,"context_line":""},{"line_number":244,"context_line":"class InvalidUUID(Invalid):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a6eadb0_9ce9f2b9","line":241,"in_reply_to":"1a6eadb0_6701ff37","updated":"2016-12-16 12:20:48.000000000","message":"Done","commit_id":"bf1b5364da63622064678c76bef0e7bc74fd5447"}],"ironic/common/network.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":40,"context_line":"               portgroup.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":41,"context_line":"               portgroup.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":42,"context_line":"               portgroup.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":43,"context_line":"        if vif:"},{"line_number":44,"context_line":"            portgroup_vifs[portgroup.uuid] \u003d vif"},{"line_number":45,"context_line":"    vifs[\u0027portgroups\u0027] \u003d portgroup_vifs"},{"line_number":46,"context_line":"    for port in task.ports:"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_c9e37332","line":43,"updated":"2016-11-14 09:13:18.000000000","message":"might be use internal_info with high precedence than extra?","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"7a1ebf55804878f65759a80a04991bed9c9366f5","unresolved":false,"context_lines":[{"line_number":38,"context_line":"        # network"},{"line_number":39,"context_line":"        vif \u003d (portgroup.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":40,"context_line":"               portgroup.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":41,"context_line":"               portgroup.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":42,"context_line":"               portgroup.extra.get(\u0027vif_port_id\u0027))"},{"line_number":43,"context_line":"        if vif:"},{"line_number":44,"context_line":"            portgroup_vifs[portgroup.uuid] \u003d vif"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_b2a97426","line":41,"updated":"2016-11-18 19:33:55.000000000","message":"Is there a reasoning behind having internal_info vif_port_id take precedence over extra vif_port_id? If so, would you mind updating vdrok\u0027s comment above indicating why?","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":38,"context_line":"        # network"},{"line_number":39,"context_line":"        vif \u003d (portgroup.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":40,"context_line":"               portgroup.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":41,"context_line":"               portgroup.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":42,"context_line":"               portgroup.extra.get(\u0027vif_port_id\u0027))"},{"line_number":43,"context_line":"        if vif:"},{"line_number":44,"context_line":"            portgroup_vifs[portgroup.uuid] \u003d vif"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_cd1c5fc4","line":41,"in_reply_to":"7a77a97e_b2a97426","updated":"2016-11-21 17:37:45.000000000","message":"internal_info.vif_port_id takes precedence over extra.vif_port_id because its the new location for the vif_port_id. Support for extra.vif_port_id wil be removed in the future.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":39,"context_line":"        vif \u003d (portgroup.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":40,"context_line":"               portgroup.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":41,"context_line":"               portgroup.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":42,"context_line":"               portgroup.extra.get(\u0027vif_port_id\u0027))"},{"line_number":43,"context_line":"        if vif:"},{"line_number":44,"context_line":"            portgroup_vifs[portgroup.uuid] \u003d vif"},{"line_number":45,"context_line":"    vifs[\u0027portgroups\u0027] \u003d portgroup_vifs"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_c64522b4","line":42,"updated":"2016-11-30 02:19:25.000000000","message":"when do we start deprecating this?","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":39,"context_line":"        vif \u003d (portgroup.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":40,"context_line":"               portgroup.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":41,"context_line":"               portgroup.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":42,"context_line":"               portgroup.extra.get(\u0027vif_port_id\u0027))"},{"line_number":43,"context_line":"        if vif:"},{"line_number":44,"context_line":"            portgroup_vifs[portgroup.uuid] \u003d vif"},{"line_number":45,"context_line":"    vifs[\u0027portgroups\u0027] \u003d portgroup_vifs"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_96d7b822","line":42,"in_reply_to":"5a74a57a_c64522b4","updated":"2016-11-30 16:12:57.000000000","message":"IMO From the point when the attach/detach REST API lands setting the vif_port_id via port_update is deprecated.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        if vif:"},{"line_number":52,"context_line":"            port_vifs[port.uuid] \u003d vif"},{"line_number":53,"context_line":"    vifs[\u0027ports\u0027] \u003d port_vifs"},{"line_number":54,"context_line":"    return vifs"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_46839bcc","line":54,"updated":"2016-11-30 22:09:24.000000000","message":"We should probably update the tests at https://github.com/openstack/ironic/blob/master/ironic/tests/unit/common/test_network.py\n\nDon\u0027t know if we want to replace port*.extra{\u0027vif_port_id\u0027) or add duplicate tests with port*.internal_info(\u0027vif_port_id\u0027).","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        if vif:"},{"line_number":52,"context_line":"            port_vifs[port.uuid] \u003d vif"},{"line_number":53,"context_line":"    vifs[\u0027ports\u0027] \u003d port_vifs"},{"line_number":54,"context_line":"    return vifs"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_f0940e44","line":54,"in_reply_to":"5a74a57a_46839bcc","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a526bf2bfe79323c2f4f852d53a5da2a87297327","unresolved":false,"context_lines":[{"line_number":36,"context_line":"        # and presence of cleaning_vif_port_id means we\u0027re doing cleaning, of"},{"line_number":37,"context_line":"        # provisioning_vif_port_id - provisioning. Otherwise it\u0027s a tenant"},{"line_number":38,"context_line":"        # network"},{"line_number":39,"context_line":"        vif \u003d (portgroup.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":40,"context_line":"               portgroup.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":41,"context_line":"               portgroup.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":42,"context_line":"               portgroup.extra.get(\u0027vif_port_id\u0027))"},{"line_number":43,"context_line":"        if vif:"},{"line_number":44,"context_line":"            portgroup_vifs[portgroup.uuid] \u003d vif"},{"line_number":45,"context_line":"    vifs[\u0027portgroups\u0027] \u003d portgroup_vifs"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_7d387ed3","line":42,"range":{"start_line":39,"start_character":14,"end_line":42,"end_character":50},"updated":"2016-12-16 19:52:25.000000000","message":"I\u0027m wondering if this logic should also be inside the network interface function, as the vifs naming is now arbitrary, and the module is generically called \u0027common.network\u0027","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":36,"context_line":"        # and presence of cleaning_vif_port_id means we\u0027re doing cleaning, of"},{"line_number":37,"context_line":"        # provisioning_vif_port_id - provisioning. Otherwise it\u0027s a tenant"},{"line_number":38,"context_line":"        # network"},{"line_number":39,"context_line":"        vif \u003d (portgroup.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":40,"context_line":"               portgroup.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":41,"context_line":"               portgroup.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":42,"context_line":"               portgroup.extra.get(\u0027vif_port_id\u0027))"},{"line_number":43,"context_line":"        if vif:"},{"line_number":44,"context_line":"            portgroup_vifs[portgroup.uuid] \u003d vif"},{"line_number":45,"context_line":"    vifs[\u0027portgroups\u0027] \u003d portgroup_vifs"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_e143a86a","line":42,"range":{"start_line":39,"start_character":14,"end_line":42,"end_character":50},"in_reply_to":"1a6eadb0_7d387ed3","updated":"2016-12-20 16:58:56.000000000","message":"Done","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"}],"ironic/common/neutron.py":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":100,"context_line":"                              \"Neutron port %s.\"), port_id)"},{"line_number":101,"context_line":"            raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"    try:"},{"line_number":106,"context_line":"        get_client(token).update_port(port_id, port_req_body)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_f124a861","line":103,"updated":"2016-11-13 22:17:58.000000000","message":"I know that\u0027s the code we have already, but I don\u0027t understand why we have this, first we remove binding, and then set the same value back.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":100,"context_line":"                              \"Neutron port %s.\"), port_id)"},{"line_number":101,"context_line":"            raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"    try:"},{"line_number":106,"context_line":"        get_client(token).update_port(port_id, port_req_body)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_d202380b","line":103,"in_reply_to":"9a629dbe_09be4bd4","updated":"2016-11-14 14:21:30.000000000","message":"The reason we need this code here is because in Neutron you can not update the mac address of a bound port. So we have to unbind it first, then update the mac address and rebind it.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":100,"context_line":"                              \"Neutron port %s.\"), port_id)"},{"line_number":101,"context_line":"            raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"    try:"},{"line_number":106,"context_line":"        get_client(token).update_port(port_id, port_req_body)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_09be4bd4","line":103,"in_reply_to":"9a629dbe_f124a861","updated":"2016-11-14 09:13:18.000000000","message":"I think this hack allows to work with Neutron ML2 drivers that implements only bind_port() function and missed update_port_{precommit|postcommit}.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":72,"context_line":"    \"\"\"Get binding:host_id property from Neutron.\"\"\""},{"line_number":73,"context_line":"    try:"},{"line_number":74,"context_line":"        return client.show_port(port_id).get(\u0027port\u0027, {}).get("},{"line_number":75,"context_line":"            \u0027binding:host_id\u0027)"},{"line_number":76,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":77,"context_line":"        LOG.exception(_LE(\u0027Failed to get the current binding on Neutron \u0027"},{"line_number":78,"context_line":"                          \u0027port %s.\u0027), port_id)"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_485aaf50","line":75,"updated":"2016-11-18 14:46:16.000000000","message":"This was copied but, if port is not bound \"binding:vif_type\" is set to unbound [0], lets use it to check if port is bound or not. Even if host_id is set port may remain unbound.\n\n[0] http://paste.openstack.org/show/589448/","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"7a1ebf55804878f65759a80a04991bed9c9366f5","unresolved":false,"context_lines":[{"line_number":72,"context_line":"    \"\"\"Get binding:host_id property from Neutron.\"\"\""},{"line_number":73,"context_line":"    try:"},{"line_number":74,"context_line":"        return client.show_port(port_id).get(\u0027port\u0027, {}).get("},{"line_number":75,"context_line":"            \u0027binding:host_id\u0027)"},{"line_number":76,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":77,"context_line":"        LOG.exception(_LE(\u0027Failed to get the current binding on Neutron \u0027"},{"line_number":78,"context_line":"                          \u0027port %s.\u0027), port_id)"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_526f40fb","line":75,"in_reply_to":"7a77a97e_485aaf50","updated":"2016-11-18 19:33:55.000000000","message":"+1","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":72,"context_line":"    \"\"\"Get binding:host_id property from Neutron.\"\"\""},{"line_number":73,"context_line":"    try:"},{"line_number":74,"context_line":"        return client.show_port(port_id).get(\u0027port\u0027, {}).get("},{"line_number":75,"context_line":"            \u0027binding:host_id\u0027)"},{"line_number":76,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":77,"context_line":"        LOG.exception(_LE(\u0027Failed to get the current binding on Neutron \u0027"},{"line_number":78,"context_line":"                          \u0027port %s.\u0027), port_id)"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_1811375e","line":75,"in_reply_to":"7a77a97e_526f40fb","updated":"2016-11-21 17:37:45.000000000","message":"It is correct that even if a host_id is set the port might be unbound. However we aren\u0027t checking if the port is bound, we are saying that if a host_id is set the port *might* be bound, and we need to unset, change the mac address and reset the host_id to trigger neutron to attempt to rebind it with the new mac address.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":105,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"},{"line_number":106,"context_line":""},{"line_number":107,"context_line":"    try:"},{"line_number":108,"context_line":"        get_client(token).update_port(port_id, port_req_body)"},{"line_number":109,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":110,"context_line":"        LOG.exception(_LE(\"Failed to update MAC address on Neutron \""},{"line_number":111,"context_line":"                          \"port %s.\"), port_id)"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_c8a07f46","line":108,"range":{"start_line":108,"start_character":8,"end_line":108,"end_character":18},"updated":"2016-11-18 14:46:16.000000000","message":"This was copied but, we already have a newtron client, lets reuse it.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":105,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"},{"line_number":106,"context_line":""},{"line_number":107,"context_line":"    try:"},{"line_number":108,"context_line":"        get_client(token).update_port(port_id, port_req_body)"},{"line_number":109,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":110,"context_line":"        LOG.exception(_LE(\"Failed to update MAC address on Neutron \""},{"line_number":111,"context_line":"                          \"port %s.\"), port_id)"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_d335e0a8","line":108,"range":{"start_line":108,"start_character":8,"end_line":108,"end_character":18},"in_reply_to":"7a77a97e_727a7cbe","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"7a1ebf55804878f65759a80a04991bed9c9366f5","unresolved":false,"context_lines":[{"line_number":105,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"},{"line_number":106,"context_line":""},{"line_number":107,"context_line":"    try:"},{"line_number":108,"context_line":"        get_client(token).update_port(port_id, port_req_body)"},{"line_number":109,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":110,"context_line":"        LOG.exception(_LE(\"Failed to update MAC address on Neutron \""},{"line_number":111,"context_line":"                          \"port %s.\"), port_id)"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_727a7cbe","line":108,"range":{"start_line":108,"start_character":8,"end_line":108,"end_character":18},"in_reply_to":"7a77a97e_c8a07f46","updated":"2016-11-18 19:33:55.000000000","message":"+1. You use it on L99.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":76,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":77,"context_line":"        LOG.exception(_LE(\u0027Failed to get the current binding on Neutron \u0027"},{"line_number":78,"context_line":"                          \u0027port %s.\u0027), port_id)"},{"line_number":79,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":80,"context_line":""},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"def update_port_address(port_id, address, token\u003dNone):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_98570326","line":79,"updated":"2016-11-30 02:19:25.000000000","message":"That seems to be an odd exception from a function called _get_binding(). I guess you don\u0027t want to handle this in the caller?","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":80,"context_line":""},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"def update_port_address(port_id, address, token\u003dNone):"},{"line_number":83,"context_line":"    \"\"\"Update a port\u0027s mac address."},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    :param port_id: Neutron port id."},{"line_number":86,"context_line":"    :param address: new MAC address."}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_3887cfd8","line":83,"updated":"2016-11-30 02:19:25.000000000","message":"nit s/mac/MAC/","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":82,"context_line":"def update_port_address(port_id, address, token\u003dNone):"},{"line_number":83,"context_line":"    \"\"\"Update a port\u0027s mac address."},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    :param port_id: Neutron port id."},{"line_number":86,"context_line":"    :param address: new MAC address."},{"line_number":87,"context_line":"    :param token: optional auth token."},{"line_number":88,"context_line":"    :raises: FailedToUpdateMacOnPort"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_78694725","line":85,"updated":"2016-11-30 02:19:25.000000000","message":"nit s/id/ID/","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    current_binding \u003d _get_binding(client, port_id)"},{"line_number":94,"context_line":"    if current_binding:"},{"line_number":95,"context_line":"        # Unbind port before we update it\u0027s mac address, because you can\u0027t"},{"line_number":96,"context_line":"        # change a bound port\u0027s mac address."},{"line_number":97,"context_line":"        binding_clean_body \u003d {\u0027port\u0027: {\u0027binding:host_id\u0027: \u0027\u0027}}"},{"line_number":98,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_18d053c9","line":95,"updated":"2016-11-30 02:19:25.000000000","message":"s/it\u0027s/its/\n\ns/mac/MAC/","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":93,"context_line":"    current_binding \u003d _get_binding(client, port_id)"},{"line_number":94,"context_line":"    if current_binding:"},{"line_number":95,"context_line":"        # Unbind port before we update it\u0027s mac address, because you can\u0027t"},{"line_number":96,"context_line":"        # change a bound port\u0027s mac address."},{"line_number":97,"context_line":"        binding_clean_body \u003d {\u0027port\u0027: {\u0027binding:host_id\u0027: \u0027\u0027}}"},{"line_number":98,"context_line":"        try:"},{"line_number":99,"context_line":"            client.update_port(port_id, binding_clean_body)"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_98e463ad","line":96,"updated":"2016-11-30 02:19:25.000000000","message":"s/mac/MAC/","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":98,"context_line":"        try:"},{"line_number":99,"context_line":"            client.update_port(port_id, binding_clean_body)"},{"line_number":100,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":101,"context_line":"            LOG.exception(_LE(\"Failed to remove the current binding from \""},{"line_number":102,"context_line":"                              \"Neutron port %s.\"), port_id)"},{"line_number":103,"context_line":"            raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":104,"context_line":""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_38ba6f6f","line":101,"updated":"2016-11-30 02:19:25.000000000","message":"don\u0027t know if it would help to log the value of \u0027current_binding\u0027","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":99,"context_line":"            client.update_port(port_id, binding_clean_body)"},{"line_number":100,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":101,"context_line":"            LOG.exception(_LE(\"Failed to remove the current binding from \""},{"line_number":102,"context_line":"                              \"Neutron port %s.\"), port_id)"},{"line_number":103,"context_line":"            raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_38718fe1","line":102,"updated":"2016-11-30 02:19:25.000000000","message":"Would it be useful to log the exception from neutron?","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":107,"context_line":"    try:"},{"line_number":108,"context_line":"        client.update_port(port_id, port_req_body)"},{"line_number":109,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":110,"context_line":"        LOG.exception(_LE(\"Failed to update MAC address on Neutron \""},{"line_number":111,"context_line":"                          \"port %s.\"), port_id)"},{"line_number":112,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":113,"context_line":""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_4c1f6c5b","line":110,"updated":"2016-11-30 02:19:25.000000000","message":"log the address?\n\nlog the neutron exception?","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":110,"context_line":"        LOG.exception(_LE(\"Failed to update MAC address on Neutron \""},{"line_number":111,"context_line":"                          \"port %s.\"), port_id)"},{"line_number":112,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":""},{"line_number":115,"context_line":"def _verify_security_groups(security_groups, client):"},{"line_number":116,"context_line":"    \"\"\"Verify that the security groups exist."}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_8c942445","line":113,"updated":"2016-11-30 02:19:25.000000000","message":"UGH. It looks like you just moved these two functions from dhcp/neutron.py. Ignore my comments then.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":110,"context_line":"        LOG.exception(_LE(\"Failed to update MAC address on Neutron \""},{"line_number":111,"context_line":"                          \"port %s.\"), port_id)"},{"line_number":112,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":""},{"line_number":115,"context_line":"def _verify_security_groups(security_groups, client):"},{"line_number":116,"context_line":"    \"\"\"Verify that the security groups exist."}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_860cd343","line":113,"updated":"2016-11-30 22:09:24.000000000","message":"Should probably move some/all of the update_port_address related unit tests from tests/unit/dhcp/test_neutron.py to tests/unit/common/test_neutron.py","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":110,"context_line":"        LOG.exception(_LE(\"Failed to update MAC address on Neutron \""},{"line_number":111,"context_line":"                          \"port %s.\"), port_id)"},{"line_number":112,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":""},{"line_number":115,"context_line":"def _verify_security_groups(security_groups, client):"},{"line_number":116,"context_line":"    \"\"\"Verify that the security groups exist."}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_7d60d6a5","line":113,"in_reply_to":"5a74a57a_860cd343","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":83,"context_line":"def unbind_neutron_port(port_id, token\u003dNone):"},{"line_number":84,"context_line":"    \"\"\"Unbind a neutron port"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    Remove a neutron port\u0027s binding profile and host id so that it returns to"},{"line_number":87,"context_line":"    an unbound state."},{"line_number":88,"context_line":""},{"line_number":89,"context_line":"    :param port_id: Neutron port id"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_9fad5beb","line":86,"updated":"2016-12-06 22:36:53.000000000","message":"nit. s/id/ID/","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":83,"context_line":"def unbind_neutron_port(port_id, token\u003dNone):"},{"line_number":84,"context_line":"    \"\"\"Unbind a neutron port"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    Remove a neutron port\u0027s binding profile and host id so that it returns to"},{"line_number":87,"context_line":"    an unbound state."},{"line_number":88,"context_line":""},{"line_number":89,"context_line":"    :param port_id: Neutron port id"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_8a3066a0","line":86,"in_reply_to":"3a71b18c_9fad5beb","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":86,"context_line":"    Remove a neutron port\u0027s binding profile and host id so that it returns to"},{"line_number":87,"context_line":"    an unbound state."},{"line_number":88,"context_line":""},{"line_number":89,"context_line":"    :param port_id: Neutron port id"},{"line_number":90,"context_line":"    :param token: optional auth token."},{"line_number":91,"context_line":"    \"\"\""},{"line_number":92,"context_line":"    client \u003d get_client(token)"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_3f7b677c","line":89,"updated":"2016-12-06 22:36:53.000000000","message":"nit. s/port id/port ID/","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":86,"context_line":"    Remove a neutron port\u0027s binding profile and host id so that it returns to"},{"line_number":87,"context_line":"    an unbound state."},{"line_number":88,"context_line":""},{"line_number":89,"context_line":"    :param port_id: Neutron port id"},{"line_number":90,"context_line":"    :param token: optional auth token."},{"line_number":91,"context_line":"    \"\"\""},{"line_number":92,"context_line":"    client \u003d get_client(token)"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_aa25225d","line":89,"in_reply_to":"3a71b18c_3f7b677c","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"1be888cb8cec62a45e51626ca3c30bcf57f2eccc","unresolved":false,"context_lines":[{"line_number":123,"context_line":"            client.update_port(port_id, binding_clean_body)"},{"line_number":124,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":125,"context_line":"            LOG.exception(_LE(\"Failed to remove the current binding from \""},{"line_number":126,"context_line":"                              \"Neutron port %s.\"), port_id)"},{"line_number":127,"context_line":"            raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_1b508ad3","line":126,"updated":"2016-12-06 17:45:40.000000000","message":"nit: might want to add a note in the log message that this unbinding occurred while attempting to update the port\u0027s MAC\n\nthis was copied from another file, though, so it doesn\u0027t really matter","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":123,"context_line":"            client.update_port(port_id, binding_clean_body)"},{"line_number":124,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":125,"context_line":"            LOG.exception(_LE(\"Failed to remove the current binding from \""},{"line_number":126,"context_line":"                              \"Neutron port %s.\"), port_id)"},{"line_number":127,"context_line":"            raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"        port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d current_binding"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_0a929657","line":126,"in_reply_to":"3a71b18c_1b508ad3","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"703dfea68c1be2c25d7244db9b0111d8fb33acd5","unresolved":false,"context_lines":[{"line_number":77,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":78,"context_line":"        LOG.exception(_LE(\u0027Failed to get the current binding on Neutron \u0027"},{"line_number":79,"context_line":"                          \u0027port %s.\u0027), port_id)"},{"line_number":80,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"def unbind_neutron_port(port_id, token\u003dNone):"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_f39d905a","line":80,"updated":"2016-12-12 15:17:31.000000000","message":"is this a proper exception? By reading the code, it seems that no update happens here","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":77,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":78,"context_line":"        LOG.exception(_LE(\u0027Failed to get the current binding on Neutron \u0027"},{"line_number":79,"context_line":"                          \u0027port %s.\u0027), port_id)"},{"line_number":80,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"def unbind_neutron_port(port_id, token\u003dNone):"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_9e4fcb91","line":80,"in_reply_to":"1a6eadb0_14cae0a1","updated":"2016-12-13 16:34:13.000000000","message":"Agree it is a bit wired to raise exception of calling method.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":77,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":78,"context_line":"        LOG.exception(_LE(\u0027Failed to get the current binding on Neutron \u0027"},{"line_number":79,"context_line":"                          \u0027port %s.\u0027), port_id)"},{"line_number":80,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"def unbind_neutron_port(port_id, token\u003dNone):"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_14cae0a1","line":80,"in_reply_to":"1a6eadb0_addc9119","updated":"2016-12-13 01:26:36.000000000","message":"I think that exceptions should reflect what the method is doing, not what the calling method is doing, because otherwise it makes it harder for people to understand what is going on -- eg Joanna\u0027s comment here. Having said that -- this is an internal method and we do it elsewhere and how many new exceptions do we want to create, etc etc, so it is fine. Someone is free to make it prettier :)","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"f15fc071b19853025c90ca5882a4fb26f7c3639d","unresolved":false,"context_lines":[{"line_number":77,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":78,"context_line":"        LOG.exception(_LE(\u0027Failed to get the current binding on Neutron \u0027"},{"line_number":79,"context_line":"                          \u0027port %s.\u0027), port_id)"},{"line_number":80,"context_line":"        raise exception.FailedToUpdateMacOnPort(port_id\u003dport_id)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"def unbind_neutron_port(port_id, token\u003dNone):"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_addc9119","line":80,"in_reply_to":"1a6eadb0_f39d905a","updated":"2016-12-12 18:44:38.000000000","message":"Yes, this is here because _get_binding is called when updating the port. See L117 in this file.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"703dfea68c1be2c25d7244db9b0111d8fb33acd5","unresolved":false,"context_lines":[{"line_number":99,"context_line":"    try:"},{"line_number":100,"context_line":"        client.update_port(port_id, body)"},{"line_number":101,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":102,"context_line":"        raise exception.NetworkError(_(\u0027Unable to clear binding profile for \u0027"},{"line_number":103,"context_line":"                                       \u0027neutron port %s\u0027) % port_id)"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_333c682f","line":102,"updated":"2016-12-12 15:17:31.000000000","message":"Is this a proper exception? Looks like a communication failure. Maybe a new exception class for failed port update would be more self-explanatory?","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":99,"context_line":"    try:"},{"line_number":100,"context_line":"        client.update_port(port_id, body)"},{"line_number":101,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":102,"context_line":"        raise exception.NetworkError(_(\u0027Unable to clear binding profile for \u0027"},{"line_number":103,"context_line":"                                       \u0027neutron port %s\u0027) % port_id)"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_d436a8b3","line":102,"in_reply_to":"1a6eadb0_0d03c574","updated":"2016-12-13 01:26:36.000000000","message":"We\u0027re not consistent on this -- we don\u0027t log the client exception, should we? If someone were to try to debug this, how/what would they do?","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"f15fc071b19853025c90ca5882a4fb26f7c3639d","unresolved":false,"context_lines":[{"line_number":99,"context_line":"    try:"},{"line_number":100,"context_line":"        client.update_port(port_id, body)"},{"line_number":101,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":102,"context_line":"        raise exception.NetworkError(_(\u0027Unable to clear binding profile for \u0027"},{"line_number":103,"context_line":"                                       \u0027neutron port %s\u0027) % port_id)"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_0d03c574","line":102,"in_reply_to":"1a6eadb0_333c682f","updated":"2016-12-12 18:44:38.000000000","message":"I believe this will be called outside the module in a variety of contexts, so a generic NetworkError would be appropriate.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"703dfea68c1be2c25d7244db9b0111d8fb33acd5","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        # change a bound port\u0027s mac address."},{"line_number":121,"context_line":"        binding_clean_body \u003d {\u0027port\u0027: {\u0027binding:host_id\u0027: \u0027\u0027}}"},{"line_number":122,"context_line":"        try:"},{"line_number":123,"context_line":"            client.update_port(port_id, binding_clean_body)"},{"line_number":124,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":125,"context_line":"            LOG.exception(_LE(\"Failed to remove the current binding from \""},{"line_number":126,"context_line":"                              \"Neutron port %s to update MAC address.\"),"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_3351c863","line":123,"updated":"2016-12-12 15:17:31.000000000","message":"why won\u0027t use unbind method here (if cleaning profile is an obstacle it can be passed as param with default value, e.g. clean_profile\u003dTrue)?","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"f15fc071b19853025c90ca5882a4fb26f7c3639d","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        # change a bound port\u0027s mac address."},{"line_number":121,"context_line":"        binding_clean_body \u003d {\u0027port\u0027: {\u0027binding:host_id\u0027: \u0027\u0027}}"},{"line_number":122,"context_line":"        try:"},{"line_number":123,"context_line":"            client.update_port(port_id, binding_clean_body)"},{"line_number":124,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":125,"context_line":"            LOG.exception(_LE(\"Failed to remove the current binding from \""},{"line_number":126,"context_line":"                              \"Neutron port %s to update MAC address.\"),"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_9fbb760e","line":123,"in_reply_to":"1a6eadb0_3351c863","updated":"2016-12-12 18:44:38.000000000","message":"Agreed, and we could also have an option to pass the client instead of just a token. Not enough to switch me to -1 alone, though.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        # change a bound port\u0027s mac address."},{"line_number":121,"context_line":"        binding_clean_body \u003d {\u0027port\u0027: {\u0027binding:host_id\u0027: \u0027\u0027}}"},{"line_number":122,"context_line":"        try:"},{"line_number":123,"context_line":"            client.update_port(port_id, binding_clean_body)"},{"line_number":124,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":125,"context_line":"            LOG.exception(_LE(\"Failed to remove the current binding from \""},{"line_number":126,"context_line":"                              \"Neutron port %s to update MAC address.\"),"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_f493a44d","line":123,"in_reply_to":"1a6eadb0_9fbb760e","updated":"2016-12-13 01:26:36.000000000","message":"I\u0027m not sure I want this to directly call .unbind_neutron_port cuz I don\u0027t want to get the client twice :) But I think having a helper function for the unbinding would be good.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        # change a bound port\u0027s mac address."},{"line_number":121,"context_line":"        binding_clean_body \u003d {\u0027port\u0027: {\u0027binding:host_id\u0027: \u0027\u0027}}"},{"line_number":122,"context_line":"        try:"},{"line_number":123,"context_line":"            client.update_port(port_id, binding_clean_body)"},{"line_number":124,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":125,"context_line":"            LOG.exception(_LE(\"Failed to remove the current binding from \""},{"line_number":126,"context_line":"                              \"Neutron port %s to update MAC address.\"),"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_f568ddbc","line":123,"in_reply_to":"1a6eadb0_f493a44d","updated":"2016-12-13 16:34:13.000000000","message":"Done","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":92,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":93,"context_line":"        msg \u003d (_(\u0027Unable to clear binding profile for \u0027"},{"line_number":94,"context_line":"                 \u0027neutron port %s\u0027) % port_id)"},{"line_number":95,"context_line":"        LOG.error(msg)"},{"line_number":96,"context_line":"        raise exception.NetworkError(msg)"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_50307f9e","line":95,"updated":"2016-12-14 19:25:36.000000000","message":"I think we should also log the exception msg, to help with debugging the failure.","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":92,"context_line":"    except neutron_exceptions.NeutronClientException:"},{"line_number":93,"context_line":"        msg \u003d (_(\u0027Unable to clear binding profile for \u0027"},{"line_number":94,"context_line":"                 \u0027neutron port %s\u0027) % port_id)"},{"line_number":95,"context_line":"        LOG.error(msg)"},{"line_number":96,"context_line":"        raise exception.NetworkError(msg)"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_f4431f40","line":95,"in_reply_to":"1a6eadb0_50307f9e","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":118,"context_line":"            # Unbind port before we update it\u0027s mac address, because you can\u0027t"},{"line_number":119,"context_line":"            # change a bound port\u0027s mac address."},{"line_number":120,"context_line":"            msg \u003d (_(\"Failed to remove the current binding from \""},{"line_number":121,"context_line":"                     \"Neutron port %s to update MAC address.\") % port_id)"},{"line_number":122,"context_line":"            unbind_neutron_port(port_id, client\u003dclient)"},{"line_number":123,"context_line":"            port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d binding_host_id"},{"line_number":124,"context_line":"            port_req_body[\u0027port\u0027][\u0027binding:profile\u0027] \u003d binding_profile"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_507ddfe5","line":121,"updated":"2016-12-14 19:25:36.000000000","message":"nit: maybe s/to update/, while updating its/","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":118,"context_line":"            # Unbind port before we update it\u0027s mac address, because you can\u0027t"},{"line_number":119,"context_line":"            # change a bound port\u0027s mac address."},{"line_number":120,"context_line":"            msg \u003d (_(\"Failed to remove the current binding from \""},{"line_number":121,"context_line":"                     \"Neutron port %s to update MAC address.\") % port_id)"},{"line_number":122,"context_line":"            unbind_neutron_port(port_id, client\u003dclient)"},{"line_number":123,"context_line":"            port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d binding_host_id"},{"line_number":124,"context_line":"            port_req_body[\u0027port\u0027][\u0027binding:profile\u0027] \u003d binding_profile"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_344af755","line":121,"in_reply_to":"1a6eadb0_507ddfe5","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"}],"ironic/conductor/manager.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":1704,"context_line":""},{"line_number":1705,"context_line":"            if \u0027address\u0027 in port_obj.obj_what_changed():"},{"line_number":1706,"context_line":"                vif \u003d (port_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":1707,"context_line":"                       port_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":1708,"context_line":"                if vif:"},{"line_number":1709,"context_line":"                    api \u003d dhcp_factory.DHCPFactory()"},{"line_number":1710,"context_line":"                    api.provider.update_port_address(vif, port_obj.address,"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_89ca5b6d","line":1707,"updated":"2016-11-14 09:13:18.000000000","message":"ditto to use internal_info with higher precedence than extra.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":1813,"context_line":"                                  \u0027node\u0027: node.uuid})"},{"line_number":1814,"context_line":""},{"line_number":1815,"context_line":"            if \u0027address\u0027 in portgroup_obj.obj_what_changed():"},{"line_number":1816,"context_line":"                vif \u003d (portgroup_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":1817,"context_line":"                       portgroup_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":1818,"context_line":"                if vif:"},{"line_number":1819,"context_line":"                    api \u003d dhcp_factory.DHCPFactory()"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_a9c71f63","line":1816,"updated":"2016-11-14 09:13:18.000000000","message":"ditto","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":2192,"context_line":"            task.spawn_after(self._spawn_worker, task.driver.deploy.heartbeat,"},{"line_number":2193,"context_line":"                             task, callback_url)"},{"line_number":2194,"context_line":""},{"line_number":2195,"context_line":"    @messaging.expected_exceptions(exception.NodeLocked,"},{"line_number":2196,"context_line":"                                   exception.NetworkError)"},{"line_number":2197,"context_line":"    def vif_list(self, context, node_id):"},{"line_number":2198,"context_line":"        print(\"1298761287129768\")"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_31a2a09b","line":2195,"updated":"2016-11-13 22:17:58.000000000","message":"network validate methods can throw Invalid/MissingParameterValue, at least that\u0027s what base class docstrings say. Please add these two exceptions too.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":2192,"context_line":"            task.spawn_after(self._spawn_worker, task.driver.deploy.heartbeat,"},{"line_number":2193,"context_line":"                             task, callback_url)"},{"line_number":2194,"context_line":""},{"line_number":2195,"context_line":"    @messaging.expected_exceptions(exception.NodeLocked,"},{"line_number":2196,"context_line":"                                   exception.NetworkError)"},{"line_number":2197,"context_line":"    def vif_list(self, context, node_id):"},{"line_number":2198,"context_line":"        print(\"1298761287129768\")"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_98029fb3","line":2195,"in_reply_to":"9a629dbe_31a2a09b","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":2195,"context_line":"    @messaging.expected_exceptions(exception.NodeLocked,"},{"line_number":2196,"context_line":"                                   exception.NetworkError)"},{"line_number":2197,"context_line":"    def vif_list(self, context, node_id):"},{"line_number":2198,"context_line":"        print(\"1298761287129768\")"},{"line_number":2199,"context_line":"        with task_manager.acquire(context, node_id,"},{"line_number":2200,"context_line":"                                  purpose\u003d\u0027list vifs\u0027) as task:"},{"line_number":2201,"context_line":"            task.driver.network.validate(task)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_31946043","line":2198,"updated":"2016-11-13 22:17:58.000000000","message":"ditto","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":2195,"context_line":"    @messaging.expected_exceptions(exception.NodeLocked,"},{"line_number":2196,"context_line":"                                   exception.NetworkError)"},{"line_number":2197,"context_line":"    def vif_list(self, context, node_id):"},{"line_number":2198,"context_line":"        print(\"1298761287129768\")"},{"line_number":2199,"context_line":"        with task_manager.acquire(context, node_id,"},{"line_number":2200,"context_line":"                                  purpose\u003d\u0027list vifs\u0027) as task:"},{"line_number":2201,"context_line":"            task.driver.network.validate(task)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_38cef3b4","line":2198,"in_reply_to":"9a629dbe_31946043","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":1704,"context_line":""},{"line_number":1705,"context_line":"            if \u0027address\u0027 in port_obj.obj_what_changed():"},{"line_number":1706,"context_line":"                vif \u003d (port_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":1707,"context_line":"                       port_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":1708,"context_line":"                if vif:"},{"line_number":1709,"context_line":"                    api \u003d dhcp_factory.DHCPFactory()"},{"line_number":1710,"context_line":"                    api.provider.update_port_address(vif, port_obj.address,"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_70ddc941","line":1707,"updated":"2016-11-15 15:52:26.000000000","message":"I think we should search in internal_info first as it is the expected dict to contain vif_port_id. It will avoid extra search in \u0027extra\u0027 dict.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5141d24a4ca5c81c5e1679a9ea6fb43fb4d6f582","unresolved":false,"context_lines":[{"line_number":1704,"context_line":""},{"line_number":1705,"context_line":"            if \u0027address\u0027 in port_obj.obj_what_changed():"},{"line_number":1706,"context_line":"                vif \u003d (port_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":1707,"context_line":"                       port_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":1708,"context_line":"                if vif:"},{"line_number":1709,"context_line":"                    api \u003d dhcp_factory.DHCPFactory()"},{"line_number":1710,"context_line":"                    api.provider.update_port_address(vif, port_obj.address,"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_f6d3675d","line":1707,"in_reply_to":"7a77a97e_5d47fdba","updated":"2016-11-16 12:15:22.000000000","message":"I have moved this into the NetworkInterface, because the existance of vif_port_id is a NetworkInterface implementation detail.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":10342,"name":"Jay Faulkner","display_name":"JayF","email":"jay@jvf.cc","username":"JayF","status":"youtube.com/@oss-gr / podcast.gr-oss.io"},"change_message_id":"f349e3434c95db3e5965ea8ef3c172580c4d88df","unresolved":false,"context_lines":[{"line_number":1704,"context_line":""},{"line_number":1705,"context_line":"            if \u0027address\u0027 in port_obj.obj_what_changed():"},{"line_number":1706,"context_line":"                vif \u003d (port_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":1707,"context_line":"                       port_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":1708,"context_line":"                if vif:"},{"line_number":1709,"context_line":"                    api \u003d dhcp_factory.DHCPFactory()"},{"line_number":1710,"context_line":"                    api.provider.update_port_address(vif, port_obj.address,"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_dd2b0d2f","line":1707,"in_reply_to":"7a77a97e_70ddc941","updated":"2016-11-15 18:21:50.000000000","message":"Hmm. This does sorta provide an ordering conundrum, right? If someone has the vif_port_id set to different things in the old + new places (extra vs internal_info), should we just use one silently? IMO we should at least log that they were different so operators know they have a misconfigured node.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5a620ac10669853e3f405706323d9cf56fead58c","unresolved":false,"context_lines":[{"line_number":1704,"context_line":""},{"line_number":1705,"context_line":"            if \u0027address\u0027 in port_obj.obj_what_changed():"},{"line_number":1706,"context_line":"                vif \u003d (port_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":1707,"context_line":"                       port_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":1708,"context_line":"                if vif:"},{"line_number":1709,"context_line":"                    api \u003d dhcp_factory.DHCPFactory()"},{"line_number":1710,"context_line":"                    api.provider.update_port_address(vif, port_obj.address,"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_5d47fdba","line":1707,"in_reply_to":"7a77a97e_dd2b0d2f","updated":"2016-11-15 18:26:27.000000000","message":"I think I should remove this change because internal_info isn\u0027t / shouldn\u0027t be writable so it should never have changed here. Also in the default implementation used by the in-tree drivers, it shouldn\u0027t be possible to set a vif_port_id via the new API if there is already one set in extra.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":2200,"context_line":"        with task_manager.acquire(context, node_id,"},{"line_number":2201,"context_line":"                                  purpose\u003d\u0027list vifs\u0027) as task:"},{"line_number":2202,"context_line":"            task.driver.network.validate(task)"},{"line_number":2203,"context_line":"            task.driver.network.list_vifs(task)"},{"line_number":2204,"context_line":""},{"line_number":2205,"context_line":"    @messaging.expected_exceptions(exception.NodeLocked,"},{"line_number":2206,"context_line":"                                   exception.NetworkError,"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_95cfb7af","line":2203,"updated":"2016-11-15 15:52:26.000000000","message":"should be\n  return task.driver.network.list_vifs(task)","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5141d24a4ca5c81c5e1679a9ea6fb43fb4d6f582","unresolved":false,"context_lines":[{"line_number":2200,"context_line":"        with task_manager.acquire(context, node_id,"},{"line_number":2201,"context_line":"                                  purpose\u003d\u0027list vifs\u0027) as task:"},{"line_number":2202,"context_line":"            task.driver.network.validate(task)"},{"line_number":2203,"context_line":"            task.driver.network.list_vifs(task)"},{"line_number":2204,"context_line":""},{"line_number":2205,"context_line":"    @messaging.expected_exceptions(exception.NodeLocked,"},{"line_number":2206,"context_line":"                                   exception.NetworkError,"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_36f79ff6","line":2203,"in_reply_to":"7a77a97e_95cfb7af","updated":"2016-11-16 12:15:22.000000000","message":"Done","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"7a1ebf55804878f65759a80a04991bed9c9366f5","unresolved":false,"context_lines":[{"line_number":1774,"context_line":"                                  \u0027node\u0027: node.uuid})"},{"line_number":1775,"context_line":""},{"line_number":1776,"context_line":"            if \u0027address\u0027 in portgroup_obj.obj_what_changed():"},{"line_number":1777,"context_line":"                vif \u003d (portgroup_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":1778,"context_line":"                       portgroup_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":1779,"context_line":"                if vif:"},{"line_number":1780,"context_line":"                    api \u003d dhcp_factory.DHCPFactory()"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_b22ed4a2","line":1777,"updated":"2016-11-18 19:33:55.000000000","message":"The precedence here is flipped from what you have in common/network.py. Is that intentional?","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":1774,"context_line":"                                  \u0027node\u0027: node.uuid})"},{"line_number":1775,"context_line":""},{"line_number":1776,"context_line":"            if \u0027address\u0027 in portgroup_obj.obj_what_changed():"},{"line_number":1777,"context_line":"                vif \u003d (portgroup_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":1778,"context_line":"                       portgroup_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":1779,"context_line":"                if vif:"},{"line_number":1780,"context_line":"                    api \u003d dhcp_factory.DHCPFactory()"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_736ecc97","line":1777,"in_reply_to":"7a77a97e_b22ed4a2","updated":"2016-11-21 17:37:45.000000000","message":"This should even be here, internal_info isn\u0027t writable.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"}],"ironic/conductor/rpcapi.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":747,"context_line":"                          vif_id\u003dvif_id)"},{"line_number":748,"context_line":""},{"line_number":749,"context_line":"    def vif_list(self, context, node_id, topic\u003dNone):"},{"line_number":750,"context_line":"        print(\"ASJHASJHVSAJHVG\")"},{"line_number":751,"context_line":"        cctxt \u003d self.client.prepare(topic\u003dtopic or self.topic, version\u003d\u00271.35\u0027)"},{"line_number":752,"context_line":"        return cctxt.call(context, \u0027vif_list\u0027, node_id\u003dnode_id)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_09a56bb4","line":750,"updated":"2016-11-14 09:13:18.000000000","message":"not needed.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":747,"context_line":"                          vif_id\u003dvif_id)"},{"line_number":748,"context_line":""},{"line_number":749,"context_line":"    def vif_list(self, context, node_id, topic\u003dNone):"},{"line_number":750,"context_line":"        print(\"ASJHASJHVSAJHVG\")"},{"line_number":751,"context_line":"        cctxt \u003d self.client.prepare(topic\u003dtopic or self.topic, version\u003d\u00271.35\u0027)"},{"line_number":752,"context_line":"        return cctxt.call(context, \u0027vif_list\u0027, node_id\u003dnode_id)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_7864ebe4","line":750,"in_reply_to":"9a629dbe_09a56bb4","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"}],"ironic/dhcp/neutron.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":66,"context_line":"            raise exception.FailedToUpdateDHCPOptOnPort(port_id\u003dport_id)"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"    def update_port_address(self, port_id, address, token\u003dNone):"},{"line_number":69,"context_line":"        neutron.update_port_address(port_id, address, token)"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"    def update_dhcp_opts(self, task, options, vifs\u003dNone):"},{"line_number":72,"context_line":"        \"\"\"Send or update the DHCP BOOT options for this node."}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_0c73b4b5","line":69,"updated":"2016-11-30 02:19:25.000000000","message":"I think it is worth putting/leaving the docstring here that describes the function \u0026 parameters.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":196,"context_line":"        # network"},{"line_number":197,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":198,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":199,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":200,"context_line":"        if not vif:"},{"line_number":201,"context_line":"            obj_name \u003d \u0027portgroup\u0027"},{"line_number":202,"context_line":"            if isinstance(p_obj, objects.Port):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_8cc3448a","line":199,"updated":"2016-11-30 02:19:25.000000000","message":"or p_obj.internal_info.get(\u0027vif_port_id\u0027)?","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4d4c25f3f39c5805057ace978900d91daf3028c0","unresolved":false,"context_lines":[{"line_number":196,"context_line":"        # network"},{"line_number":197,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":198,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":199,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":200,"context_line":"        if not vif:"},{"line_number":201,"context_line":"            obj_name \u003d \u0027portgroup\u0027"},{"line_number":202,"context_line":"            if isinstance(p_obj, objects.Port):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_c8c35b89","line":199,"in_reply_to":"5a74a57a_8cc3448a","updated":"2016-11-30 09:40:23.000000000","message":"++","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":203,"context_line":"        # network"},{"line_number":204,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":205,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":206,"context_line":"               p_obj.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":207,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":208,"context_line":"        if not vif:"},{"line_number":209,"context_line":"            obj_name \u003d \u0027portgroup\u0027"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_49572c02","line":206,"updated":"2016-11-30 22:09:24.000000000","message":"(cuz I read the above comment and it make me wonder). Why aren\u0027t we calling it internal_info[\u0027tenant_vif_port_id\u0027] to make it more consistent with the cleaning/provisioning names?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4f78464056c02c4452224e4f69e3488d1709f5e0","unresolved":false,"context_lines":[{"line_number":203,"context_line":"        # network"},{"line_number":204,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":205,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":206,"context_line":"               p_obj.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":207,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":208,"context_line":"        if not vif:"},{"line_number":209,"context_line":"            obj_name \u003d \u0027portgroup\u0027"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_9f939b5a","line":206,"in_reply_to":"3a71b18c_ddebaa76","updated":"2016-12-06 22:36:28.000000000","message":"Ah. I don\u0027t see a need for consistency; we\u0027re basically deprecating .extra[\u0027vif_port_id\u0027]. Since this is a new key, we should name it the way we think it ought to be named. \u0027tenant_vif_port_id\u0027 makes more sense to me than \u0027vif_port_id\u0027. Not sure what others think.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":203,"context_line":"        # network"},{"line_number":204,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":205,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":206,"context_line":"               p_obj.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":207,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":208,"context_line":"        if not vif:"},{"line_number":209,"context_line":"            obj_name \u003d \u0027portgroup\u0027"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_ddebaa76","line":206,"in_reply_to":"5a74a57a_49572c02","updated":"2016-12-06 11:43:59.000000000","message":"I kept it as vif_port_id for consistency with the original variable, however I can rename it if we prefer.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":204,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":205,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":206,"context_line":"               p_obj.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":207,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":208,"context_line":"        if not vif:"},{"line_number":209,"context_line":"            obj_name \u003d \u0027portgroup\u0027"},{"line_number":210,"context_line":"            if isinstance(p_obj, objects.Port):"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_5f0c3e3b","line":207,"updated":"2016-11-30 22:09:24.000000000","message":"Also wondering why we didn\u0027t add a port.get_vif() \u0026 portgroup.get_vif() to do this. (Or some helper function.) Then we wouldn\u0027t have to update/add so many unit tests, etc. just for this little change.\n\nI see this in ironic/common/network.py, driver/modules/deploy_utils.py. \n\nJust a thought though, can be done later or not done.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":204,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":205,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":206,"context_line":"               p_obj.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":207,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":208,"context_line":"        if not vif:"},{"line_number":209,"context_line":"            obj_name \u003d \u0027portgroup\u0027"},{"line_number":210,"context_line":"            if isinstance(p_obj, objects.Port):"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_5d4a3aad","line":207,"in_reply_to":"5a74a57a_5f0c3e3b","updated":"2016-12-06 11:43:59.000000000","message":"the existence of *_vif_port_id is actually an implementation detail of neutron and flat NetworkInterfaces, which ties this dhcp provider to those network interfaces :(. I hope the dhcp providers can go away soon.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":216,"context_line":"            raise exception.FailedToGetIPAddressOnPort(port_id\u003dp_obj.uuid)"},{"line_number":217,"context_line":""},{"line_number":218,"context_line":"        vif_ip_address \u003d self._get_fixed_ip_address(vif, client)"},{"line_number":219,"context_line":"        return vif_ip_address"},{"line_number":220,"context_line":""},{"line_number":221,"context_line":"    def _get_ip_addresses(self, task, pobj_list, client):"},{"line_number":222,"context_line":"        \"\"\"Get IP addresses for all ports/portgroups."}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_e95d5816","line":219,"updated":"2016-11-30 22:09:24.000000000","message":"there are some units tests for this in tests/unit/dhcp/test_neutron.py. Wondering if we should add more tests or change some, to use .internal_info[\u0027vif_port_id\u0027] instead of .extra[].","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":216,"context_line":"            raise exception.FailedToGetIPAddressOnPort(port_id\u003dp_obj.uuid)"},{"line_number":217,"context_line":""},{"line_number":218,"context_line":"        vif_ip_address \u003d self._get_fixed_ip_address(vif, client)"},{"line_number":219,"context_line":"        return vif_ip_address"},{"line_number":220,"context_line":""},{"line_number":221,"context_line":"    def _get_ip_addresses(self, task, pobj_list, client):"},{"line_number":222,"context_line":"        \"\"\"Get IP addresses for all ports/portgroups."}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_bd426e66","line":219,"in_reply_to":"5a74a57a_e95d5816","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":79,"context_line":"        \"\"\""},{"line_number":80,"context_line":"        global update_port_address_deprecation"},{"line_number":81,"context_line":"        if not update_port_address_deprecation:"},{"line_number":82,"context_line":"            LOG.warning(_LW(\u0027update_port_address via dhcp provider is \u0027"},{"line_number":83,"context_line":"                            \u0027deprecated. The node.network_interface \u0027"},{"line_number":84,"context_line":"                            \u0027port_changed() should be used instead.\u0027))"},{"line_number":85,"context_line":"            update_port_address_deprecation \u003d True"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_53cb291e","line":82,"updated":"2016-12-14 19:25:36.000000000","message":"nit: s/dhcp/DHCP/","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":79,"context_line":"        \"\"\""},{"line_number":80,"context_line":"        global update_port_address_deprecation"},{"line_number":81,"context_line":"        if not update_port_address_deprecation:"},{"line_number":82,"context_line":"            LOG.warning(_LW(\u0027update_port_address via dhcp provider is \u0027"},{"line_number":83,"context_line":"                            \u0027deprecated. The node.network_interface \u0027"},{"line_number":84,"context_line":"                            \u0027port_changed() should be used instead.\u0027))"},{"line_number":85,"context_line":"            update_port_address_deprecation \u003d True"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_74762fa5","line":82,"in_reply_to":"1a6eadb0_53cb291e","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a526bf2bfe79323c2f4f852d53a5da2a87297327","unresolved":false,"context_lines":[{"line_number":212,"context_line":"        # and presence of cleaning_vif_port_id means we\u0027re doing cleaning, of"},{"line_number":213,"context_line":"        # provisioning_vif_port_id - provisioning. Otherwise it\u0027s a tenant"},{"line_number":214,"context_line":"        # network"},{"line_number":215,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":216,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":217,"context_line":"               p_obj.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":218,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":219,"context_line":"        if not vif:"},{"line_number":220,"context_line":"            obj_name \u003d \u0027portgroup\u0027"},{"line_number":221,"context_line":"            if isinstance(p_obj, objects.Port):"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_1d56aa05","line":218,"range":{"start_line":215,"start_character":14,"end_line":218,"end_character":46},"updated":"2016-12-16 19:52:25.000000000","message":"same comment feels like it belongs to the network interface","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":212,"context_line":"        # and presence of cleaning_vif_port_id means we\u0027re doing cleaning, of"},{"line_number":213,"context_line":"        # provisioning_vif_port_id - provisioning. Otherwise it\u0027s a tenant"},{"line_number":214,"context_line":"        # network"},{"line_number":215,"context_line":"        vif \u003d (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":216,"context_line":"               p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":217,"context_line":"               p_obj.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":218,"context_line":"               p_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":219,"context_line":"        if not vif:"},{"line_number":220,"context_line":"            obj_name \u003d \u0027portgroup\u0027"},{"line_number":221,"context_line":"            if isinstance(p_obj, objects.Port):"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_8cdb041b","line":218,"range":{"start_line":215,"start_character":14,"end_line":218,"end_character":46},"in_reply_to":"1a6eadb0_1d56aa05","updated":"2016-12-20 16:58:56.000000000","message":"Done","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"}],"ironic/drivers/base.py":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":1064,"context_line":"        :param task: A TaskManager instance."},{"line_number":1065,"context_line":"        :param vif: A VIF to attach"},{"line_number":1066,"context_line":"        :raises: NetworkError"},{"line_number":1067,"context_line":"        \"\"\""},{"line_number":1068,"context_line":""},{"line_number":1069,"context_line":"    @abc.abstractmethod"},{"line_number":1070,"context_line":"    def detach_vif(self, task, vif_id):"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_b1ceb0b5","line":1067,"updated":"2016-11-13 22:17:58.000000000","message":"Please add default implementations here.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":1064,"context_line":"        :param task: A TaskManager instance."},{"line_number":1065,"context_line":"        :param vif: A VIF to attach"},{"line_number":1066,"context_line":"        :raises: NetworkError"},{"line_number":1067,"context_line":"        \"\"\""},{"line_number":1068,"context_line":""},{"line_number":1069,"context_line":"    @abc.abstractmethod"},{"line_number":1070,"context_line":"    def detach_vif(self, task, vif_id):"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_dee79f44","line":1067,"in_reply_to":"9a629dbe_b1ceb0b5","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":942,"context_line":"        \"\"\""},{"line_number":943,"context_line":"        LOG.warning(_LW(\u0027The network interface loaded by node %s should be \u0027"},{"line_number":944,"context_line":"                        \u0027updated to implement the port_changed function, \u0027"},{"line_number":945,"context_line":"                        \u0027falling back to default implementation, this \u0027"},{"line_number":946,"context_line":"                        \u0027behaviour will be removed in Pike\u0027), task.node.uuid)"},{"line_number":947,"context_line":"        return super(NetworkInterface, self).port_changed(task, port)"},{"line_number":948,"context_line":""}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_8b05a17b","line":945,"updated":"2016-11-18 14:46:16.000000000","message":"We should show messages only once during conductor start, otherwise for example calling vif_list() or vif_attach() will generate a lot of spam in the log.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":942,"context_line":"        \"\"\""},{"line_number":943,"context_line":"        LOG.warning(_LW(\u0027The network interface loaded by node %s should be \u0027"},{"line_number":944,"context_line":"                        \u0027updated to implement the port_changed function, \u0027"},{"line_number":945,"context_line":"                        \u0027falling back to default implementation, this \u0027"},{"line_number":946,"context_line":"                        \u0027behaviour will be removed in Pike\u0027), task.node.uuid)"},{"line_number":947,"context_line":"        return super(NetworkInterface, self).port_changed(task, port)"},{"line_number":948,"context_line":""}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_3371b4e1","line":945,"in_reply_to":"7a77a97e_8b05a17b","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":956,"context_line":"        LOG.warning(_LW(\u0027The network interface loaded by node %s should be \u0027"},{"line_number":957,"context_line":"                        \u0027updated to implement the vif_attach function, \u0027"},{"line_number":958,"context_line":"                        \u0027falling back to default implementation, this \u0027"},{"line_number":959,"context_line":"                        \u0027behaviour will be removed in Pike\u0027), task.node.uuid)"},{"line_number":960,"context_line":"        return super(NetworkInterface, self).vif_attach(task, vif)"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"    def vif_detach(self, task, vif_id):"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_cbff9965","line":959,"updated":"2016-11-18 14:46:16.000000000","message":"ditto","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":956,"context_line":"        LOG.warning(_LW(\u0027The network interface loaded by node %s should be \u0027"},{"line_number":957,"context_line":"                        \u0027updated to implement the vif_attach function, \u0027"},{"line_number":958,"context_line":"                        \u0027falling back to default implementation, this \u0027"},{"line_number":959,"context_line":"                        \u0027behaviour will be removed in Pike\u0027), task.node.uuid)"},{"line_number":960,"context_line":"        return super(NetworkInterface, self).vif_attach(task, vif)"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"    def vif_detach(self, task, vif_id):"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_73732ce8","line":959,"in_reply_to":"7a77a97e_cbff9965","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":968,"context_line":"        \"\"\""},{"line_number":969,"context_line":"        LOG.warning(_LW(\u0027The network interface loaded by node %s should be \u0027"},{"line_number":970,"context_line":"                        \u0027updated to implement the vif_detach function, \u0027"},{"line_number":971,"context_line":"                        \u0027falling back to default implementation, this \u0027"},{"line_number":972,"context_line":"                        \u0027behaviour will be removed in Pike\u0027), task.node.uuid)"},{"line_number":973,"context_line":"        return super(NetworkInterface, self).vif_detach(task, vif_id)"},{"line_number":974,"context_line":""}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_eb02956e","line":971,"updated":"2016-11-18 14:46:16.000000000","message":"ditto","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":968,"context_line":"        \"\"\""},{"line_number":969,"context_line":"        LOG.warning(_LW(\u0027The network interface loaded by node %s should be \u0027"},{"line_number":970,"context_line":"                        \u0027updated to implement the vif_detach function, \u0027"},{"line_number":971,"context_line":"                        \u0027falling back to default implementation, this \u0027"},{"line_number":972,"context_line":"                        \u0027behaviour will be removed in Pike\u0027), task.node.uuid)"},{"line_number":973,"context_line":"        return super(NetworkInterface, self).vif_detach(task, vif_id)"},{"line_number":974,"context_line":""}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_d348808d","line":971,"in_reply_to":"7a77a97e_eb02956e","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":978,"context_line":"        :param task: A TaskManager instance."},{"line_number":979,"context_line":"        :raises: NetworkError"},{"line_number":980,"context_line":"        \"\"\""},{"line_number":981,"context_line":"        LOG.warning(_LW(\u0027The network interface loaded by node %s should be \u0027"},{"line_number":982,"context_line":"                        \u0027updated to implement the vif_list function, \u0027"},{"line_number":983,"context_line":"                        \u0027falling back to default implementation, this \u0027"},{"line_number":984,"context_line":"                        \u0027behaviour will be removed in Pike\u0027), task.node.uuid)"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_0bfa7175","line":981,"updated":"2016-11-18 14:46:16.000000000","message":"ditto","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":978,"context_line":"        :param task: A TaskManager instance."},{"line_number":979,"context_line":"        :raises: NetworkError"},{"line_number":980,"context_line":"        \"\"\""},{"line_number":981,"context_line":"        LOG.warning(_LW(\u0027The network interface loaded by node %s should be \u0027"},{"line_number":982,"context_line":"                        \u0027updated to implement the vif_list function, \u0027"},{"line_number":983,"context_line":"                        \u0027falling back to default implementation, this \u0027"},{"line_number":984,"context_line":"                        \u0027behaviour will be removed in Pike\u0027), task.node.uuid)"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_f34d7c9a","line":981,"in_reply_to":"7a77a97e_0bfa7175","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":982,"context_line":"        return default_impl.vif_attach(task, vif)"},{"line_number":983,"context_line":""},{"line_number":984,"context_line":"    def vif_detach(self, task, vif_id):"},{"line_number":985,"context_line":"        \"\"\"Detach a virtual network interface to a node"},{"line_number":986,"context_line":""},{"line_number":987,"context_line":"        :param task: A TaskManager instance."},{"line_number":988,"context_line":"        :param vif_id: A VIF ID to detach"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_31a412a5","line":985,"range":{"start_line":985,"start_character":46,"end_line":985,"end_character":55},"updated":"2016-11-24 12:15:19.000000000","message":"sounds funny :)","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":982,"context_line":"        return default_impl.vif_attach(task, vif)"},{"line_number":983,"context_line":""},{"line_number":984,"context_line":"    def vif_detach(self, task, vif_id):"},{"line_number":985,"context_line":"        \"\"\"Detach a virtual network interface to a node"},{"line_number":986,"context_line":""},{"line_number":987,"context_line":"        :param task: A TaskManager instance."},{"line_number":988,"context_line":"        :param vif_id: A VIF ID to detach"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_93981c6c","line":985,"range":{"start_line":985,"start_character":46,"end_line":985,"end_character":55},"in_reply_to":"5a74a57a_31a412a5","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":960,"context_line":"            LOG.warning(_LW(\u0027The network interface %s should be updated to \u0027"},{"line_number":961,"context_line":"                            \u0027implement the port_changed function, falling \u0027"},{"line_number":962,"context_line":"                            \u0027back to default implementation, this behaviour \u0027"},{"line_number":963,"context_line":"                            \u0027will be removed in Pike\u0027),"},{"line_number":964,"context_line":"                        self.__class__.__name__)"},{"line_number":965,"context_line":"        return default_impl.port_changed(task, port)"},{"line_number":966,"context_line":""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_4924c3ae","line":963,"updated":"2016-11-30 02:19:25.000000000","message":"nit: this is one very long sentence. Might want to break it up into two.\n\nIt seems to me that if they didn\u0027t implement port_changed(), the others aren\u0027t implemented either. I was wondering if we should just log a warning once for all of them. But I guess it doesn\u0027t matter that much.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":968,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":969,"context_line":""},{"line_number":970,"context_line":"        :param task: A TaskManager instance."},{"line_number":971,"context_line":"        :param vif: A VIF to attach"},{"line_number":972,"context_line":"        :raises: NetworkError"},{"line_number":973,"context_line":"        \"\"\""},{"line_number":974,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_f8e0f7ce","line":971,"updated":"2016-11-30 02:19:25.000000000","message":"maybe this is a dumb question, but what is a VIF? Is it an object?","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":968,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":969,"context_line":""},{"line_number":970,"context_line":"        :param task: A TaskManager instance."},{"line_number":971,"context_line":"        :param vif: A VIF to attach"},{"line_number":972,"context_line":"        :raises: NetworkError"},{"line_number":973,"context_line":"        \"\"\""},{"line_number":974,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_e912c657","line":971,"in_reply_to":"5a74a57a_f8e0f7ce","updated":"2016-11-30 16:12:57.000000000","message":"It was a dict, it will now be an object.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":948,"context_line":"        :raises: MissingParameterValue, if some parameters are missing."},{"line_number":949,"context_line":"        \"\"\""},{"line_number":950,"context_line":""},{"line_number":951,"context_line":"    def port_changed(self, task, port):"},{"line_number":952,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":953,"context_line":""},{"line_number":954,"context_line":"        :param task: a TaskManager instance."}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_e212c861","line":951,"updated":"2016-12-02 13:58:52.000000000","message":"This was not mentioned in the original spec, so should be a separate change.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"7846c4b0b91738018fb5e4430309f1d73bdb548d","unresolved":false,"context_lines":[{"line_number":948,"context_line":"        :raises: MissingParameterValue, if some parameters are missing."},{"line_number":949,"context_line":"        \"\"\""},{"line_number":950,"context_line":""},{"line_number":951,"context_line":"    def port_changed(self, task, port):"},{"line_number":952,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":953,"context_line":""},{"line_number":954,"context_line":"        :param task: a TaskManager instance."}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_1df9e580","line":951,"in_reply_to":"3a71b18c_e212c861","updated":"2016-12-02 14:20:05.000000000","message":"ah, with attach/detach we can store vif in a new place, and need to have ability to check it somehow on update. Please disregard this comment.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":999,"context_line":"        return default_impl.vif_detach(task, vif_id)"},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"    def vif_list(self, task):"},{"line_number":1002,"context_line":"        \"\"\"List attached VIF IDs."},{"line_number":1003,"context_line":""},{"line_number":1004,"context_line":"        :param task: A TaskManager instance."},{"line_number":1005,"context_line":"        :raises: NetworkError"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_a22b70ea","line":1002,"updated":"2016-12-02 13:58:52.000000000","message":"for a node.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":999,"context_line":"        return default_impl.vif_detach(task, vif_id)"},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"    def vif_list(self, task):"},{"line_number":1002,"context_line":"        \"\"\"List attached VIF IDs."},{"line_number":1003,"context_line":""},{"line_number":1004,"context_line":"        :param task: A TaskManager instance."},{"line_number":1005,"context_line":"        :raises: NetworkError"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_e0e0bdfc","line":1002,"in_reply_to":"3a71b18c_a22b70ea","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2dac1315fca80786a150e45cc723ac54575ffc50","unresolved":false,"context_lines":[{"line_number":953,"context_line":""},{"line_number":954,"context_line":"        :param task: a TaskManager instance."},{"line_number":955,"context_line":"        :param port: a changed Port object."},{"line_number":956,"context_line":"        \"\"\""},{"line_number":957,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":958,"context_line":"        if not self._deprecated_port_change_shown:"},{"line_number":959,"context_line":"            self.__class__._deprecated_port_change_shown \u003d True"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_0f99ef1f","line":956,"updated":"2016-12-07 17:58:21.000000000","message":"we should add \"raises:\" here. Looks like Conflict, FailedToUpdateDHCPOptOnPort","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":953,"context_line":""},{"line_number":954,"context_line":"        :param task: a TaskManager instance."},{"line_number":955,"context_line":"        :param port: a changed Port object."},{"line_number":956,"context_line":"        \"\"\""},{"line_number":957,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":958,"context_line":"        if not self._deprecated_port_change_shown:"},{"line_number":959,"context_line":"            self.__class__._deprecated_port_change_shown \u003d True"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_2ac4b23e","line":956,"in_reply_to":"3a71b18c_0f99ef1f","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":10342,"name":"Jay Faulkner","display_name":"JayF","email":"jay@jvf.cc","username":"JayF","status":"youtube.com/@oss-gr / podcast.gr-oss.io"},"change_message_id":"76702d879c51b18445b78de7893e173b591ddd1b","unresolved":false,"context_lines":[{"line_number":962,"context_line":"                            \u0027implement the port_changed function. Falling \u0027"},{"line_number":963,"context_line":"                            \u0027back to default implementation, this behaviour \u0027"},{"line_number":964,"context_line":"                            \u0027will be removed in Pike\u0027),"},{"line_number":965,"context_line":"                        self.__class__.__name__)"},{"line_number":966,"context_line":"        return default_impl.port_changed(task, port)"},{"line_number":967,"context_line":""},{"line_number":968,"context_line":"    def vif_attach(self, task, vif):"}],"source_content_type":"text/x-python","patch_set":29,"id":"3a71b18c_8b11fe06","line":965,"updated":"2016-12-09 23:18:00.000000000","message":"Are you sure this is going to be the actual name of the driver? When I tried to do something similar in a previous patch, this always seemed to return BaseDriver.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"f15fc071b19853025c90ca5882a4fb26f7c3639d","unresolved":false,"context_lines":[{"line_number":962,"context_line":"                            \u0027implement the port_changed function. Falling \u0027"},{"line_number":963,"context_line":"                            \u0027back to default implementation, this behaviour \u0027"},{"line_number":964,"context_line":"                            \u0027will be removed in Pike\u0027),"},{"line_number":965,"context_line":"                        self.__class__.__name__)"},{"line_number":966,"context_line":"        return default_impl.port_changed(task, port)"},{"line_number":967,"context_line":""},{"line_number":968,"context_line":"    def vif_attach(self, task, vif):"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_3f20a249","line":965,"in_reply_to":"3a71b18c_8b11fe06","updated":"2016-12-12 18:44:38.000000000","message":"This should work as long as the driver inherits from BaseDriver.\n\n\u003e\u003e\u003e class BD:\n...     pass\n... \n\u003e\u003e\u003e class ID(BD):\n...     pass\n... \n\u003e\u003e\u003e dr \u003d ID()\n\u003e\u003e\u003e dr.__class__.__name__\n\u0027ID\u0027\n\nAlso, https://docs.python.org/2/library/stdtypes.html?highlight\u003d__class__#instance.__class__ says that __class__ refers to an instance\u0027s class, not superclass.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"8f520f373fefdbd12e89ba249329439a36dc1882","unresolved":false,"context_lines":[{"line_number":969,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":970,"context_line":""},{"line_number":971,"context_line":"        :param task: A TaskManager instance."},{"line_number":972,"context_line":"        :param vif: A VIF object to attach"},{"line_number":973,"context_line":"        :raises: NetworkError"},{"line_number":974,"context_line":"        \"\"\""},{"line_number":975,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_445b9c2e","line":972,"updated":"2016-12-13 18:22:22.000000000","message":"I\u0027m kind of moving the discussion about vif_attach to here, since this is where we are specifying the interface methods for all NetworkInterfaces.\n\nWe need to clarify what this vif is.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"8f520f373fefdbd12e89ba249329439a36dc1882","unresolved":false,"context_lines":[{"line_number":1000,"context_line":"        return default_impl.vif_detach(task, vif_id)"},{"line_number":1001,"context_line":""},{"line_number":1002,"context_line":"    def vif_list(self, task):"},{"line_number":1003,"context_line":"        \"\"\"List attached VIF IDs for a node"},{"line_number":1004,"context_line":""},{"line_number":1005,"context_line":"        :param task: A TaskManager instance."},{"line_number":1006,"context_line":"        :raises: NetworkError"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_04ed2425","line":1003,"updated":"2016-12-13 18:22:22.000000000","message":"in light of the discussion about vif_attach and what a vif is... I know this says that it lists VIF IDs. But is that what the user will expect. All our other \u0027list\u0027 APIs return an object back. I suppose it could return ID only in the \u0027non-detail\u0027 form of the request. But even so, I wonder if we should be returning whatever vif object is being used in vif_attach(). Eg, if it is a dict in vif_attach, shouldn\u0027t it be a dict here too? It\u0027ll make it easler later if we need/want to extend it to include eg other info that was passed in as part of the vif.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":1003,"context_line":"        \"\"\"List attached VIF IDs for a node"},{"line_number":1004,"context_line":""},{"line_number":1005,"context_line":"        :param task: A TaskManager instance."},{"line_number":1006,"context_line":"        :raises: NetworkError"},{"line_number":1007,"context_line":"        \"\"\""},{"line_number":1008,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":1009,"context_line":"        if not self._deprecated_vif_list_shown:"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_9aaa9718","line":1006,"updated":"2016-12-13 01:26:36.000000000","message":"Joanna brought it up elsewhere, should add \u0027:returns: ...\u0027 here.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":1028,"context_line":"        \"\"\"List attached VIF IDs for a node"},{"line_number":1029,"context_line":""},{"line_number":1030,"context_line":"        :param task: A TaskManager instance."},{"line_number":1031,"context_line":"        :raises: NetworkError"},{"line_number":1032,"context_line":"        \"\"\""},{"line_number":1033,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":1034,"context_line":"        if not self._deprecated_vif_list_shown:"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_c3a84623","line":1031,"updated":"2016-12-14 19:25:36.000000000","message":"Joanna brought it up elsewhere, should add something like \u0027:returns: List of VIF dictionaries, each dictionary will have an \u0027id\u0027 entry with the ID of the VIF.\u0027","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":1028,"context_line":"        \"\"\"List attached VIF IDs for a node"},{"line_number":1029,"context_line":""},{"line_number":1030,"context_line":"        :param task: A TaskManager instance."},{"line_number":1031,"context_line":"        :raises: NetworkError"},{"line_number":1032,"context_line":"        \"\"\""},{"line_number":1033,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":1034,"context_line":"        if not self._deprecated_vif_list_shown:"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_54ff73a9","line":1031,"in_reply_to":"1a6eadb0_c3a84623","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"f7e995985bad7f588d56553d209d51612b681739","unresolved":false,"context_lines":[{"line_number":1044,"context_line":""},{"line_number":1045,"context_line":"    # TODO(vsaienko) Make this method abstract in Pike."},{"line_number":1046,"context_line":"    def get_current_vif(self, task, p_obj):"},{"line_number":1047,"context_line":"        \"\"\"Returns a VIF associated with port or portgroup"},{"line_number":1048,"context_line":""},{"line_number":1049,"context_line":"        :param task: A TaskManager instance."},{"line_number":1050,"context_line":"        :param p_obj: Ironic port or portgroup object."}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_136e282f","line":1047,"updated":"2016-12-20 14:57:20.000000000","message":"it is more than a VIF that is associated with p*. Since cleaning, provisioning, tenant vifs are associated with p*. You mean the VIF that is currently being used/attached, right?","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"a5868bfab3e38848d2b3d1e9f35ae9f7a4277c9d","unresolved":false,"context_lines":[{"line_number":1044,"context_line":""},{"line_number":1045,"context_line":"    # TODO(vsaienko) Make this method abstract in Pike."},{"line_number":1046,"context_line":"    def get_current_vif(self, task, p_obj):"},{"line_number":1047,"context_line":"        \"\"\"Returns a VIF associated with port or portgroup"},{"line_number":1048,"context_line":""},{"line_number":1049,"context_line":"        :param task: A TaskManager instance."},{"line_number":1050,"context_line":"        :param p_obj: Ironic port or portgroup object."}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_beeb7477","line":1047,"in_reply_to":"1a6eadb0_136e282f","updated":"2016-12-20 16:59:09.000000000","message":"correct, this function returns currently used vif associated with the port. I\u0027ve update docstring.","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"f7e995985bad7f588d56553d209d51612b681739","unresolved":false,"context_lines":[{"line_number":1048,"context_line":""},{"line_number":1049,"context_line":"        :param task: A TaskManager instance."},{"line_number":1050,"context_line":"        :param p_obj: Ironic port or portgroup object."},{"line_number":1051,"context_line":"        :returns: VIF ID associated with p_obj."},{"line_number":1052,"context_line":"        \"\"\""},{"line_number":1053,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":1054,"context_line":"        if not self._deprecated_get_current_vif_shown:"}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_d3e8307f","line":1051,"updated":"2016-12-20 14:57:20.000000000","message":"what if there is no VIF. What does it return?","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"a5868bfab3e38848d2b3d1e9f35ae9f7a4277c9d","unresolved":false,"context_lines":[{"line_number":1048,"context_line":""},{"line_number":1049,"context_line":"        :param task: A TaskManager instance."},{"line_number":1050,"context_line":"        :param p_obj: Ironic port or portgroup object."},{"line_number":1051,"context_line":"        :returns: VIF ID associated with p_obj."},{"line_number":1052,"context_line":"        \"\"\""},{"line_number":1053,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":1054,"context_line":"        if not self._deprecated_get_current_vif_shown:"}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_3e47644c","line":1051,"in_reply_to":"1a6eadb0_d3e8307f","updated":"2016-12-20 16:59:09.000000000","message":"It will return None.","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"f7e995985bad7f588d56553d209d51612b681739","unresolved":false,"context_lines":[{"line_number":1052,"context_line":"        \"\"\""},{"line_number":1053,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":1054,"context_line":"        if not self._deprecated_get_current_vif_shown:"},{"line_number":1055,"context_line":"            self._deprecated_get_current_vif_shown \u003d True"},{"line_number":1056,"context_line":"            LOG.warning(_LW(\u0027The network interface %s should be updated to \u0027"},{"line_number":1057,"context_line":"                            \u0027implement the get_current_vif function. Falling \u0027"},{"line_number":1058,"context_line":"                            \u0027back to default implementation, this behaviour \u0027"}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_3350845e","line":1055,"updated":"2016-12-20 14:57:20.000000000","message":"nit. The other lines (eg L1037) have self.__class__._deprecated... so would be good if this was consistent.","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"a5868bfab3e38848d2b3d1e9f35ae9f7a4277c9d","unresolved":false,"context_lines":[{"line_number":1052,"context_line":"        \"\"\""},{"line_number":1053,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":1054,"context_line":"        if not self._deprecated_get_current_vif_shown:"},{"line_number":1055,"context_line":"            self._deprecated_get_current_vif_shown \u003d True"},{"line_number":1056,"context_line":"            LOG.warning(_LW(\u0027The network interface %s should be updated to \u0027"},{"line_number":1057,"context_line":"                            \u0027implement the get_current_vif function. Falling \u0027"},{"line_number":1058,"context_line":"                            \u0027back to default implementation, this behaviour \u0027"}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_7e02bc0a","line":1055,"in_reply_to":"1a6eadb0_3350845e","updated":"2016-12-20 16:59:09.000000000","message":"Done","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"409b583e400b0f073439f55979e1a4b8a84c1de0","unresolved":false,"context_lines":[{"line_number":1049,"context_line":"        We are booting the node only in one network at a time, and presence of"},{"line_number":1050,"context_line":"        cleaning_vif_port_id means we\u0027re doing cleaning, of"},{"line_number":1051,"context_line":"        provisioning_vif_port_id - provisioning."},{"line_number":1052,"context_line":"        Otherwise it\u0027s a tenant network"},{"line_number":1053,"context_line":""},{"line_number":1054,"context_line":"        :param task: A TaskManager instance."},{"line_number":1055,"context_line":"        :param p_obj: Ironic port or portgroup object."}],"source_content_type":"text/x-python","patch_set":36,"id":"1a6eadb0_f726ef14","line":1052,"updated":"2016-12-20 17:36:18.000000000","message":"nit, missing period at end. The formatting is odd too.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"409b583e400b0f073439f55979e1a4b8a84c1de0","unresolved":false,"context_lines":[{"line_number":1056,"context_line":"        :returns: VIF ID associated with p_obj or None."},{"line_number":1057,"context_line":"        \"\"\""},{"line_number":1058,"context_line":"        default_impl \u003d net_common.VIFPortIDMixin()"},{"line_number":1059,"context_line":"        if not self.__class__._deprecated_get_current_vif_shown:"},{"line_number":1060,"context_line":"            self.__class__._deprecated_get_current_vif_shown \u003d True"},{"line_number":1061,"context_line":"            LOG.warning(_LW(\u0027The network interface %s should be updated to \u0027"},{"line_number":1062,"context_line":"                            \u0027implement the get_current_vif function. Falling \u0027"}],"source_content_type":"text/x-python","patch_set":36,"id":"1a6eadb0_7763bf1a","line":1059,"updated":"2016-12-20 17:36:18.000000000","message":"nit: this is self.deprecated_* elsewhere (eg L1036) but I\u0027m not going to ask you to change it :)","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"}],"ironic/drivers/modules/deploy_utils.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":542,"context_line":"        if (port.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":543,"context_line":"                port.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":544,"context_line":"                port.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":545,"context_line":"                port.internal_info.get(\u0027vif_port_id\u0027)):"},{"line_number":546,"context_line":"            return port.address"},{"line_number":547,"context_line":""},{"line_number":548,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_e9867715","line":545,"range":{"start_line":545,"start_character":34,"end_line":545,"end_character":35},"updated":"2016-11-14 09:13:18.000000000","message":"ditto","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":542,"context_line":"        if (port.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":543,"context_line":"                port.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":544,"context_line":"                port.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":545,"context_line":"                port.internal_info.get(\u0027vif_port_id\u0027)):"},{"line_number":546,"context_line":"            return port.address"},{"line_number":547,"context_line":""},{"line_number":548,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_1e5757cb","line":545,"range":{"start_line":545,"start_character":34,"end_line":545,"end_character":35},"in_reply_to":"9a629dbe_e9867715","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"7a1ebf55804878f65759a80a04991bed9c9366f5","unresolved":false,"context_lines":[{"line_number":541,"context_line":"    for port in task.ports:"},{"line_number":542,"context_line":"        if (port.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":543,"context_line":"                port.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":544,"context_line":"                port.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":545,"context_line":"                port.extra.get(\u0027vif_port_id\u0027)):"},{"line_number":546,"context_line":"            return port.address"},{"line_number":547,"context_line":""}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_9552a265","line":544,"updated":"2016-11-18 19:33:55.000000000","message":"ditto with precedence question from other files","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":542,"context_line":"                port.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":543,"context_line":"                port.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":544,"context_line":"                port.extra.get(\u0027vif_port_id\u0027)):"},{"line_number":545,"context_line":"            return port.address"},{"line_number":546,"context_line":""},{"line_number":547,"context_line":""},{"line_number":548,"context_line":"def parse_instance_info_capabilities(node):"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_690f8888","line":545,"updated":"2016-11-30 22:09:24.000000000","message":"probably add a unit test for this in tests/unit/drivers/modules/test_deploy_utils.py","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":542,"context_line":"                port.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":543,"context_line":"                port.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":544,"context_line":"                port.extra.get(\u0027vif_port_id\u0027)):"},{"line_number":545,"context_line":"            return port.address"},{"line_number":546,"context_line":""},{"line_number":547,"context_line":""},{"line_number":548,"context_line":"def parse_instance_info_capabilities(node):"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_20db95ed","line":545,"in_reply_to":"5a74a57a_690f8888","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a526bf2bfe79323c2f4f852d53a5da2a87297327","unresolved":false,"context_lines":[{"line_number":536,"context_line":"    for port in task.ports:"},{"line_number":537,"context_line":"        if (port.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":538,"context_line":"                port.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":539,"context_line":"                port.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":540,"context_line":"                port.extra.get(\u0027vif_port_id\u0027)):"},{"line_number":541,"context_line":"            return port.address"},{"line_number":542,"context_line":""}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_3da7e60b","line":539,"updated":"2016-12-16 19:52:25.000000000","message":"ditto, network interface method","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":536,"context_line":"    for port in task.ports:"},{"line_number":537,"context_line":"        if (port.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":538,"context_line":"                port.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":539,"context_line":"                port.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":540,"context_line":"                port.extra.get(\u0027vif_port_id\u0027)):"},{"line_number":541,"context_line":"            return port.address"},{"line_number":542,"context_line":""}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_2c5d9079","line":539,"in_reply_to":"1a6eadb0_3da7e60b","updated":"2016-12-20 16:58:56.000000000","message":"Done","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"}],"ironic/drivers/modules/fake.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":227,"context_line":"        pass"},{"line_number":228,"context_line":""},{"line_number":229,"context_line":""},{"line_number":230,"context_line":"class FakeNetwork(base.NetworkInterface):"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"    def add_provisioning_network(self, task):"},{"line_number":233,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_460ad3d3","line":230,"updated":"2016-11-15 15:52:26.000000000","message":"It is not related to this patch.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5141d24a4ca5c81c5e1679a9ea6fb43fb4d6f582","unresolved":false,"context_lines":[{"line_number":227,"context_line":"        pass"},{"line_number":228,"context_line":""},{"line_number":229,"context_line":""},{"line_number":230,"context_line":"class FakeNetwork(base.NetworkInterface):"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"    def add_provisioning_network(self, task):"},{"line_number":233,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_56733b80","line":230,"in_reply_to":"7a77a97e_460ad3d3","updated":"2016-11-16 12:15:22.000000000","message":"This is required for testing the default implementation.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":227,"context_line":"        pass"},{"line_number":228,"context_line":""},{"line_number":229,"context_line":""},{"line_number":230,"context_line":"class FakeNetwork(base.NetworkInterface):"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"    def add_provisioning_network(self, task):"},{"line_number":233,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_d080b68d","line":230,"updated":"2016-11-18 14:46:16.000000000","message":"We shouldn\u0027t add a FakeNetwork driver only for tests, it is possible to create TestNetwrokDriver in tests itself to test that attach/detach methods are defined. for example like it done here:\n\nhttps://github.com/openstack/ironic/blob/106455811be0d678ce4fe0c3a67894e31e44e6f9/ironic/tests/unit/drivers/test_base.py#L229","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"}],"ironic/drivers/modules/network/common.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"    def list_vifs(self, task):"},{"line_number":22,"context_line":"        vifs \u003d []"},{"line_number":23,"context_line":"        for port in task.ports:"},{"line_number":24,"context_line":"            vif \u003d port.internal_info.get("},{"line_number":25,"context_line":"                \u0027vif_port_id\u0027, port.extra.get(\u0027vif_port_id\u0027))"},{"line_number":26,"context_line":"            if vif:"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_ccb54132","line":23,"updated":"2016-11-14 09:13:18.000000000","message":"should walk via portgroups also.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":22,"context_line":"        vifs \u003d []"},{"line_number":23,"context_line":"        for port in task.ports:"},{"line_number":24,"context_line":"            vif \u003d port.internal_info.get("},{"line_number":25,"context_line":"                \u0027vif_port_id\u0027, port.extra.get(\u0027vif_port_id\u0027))"},{"line_number":26,"context_line":"            if vif:"},{"line_number":27,"context_line":"                vifs.append(vif)"},{"line_number":28,"context_line":"        return vifs"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_51f554c9","line":25,"updated":"2016-11-13 22:17:58.000000000","message":"So in case of attaching/detaching and determining the currently used vif_id we\u0027re giving preference to extra, here internal_info will be used first. Let\u0027s decide which one has the priority and use it everywhere.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    def attach_vif(self, task, vif):"},{"line_number":31,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":32,"context_line":"        for port in task.ports:"},{"line_number":33,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"},{"line_number":34,"context_line":"            # a nova driver that uses port.extra"},{"line_number":35,"context_line":"            if (\"vif_port_id\" not in port.extra and"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_2ca4fd06","line":32,"updated":"2016-11-14 09:13:18.000000000","message":"We should walk over portgroups also.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":41,"context_line":"                break"},{"line_number":42,"context_line":"        else:"},{"line_number":43,"context_line":"            raise exception.NetworkError(\"Unable to attach vif, not \""},{"line_number":44,"context_line":"                                         \"enough physical vifs\")"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"    def detach_vif(self, task, vif_id):"},{"line_number":47,"context_line":"        for port in task.ports:"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_c9737314","line":44,"updated":"2016-11-14 09:13:18.000000000","message":"what do you think about the following:\n\n\"Unable to attach a new vif %(vif)s to node %(node)s as node doesn\u0027t have free physical network ports.\"","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":44,"context_line":"                                         \"enough physical vifs\")"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"    def detach_vif(self, task, vif_id):"},{"line_number":47,"context_line":"        for port in task.ports:"},{"line_number":48,"context_line":"            # FIXME(sambetts) Remove this when we no longer support a nova"},{"line_number":49,"context_line":"            # driver that uses port.extra"},{"line_number":50,"context_line":"            if port.extra.get(\"vif_port_id\") \u003d\u003d vif_id:"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_6caef5e8","line":47,"updated":"2016-11-14 09:13:18.000000000","message":"ditto","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        for port in task.ports:"},{"line_number":48,"context_line":"            # FIXME(sambetts) Remove this when we no longer support a nova"},{"line_number":49,"context_line":"            # driver that uses port.extra"},{"line_number":50,"context_line":"            if port.extra.get(\"vif_port_id\") \u003d\u003d vif_id:"},{"line_number":51,"context_line":"                extra \u003d port.extra"},{"line_number":52,"context_line":"                del extra[\u0027vif_port_id\u0027]"},{"line_number":53,"context_line":"                port.extra \u003d extra"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_91ba8c09","line":50,"updated":"2016-11-13 22:17:58.000000000","message":"If someone puts extra[\u0027vif_port_id\u0027] manually, vif_port_id in internal_info won\u0027t be cleaned up, and when attach_vif will be called next time, NetworkError will be raised because of this. I\u0027d rather remove both I think.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        for port in task.ports:"},{"line_number":48,"context_line":"            # FIXME(sambetts) Remove this when we no longer support a nova"},{"line_number":49,"context_line":"            # driver that uses port.extra"},{"line_number":50,"context_line":"            if port.extra.get(\"vif_port_id\") \u003d\u003d vif_id:"},{"line_number":51,"context_line":"                extra \u003d port.extra"},{"line_number":52,"context_line":"                del extra[\u0027vif_port_id\u0027]"},{"line_number":53,"context_line":"                port.extra \u003d extra"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_352a797f","line":50,"in_reply_to":"9a629dbe_09f2cb6f","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        for port in task.ports:"},{"line_number":48,"context_line":"            # FIXME(sambetts) Remove this when we no longer support a nova"},{"line_number":49,"context_line":"            # driver that uses port.extra"},{"line_number":50,"context_line":"            if port.extra.get(\"vif_port_id\") \u003d\u003d vif_id:"},{"line_number":51,"context_line":"                extra \u003d port.extra"},{"line_number":52,"context_line":"                del extra[\u0027vif_port_id\u0027]"},{"line_number":53,"context_line":"                port.extra \u003d extra"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_09f2cb6f","line":50,"in_reply_to":"9a629dbe_91ba8c09","updated":"2016-11-14 09:13:18.000000000","message":"Will we allow to attach interface by old api version, ie value is stored in port.extra. While remove it by request with new API version and vice versa?","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":60,"context_line":"                port.save()"},{"line_number":61,"context_line":"                break"},{"line_number":62,"context_line":"        else:"},{"line_number":63,"context_line":"            raise exception.NetworkError(\"Unable to detach vif, \""},{"line_number":64,"context_line":"                                         \"vif not attached to node\")"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_29b5cf7d","line":63,"updated":"2016-11-14 09:13:18.000000000","message":"Might be something like:\n\n\"Vif %(vif)s is not attach to node %(node)s. Unable to detach it.\"","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":60,"context_line":"                port.save()"},{"line_number":61,"context_line":"                break"},{"line_number":62,"context_line":"        else:"},{"line_number":63,"context_line":"            raise exception.NetworkError(\"Unable to detach vif, \""},{"line_number":64,"context_line":"                                         \"vif not attached to node\")"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_551fed5a","line":63,"in_reply_to":"9a629dbe_29b5cf7d","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":21,"context_line":""},{"line_number":22,"context_line":"    def list_vifs(self, task):"},{"line_number":23,"context_line":"        vifs \u003d []"},{"line_number":24,"context_line":"        for port in task.ports:"},{"line_number":25,"context_line":"            vif \u003d port.internal_info.get("},{"line_number":26,"context_line":"                \u0027vif_port_id\u0027, port.extra.get(\u0027vif_port_id\u0027))"},{"line_number":27,"context_line":"            if vif:"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_d5a04f93","line":24,"updated":"2016-11-15 15:52:26.000000000","message":"we should walk over portgroups also.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5141d24a4ca5c81c5e1679a9ea6fb43fb4d6f582","unresolved":false,"context_lines":[{"line_number":21,"context_line":""},{"line_number":22,"context_line":"    def list_vifs(self, task):"},{"line_number":23,"context_line":"        vifs \u003d []"},{"line_number":24,"context_line":"        for port in task.ports:"},{"line_number":25,"context_line":"            vif \u003d port.internal_info.get("},{"line_number":26,"context_line":"                \u0027vif_port_id\u0027, port.extra.get(\u0027vif_port_id\u0027))"},{"line_number":27,"context_line":"            if vif:"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_56fa5bbe","line":24,"in_reply_to":"7a77a97e_d5a04f93","updated":"2016-11-16 12:15:22.000000000","message":"Discussed this with jroll, going to add portgroups in a follow up patch.","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":25,"context_line":"            vif \u003d port.internal_info.get("},{"line_number":26,"context_line":"                \u0027vif_port_id\u0027, port.extra.get(\u0027vif_port_id\u0027))"},{"line_number":27,"context_line":"            if vif:"},{"line_number":28,"context_line":"                vifs.append(vif)"},{"line_number":29,"context_line":"        return vifs"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def attach_vif(self, task, vif):"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_558d1f30","line":28,"updated":"2016-11-15 15:52:26.000000000","message":"the spec was updated it should return now:\n\n[{\u0027id\u0027: \u0027vif-id\u0027}]","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5141d24a4ca5c81c5e1679a9ea6fb43fb4d6f582","unresolved":false,"context_lines":[{"line_number":25,"context_line":"            vif \u003d port.internal_info.get("},{"line_number":26,"context_line":"                \u0027vif_port_id\u0027, port.extra.get(\u0027vif_port_id\u0027))"},{"line_number":27,"context_line":"            if vif:"},{"line_number":28,"context_line":"                vifs.append(vif)"},{"line_number":29,"context_line":"        return vifs"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def attach_vif(self, task, vif):"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_96a073a1","line":28,"in_reply_to":"7a77a97e_558d1f30","updated":"2016-11-16 12:15:22.000000000","message":"Done","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":28,"context_line":"                vifs.append(vif)"},{"line_number":29,"context_line":"        return vifs"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def attach_vif(self, task, vif):"},{"line_number":32,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":33,"context_line":"        for port in task.ports:"},{"line_number":34,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_46049314","line":31,"range":{"start_line":31,"start_character":8,"end_line":31,"end_character":18},"updated":"2016-11-15 15:52:26.000000000","message":"according to the spec new method name should be vif_attach/vif_detach","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5141d24a4ca5c81c5e1679a9ea6fb43fb4d6f582","unresolved":false,"context_lines":[{"line_number":28,"context_line":"                vifs.append(vif)"},{"line_number":29,"context_line":"        return vifs"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def attach_vif(self, task, vif):"},{"line_number":32,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":33,"context_line":"        for port in task.ports:"},{"line_number":34,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_a9727047","line":31,"range":{"start_line":31,"start_character":8,"end_line":31,"end_character":18},"in_reply_to":"7a77a97e_46049314","updated":"2016-11-16 12:15:22.000000000","message":"Done","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def attach_vif(self, task, vif):"},{"line_number":32,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":33,"context_line":"        for port in task.ports:"},{"line_number":34,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"},{"line_number":35,"context_line":"            # a nova driver that uses port.extra"},{"line_number":36,"context_line":"            if (\"vif_port_id\" not in port.extra and"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_f5770b00","line":33,"updated":"2016-11-15 15:52:26.000000000","message":"ditto about portgroups. According to nova specification [0] portgroup should be picked first with higher precedence than port.\n\n\n[0] https://review.openstack.org/#/c/387534/","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f0e110ce915a3ad72ae7f814c5979bd3ace44553","unresolved":false,"context_lines":[{"line_number":45,"context_line":"                                         \"enough physical vifs\")"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"    def detach_vif(self, task, vif_id):"},{"line_number":48,"context_line":"        for port in task.ports:"},{"line_number":49,"context_line":"            # FIXME(sambetts) Remove this when we no longer support a nova"},{"line_number":50,"context_line":"            # driver that uses port.extra"},{"line_number":51,"context_line":"            if (port.extra.get(\"vif_port_id\") \u003d\u003d vif_id or"}],"source_content_type":"text/x-python","patch_set":21,"id":"7a77a97e_557effe4","line":48,"updated":"2016-11-15 15:52:26.000000000","message":"ditto about portgroups","commit_id":"cd736cdfbf81cb0fdf65bc28ad6ade6a41c32345"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":29,"context_line":""},{"line_number":30,"context_line":"class VIFPortIDMixin(object):"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    def port_changed(self, task, port_obj):"},{"line_number":33,"context_line":"        context \u003d task.context"},{"line_number":34,"context_line":"        node \u003d task.node"},{"line_number":35,"context_line":"        port_uuid \u003d port_obj.uuid"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_f6b43cd2","line":32,"updated":"2016-11-18 14:46:16.000000000","message":"please add docstring.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":29,"context_line":""},{"line_number":30,"context_line":"class VIFPortIDMixin(object):"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    def port_changed(self, task, port_obj):"},{"line_number":33,"context_line":"        context \u003d task.context"},{"line_number":34,"context_line":"        node \u003d task.node"},{"line_number":35,"context_line":"        port_uuid \u003d port_obj.uuid"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_be682b89","line":32,"in_reply_to":"7a77a97e_f6b43cd2","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":75,"context_line":"                        {\u0027port\u0027: port_uuid,"},{"line_number":76,"context_line":"                         \u0027instance\u0027: node.instance_uuid})"},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    def vif_list(self, task):"},{"line_number":79,"context_line":"        vifs \u003d []"},{"line_number":80,"context_line":"        for port in task.ports:"},{"line_number":81,"context_line":"            vif_id \u003d port.internal_info.get("}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_36a07490","line":78,"updated":"2016-11-18 14:46:16.000000000","message":"please add docstring.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":75,"context_line":"                        {\u0027port\u0027: port_uuid,"},{"line_number":76,"context_line":"                         \u0027instance\u0027: node.instance_uuid})"},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    def vif_list(self, task):"},{"line_number":79,"context_line":"        vifs \u003d []"},{"line_number":80,"context_line":"        for port in task.ports:"},{"line_number":81,"context_line":"            vif_id \u003d port.internal_info.get("}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_fe08e3db","line":78,"in_reply_to":"7a77a97e_36a07490","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":84,"context_line":"                vifs.append({\u0027id\u0027: vif_id})"},{"line_number":85,"context_line":"        return vifs"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def vif_attach(self, task, vif):"},{"line_number":88,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":89,"context_line":"        for port in task.ports:"},{"line_number":90,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_16a538a1","line":87,"updated":"2016-11-18 14:46:16.000000000","message":"please add docstring.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":84,"context_line":"                vifs.append({\u0027id\u0027: vif_id})"},{"line_number":85,"context_line":"        return vifs"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def vif_attach(self, task, vif):"},{"line_number":88,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":89,"context_line":"        for port in task.ports:"},{"line_number":90,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_1e0e7fe5","line":87,"in_reply_to":"7a77a97e_16a538a1","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"0a75c35f78204d1b466bc86e32b61de45334a731","unresolved":false,"context_lines":[{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def vif_attach(self, task, vif):"},{"line_number":88,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":89,"context_line":"        for port in task.ports:"},{"line_number":90,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"},{"line_number":91,"context_line":"            # a nova driver that uses port.extra"},{"line_number":92,"context_line":"            if (\"vif_port_id\" not in port.extra and"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_cb33a7f4","line":89,"updated":"2016-11-18 14:46:16.000000000","message":"Attaching VIF to port with pxe_enabled\u003dFalse and flat network interface will lead to deploy failure, we shouldn\u0027t allow that.","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"64cad705cb7318ada5113a3049c187b7a8e1501a","unresolved":false,"context_lines":[{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def vif_attach(self, task, vif):"},{"line_number":88,"context_line":"        vif_id \u003d vif.get(\u0027id\u0027)"},{"line_number":89,"context_line":"        for port in task.ports:"},{"line_number":90,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"},{"line_number":91,"context_line":"            # a nova driver that uses port.extra"},{"line_number":92,"context_line":"            if (\"vif_port_id\" not in port.extra and"}],"source_content_type":"text/x-python","patch_set":22,"id":"7a77a97e_9e752f34","line":89,"in_reply_to":"7a77a97e_cb33a7f4","updated":"2016-11-21 17:37:45.000000000","message":"Done","commit_id":"86f60ce7389dee248160f93b1de2364397f26658"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":123,"context_line":"                        neutron.update_port_address(vif_id, port.address)"},{"line_number":124,"context_line":"                    except exception.FailedToUpdateMacOnPort:"},{"line_number":125,"context_line":"                        raise exception.NetworkError("},{"line_number":126,"context_line":"                            \"Unable to attach VIF because Ironic can not \""},{"line_number":127,"context_line":"                            \"update Neutron port MAC address to match \""},{"line_number":128,"context_line":"                            \"physical MAC address\")"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"                int_info \u003d port.internal_info"},{"line_number":131,"context_line":"                int_info[\u0027vif_port_id\u0027] \u003d vif_id"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_149d4459","line":128,"range":{"start_line":126,"start_character":28,"end_line":128,"end_character":50},"updated":"2016-11-24 12:15:19.000000000","message":"missed translation here.","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":123,"context_line":"                        neutron.update_port_address(vif_id, port.address)"},{"line_number":124,"context_line":"                    except exception.FailedToUpdateMacOnPort:"},{"line_number":125,"context_line":"                        raise exception.NetworkError("},{"line_number":126,"context_line":"                            \"Unable to attach VIF because Ironic can not \""},{"line_number":127,"context_line":"                            \"update Neutron port MAC address to match \""},{"line_number":128,"context_line":"                            \"physical MAC address\")"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"                int_info \u003d port.internal_info"},{"line_number":131,"context_line":"                int_info[\u0027vif_port_id\u0027] \u003d vif_id"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_53ca041c","line":128,"range":{"start_line":126,"start_character":28,"end_line":128,"end_character":50},"in_reply_to":"5a74a57a_149d4459","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":133,"context_line":"                port.save()"},{"line_number":134,"context_line":"                break"},{"line_number":135,"context_line":"        else:"},{"line_number":136,"context_line":"            raise exception.NetworkError(\"Unable to attach vif, not \""},{"line_number":137,"context_line":"                                         \"enough physical vifs\")"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"    def vif_detach(self, task, vif_id):"},{"line_number":140,"context_line":"        \"\"\"Detach a virtual network interface to a node"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_74ae7886","line":137,"range":{"start_line":136,"start_character":41,"end_line":137,"end_character":63},"updated":"2016-11-24 12:15:19.000000000","message":"ditto","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":133,"context_line":"                port.save()"},{"line_number":134,"context_line":"                break"},{"line_number":135,"context_line":"        else:"},{"line_number":136,"context_line":"            raise exception.NetworkError(\"Unable to attach vif, not \""},{"line_number":137,"context_line":"                                         \"enough physical vifs\")"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"    def vif_detach(self, task, vif_id):"},{"line_number":140,"context_line":"        \"\"\"Detach a virtual network interface to a node"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_334908b8","line":137,"range":{"start_line":136,"start_character":41,"end_line":137,"end_character":63},"in_reply_to":"5a74a57a_74ae7886","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":157,"context_line":"                port.save()"},{"line_number":158,"context_line":"                break"},{"line_number":159,"context_line":"        else:"},{"line_number":160,"context_line":"            raise exception.NetworkError(\"Unable to detach VIF: \""},{"line_number":161,"context_line":"                                         \"VIF %s not attached to node \""},{"line_number":162,"context_line":"                                         \"%s\" % (vif_id, task.node.uuid))"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_94a9547e","line":162,"range":{"start_line":160,"start_character":41,"end_line":162,"end_character":45},"updated":"2016-11-24 12:15:19.000000000","message":"ditto","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":157,"context_line":"                port.save()"},{"line_number":158,"context_line":"                break"},{"line_number":159,"context_line":"        else:"},{"line_number":160,"context_line":"            raise exception.NetworkError(\"Unable to detach VIF: \""},{"line_number":161,"context_line":"                                         \"VIF %s not attached to node \""},{"line_number":162,"context_line":"                                         \"%s\" % (vif_id, task.node.uuid))"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_73cd4030","line":162,"range":{"start_line":160,"start_character":41,"end_line":162,"end_character":45},"in_reply_to":"5a74a57a_94a9547e","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4d4c25f3f39c5805057ace978900d91daf3028c0","unresolved":false,"context_lines":[{"line_number":33,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"        :param task: a TaskManager instance."},{"line_number":36,"context_line":"        :param port: a changed Port object."},{"line_number":37,"context_line":"        \"\"\""},{"line_number":38,"context_line":"        context \u003d task.context"},{"line_number":39,"context_line":"        node \u003d task.node"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_2deea1ec","line":36,"updated":"2016-11-30 09:40:23.000000000","message":"might need to mention what it raises","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":33,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"        :param task: a TaskManager instance."},{"line_number":36,"context_line":"        :param port: a changed Port object."},{"line_number":37,"context_line":"        \"\"\""},{"line_number":38,"context_line":"        context \u003d task.context"},{"line_number":39,"context_line":"        node \u003d task.node"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_29be7eff","line":36,"in_reply_to":"5a74a57a_2deea1ec","updated":"2016-11-30 16:12:57.000000000","message":"Done","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"35c76888c40057921b4d63e6a053fc81e7fe90fc","unresolved":false,"context_lines":[{"line_number":55,"context_line":"                    {\u0027port\u0027: port_uuid, \u0027instance\u0027: node.instance_uuid})"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"        if \u0027extra\u0027 in port_obj.obj_what_changed():"},{"line_number":58,"context_line":"            orignal_port \u003d objects.Port.get_by_id(context, port_obj.id)"},{"line_number":59,"context_line":"            updated_client_id \u003d port_obj.extra.get(\u0027client-id\u0027)"},{"line_number":60,"context_line":"            if (orignal_port.extra.get(\u0027client-id\u0027) !\u003d"},{"line_number":61,"context_line":"                updated_client_id):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_e8074e7f","line":58,"range":{"start_line":58,"start_character":12,"end_line":58,"end_character":19},"updated":"2016-11-29 21:33:32.000000000","message":"nit: s/orignal/original","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":55,"context_line":"                    {\u0027port\u0027: port_uuid, \u0027instance\u0027: node.instance_uuid})"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"        if \u0027extra\u0027 in port_obj.obj_what_changed():"},{"line_number":58,"context_line":"            orignal_port \u003d objects.Port.get_by_id(context, port_obj.id)"},{"line_number":59,"context_line":"            updated_client_id \u003d port_obj.extra.get(\u0027client-id\u0027)"},{"line_number":60,"context_line":"            if (orignal_port.extra.get(\u0027client-id\u0027) !\u003d"},{"line_number":61,"context_line":"                updated_client_id):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_49001aab","line":58,"range":{"start_line":58,"start_character":12,"end_line":58,"end_character":19},"in_reply_to":"5a74a57a_e8074e7f","updated":"2016-11-30 16:12:57.000000000","message":"Fixed although this was moved code :)","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4d4c25f3f39c5805057ace978900d91daf3028c0","unresolved":false,"context_lines":[{"line_number":84,"context_line":"        \"\"\"List attached VIF IDs."},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"        :param task: A TaskManager instance."},{"line_number":87,"context_line":"        :raises: NetworkError"},{"line_number":88,"context_line":"        \"\"\""},{"line_number":89,"context_line":"        vifs \u003d []"},{"line_number":90,"context_line":"        for port in task.ports:"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_cdcd2d88","line":87,"range":{"start_line":87,"start_character":9,"end_line":87,"end_character":29},"updated":"2016-11-30 09:40:23.000000000","message":"it does not :)","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":84,"context_line":"        \"\"\"List attached VIF IDs."},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"        :param task: A TaskManager instance."},{"line_number":87,"context_line":"        :raises: NetworkError"},{"line_number":88,"context_line":"        \"\"\""},{"line_number":89,"context_line":"        vifs \u003d []"},{"line_number":90,"context_line":"        for port in task.ports:"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_898cf236","line":87,"range":{"start_line":87,"start_character":9,"end_line":87,"end_character":29},"in_reply_to":"5a74a57a_cdcd2d88","updated":"2016-11-30 16:12:57.000000000","message":"Done","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"35c76888c40057921b4d63e6a053fc81e7fe90fc","unresolved":false,"context_lines":[{"line_number":129,"context_line":""},{"line_number":130,"context_line":"                int_info \u003d port.internal_info"},{"line_number":131,"context_line":"                int_info[\u0027vif_port_id\u0027] \u003d vif_id"},{"line_number":132,"context_line":"                port.internal_info \u003d int_info"},{"line_number":133,"context_line":"                port.save()"},{"line_number":134,"context_line":"                break"},{"line_number":135,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_230de937","line":132,"updated":"2016-11-29 21:33:32.000000000","message":"One thing that might be unrelated to this patch that I\u0027m concerned about - what happens when the port changes in between retrieval and save()? Any changed fields will be wiped. Maybe ports need a locking mechanism like nodes.\n\nOr, is locking the port(s) already part of the task?","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4d4c25f3f39c5805057ace978900d91daf3028c0","unresolved":false,"context_lines":[{"line_number":129,"context_line":""},{"line_number":130,"context_line":"                int_info \u003d port.internal_info"},{"line_number":131,"context_line":"                int_info[\u0027vif_port_id\u0027] \u003d vif_id"},{"line_number":132,"context_line":"                port.internal_info \u003d int_info"},{"line_number":133,"context_line":"                port.save()"},{"line_number":134,"context_line":"                break"},{"line_number":135,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_0dad6588","line":132,"in_reply_to":"5a74a57a_230de937","updated":"2016-11-30 09:40:23.000000000","message":"port update happens on conductor side under the lock, so it should be ok.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright 2015 Cisco Systems"},{"line_number":2,"context_line":"# All Rights Reserved"},{"line_number":3,"context_line":"#"},{"line_number":4,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_dcb93c17","line":1,"updated":"2016-11-30 22:09:24.000000000","message":"out of curiosity, did you have this code in 2015?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright 2015 Cisco Systems"},{"line_number":2,"context_line":"# All Rights Reserved"},{"line_number":3,"context_line":"#"},{"line_number":4,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_f6608303","line":1,"in_reply_to":"5a74a57a_dcb93c17","updated":"2016-12-06 11:43:59.000000000","message":";) some of it, just not in this form.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":33,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"        :param task: a TaskManager instance."},{"line_number":36,"context_line":"        :param port: a changed Port object."},{"line_number":37,"context_line":"        :raises: FailedToUpdateDHCPOptOnPort"},{"line_number":38,"context_line":"        \"\"\""},{"line_number":39,"context_line":"        context \u003d task.context"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_fa67d8b4","line":36,"updated":"2016-11-30 22:09:24.000000000","message":"wondering. The port has changed and the changes were saved in the DB?\n\nOk, I see code below that indicates that the port has changed but hasn\u0027t  been saved to the db yet. We should document this.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":56,"context_line":"                LOG.warning(_LW("},{"line_number":57,"context_line":"                    \"No VIF found for instance %(instance)s \""},{"line_number":58,"context_line":"                    \"port %(port)s when attempting to update port MAC \""},{"line_number":59,"context_line":"                    \"address.\"),"},{"line_number":60,"context_line":"                    {\u0027port\u0027: port_uuid, \u0027instance\u0027: node.instance_uuid})"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"        if \u0027extra\u0027 in port_obj.obj_what_changed():"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_ba9e4052","line":59,"updated":"2016-11-30 22:09:24.000000000","message":"do we want to log the new mac address?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":56,"context_line":"                LOG.warning(_LW("},{"line_number":57,"context_line":"                    \"No VIF found for instance %(instance)s \""},{"line_number":58,"context_line":"                    \"port %(port)s when attempting to update port MAC \""},{"line_number":59,"context_line":"                    \"address.\"),"},{"line_number":60,"context_line":"                    {\u0027port\u0027: port_uuid, \u0027instance\u0027: node.instance_uuid})"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"        if \u0027extra\u0027 in port_obj.obj_what_changed():"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_f1740d69","line":59,"in_reply_to":"5a74a57a_ba9e4052","updated":"2016-12-06 11:43:59.000000000","message":"This is moved code, but I can update it if we want too.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":83,"context_line":"                        \"port %(port)s when attempting to update port \""},{"line_number":84,"context_line":"                        \"client-id.\"),"},{"line_number":85,"context_line":"                        {\u0027port\u0027: port_uuid,"},{"line_number":86,"context_line":"                         \u0027instance\u0027: node.instance_uuid})"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        if portgroup_obj and ((set(port_obj.obj_what_changed()) \u0026"},{"line_number":89,"context_line":"                              {\u0027pxe_enabled\u0027, \u0027portgroup_id\u0027}) or vif):"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_5ab0ccdd","line":86,"updated":"2016-11-30 22:09:24.000000000","message":"do we want to log the new client-id?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":83,"context_line":"                        \"port %(port)s when attempting to update port \""},{"line_number":84,"context_line":"                        \"client-id.\"),"},{"line_number":85,"context_line":"                        {\u0027port\u0027: port_uuid,"},{"line_number":86,"context_line":"                         \u0027instance\u0027: node.instance_uuid})"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        if portgroup_obj and ((set(port_obj.obj_what_changed()) \u0026"},{"line_number":89,"context_line":"                              {\u0027pxe_enabled\u0027, \u0027portgroup_id\u0027}) or vif):"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_31c76565","line":86,"in_reply_to":"5a74a57a_5ab0ccdd","updated":"2016-12-06 11:43:59.000000000","message":"ditto as above.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":96,"context_line":"                         \"\u0027pxe_enabled\u0027 was set to True.\") %"},{"line_number":97,"context_line":"                       {\"portgroup\": portgroup_obj.uuid,"},{"line_number":98,"context_line":"                        \"port\": port_uuid})"},{"line_number":99,"context_line":"                raise exception.Conflict(msg)"},{"line_number":100,"context_line":""},{"line_number":101,"context_line":"    def vif_list(self, task):"},{"line_number":102,"context_line":"        \"\"\"List attached VIF IDs."}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_ba21e0fe","line":99,"updated":"2016-11-30 22:09:24.000000000","message":"This code looks familiar to me. It is in conductor/manager.py, update_port(). I hope we unify the code at some point... guess I\u0027ll find out after I look at the other patches in this series :)","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":96,"context_line":"                         \"\u0027pxe_enabled\u0027 was set to True.\") %"},{"line_number":97,"context_line":"                       {\"portgroup\": portgroup_obj.uuid,"},{"line_number":98,"context_line":"                        \"port\": port_uuid})"},{"line_number":99,"context_line":"                raise exception.Conflict(msg)"},{"line_number":100,"context_line":""},{"line_number":101,"context_line":"    def vif_list(self, task):"},{"line_number":102,"context_line":"        \"\"\"List attached VIF IDs."}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_31da0518","line":99,"in_reply_to":"5a74a57a_ba21e0fe","updated":"2016-12-06 11:43:59.000000000","message":"This code is moving from the conductor/manager.py to here, it is deleted from manager.py in the next patch.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":99,"context_line":"                raise exception.Conflict(msg)"},{"line_number":100,"context_line":""},{"line_number":101,"context_line":"    def vif_list(self, task):"},{"line_number":102,"context_line":"        \"\"\"List attached VIF IDs."},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"        :param task: A TaskManager instance."},{"line_number":105,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_bfc47240","line":102,"updated":"2016-11-30 22:09:24.000000000","message":"Is this just the tenant VIFs, if any? (I mean, not cleaning or provisioning if that is what is happening at the time of this call?)","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":99,"context_line":"                raise exception.Conflict(msg)"},{"line_number":100,"context_line":""},{"line_number":101,"context_line":"    def vif_list(self, task):"},{"line_number":102,"context_line":"        \"\"\"List attached VIF IDs."},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"        :param task: A TaskManager instance."},{"line_number":105,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_911919da","line":102,"in_reply_to":"5a74a57a_bfc47240","updated":"2016-12-06 11:43:59.000000000","message":"That is correct in the case of the multi-tenant neutron network interface, in the flat case tenant vifs and provisioning vifs are the same.\n\nIt is listing only \"attached\" vifs so vifs that where added by something from outside, not ones created by Ironic itself. Not sure how to describe it well in the comment.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":112,"context_line":"        return vifs"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"    def vif_attach(self, task, vif):"},{"line_number":115,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"        :param task: A TaskManager instance."},{"line_number":118,"context_line":"        :param vif: A VIF to attach"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_7acd88b6","line":115,"updated":"2016-11-30 22:09:24.000000000","message":"may be a dumb question. but what if it is already attached? Is that possible?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":112,"context_line":"        return vifs"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"    def vif_attach(self, task, vif):"},{"line_number":115,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"        :param task: A TaskManager instance."},{"line_number":118,"context_line":"        :param vif: A VIF to attach"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_d188ea73","line":115,"in_reply_to":"5a74a57a_7acd88b6","updated":"2016-12-06 11:43:59.000000000","message":"I seem to have completely missed that scenario... I have revisited this code to fix that.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":115,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"        :param task: A TaskManager instance."},{"line_number":118,"context_line":"        :param vif: A VIF to attach"},{"line_number":119,"context_line":"        :raises: NetworkError"},{"line_number":120,"context_line":"        \"\"\""},{"line_number":121,"context_line":"        vif_id \u003d vif.id"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_bd29d18b","line":118,"updated":"2016-12-02 13:58:52.000000000","message":"VIF object","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":115,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"        :param task: A TaskManager instance."},{"line_number":118,"context_line":"        :param vif: A VIF to attach"},{"line_number":119,"context_line":"        :raises: NetworkError"},{"line_number":120,"context_line":"        \"\"\""},{"line_number":121,"context_line":"        vif_id \u003d vif.id"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_b1ea8e0d","line":118,"in_reply_to":"3a71b18c_bd29d18b","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                              reverse\u003dTrue)"},{"line_number":126,"context_line":"        for port in sorted_ports:"},{"line_number":127,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"},{"line_number":128,"context_line":"            # a nova driver that uses port.extra"},{"line_number":129,"context_line":"            if (\"vif_port_id\" not in port.extra and"},{"line_number":130,"context_line":"                    \"vif_port_id\" not in port.internal_info):"},{"line_number":131,"context_line":"                # Check if the requested vif_id is a neutron port. If it is"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_ffbb4a73","line":128,"updated":"2016-11-30 22:09:24.000000000","message":"well, after some deprecation period, i don\u0027t know if we can assume that only nova uses port.extra.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                              reverse\u003dTrue)"},{"line_number":126,"context_line":"        for port in sorted_ports:"},{"line_number":127,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"},{"line_number":128,"context_line":"            # a nova driver that uses port.extra"},{"line_number":129,"context_line":"            if (\"vif_port_id\" not in port.extra and"},{"line_number":130,"context_line":"                    \"vif_port_id\" not in port.internal_info):"},{"line_number":131,"context_line":"                # Check if the requested vif_id is a neutron port. If it is"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_514a1a27","line":128,"in_reply_to":"3a71b18c_5d4c3d70","updated":"2016-12-06 11:43:59.000000000","message":"port.extra the DB field isn\u0027t going away only the behaviour of setting vif_port_id in it. Standalone mode doesn\u0027t use vif_port_id right?, unless someone as magically made neutron run standalone too?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                              reverse\u003dTrue)"},{"line_number":126,"context_line":"        for port in sorted_ports:"},{"line_number":127,"context_line":"            # FIXME(sambetts) Remove port.extra check when we no longer support"},{"line_number":128,"context_line":"            # a nova driver that uses port.extra"},{"line_number":129,"context_line":"            if (\"vif_port_id\" not in port.extra and"},{"line_number":130,"context_line":"                    \"vif_port_id\" not in port.internal_info):"},{"line_number":131,"context_line":"                # Check if the requested vif_id is a neutron port. If it is"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_5d4c3d70","line":128,"in_reply_to":"5a74a57a_ffbb4a73","updated":"2016-12-02 13:58:52.000000000","message":"not only nova, port.extra() is used in standalone mode.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":129,"context_line":"            if (\"vif_port_id\" not in port.extra and"},{"line_number":130,"context_line":"                    \"vif_port_id\" not in port.internal_info):"},{"line_number":131,"context_line":"                # Check if the requested vif_id is a neutron port. If it is"},{"line_number":132,"context_line":"                # then attempt to update the ports MAC address."},{"line_number":133,"context_line":"                try:"},{"line_number":134,"context_line":"                    client \u003d neutron.get_client()"},{"line_number":135,"context_line":"                    client.show_port(vif_id)"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_bf81d291","line":132,"updated":"2016-11-30 22:09:24.000000000","message":"nit, s/ports/port\u0027s/","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":129,"context_line":"            if (\"vif_port_id\" not in port.extra and"},{"line_number":130,"context_line":"                    \"vif_port_id\" not in port.internal_info):"},{"line_number":131,"context_line":"                # Check if the requested vif_id is a neutron port. If it is"},{"line_number":132,"context_line":"                # then attempt to update the ports MAC address."},{"line_number":133,"context_line":"                try:"},{"line_number":134,"context_line":"                    client \u003d neutron.get_client()"},{"line_number":135,"context_line":"                    client.show_port(vif_id)"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_f1da464a","line":132,"in_reply_to":"5a74a57a_bf81d291","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":131,"context_line":"                # Check if the requested vif_id is a neutron port. If it is"},{"line_number":132,"context_line":"                # then attempt to update the ports MAC address."},{"line_number":133,"context_line":"                try:"},{"line_number":134,"context_line":"                    client \u003d neutron.get_client()"},{"line_number":135,"context_line":"                    client.show_port(vif_id)"},{"line_number":136,"context_line":"                except neutron_exceptions.NeutronClientException:"},{"line_number":137,"context_line":"                    pass"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_5d635ddc","line":134,"updated":"2016-12-02 13:58:52.000000000","message":"please pass existed token.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":131,"context_line":"                # Check if the requested vif_id is a neutron port. If it is"},{"line_number":132,"context_line":"                # then attempt to update the ports MAC address."},{"line_number":133,"context_line":"                try:"},{"line_number":134,"context_line":"                    client \u003d neutron.get_client()"},{"line_number":135,"context_line":"                    client.show_port(vif_id)"},{"line_number":136,"context_line":"                except neutron_exceptions.NeutronClientException:"},{"line_number":137,"context_line":"                    pass"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_71747635","line":134,"in_reply_to":"3a71b18c_5d635ddc","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":134,"context_line":"                    client \u003d neutron.get_client()"},{"line_number":135,"context_line":"                    client.show_port(vif_id)"},{"line_number":136,"context_line":"                except neutron_exceptions.NeutronClientException:"},{"line_number":137,"context_line":"                    pass"},{"line_number":138,"context_line":"                else:"},{"line_number":139,"context_line":"                    try:"},{"line_number":140,"context_line":"                        neutron.update_port_address(vif_id, port.address)"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_9aafc4e2","line":137,"updated":"2016-11-30 22:09:24.000000000","message":"If we have say 4 ports for this node, and they are all available. if vif_id is NOT a neutron port, what is the chance that it will exist in one of the same 4 calls to client.show_port()? I am wondering why we don\u0027t check this first, and then just fail if it isn\u0027t a neutron port.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":134,"context_line":"                    client \u003d neutron.get_client()"},{"line_number":135,"context_line":"                    client.show_port(vif_id)"},{"line_number":136,"context_line":"                except neutron_exceptions.NeutronClientException:"},{"line_number":137,"context_line":"                    pass"},{"line_number":138,"context_line":"                else:"},{"line_number":139,"context_line":"                    try:"},{"line_number":140,"context_line":"                        neutron.update_port_address(vif_id, port.address)"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_bc00a502","line":137,"in_reply_to":"5a74a57a_9aafc4e2","updated":"2016-12-06 11:43:59.000000000","message":"I did this because I didn\u0027t think we could assume all NetworkInterfaces out of tree use neutron ports as vifs e.g. ones written for standalone mode, and we needed to provide a default implementation for them, and I wanted to make a mixin that any NetworkInterface could use as a starter implementation. I initially created a neutron specific version of the mixin which didn\u0027t need this check, but then the default provided implementation will break out of tree neutron based NetworkInterface that don\u0027t switch to the neutron specific mixin. So having an implementation that supports both is the only way I see these defaults working.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":142,"context_line":"                        raise exception.NetworkError(_("},{"line_number":143,"context_line":"                            \"Unable to attach VIF because Ironic can not \""},{"line_number":144,"context_line":"                            \"update Neutron port MAC address to match \""},{"line_number":145,"context_line":"                            \"physical MAC address\"))"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"                int_info \u003d port.internal_info"},{"line_number":148,"context_line":"                int_info[\u0027vif_port_id\u0027] \u003d vif_id"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_1f1ba681","line":145,"updated":"2016-11-30 22:09:24.000000000","message":"Should we log the port ID, vif ID, and MAC address?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":142,"context_line":"                        raise exception.NetworkError(_("},{"line_number":143,"context_line":"                            \"Unable to attach VIF because Ironic can not \""},{"line_number":144,"context_line":"                            \"update Neutron port MAC address to match \""},{"line_number":145,"context_line":"                            \"physical MAC address\"))"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"                int_info \u003d port.internal_info"},{"line_number":148,"context_line":"                int_info[\u0027vif_port_id\u0027] \u003d vif_id"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_fcfbfd78","line":145,"in_reply_to":"5a74a57a_1f1ba681","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":154,"context_line":"                                           \"enough physical vifs\"))"},{"line_number":155,"context_line":""},{"line_number":156,"context_line":"    def vif_detach(self, task, vif_id):"},{"line_number":157,"context_line":"        \"\"\"Detach a virtual network interface to a node"},{"line_number":158,"context_line":""},{"line_number":159,"context_line":"        :param task: A TaskManager instance."},{"line_number":160,"context_line":"        :param vif_id: A VIF ID to detach"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_fab43836","line":157,"updated":"2016-11-30 22:09:24.000000000","message":"it might be s/to/from/ but ...","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":154,"context_line":"                                           \"enough physical vifs\"))"},{"line_number":155,"context_line":""},{"line_number":156,"context_line":"    def vif_detach(self, task, vif_id):"},{"line_number":157,"context_line":"        \"\"\"Detach a virtual network interface to a node"},{"line_number":158,"context_line":""},{"line_number":159,"context_line":"        :param task: A TaskManager instance."},{"line_number":160,"context_line":"        :param vif_id: A VIF ID to detach"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_f7e5d6a3","line":157,"in_reply_to":"5a74a57a_fab43836","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f2a78422d87bd283f74467994cdcfff4fc1e74a8","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"        :param task: a TaskManager instance."},{"line_number":36,"context_line":"        :param port: a changed Port object from the API before it is saved."},{"line_number":37,"context_line":"        :raises: FailedToUpdateDHCPOptOnPort"},{"line_number":38,"context_line":"        \"\"\""},{"line_number":39,"context_line":"        context \u003d task.context"},{"line_number":40,"context_line":"        node \u003d task.node"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_5a92d5f7","line":37,"updated":"2016-12-07 13:30:20.000000000","message":"and Conflict","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"c5b4f41bab99b920aab666d5c3cef5521cd1a972","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"        :param task: a TaskManager instance."},{"line_number":36,"context_line":"        :param port: a changed Port object from the API before it is saved."},{"line_number":37,"context_line":"        :raises: FailedToUpdateDHCPOptOnPort"},{"line_number":38,"context_line":"        \"\"\""},{"line_number":39,"context_line":"        context \u003d task.context"},{"line_number":40,"context_line":"        node \u003d task.node"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_664a9029","line":37,"in_reply_to":"3a71b18c_5a92d5f7","updated":"2016-12-07 16:49:22.000000000","message":"agreed","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"        :param task: a TaskManager instance."},{"line_number":36,"context_line":"        :param port: a changed Port object from the API before it is saved."},{"line_number":37,"context_line":"        :raises: FailedToUpdateDHCPOptOnPort"},{"line_number":38,"context_line":"        \"\"\""},{"line_number":39,"context_line":"        context \u003d task.context"},{"line_number":40,"context_line":"        node \u003d task.node"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_2adbd21c","line":37,"in_reply_to":"3a71b18c_664a9029","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                        \"vif\": vif_id, \"port\": port.uuid})"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if not free_ports:"},{"line_number":140,"context_line":"            raise exception.NetworkError(_(\"Unable to attach vif, not \""},{"line_number":141,"context_line":"                                           \"enough physical vifs\"))"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # Get first free port"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_0a8bcb1f","line":140,"updated":"2016-12-06 22:36:53.000000000","message":"nit s/vif/VIF/\n\nMaybe add the vif ID they are trying to attach.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                        \"vif\": vif_id, \"port\": port.uuid})"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if not free_ports:"},{"line_number":140,"context_line":"            raise exception.NetworkError(_(\"Unable to attach vif, not \""},{"line_number":141,"context_line":"                                           \"enough physical vifs\"))"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # Get first free port"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_6a786af9","line":140,"in_reply_to":"3a71b18c_0a8bcb1f","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if not free_ports:"},{"line_number":140,"context_line":"            raise exception.NetworkError(_(\"Unable to attach vif, not \""},{"line_number":141,"context_line":"                                           \"enough physical vifs\"))"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # Get first free port"},{"line_number":144,"context_line":"        port \u003d free_ports.pop(0)"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_4a8143fa","line":141,"updated":"2016-12-06 22:36:53.000000000","message":"nit s/vifs/VIFs/","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"c5b4f41bab99b920aab666d5c3cef5521cd1a972","unresolved":false,"context_lines":[{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if not free_ports:"},{"line_number":140,"context_line":"            raise exception.NetworkError(_(\"Unable to attach vif, not \""},{"line_number":141,"context_line":"                                           \"enough physical vifs\"))"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # Get first free port"},{"line_number":144,"context_line":"        port \u003d free_ports.pop(0)"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_465cb4ed","line":141,"in_reply_to":"3a71b18c_3a7359e9","updated":"2016-12-07 16:49:22.000000000","message":"+1, should be interfaces","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if not free_ports:"},{"line_number":140,"context_line":"            raise exception.NetworkError(_(\"Unable to attach vif, not \""},{"line_number":141,"context_line":"                                           \"enough physical vifs\"))"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # Get first free port"},{"line_number":144,"context_line":"        port \u003d free_ports.pop(0)"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_aa8282c6","line":141,"in_reply_to":"3a71b18c_465cb4ed","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f2a78422d87bd283f74467994cdcfff4fc1e74a8","unresolved":false,"context_lines":[{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if not free_ports:"},{"line_number":140,"context_line":"            raise exception.NetworkError(_(\"Unable to attach vif, not \""},{"line_number":141,"context_line":"                                           \"enough physical vifs\"))"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        # Get first free port"},{"line_number":144,"context_line":"        port \u003d free_ports.pop(0)"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_3a7359e9","line":141,"in_reply_to":"3a71b18c_4a8143fa","updated":"2016-12-07 13:30:20.000000000","message":"physical vifs is strange might be: not enough physical interfaces?","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f2a78422d87bd283f74467994cdcfff4fc1e74a8","unresolved":false,"context_lines":[{"line_number":150,"context_line":"            client.show_port(vif_id)"},{"line_number":151,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":152,"context_line":"            # NOTE(sambetts): If a client error occurs this is because either"},{"line_number":153,"context_line":"            # neutron doesn\u0027t exist because we\u0027re running in standalone"},{"line_number":154,"context_line":"            # environment or we can\u0027t find a matching neutron port which means"},{"line_number":155,"context_line":"            # a user might be requesting a non-neutron port. So skip trying to"},{"line_number":156,"context_line":"            # update the neutron port MAC address in these cases."}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_3d0fd32f","line":153,"updated":"2016-12-07 13:30:20.000000000","message":"If we running in stand alone environment without Neutron we shouldn\u0027t call this as node will be registered with other network driver that neutron.\n\nAlso it is possible that we running Ironic in stand alone with neutron, in this case we should fail.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":150,"context_line":"            client.show_port(vif_id)"},{"line_number":151,"context_line":"        except neutron_exceptions.NeutronClientException:"},{"line_number":152,"context_line":"            # NOTE(sambetts): If a client error occurs this is because either"},{"line_number":153,"context_line":"            # neutron doesn\u0027t exist because we\u0027re running in standalone"},{"line_number":154,"context_line":"            # environment or we can\u0027t find a matching neutron port which means"},{"line_number":155,"context_line":"            # a user might be requesting a non-neutron port. So skip trying to"},{"line_number":156,"context_line":"            # update the neutron port MAC address in these cases."}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_8ac066e2","line":153,"in_reply_to":"3a71b18c_3d0fd32f","updated":"2016-12-08 14:18:02.000000000","message":"We need this because some out of tree NetworkInterfaces  might use neutron ports as vifs and some written for standalone mode might not, and we needed to provide a default implementation that works for both.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":52,"context_line":"                api \u003d dhcp_factory.DHCPFactory()"},{"line_number":53,"context_line":"                api.provider.update_port_address(vif, port_obj.address,"},{"line_number":54,"context_line":"                                                 token\u003dcontext.auth_token)"},{"line_number":55,"context_line":"            # Log warning if there is no vif_port_id and an instance"},{"line_number":56,"context_line":"            # is associated with the node."},{"line_number":57,"context_line":"            elif node.instance_uuid:"},{"line_number":58,"context_line":"                LOG.warning(_LW("}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_5ad1dffa","line":55,"updated":"2016-12-13 01:26:36.000000000","message":"nit s/vif_port_id/VIF/","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":52,"context_line":"                api \u003d dhcp_factory.DHCPFactory()"},{"line_number":53,"context_line":"                api.provider.update_port_address(vif, port_obj.address,"},{"line_number":54,"context_line":"                                                 token\u003dcontext.auth_token)"},{"line_number":55,"context_line":"            # Log warning if there is no vif_port_id and an instance"},{"line_number":56,"context_line":"            # is associated with the node."},{"line_number":57,"context_line":"            elif node.instance_uuid:"},{"line_number":58,"context_line":"                LOG.warning(_LW("}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_88095098","line":55,"in_reply_to":"1a6eadb0_5ad1dffa","updated":"2016-12-13 16:34:13.000000000","message":"Done","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":77,"context_line":""},{"line_number":78,"context_line":"                    api.provider.update_port_dhcp_opts("},{"line_number":79,"context_line":"                        vif, [client_id_opt], token\u003dcontext.auth_token)"},{"line_number":80,"context_line":"                # Log warning if there is no vif_port_id and an instance"},{"line_number":81,"context_line":"                # is associated with the node."},{"line_number":82,"context_line":"                elif node.instance_uuid:"},{"line_number":83,"context_line":"                    LOG.warning(_LW("}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_3a034375","line":80,"updated":"2016-12-13 01:26:36.000000000","message":"ditto about vif_port_id","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":77,"context_line":""},{"line_number":78,"context_line":"                    api.provider.update_port_dhcp_opts("},{"line_number":79,"context_line":"                        vif, [client_id_opt], token\u003dcontext.auth_token)"},{"line_number":80,"context_line":"                # Log warning if there is no vif_port_id and an instance"},{"line_number":81,"context_line":"                # is associated with the node."},{"line_number":82,"context_line":"                elif node.instance_uuid:"},{"line_number":83,"context_line":"                    LOG.warning(_LW("}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_c83a6836","line":80,"in_reply_to":"1a6eadb0_3a034375","updated":"2016-12-13 16:34:13.000000000","message":"Done","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":94,"context_line":"                msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""},{"line_number":95,"context_line":"                         \"standalone ports. This port %(port)s cannot be \""},{"line_number":96,"context_line":"                         \" a member of that port group because either \""},{"line_number":97,"context_line":"                         \"\u0027extra/vif_port_id\u0027 was specified or \""},{"line_number":98,"context_line":"                         \"\u0027pxe_enabled\u0027 was set to True.\") %"},{"line_number":99,"context_line":"                       {\"portgroup\": portgroup_obj.uuid,"},{"line_number":100,"context_line":"                        \"port\": port_uuid})"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_5a263f17","line":97,"updated":"2016-12-13 01:26:36.000000000","message":"hmm, do we also need to mention internal_info/tenant_vif_port_id?","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"511aafa3d5c9564ce18524c55ffc2eac15801ac0","unresolved":false,"context_lines":[{"line_number":94,"context_line":"                msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""},{"line_number":95,"context_line":"                         \"standalone ports. This port %(port)s cannot be \""},{"line_number":96,"context_line":"                         \" a member of that port group because either \""},{"line_number":97,"context_line":"                         \"\u0027extra/vif_port_id\u0027 was specified or \""},{"line_number":98,"context_line":"                         \"\u0027pxe_enabled\u0027 was set to True.\") %"},{"line_number":99,"context_line":"                       {\"portgroup\": portgroup_obj.uuid,"},{"line_number":100,"context_line":"                        \"port\": port_uuid})"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_978329cc","line":97,"in_reply_to":"1a6eadb0_4b8e5279","updated":"2016-12-13 17:22:57.000000000","message":"That is good. But bad to make me think more. We know whether it is due to vif and/or pxe_enabled. So how about changing it to something like:\n\n   reason \u003d []\n   if port_obj.pxe_enabled: reason.append[\"pxe_enabled\u0027 was set to True\u0027]\n   if vif: reason.append[\u0027VIF %(vif)s is attached to the port\u0027]\n\nthen do a join of reason etc.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":94,"context_line":"                msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""},{"line_number":95,"context_line":"                         \"standalone ports. This port %(port)s cannot be \""},{"line_number":96,"context_line":"                         \" a member of that port group because either \""},{"line_number":97,"context_line":"                         \"\u0027extra/vif_port_id\u0027 was specified or \""},{"line_number":98,"context_line":"                         \"\u0027pxe_enabled\u0027 was set to True.\") %"},{"line_number":99,"context_line":"                       {\"portgroup\": portgroup_obj.uuid,"},{"line_number":100,"context_line":"                        \"port\": port_uuid})"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_4b8e5279","line":97,"in_reply_to":"1a6eadb0_5a263f17","updated":"2016-12-13 16:34:13.000000000","message":"What do you think about the following:\n\nThis port cannot be a member of that port group because either VIF is attached to this port or \u0027pxe_enabled\u0027 is set to True?","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"85fa86a7405378166a5b4d080746e8866c9aedff","unresolved":false,"context_lines":[{"line_number":94,"context_line":"                msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""},{"line_number":95,"context_line":"                         \"standalone ports. This port %(port)s cannot be \""},{"line_number":96,"context_line":"                         \" a member of that port group because either \""},{"line_number":97,"context_line":"                         \"\u0027extra/vif_port_id\u0027 was specified or \""},{"line_number":98,"context_line":"                         \"\u0027pxe_enabled\u0027 was set to True.\") %"},{"line_number":99,"context_line":"                       {\"portgroup\": portgroup_obj.uuid,"},{"line_number":100,"context_line":"                        \"port\": port_uuid})"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_9fd79f22","line":97,"in_reply_to":"1a6eadb0_978329cc","updated":"2016-12-14 16:16:42.000000000","message":"Done","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"703dfea68c1be2c25d7244db9b0111d8fb33acd5","unresolved":false,"context_lines":[{"line_number":103,"context_line":"    def vif_list(self, task):"},{"line_number":104,"context_line":"        \"\"\"List attached VIF IDs for a node"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"        :param task: A TaskManager instance."},{"line_number":107,"context_line":"        \"\"\""},{"line_number":108,"context_line":"        vifs \u003d []"},{"line_number":109,"context_line":"        for port in task.ports:"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_338628ba","line":106,"updated":"2016-12-12 15:17:31.000000000","message":"return value should be included in this comment","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"f15fc071b19853025c90ca5882a4fb26f7c3639d","unresolved":false,"context_lines":[{"line_number":103,"context_line":"    def vif_list(self, task):"},{"line_number":104,"context_line":"        \"\"\"List attached VIF IDs for a node"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"        :param task: A TaskManager instance."},{"line_number":107,"context_line":"        \"\"\""},{"line_number":108,"context_line":"        vifs \u003d []"},{"line_number":109,"context_line":"        for port in task.ports:"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_957437fe","line":106,"in_reply_to":"1a6eadb0_338628ba","updated":"2016-12-12 18:44:38.000000000","message":"+1","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":103,"context_line":"    def vif_list(self, task):"},{"line_number":104,"context_line":"        \"\"\"List attached VIF IDs for a node"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"        :param task: A TaskManager instance."},{"line_number":107,"context_line":"        \"\"\""},{"line_number":108,"context_line":"        vifs \u003d []"},{"line_number":109,"context_line":"        for port in task.ports:"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_6674259c","line":106,"in_reply_to":"1a6eadb0_957437fe","updated":"2016-12-13 16:34:13.000000000","message":"Done","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        :param vif: A VIF object to attach"},{"line_number":121,"context_line":"        :raises: NetworkError"},{"line_number":122,"context_line":"        \"\"\""},{"line_number":123,"context_line":"        vif_id \u003d vif[\u0027id\u0027]"},{"line_number":124,"context_line":"        # Sort ports by pxe_enabled to ensure we always bind pxe_enabled ports"},{"line_number":125,"context_line":"        # first"},{"line_number":126,"context_line":"        sorted_ports \u003d sorted(task.ports, key\u003dlambda p: p.pxe_enabled,"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_7ac77b45","line":123,"updated":"2016-12-13 01:26:36.000000000","message":"if it is a VIF object, why is it vif[\u0027id\u0027]? Is it a dictionary?","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"809dd182b4499615cf7694996b4535f74a982aaa","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        :param vif: A VIF object to attach"},{"line_number":121,"context_line":"        :raises: NetworkError"},{"line_number":122,"context_line":"        \"\"\""},{"line_number":123,"context_line":"        vif_id \u003d vif[\u0027id\u0027]"},{"line_number":124,"context_line":"        # Sort ports by pxe_enabled to ensure we always bind pxe_enabled ports"},{"line_number":125,"context_line":"        # first"},{"line_number":126,"context_line":"        sorted_ports \u003d sorted(task.ports, key\u003dlambda p: p.pxe_enabled,"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_3e5ead76","line":123,"in_reply_to":"1a6eadb0_3bb4ffcf","updated":"2016-12-13 17:47:22.000000000","message":"I think I\u0027d be good if we changed the method to vif_attach(self, task, vif_info). \u0027vif\u0027 makes it seem like an object and it isn\u0027t.\n\n:param vif_info: a dictionary of information about a VIF. It must have an \u0027id\u0027 key, whose value is a unique identifier for that VIF.\n\nNot totally sure if that helps at all wrt any future change to pass a VIF object instead of a dict but anyway.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"511aafa3d5c9564ce18524c55ffc2eac15801ac0","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        :param vif: A VIF object to attach"},{"line_number":121,"context_line":"        :raises: NetworkError"},{"line_number":122,"context_line":"        \"\"\""},{"line_number":123,"context_line":"        vif_id \u003d vif[\u0027id\u0027]"},{"line_number":124,"context_line":"        # Sort ports by pxe_enabled to ensure we always bind pxe_enabled ports"},{"line_number":125,"context_line":"        # first"},{"line_number":126,"context_line":"        sorted_ports \u003d sorted(task.ports, key\u003dlambda p: p.pxe_enabled,"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_3bb4ffcf","line":123,"in_reply_to":"1a6eadb0_41ab9374","updated":"2016-12-13 17:22:57.000000000","message":"Yikes. Discussed a bit with Vasyl on irc [1]. the spec sez \u0027These API endpoints will take via a POST body, a JSON representation of a generic VIF object. Making it generic allows for non-neutron based implementations to use this API\u0027. We aren\u0027t saving the VIF in the db as a first class citizen. It is being \u0027hidden\u0027 in port or node\u0027s internal info. Which seems wrong, since we have an API for it etc.\n\nIf we were to go with an ovo (oslo versioned object), i think we\u0027d want to save it in the db as an object as well. But there is no plumbing for that now. So how hard would it be to use a vif json-object for now, and then move to a more formal ovo later, support backwards compatibility, and then deprecate? Since this is an interface API, I don\u0027t know if/when we can deprecate. If we want to allow for both formats later, do we overload the existing \u0027vif\u0027 parameter -- check to see if it is json object or ovo, or would we add a new eg \u0027vif-object\u0027 parameter. I think if we add a second vif-like parameter, it might make things easier. (If the vif can be either json or an ovo, a 3rd party interface would have to update their code to check for either or things will break). Sigh. After writing that, I\u0027m wondering if we should go with ovo and versioning... it isn\u0027t clear to me which way to go. Maybe we need to discuss with others.\n\n\n[1] http://eavesdrop.openstack.org/irclogs/%23openstack-ironic/%23openstack-ironic.2016-12-13.log.html#t2016-12-13T16:37:13","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        :param vif: A VIF object to attach"},{"line_number":121,"context_line":"        :raises: NetworkError"},{"line_number":122,"context_line":"        \"\"\""},{"line_number":123,"context_line":"        vif_id \u003d vif[\u0027id\u0027]"},{"line_number":124,"context_line":"        # Sort ports by pxe_enabled to ensure we always bind pxe_enabled ports"},{"line_number":125,"context_line":"        # first"},{"line_number":126,"context_line":"        sorted_ports \u003d sorted(task.ports, key\u003dlambda p: p.pxe_enabled,"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_41ab9374","line":123,"in_reply_to":"1a6eadb0_7ac77b45","updated":"2016-12-13 16:34:13.000000000","message":"We do not convert VIF API object to RPC object and send it as json via RPC from API to Conductor. That is why here we receive json instead of object.\n\nI think that we should introduce VIF RPC object (oslo versioned object) to have possibility to add new fields, otherwise it would be very hard or even impossible to extend it. what do you think?","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":94,"context_line":"            if port_obj.pxe_enabled:"},{"line_number":95,"context_line":"                reason.append(\"\u0027pxe_enabled\u0027 was set to True\")"},{"line_number":96,"context_line":"            if vif:"},{"line_number":97,"context_line":"                reason.append(\u0027VIF %(vif)s is attached to the port\u0027)"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"            if reason and not portgroup_obj.standalone_ports_supported:"},{"line_number":100,"context_line":"                msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_a30b4a29","line":97,"updated":"2016-12-14 19:25:36.000000000","message":"you need to fill in %(vif)s, either here or below.","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":94,"context_line":"            if port_obj.pxe_enabled:"},{"line_number":95,"context_line":"                reason.append(\"\u0027pxe_enabled\u0027 was set to True\")"},{"line_number":96,"context_line":"            if vif:"},{"line_number":97,"context_line":"                reason.append(\u0027VIF %(vif)s is attached to the port\u0027)"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"            if reason and not portgroup_obj.standalone_ports_supported:"},{"line_number":100,"context_line":"                msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_34c75765","line":97,"in_reply_to":"1a6eadb0_a30b4a29","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":96,"context_line":"            if vif:"},{"line_number":97,"context_line":"                reason.append(\u0027VIF %(vif)s is attached to the port\u0027)"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"            if reason and not portgroup_obj.standalone_ports_supported:"},{"line_number":100,"context_line":"                msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""},{"line_number":101,"context_line":"                         \"standalone ports. This port %(port)s cannot be \""},{"line_number":102,"context_line":"                         \" a member of that port group because of: \""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_8643bc41","line":99,"updated":"2016-12-14 19:25:36.000000000","message":"Before line 93, you could do \u0027if portgroup_obj.standalong_ports_supported:\u0027\n  then the rest to avoid setting up reason if it isn\u0027t needed.","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":96,"context_line":"            if vif:"},{"line_number":97,"context_line":"                reason.append(\u0027VIF %(vif)s is attached to the port\u0027)"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"            if reason and not portgroup_obj.standalone_ports_supported:"},{"line_number":100,"context_line":"                msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""},{"line_number":101,"context_line":"                         \"standalone ports. This port %(port)s cannot be \""},{"line_number":102,"context_line":"                         \" a member of that port group because of: \""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_74a38fb2","line":99,"in_reply_to":"1a6eadb0_8643bc41","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":109,"context_line":"        \"\"\"Handle any actions required when a portgroup changes"},{"line_number":110,"context_line":""},{"line_number":111,"context_line":"        :param task: a TaskManager instance."},{"line_number":112,"context_line":"        :param portgroup: a changed Portgroup object from the API before"},{"line_number":113,"context_line":"            it is saved to database."},{"line_number":114,"context_line":"        :raises: FailedToUpdateDHCPOptOnPort, Conflict"},{"line_number":115,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_069decbb","line":112,"updated":"2016-12-14 19:25:36.000000000","message":"s/portgroup/portgroup_obj/","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":109,"context_line":"        \"\"\"Handle any actions required when a portgroup changes"},{"line_number":110,"context_line":""},{"line_number":111,"context_line":"        :param task: a TaskManager instance."},{"line_number":112,"context_line":"        :param portgroup: a changed Portgroup object from the API before"},{"line_number":113,"context_line":"            it is saved to database."},{"line_number":114,"context_line":"        :raises: FailedToUpdateDHCPOptOnPort, Conflict"},{"line_number":115,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_d4ae2397","line":112,"in_reply_to":"1a6eadb0_069decbb","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":124,"context_line":"                neutron.update_port_address(vif,"},{"line_number":125,"context_line":"                                            portgroup_obj.address,"},{"line_number":126,"context_line":"                                            token\u003dcontext.auth_token)"},{"line_number":127,"context_line":"            # Log warning if there is no vif_port_id and an instance"},{"line_number":128,"context_line":"            # is associated with the node."},{"line_number":129,"context_line":"            elif node.instance_uuid:"},{"line_number":130,"context_line":"                LOG.warning(_LW("}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_06d24c5c","line":127,"updated":"2016-12-14 19:25:36.000000000","message":"s/vif_port_id/VIF/","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":124,"context_line":"                neutron.update_port_address(vif,"},{"line_number":125,"context_line":"                                            portgroup_obj.address,"},{"line_number":126,"context_line":"                                            token\u003dcontext.auth_token)"},{"line_number":127,"context_line":"            # Log warning if there is no vif_port_id and an instance"},{"line_number":128,"context_line":"            # is associated with the node."},{"line_number":129,"context_line":"            elif node.instance_uuid:"},{"line_number":130,"context_line":"                LOG.warning(_LW("}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_349e7763","line":127,"in_reply_to":"1a6eadb0_06d24c5c","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":142,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":143,"context_line":"                for p in ports:"},{"line_number":144,"context_line":"                    extra \u003d p.extra"},{"line_number":145,"context_line":"                    vif \u003d extra.get(\u0027vif_port_id\u0027)"},{"line_number":146,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":147,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":148,"context_line":"                                \"set to False, because the port group %s \""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_4624445f","line":145,"updated":"2016-12-14 19:25:36.000000000","message":"don\u0027t you also have to look at p.internal_info[TENANT_VIF_KEY]?","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":142,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":143,"context_line":"                for p in ports:"},{"line_number":144,"context_line":"                    extra \u003d p.extra"},{"line_number":145,"context_line":"                    vif \u003d extra.get(\u0027vif_port_id\u0027)"},{"line_number":146,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":147,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":148,"context_line":"                                \"set to False, because the port group %s \""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_b480c7f8","line":145,"in_reply_to":"1a6eadb0_4624445f","updated":"2016-12-15 12:04:34.000000000","message":"It will be done separately when we allow to attach VIF to a portgroup: https://review.openstack.org/#/c/406915/","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":147,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":148,"context_line":"                                \"set to False, because the port group %s \""},{"line_number":149,"context_line":"                                \"contains ports with \u0027extra/vif_port_id\u0027 \""},{"line_number":150,"context_line":"                                \"or pxe_enabled\u003dTrue\") % portgroup_uuid"},{"line_number":151,"context_line":"                        raise exception.Conflict(msg)"},{"line_number":152,"context_line":""},{"line_number":153,"context_line":"    def vif_list(self, task):"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_c6ef74e7","line":150,"updated":"2016-12-14 19:25:36.000000000","message":"is it worth mentioning which port, and whether it is pxe_enabled or the vif? (which could be from internal_info[\u0027tenant_vif_port_id\u0027])","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":147,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":148,"context_line":"                                \"set to False, because the port group %s \""},{"line_number":149,"context_line":"                                \"contains ports with \u0027extra/vif_port_id\u0027 \""},{"line_number":150,"context_line":"                                \"or pxe_enabled\u003dTrue\") % portgroup_uuid"},{"line_number":151,"context_line":"                        raise exception.Conflict(msg)"},{"line_number":152,"context_line":""},{"line_number":153,"context_line":"    def vif_list(self, task):"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_34acb78b","line":150,"in_reply_to":"1a6eadb0_c6ef74e7","updated":"2016-12-15 12:04:34.000000000","message":"It is just copy paste of already existed message, I will rework it in https://review.openstack.org/#/c/406915/ when add possibility to attach VIF to portgroup.","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ec0d55c1052e46b5e33e097bc37ae9e62fb6c9dd","unresolved":false,"context_lines":[{"line_number":104,"context_line":"                             \"%(reason)s\"), {\"reason\": \u0027, \u0027.join(reason),"},{"line_number":105,"context_line":"                                             \"portgroup\": portgroup_obj.uuid,"},{"line_number":106,"context_line":"                                             \"port\": port_uuid,"},{"line_number":107,"context_line":"                                             \"vif\": vif})"},{"line_number":108,"context_line":"                    raise exception.Conflict(msg)"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def portgroup_changed(self, task, portgroup_obj):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a6eadb0_e737cffc","line":107,"updated":"2016-12-15 22:03:26.000000000","message":"does this work? %(vif)s is part of the %(reason)s string, so I don\u0027t think it will resolve (but I didn\u0027t try it). Sorry, I wasn\u0027t thinking when I commented on it before.","commit_id":"bf1b5364da63622064678c76bef0e7bc74fd5447"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"b53aebf2711e2d6fb535c0a20b9366cdb2da4bf9","unresolved":false,"context_lines":[{"line_number":104,"context_line":"                             \"%(reason)s\"), {\"reason\": \u0027, \u0027.join(reason),"},{"line_number":105,"context_line":"                                             \"portgroup\": portgroup_obj.uuid,"},{"line_number":106,"context_line":"                                             \"port\": port_uuid,"},{"line_number":107,"context_line":"                                             \"vif\": vif})"},{"line_number":108,"context_line":"                    raise exception.Conflict(msg)"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def portgroup_changed(self, task, portgroup_obj):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a6eadb0_7fe6c8e8","line":107,"in_reply_to":"1a6eadb0_e737cffc","updated":"2016-12-16 12:20:48.000000000","message":"Good catch Ruby, It doesn\u0027t work. I added unit test to check this, and fixed code.","commit_id":"bf1b5364da63622064678c76bef0e7bc74fd5447"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ec0d55c1052e46b5e33e097bc37ae9e62fb6c9dd","unresolved":false,"context_lines":[{"line_number":144,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":145,"context_line":"                for p in ports:"},{"line_number":146,"context_line":"                    extra \u003d p.extra"},{"line_number":147,"context_line":"                    vif \u003d extra.get(\u0027vif_port_id\u0027)"},{"line_number":148,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":149,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":150,"context_line":"                                \"set to False, because the port group %s \""}],"source_content_type":"text/x-python","patch_set":31,"id":"1a6eadb0_eb3f99b1","line":147,"updated":"2016-12-15 22:03:26.000000000","message":"continuing the discussion from set #30, I\u0027m not sure how https://review.openstack.org/#/c/406915/ addresses whether or not we need to check p.internal_info[TENANT_VIF_PORT_ID] here. Isn\u0027t this code supposed to see if there is a (tenant) VIF, which could be in .internal_info or extra, until we deprecate .extra[]?","commit_id":"bf1b5364da63622064678c76bef0e7bc74fd5447"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"b53aebf2711e2d6fb535c0a20b9366cdb2da4bf9","unresolved":false,"context_lines":[{"line_number":144,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":145,"context_line":"                for p in ports:"},{"line_number":146,"context_line":"                    extra \u003d p.extra"},{"line_number":147,"context_line":"                    vif \u003d extra.get(\u0027vif_port_id\u0027)"},{"line_number":148,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":149,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":150,"context_line":"                                \"set to False, because the port group %s \""}],"source_content_type":"text/x-python","patch_set":31,"id":"1a6eadb0_dc244a0e","line":147,"in_reply_to":"1a6eadb0_eb3f99b1","updated":"2016-12-16 12:20:48.000000000","message":"tenant vif can be only in extra at the moment, please have look at L186. We allow attaching VIF to ports only (not portgroups) via new attach/detach API. As soon we allow to attach VIFs to portgroup  we will need to look onto internal_info here.","commit_id":"bf1b5364da63622064678c76bef0e7bc74fd5447"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a526bf2bfe79323c2f4f852d53a5da2a87297327","unresolved":false,"context_lines":[{"line_number":67,"context_line":"            updated_client_id \u003d port_obj.extra.get(\u0027client-id\u0027)"},{"line_number":68,"context_line":"            if (original_port.extra.get(\u0027client-id\u0027) !\u003d"},{"line_number":69,"context_line":"                updated_client_id):"},{"line_number":70,"context_line":"                vif \u003d (port_obj.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":71,"context_line":"                       port_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":72,"context_line":"                # DHCP Option with opt_value\u003dNone will remove it"},{"line_number":73,"context_line":"                # from the neutron port"},{"line_number":74,"context_line":"                if vif:"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_1daa2a85","line":71,"range":{"start_line":70,"start_character":16,"end_line":71,"end_character":57},"updated":"2016-12-16 19:52:25.000000000","message":"you\u0027ve done it already on L49","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":67,"context_line":"            updated_client_id \u003d port_obj.extra.get(\u0027client-id\u0027)"},{"line_number":68,"context_line":"            if (original_port.extra.get(\u0027client-id\u0027) !\u003d"},{"line_number":69,"context_line":"                updated_client_id):"},{"line_number":70,"context_line":"                vif \u003d (port_obj.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":71,"context_line":"                       port_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":72,"context_line":"                # DHCP Option with opt_value\u003dNone will remove it"},{"line_number":73,"context_line":"                # from the neutron port"},{"line_number":74,"context_line":"                if vif:"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_908b2068","line":71,"range":{"start_line":70,"start_character":16,"end_line":71,"end_character":57},"in_reply_to":"1a6eadb0_1daa2a85","updated":"2016-12-20 16:58:56.000000000","message":"Done","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"0455ad63523d2986977818c108a215427ccbfa13","unresolved":false,"context_lines":[{"line_number":98,"context_line":"                    reason.append(\u0027VIF %s is attached to the port\u0027 % vif)"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"                if reason:"},{"line_number":101,"context_line":"                    msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""},{"line_number":102,"context_line":"                             \"standalone ports. This port %(port)s cannot be \""},{"line_number":103,"context_line":"                             \" a member of that port group because of: \""},{"line_number":104,"context_line":"                             \"%(reason)s\") % {\"reason\": \u0027, \u0027.join(reason),"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_89787ffa","line":101,"updated":"2016-12-19 16:47:01.000000000","message":"oooo, another one - there is no _ imported in this module.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":98,"context_line":"                    reason.append(\u0027VIF %s is attached to the port\u0027 % vif)"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"                if reason:"},{"line_number":101,"context_line":"                    msg \u003d (_(\"Port group %(portgroup)s doesn\u0027t support \""},{"line_number":102,"context_line":"                             \"standalone ports. This port %(port)s cannot be \""},{"line_number":103,"context_line":"                             \" a member of that port group because of: \""},{"line_number":104,"context_line":"                             \"%(reason)s\") % {\"reason\": \u0027, \u0027.join(reason),"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_10447019","line":101,"in_reply_to":"1a6eadb0_89787ffa","updated":"2016-12-20 16:58:56.000000000","message":"looks like _ is mocked in our tests, since unittest passed:\n\nhttps://review.openstack.org/#/c/327046/33/ironic/tests/unit/drivers/modules/network/test_common.py@230","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"2369531f87d3d8189b0f5c0a709b5d5a0feca583","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        node \u003d task.node"},{"line_number":120,"context_line":"        portgroup_uuid \u003d portgroup_obj.uuid"},{"line_number":121,"context_line":"        if \u0027address\u0027 in portgroup_obj.obj_what_changed():"},{"line_number":122,"context_line":"            vif \u003d (portgroup_obj.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":123,"context_line":"                   portgroup_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":124,"context_line":"            if vif:"},{"line_number":125,"context_line":"                neutron.update_port_address(vif,"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_693163ec","line":122,"range":{"start_line":122,"start_character":19,"end_line":122,"end_character":66},"updated":"2016-12-19 16:35:45.000000000","message":"Noticed after discussion with Ruby, so if you say we don\u0027t support portgroups yet, do we need it here? Maybe it\u0027s OK to leave it here, so that do less changes in future.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        node \u003d task.node"},{"line_number":120,"context_line":"        portgroup_uuid \u003d portgroup_obj.uuid"},{"line_number":121,"context_line":"        if \u0027address\u0027 in portgroup_obj.obj_what_changed():"},{"line_number":122,"context_line":"            vif \u003d (portgroup_obj.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":123,"context_line":"                   portgroup_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":124,"context_line":"            if vif:"},{"line_number":125,"context_line":"                neutron.update_port_address(vif,"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_30724c7d","line":122,"range":{"start_line":122,"start_character":19,"end_line":122,"end_character":66},"in_reply_to":"1a6eadb0_496ca79c","updated":"2016-12-20 16:58:56.000000000","message":"Done","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07b3b261b54f72dd812ae37c9545be05d627985b","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        node \u003d task.node"},{"line_number":120,"context_line":"        portgroup_uuid \u003d portgroup_obj.uuid"},{"line_number":121,"context_line":"        if \u0027address\u0027 in portgroup_obj.obj_what_changed():"},{"line_number":122,"context_line":"            vif \u003d (portgroup_obj.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":123,"context_line":"                   portgroup_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":124,"context_line":"            if vif:"},{"line_number":125,"context_line":"                neutron.update_port_address(vif,"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_496ca79c","line":122,"range":{"start_line":122,"start_character":19,"end_line":122,"end_character":66},"in_reply_to":"1a6eadb0_693163ec","updated":"2016-12-19 16:42:07.000000000","message":"I think we should remove it if we don\u0027t support portgroups, because it is confusing.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a526bf2bfe79323c2f4f852d53a5da2a87297327","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                neutron.update_port_address(vif,"},{"line_number":126,"context_line":"                                            portgroup_obj.address,"},{"line_number":127,"context_line":"                                            token\u003dcontext.auth_token)"},{"line_number":128,"context_line":"            # Log warning if there is no VIF and an instance is associated with"},{"line_number":129,"context_line":"            # the node."},{"line_number":130,"context_line":"            elif node.instance_uuid:"},{"line_number":131,"context_line":"                LOG.warning(_LW("},{"line_number":132,"context_line":"                    \"No VIF was found for instance %(instance)s \""},{"line_number":133,"context_line":"                    \"on node %(node)s, when attempting to update \""},{"line_number":134,"context_line":"                    \"portgroup %(portgroup)s MAC address.\"),"},{"line_number":135,"context_line":"                    {\u0027portgroup\u0027: portgroup_uuid,"},{"line_number":136,"context_line":"                     \u0027instance\u0027: node.instance_uuid,"},{"line_number":137,"context_line":"                     \u0027node\u0027: node.uuid})"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if (\u0027standalone_ports_supported\u0027 in"},{"line_number":140,"context_line":"                portgroup_obj.obj_what_changed()):"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_1d25ca5a","line":137,"range":{"start_line":128,"start_character":12,"end_line":137,"end_character":40},"updated":"2016-12-16 19:52:25.000000000","message":"do we actually care about it now, when portgroup address is optional? iiuc the intent was just the contrary - to set neutron port address as portgroup address, in case of using nova, or just ignore it in case of standalone as it should be set in configdrive anyway? Maybe even remove this whole \"if address\" part because of that.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"c7ede8539b40fb250e79d57fcb3396ee2bdb13f4","unresolved":false,"context_lines":[{"line_number":134,"context_line":"                    \"portgroup %(portgroup)s MAC address.\"),"},{"line_number":135,"context_line":"                    {\u0027portgroup\u0027: portgroup_uuid,"},{"line_number":136,"context_line":"                     \u0027instance\u0027: node.instance_uuid,"},{"line_number":137,"context_line":"                     \u0027node\u0027: node.uuid})"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if (\u0027standalone_ports_supported\u0027 in"},{"line_number":140,"context_line":"                portgroup_obj.obj_what_changed()):"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_44420eaf","line":137,"in_reply_to":"1a6eadb0_1d25ca5a","updated":"2016-12-16 20:58:43.000000000","message":"reply to self :) maybe we do care, if we wont update the address of vif in case of nova, address field is useless. otoh, the last part of if, when we log warning if there is instance uuid, it might be actually all ok since we dont use portgroups yet?","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":134,"context_line":"                    \"portgroup %(portgroup)s MAC address.\"),"},{"line_number":135,"context_line":"                    {\u0027portgroup\u0027: portgroup_uuid,"},{"line_number":136,"context_line":"                     \u0027instance\u0027: node.instance_uuid,"},{"line_number":137,"context_line":"                     \u0027node\u0027: node.uuid})"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"        if (\u0027standalone_ports_supported\u0027 in"},{"line_number":140,"context_line":"                portgroup_obj.obj_what_changed()):"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_3372567d","line":137,"in_reply_to":"1a6eadb0_44420eaf","updated":"2016-12-20 16:58:56.000000000","message":"I either doubt about use case for this warning in portgroup and port above.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"2369531f87d3d8189b0f5c0a709b5d5a0feca583","unresolved":false,"context_lines":[{"line_number":143,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":144,"context_line":"                for p in ports:"},{"line_number":145,"context_line":"                    extra \u003d p.extra"},{"line_number":146,"context_line":"                    vif \u003d extra.get(\u0027vif_port_id\u0027)"},{"line_number":147,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":148,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":149,"context_line":"                                \"set to False, because the port group %s \""}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_695fa30e","line":146,"updated":"2016-12-19 16:35:45.000000000","message":"Seems like Ruby is correct here, it checks ports, not portgroups. We need to check internal_info here too.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07b3b261b54f72dd812ae37c9545be05d627985b","unresolved":false,"context_lines":[{"line_number":143,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":144,"context_line":"                for p in ports:"},{"line_number":145,"context_line":"                    extra \u003d p.extra"},{"line_number":146,"context_line":"                    vif \u003d extra.get(\u0027vif_port_id\u0027)"},{"line_number":147,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":148,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":149,"context_line":"                                \"set to False, because the port group %s \""}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_e92ad32b","line":146,"in_reply_to":"1a6eadb0_695fa30e","updated":"2016-12-19 16:42:07.000000000","message":"thx vdrok for checking!","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":143,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":144,"context_line":"                for p in ports:"},{"line_number":145,"context_line":"                    extra \u003d p.extra"},{"line_number":146,"context_line":"                    vif \u003d extra.get(\u0027vif_port_id\u0027)"},{"line_number":147,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":148,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":149,"context_line":"                                \"set to False, because the port group %s \""}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_f381befc","line":146,"in_reply_to":"1a6eadb0_e92ad32b","updated":"2016-12-20 16:58:56.000000000","message":"right it is port not portgroup object.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a526bf2bfe79323c2f4f852d53a5da2a87297327","unresolved":false,"context_lines":[{"line_number":176,"context_line":"        :raises: NetworkError, VifAlreadyAttached, NoFreePhysicalPorts"},{"line_number":177,"context_line":"        \"\"\""},{"line_number":178,"context_line":"        vif_id \u003d vif_info[\u0027id\u0027]"},{"line_number":179,"context_line":"        # Sort ports by pxe_enabled to ensure we always bind pxe_enabled ports"},{"line_number":180,"context_line":"        # first"},{"line_number":181,"context_line":"        sorted_ports \u003d sorted(task.ports, key\u003dlambda p: p.pxe_enabled,"},{"line_number":182,"context_line":"                              reverse\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_9de63a42","line":179,"updated":"2016-12-16 19:52:25.000000000","message":"Just to recall, if pxe_enabled\u003dfalse, we can still use the port if standalone_ports_supported\u003dtrue?","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":176,"context_line":"        :raises: NetworkError, VifAlreadyAttached, NoFreePhysicalPorts"},{"line_number":177,"context_line":"        \"\"\""},{"line_number":178,"context_line":"        vif_id \u003d vif_info[\u0027id\u0027]"},{"line_number":179,"context_line":"        # Sort ports by pxe_enabled to ensure we always bind pxe_enabled ports"},{"line_number":180,"context_line":"        # first"},{"line_number":181,"context_line":"        sorted_ports \u003d sorted(task.ports, key\u003dlambda p: p.pxe_enabled,"},{"line_number":182,"context_line":"                              reverse\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_53c5123b","line":179,"in_reply_to":"1a6eadb0_9de63a42","updated":"2016-12-20 16:58:56.000000000","message":"right, port with pxe_enabled\u003dfalse may be a member of portgroup with standalone_port_supported\u003dtrue. In this case port will not be picked for provisioning (slow NIC for example), but tenant port still can be associated with it.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"f7e995985bad7f588d56553d209d51612b681739","unresolved":false,"context_lines":[{"line_number":120,"context_line":"                ports \u003d [p for p in task.ports if"},{"line_number":121,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":122,"context_line":"                for p in ports:"},{"line_number":123,"context_line":"                    extra \u003d p.extra"},{"line_number":124,"context_line":"                    vif \u003d (p.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":125,"context_line":"                           extra.get(\u0027vif_port_id\u0027))"},{"line_number":126,"context_line":"                    if vif or p.pxe_enabled:"}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_eea8e3dd","line":123,"updated":"2016-12-20 14:57:20.000000000","message":"i\u0027m not sure this is needed since p.extra seems to be used only once","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"a5868bfab3e38848d2b3d1e9f35ae9f7a4277c9d","unresolved":false,"context_lines":[{"line_number":120,"context_line":"                ports \u003d [p for p in task.ports if"},{"line_number":121,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":122,"context_line":"                for p in ports:"},{"line_number":123,"context_line":"                    extra \u003d p.extra"},{"line_number":124,"context_line":"                    vif \u003d (p.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":125,"context_line":"                           extra.get(\u0027vif_port_id\u0027))"},{"line_number":126,"context_line":"                    if vif or p.pxe_enabled:"}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_1c6e3096","line":123,"in_reply_to":"1a6eadb0_eea8e3dd","updated":"2016-12-20 16:59:09.000000000","message":"Done","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"f7e995985bad7f588d56553d209d51612b681739","unresolved":false,"context_lines":[{"line_number":121,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":122,"context_line":"                for p in ports:"},{"line_number":123,"context_line":"                    extra \u003d p.extra"},{"line_number":124,"context_line":"                    vif \u003d (p.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":125,"context_line":"                           extra.get(\u0027vif_port_id\u0027))"},{"line_number":126,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":127,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_2e473b1e","line":124,"updated":"2016-12-20 14:57:20.000000000","message":"L142 uses a different pattern to get the vif; might be good to be consistent with that.","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"a5868bfab3e38848d2b3d1e9f35ae9f7a4277c9d","unresolved":false,"context_lines":[{"line_number":121,"context_line":"                         p.portgroup_id \u003d\u003d portgroup_obj.id]"},{"line_number":122,"context_line":"                for p in ports:"},{"line_number":123,"context_line":"                    extra \u003d p.extra"},{"line_number":124,"context_line":"                    vif \u003d (p.internal_info.get(TENANT_VIF_KEY) or"},{"line_number":125,"context_line":"                           extra.get(\u0027vif_port_id\u0027))"},{"line_number":126,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":127,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_dc12f808","line":124,"in_reply_to":"1a6eadb0_2e473b1e","updated":"2016-12-20 16:59:09.000000000","message":"Done","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"c76af219af7227d422bfeb5ca271a2dbf59d49f4","unresolved":false,"context_lines":[{"line_number":126,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":127,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":128,"context_line":"                                \"set to False, because the port group %s \""},{"line_number":129,"context_line":"                                \"contains ports with \u0027extra/vif_port_id\u0027 \""},{"line_number":130,"context_line":"                                \"or pxe_enabled\u003dTrue\") % portgroup_uuid"},{"line_number":131,"context_line":"                        raise exception.Conflict(msg)"},{"line_number":132,"context_line":""}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_f329ac38","line":129,"updated":"2016-12-20 14:36:43.000000000","message":"need to be updated according to Ruby comment.","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"a5868bfab3e38848d2b3d1e9f35ae9f7a4277c9d","unresolved":false,"context_lines":[{"line_number":126,"context_line":"                    if vif or p.pxe_enabled:"},{"line_number":127,"context_line":"                        msg \u003d _(\"standalone_ports_supported can not be \""},{"line_number":128,"context_line":"                                \"set to False, because the port group %s \""},{"line_number":129,"context_line":"                                \"contains ports with \u0027extra/vif_port_id\u0027 \""},{"line_number":130,"context_line":"                                \"or pxe_enabled\u003dTrue\") % portgroup_uuid"},{"line_number":131,"context_line":"                        raise exception.Conflict(msg)"},{"line_number":132,"context_line":""}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_fcf974c9","line":129,"in_reply_to":"1a6eadb0_f329ac38","updated":"2016-12-20 16:59:09.000000000","message":"Done","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"3daa02a652ef24a4c0aeb8a99b65734ba1875e41","unresolved":false,"context_lines":[{"line_number":248,"context_line":"        return (p_obj.internal_info.get(\u0027cleaning_vif_port_id\u0027) or"},{"line_number":249,"context_line":"                p_obj.internal_info.get(\u0027provisioning_vif_port_id\u0027) or"},{"line_number":250,"context_line":"                p_obj.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":251,"context_line":"                p_obj.extra.get(\u0027vif_port_id\u0027) or None)"}],"source_content_type":"text/x-python","patch_set":36,"id":"fa48f94a_d2d084cc","line":251,"range":{"start_line":251,"start_character":46,"end_line":251,"end_character":54},"updated":"2016-12-21 17:40:20.000000000","message":"nit - not necessary :)","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"}],"ironic/drivers/modules/network/flat.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        :param task: A TaskManager instance."},{"line_number":53,"context_line":"        \"\"\""},{"line_number":54,"context_line":"        LOG.debug(\"Binding flat network ports\")"},{"line_number":55,"context_line":"        node \u003d task.node"},{"line_number":56,"context_line":"        host_id \u003d node.instance_info.get(\u0027nova_host_id\u0027)"},{"line_number":57,"context_line":"        if not host_id:"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_c9545323","line":54,"updated":"2016-11-14 09:13:18.000000000","message":"Why we need to implement add_provisioning_network for flat driver?","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        :param task: A TaskManager instance."},{"line_number":53,"context_line":"        \"\"\""},{"line_number":54,"context_line":"        LOG.debug(\"Binding flat network ports\")"},{"line_number":55,"context_line":"        node \u003d task.node"},{"line_number":56,"context_line":"        host_id \u003d node.instance_info.get(\u0027nova_host_id\u0027)"},{"line_number":57,"context_line":"        if not host_id:"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_55560d07","line":54,"in_reply_to":"9a629dbe_c9545323","updated":"2016-11-14 14:21:30.000000000","message":"The port created by Nova is no longer bound, so we must bind it before we can use it.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"abceed988db1c158238331b42f7dc5f1d911ddee","unresolved":false,"context_lines":[{"line_number":61,"context_line":"        portgroups \u003d task.portgroups"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"},{"line_number":64,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":65,"context_line":"            vif_port_id \u003d (port_like_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":66,"context_line":"                           port_like_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":67,"context_line":"            if not vif_port_id:"},{"line_number":68,"context_line":"                continue"},{"line_number":69,"context_line":"            body \u003d {"},{"line_number":70,"context_line":"                \u0027port\u0027: {"},{"line_number":71,"context_line":"                    \u0027mac_address\u0027: port_like_obj.address,"},{"line_number":72,"context_line":"                    \u0027binding:host_id\u0027: host_id"},{"line_number":73,"context_line":"                }"},{"line_number":74,"context_line":"            }"},{"line_number":75,"context_line":"            client.update_port(vif_port_id, body)"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"    def remove_provisioning_network(self, task):"},{"line_number":78,"context_line":"        \"\"\"Remove the provisioning network from a node."}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_b1d15032","line":75,"range":{"start_line":64,"start_character":8,"end_line":75,"end_character":49},"updated":"2016-11-13 22:17:58.000000000","message":"could you reuse common.neutron.update_port_address here? E.g. by allowing it not to query neutron to get binding if one is already provided as a parameter.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":61,"context_line":"        portgroups \u003d task.portgroups"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"},{"line_number":64,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":65,"context_line":"            vif_port_id \u003d (port_like_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":66,"context_line":"                           port_like_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":67,"context_line":"            if not vif_port_id:"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_f43b68e9","line":64,"updated":"2016-11-24 12:15:19.000000000","message":"This place will also include the standalone_ports_supported/pxe_enabled logic too when it\u0027s merged?","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":61,"context_line":"        portgroups \u003d task.portgroups"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"},{"line_number":64,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":65,"context_line":"            vif_port_id \u003d (port_like_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":66,"context_line":"                           port_like_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":67,"context_line":"            if not vif_port_id:"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_b6cc26bc","line":64,"in_reply_to":"5a74a57a_f43b68e9","updated":"2016-11-28 15:35:02.000000000","message":"Possible but I think unessesary, as being bound or unbound doesn\u0027t effect whether or not DHCP is enabled for ports in a flat network. The place we\u0027ll handle those flags is in the vif_attach function for mapping the vifs to pifs and in the PXE DHCP configuration functions to only config PXE DHCP for pxe_enabled NICs","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4d4c25f3f39c5805057ace978900d91daf3028c0","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        if not host_id:"},{"line_number":58,"context_line":"            return"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"        ports \u003d [p for p in task.ports if not p.portgroup_id]"},{"line_number":61,"context_line":"        portgroups \u003d task.portgroups"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_6803270e","line":60,"range":{"start_line":60,"start_character":46,"end_line":60,"end_character":60},"updated":"2016-11-30 09:40:23.000000000","message":"so in the mixin, you iterate on all ports, sorting them by pxe_enabled value first, here you filter out the ones that are associated with portgroups. If you intend to do only ports for now, and add portgroups later, maybe just drop this bit of logic too?\n\nAs, if I understand correctly, if you have not attached a VIF to portgroup, there is no point in trying to update VIF binding.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        if not host_id:"},{"line_number":58,"context_line":"            return"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"        ports \u003d [p for p in task.ports if not p.portgroup_id]"},{"line_number":61,"context_line":"        portgroups \u003d task.portgroups"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_24c86574","line":60,"range":{"start_line":60,"start_character":46,"end_line":60,"end_character":60},"in_reply_to":"5a74a57a_6803270e","updated":"2016-11-30 16:12:57.000000000","message":"Done","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":94,"context_line":"        \"\"\""},{"line_number":95,"context_line":"        for port in task.ports:"},{"line_number":96,"context_line":"            extra_dict \u003d port.extra"},{"line_number":97,"context_line":"            extra_dict.pop(\u0027vif_port_id\u0027, None)"},{"line_number":98,"context_line":"            port.extra \u003d extra_dict"},{"line_number":99,"context_line":"            port.save()"},{"line_number":100,"context_line":""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_eced98f0","line":97,"updated":"2016-11-30 02:19:25.000000000","message":"should we try to also do this for port.internal_info[\u0027vif_port_id\u0027]?","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":94,"context_line":"        \"\"\""},{"line_number":95,"context_line":"        for port in task.ports:"},{"line_number":96,"context_line":"            extra_dict \u003d port.extra"},{"line_number":97,"context_line":"            extra_dict.pop(\u0027vif_port_id\u0027, None)"},{"line_number":98,"context_line":"            port.extra \u003d extra_dict"},{"line_number":99,"context_line":"            port.save()"},{"line_number":100,"context_line":""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_648edd28","line":97,"in_reply_to":"5a74a57a_285f6f0f","updated":"2016-11-30 16:12:57.000000000","message":"Done","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4d4c25f3f39c5805057ace978900d91daf3028c0","unresolved":false,"context_lines":[{"line_number":94,"context_line":"        \"\"\""},{"line_number":95,"context_line":"        for port in task.ports:"},{"line_number":96,"context_line":"            extra_dict \u003d port.extra"},{"line_number":97,"context_line":"            extra_dict.pop(\u0027vif_port_id\u0027, None)"},{"line_number":98,"context_line":"            port.extra \u003d extra_dict"},{"line_number":99,"context_line":"            port.save()"},{"line_number":100,"context_line":""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_285f6f0f","line":97,"in_reply_to":"5a74a57a_eced98f0","updated":"2016-11-30 09:40:23.000000000","message":"Actually, seems like we need to drop it? As nova will do it with detach call.","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":73,"context_line":"        \"\"\""},{"line_number":74,"context_line":"        for port in task.ports:"},{"line_number":75,"context_line":"            extra_dict \u003d port.extra"},{"line_number":76,"context_line":"            extra_dict.pop(\u0027vif_port_id\u0027, None)"},{"line_number":77,"context_line":"            port.extra \u003d extra_dict"},{"line_number":78,"context_line":"            port.save()"},{"line_number":79,"context_line":""}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_7ded79ee","side":"PARENT","line":76,"updated":"2016-12-02 13:58:52.000000000","message":"Why it was removed?","commit_id":"9d4e1070e9e0e098aeb81e5805eff8d768322d65"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":73,"context_line":"        \"\"\""},{"line_number":74,"context_line":"        for port in task.ports:"},{"line_number":75,"context_line":"            extra_dict \u003d port.extra"},{"line_number":76,"context_line":"            extra_dict.pop(\u0027vif_port_id\u0027, None)"},{"line_number":77,"context_line":"            port.extra \u003d extra_dict"},{"line_number":78,"context_line":"            port.save()"},{"line_number":79,"context_line":""}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_17b97279","side":"PARENT","line":76,"in_reply_to":"3a71b18c_7ded79ee","updated":"2016-12-06 11:43:59.000000000","message":"because this is what detach_vif is for.","commit_id":"9d4e1070e9e0e098aeb81e5805eff8d768322d65"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        if not host_id:"},{"line_number":58,"context_line":"            return"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"        # FIXME(sambetts): Uncomment when we support vifs attached to"},{"line_number":61,"context_line":"        # portgroups"},{"line_number":62,"context_line":"        #"},{"line_number":63,"context_line":"        # ports \u003d [p for p in task.ports if not p.portgroup_id]"},{"line_number":64,"context_line":"        # portgroups \u003d task.portgroups"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"},{"line_number":67,"context_line":"        for port_like_obj in task.ports:  # + portgroups:"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_9d05f5c3","line":64,"range":{"start_line":60,"start_character":8,"end_line":64,"end_character":38},"updated":"2016-12-02 13:58:52.000000000","message":"This should be a separate patch as for me.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4f78464056c02c4452224e4f69e3488d1709f5e0","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        if not host_id:"},{"line_number":58,"context_line":"            return"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"        # FIXME(sambetts): Uncomment when we support vifs attached to"},{"line_number":61,"context_line":"        # portgroups"},{"line_number":62,"context_line":"        #"},{"line_number":63,"context_line":"        # ports \u003d [p for p in task.ports if not p.portgroup_id]"},{"line_number":64,"context_line":"        # portgroups \u003d task.portgroups"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"},{"line_number":67,"context_line":"        for port_like_obj in task.ports:  # + portgroups:"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_2ac247e9","line":64,"range":{"start_line":60,"start_character":8,"end_line":64,"end_character":38},"in_reply_to":"3a71b18c_9d05f5c3","updated":"2016-12-06 22:36:28.000000000","message":"I\u0027m not sure what you mean Vasyl. Did Sam do what you wanted?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"921782a77881cba780d4a3e8802cb5e0f285e71b","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        # portgroups \u003d task.portgroups"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"},{"line_number":67,"context_line":"        for port_like_obj in task.ports:  # + portgroups:"},{"line_number":68,"context_line":"            vif_port_id \u003d (port_like_obj.extra.get(\u0027vif_port_id\u0027) or"},{"line_number":69,"context_line":"                           port_like_obj.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":70,"context_line":"            if not vif_port_id:"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_1dfac5bd","line":67,"updated":"2016-12-02 13:58:52.000000000","message":"ditto","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f2a78422d87bd283f74467994cdcfff4fc1e74a8","unresolved":false,"context_lines":[{"line_number":60,"context_line":""},{"line_number":61,"context_line":"        :param task: A TaskManager instance."},{"line_number":62,"context_line":"        \"\"\""},{"line_number":63,"context_line":"        LOG.debug(\"Binding flat network ports\")"},{"line_number":64,"context_line":"        node \u003d task.node"},{"line_number":65,"context_line":"        host_id \u003d node.instance_info.get(\u0027nova_host_id\u0027)"},{"line_number":66,"context_line":"        if not host_id:"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_9dd1c732","line":63,"updated":"2016-12-07 13:30:20.000000000","message":"This is FLAT network interface, we adding this implementation here, because we will no longer set binding:host_id on nova side. And need to keep this behaviour for out of tree dhcp/neutwork interfaces who relied on this behaviour. It should be deprecated in future right?","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":60,"context_line":""},{"line_number":61,"context_line":"        :param task: A TaskManager instance."},{"line_number":62,"context_line":"        \"\"\""},{"line_number":63,"context_line":"        LOG.debug(\"Binding flat network ports\")"},{"line_number":64,"context_line":"        node \u003d task.node"},{"line_number":65,"context_line":"        host_id \u003d node.instance_info.get(\u0027nova_host_id\u0027)"},{"line_number":66,"context_line":"        if not host_id:"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_8a1ce678","line":63,"in_reply_to":"3a71b18c_9dd1c732","updated":"2016-12-08 14:18:02.000000000","message":"Correct, once we can bind statically configured baremetal ports in neutron, we will hopefully be able to deprecate this whole network interface.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f2a78422d87bd283f74467994cdcfff4fc1e74a8","unresolved":false,"context_lines":[{"line_number":66,"context_line":"        if not host_id:"},{"line_number":67,"context_line":"            return"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"        # FIXME(sambetts): Uncomment when we support vifs attached to"},{"line_number":70,"context_line":"        # portgroups"},{"line_number":71,"context_line":"        #"},{"line_number":72,"context_line":"        # ports \u003d [p for p in task.ports if not p.portgroup_id]"},{"line_number":73,"context_line":"        # portgroups \u003d task.portgroups"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"        client \u003d neutron.get_client(task.context.auth_token)"},{"line_number":76,"context_line":"        for port_like_obj in task.ports:  # + portgroups:"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_bd6123ab","line":73,"range":{"start_line":69,"start_character":8,"end_line":73,"end_character":38},"updated":"2016-12-07 13:30:20.000000000","message":"Interested idea to configure bond during provisioning, portgroup should support standalone_ports_supported to be PXE bootable, or portgroup should be hardcoded in bootstrap.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"1be888cb8cec62a45e51626ca3c30bcf57f2eccc","unresolved":false,"context_lines":[{"line_number":104,"context_line":""},{"line_number":105,"context_line":"        :param task: A TaskManager instance."},{"line_number":106,"context_line":"        \"\"\""},{"line_number":107,"context_line":"        pass"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"    def add_cleaning_network(self, task):"},{"line_number":110,"context_line":"        \"\"\"Add the cleaning network to a node."}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_5e32f0a7","line":107,"updated":"2016-12-06 17:45:40.000000000","message":"Note to anyone reading:\n\nThis is necessary to avoid destructive operations when unconfiguring tenant networks. If the vif_port_id really needs to be removed, the creator of the port (nova) should handle it.\n\nThis change is also a prerequisite for rescue mode since we unconfigure and reconfigure tenant networks during the rescue operation, in order to boot the rescue ramdisk.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a526bf2bfe79323c2f4f852d53a5da2a87297327","unresolved":false,"context_lines":[{"line_number":84,"context_line":"                    \u0027binding:host_id\u0027: host_id"},{"line_number":85,"context_line":"                }"},{"line_number":86,"context_line":"            }"},{"line_number":87,"context_line":"            client.update_port(vif_port_id, body)"},{"line_number":88,"context_line":""},{"line_number":89,"context_line":"    def remove_provisioning_network(self, task):"},{"line_number":90,"context_line":"        \"\"\"Remove the provisioning network from a node."}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_bdbe96ab","line":87,"updated":"2016-12-16 19:52:25.000000000","message":"Don\u0027t we care about possible neutron client exception here? Its docstring in the base class says it can only raise network error.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":84,"context_line":"                    \u0027binding:host_id\u0027: host_id"},{"line_number":85,"context_line":"                }"},{"line_number":86,"context_line":"            }"},{"line_number":87,"context_line":"            client.update_port(vif_port_id, body)"},{"line_number":88,"context_line":""},{"line_number":89,"context_line":"    def remove_provisioning_network(self, task):"},{"line_number":90,"context_line":"        \"\"\"Remove the provisioning network from a node."}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_93a5ea48","line":87,"in_reply_to":"1a6eadb0_bdbe96ab","updated":"2016-12-20 16:58:56.000000000","message":"Done","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"c76af219af7227d422bfeb5ca271a2dbf59d49f4","unresolved":false,"context_lines":[{"line_number":89,"context_line":"            }"},{"line_number":90,"context_line":"            try:"},{"line_number":91,"context_line":"                client.update_port(vif_port_id, body)"},{"line_number":92,"context_line":"            except neutron_exceptions.NeutronClientException as e:"},{"line_number":93,"context_line":"                msg \u003d (_(\u0027Unable to set binding:host_id for \u0027"},{"line_number":94,"context_line":"                         \u0027neutron port %(port_id)s. Error: \u0027"},{"line_number":95,"context_line":"                         \u0027%(err)s\u0027) % {\u0027port_id\u0027: vif_port_id, \u0027err\u0027: e})"}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_d3dd9043","line":92,"updated":"2016-12-20 14:36:43.000000000","message":"missed unit tests for this.","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"a5868bfab3e38848d2b3d1e9f35ae9f7a4277c9d","unresolved":false,"context_lines":[{"line_number":89,"context_line":"            }"},{"line_number":90,"context_line":"            try:"},{"line_number":91,"context_line":"                client.update_port(vif_port_id, body)"},{"line_number":92,"context_line":"            except neutron_exceptions.NeutronClientException as e:"},{"line_number":93,"context_line":"                msg \u003d (_(\u0027Unable to set binding:host_id for \u0027"},{"line_number":94,"context_line":"                         \u0027neutron port %(port_id)s. Error: \u0027"},{"line_number":95,"context_line":"                         \u0027%(err)s\u0027) % {\u0027port_id\u0027: vif_port_id, \u0027err\u0027: e})"}],"source_content_type":"text/x-python","patch_set":34,"id":"1a6eadb0_1cc0f07b","line":92,"in_reply_to":"1a6eadb0_d3dd9043","updated":"2016-12-20 16:59:09.000000000","message":"Done","commit_id":"f00ce04638b2a4be5860deae40add77beade24f7"}],"ironic/drivers/modules/network/neutron.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":189,"context_line":"                }"},{"line_number":190,"context_line":"            }"},{"line_number":191,"context_line":"            if port_like_obj.address:"},{"line_number":192,"context_line":"                body[\u0027port\u0027][\u0027mac_address\u0027] \u003d port_like_obj.address"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"            if client_id_opt:"},{"line_number":195,"context_line":"                body[\u0027port\u0027][\u0027extra_dhcp_opts\u0027] \u003d [client_id_opt]"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_a9055f15","line":192,"updated":"2016-11-14 09:13:18.000000000","message":"why do we need this?","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"61a5f9200c074ebb279aed24975047d7edc1a97e","unresolved":false,"context_lines":[{"line_number":189,"context_line":"                }"},{"line_number":190,"context_line":"            }"},{"line_number":191,"context_line":"            if port_like_obj.address:"},{"line_number":192,"context_line":"                body[\u0027port\u0027][\u0027mac_address\u0027] \u003d port_like_obj.address"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"            if client_id_opt:"},{"line_number":195,"context_line":"                body[\u0027port\u0027][\u0027extra_dhcp_opts\u0027] \u003d [client_id_opt]"}],"source_content_type":"text/x-python","patch_set":19,"id":"7a77a97e_69f4d886","line":192,"in_reply_to":"7a77a97e_c6ffc332","updated":"2016-11-16 12:15:10.000000000","message":"This is being integrated into the vif_attach function, so out of tree drivers who will pick up the default implementation will not be broken by this.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":189,"context_line":"                }"},{"line_number":190,"context_line":"            }"},{"line_number":191,"context_line":"            if port_like_obj.address:"},{"line_number":192,"context_line":"                body[\u0027port\u0027][\u0027mac_address\u0027] \u003d port_like_obj.address"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"            if client_id_opt:"},{"line_number":195,"context_line":"                body[\u0027port\u0027][\u0027extra_dhcp_opts\u0027] \u003d [client_id_opt]"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_e8b58831","line":192,"in_reply_to":"9a629dbe_a9055f15","updated":"2016-11-14 14:21:30.000000000","message":"The mac address isn\u0027t set at port create time any longer so we much update it on the ironic side.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"686fdfe8d35d63fd9101489a802955e996345636","unresolved":false,"context_lines":[{"line_number":189,"context_line":"                }"},{"line_number":190,"context_line":"            }"},{"line_number":191,"context_line":"            if port_like_obj.address:"},{"line_number":192,"context_line":"                body[\u0027port\u0027][\u0027mac_address\u0027] \u003d port_like_obj.address"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"            if client_id_opt:"},{"line_number":195,"context_line":"                body[\u0027port\u0027][\u0027extra_dhcp_opts\u0027] \u003d [client_id_opt]"}],"source_content_type":"text/x-python","patch_set":19,"id":"7a77a97e_c6ffc332","line":192,"in_reply_to":"9a629dbe_e8b58831","updated":"2016-11-15 15:52:54.000000000","message":"It will break out of tree network driver who rely on behaviour that nova create port with correct driver, we can\u0027t just drop mac_for_instance() without proper deprecation.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":156,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":157,"context_line":"            vif_port_id \u003d (port_like_obj.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":158,"context_line":"                           port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"            if not vif_port_id:"},{"line_number":161,"context_line":"                pobj_without_vif +\u003d 1"},{"line_number":162,"context_line":"                continue"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_09c7f412","line":159,"updated":"2016-11-30 22:09:24.000000000","message":"unit test in tests/unit/drivers/modules/network/test_neutron.py?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":156,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":157,"context_line":"            vif_port_id \u003d (port_like_obj.internal_info.get(\u0027vif_port_id\u0027) or"},{"line_number":158,"context_line":"                           port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"            if not vif_port_id:"},{"line_number":161,"context_line":"                pobj_without_vif +\u003d 1"},{"line_number":162,"context_line":"                continue"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_e2c276e8","line":159,"in_reply_to":"5a74a57a_09c7f412","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"1be888cb8cec62a45e51626ca3c30bcf57f2eccc","unresolved":false,"context_lines":[{"line_number":222,"context_line":"            LOG.error(msg)"},{"line_number":223,"context_line":"            raise exception.NetworkError(msg)"},{"line_number":224,"context_line":""},{"line_number":225,"context_line":"    def unconfigure_tenant_networks(self, task):"},{"line_number":226,"context_line":"        \"\"\"Unconfigure tenant networks for a node."},{"line_number":227,"context_line":""},{"line_number":228,"context_line":"        Nova takes care of port removal from tenant network, we binding it"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_decc408b","line":225,"updated":"2016-12-06 17:45:40.000000000","message":"See the comment on the flat network driver for the reason why this change is necessary, for anyone reading.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":225,"context_line":"    def unconfigure_tenant_networks(self, task):"},{"line_number":226,"context_line":"        \"\"\"Unconfigure tenant networks for a node."},{"line_number":227,"context_line":""},{"line_number":228,"context_line":"        Nova takes care of port removal from tenant network, we binding it"},{"line_number":229,"context_line":"        here/now to avoid the possibility of the ironic port being bound to the"},{"line_number":230,"context_line":"        tenant and cleaning networks at the same time."},{"line_number":231,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_0a666b29","line":228,"updated":"2016-12-06 22:36:53.000000000","message":"s/binding/unbind/","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":225,"context_line":"    def unconfigure_tenant_networks(self, task):"},{"line_number":226,"context_line":"        \"\"\"Unconfigure tenant networks for a node."},{"line_number":227,"context_line":""},{"line_number":228,"context_line":"        Nova takes care of port removal from tenant network, we binding it"},{"line_number":229,"context_line":"        here/now to avoid the possibility of the ironic port being bound to the"},{"line_number":230,"context_line":"        tenant and cleaning networks at the same time."},{"line_number":231,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_c5724fad","line":228,"in_reply_to":"3a71b18c_0a666b29","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"a526bf2bfe79323c2f4f852d53a5da2a87297327","unresolved":false,"context_lines":[{"line_number":244,"context_line":"                port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":245,"context_line":"            if not vif_port_id:"},{"line_number":246,"context_line":"                continue"},{"line_number":247,"context_line":"            neutron.unbind_neutron_port(vif_port_id,"},{"line_number":248,"context_line":"                                        token\u003dtask.context.auth_token)"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_7d24fe0b","line":247,"updated":"2016-12-16 19:52:25.000000000","message":"I\u0027m thinking, what happens if we use ironic+neutron but without nova? neutron ports are not cleaned up anymore automatically.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"c7ede8539b40fb250e79d57fcb3396ee2bdb13f4","unresolved":false,"context_lines":[{"line_number":244,"context_line":"                port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":245,"context_line":"            if not vif_port_id:"},{"line_number":246,"context_line":"                continue"},{"line_number":247,"context_line":"            neutron.unbind_neutron_port(vif_port_id,"},{"line_number":248,"context_line":"                                        token\u003dtask.context.auth_token)"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_8476e603","line":247,"in_reply_to":"1a6eadb0_7d24fe0b","updated":"2016-12-16 20:58:43.000000000","message":"yup, this actually brings more consistent behaviour - you create vif, do the attach, use instance, and vif is gone only after you do detach and delete it. might need to mention it in reno tho","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"ee452d20114e08905a49f9ce34f2de8c6c1332ca","unresolved":false,"context_lines":[{"line_number":244,"context_line":"                port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":245,"context_line":"            if not vif_port_id:"},{"line_number":246,"context_line":"                continue"},{"line_number":247,"context_line":"            neutron.unbind_neutron_port(vif_port_id,"},{"line_number":248,"context_line":"                                        token\u003dtask.context.auth_token)"}],"source_content_type":"text/x-python","patch_set":33,"id":"1a6eadb0_5690a04e","line":247,"in_reply_to":"1a6eadb0_8476e603","updated":"2016-12-20 16:58:56.000000000","message":"There was an old bug in nova, and we have the same bug in Ironic we shouldn\u0027t delete pre-created port as it is break heat.\n\nhttps://bugs.launchpad.net/ironic/+bug/115868\n\nWill add release notes.","commit_id":"abfa69554ef8dac9b4e6bc95a9a7dfe769b8ece5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"3daa02a652ef24a4c0aeb8a99b65734ba1875e41","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        pobj_without_vif \u003d 0"},{"line_number":167,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":168,"context_line":"            vif_port_id \u003d ("},{"line_number":169,"context_line":"                port_like_obj.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":170,"context_line":"                port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"            if not vif_port_id:"},{"line_number":173,"context_line":"                pobj_without_vif +\u003d 1"}],"source_content_type":"text/x-python","patch_set":36,"id":"fa48f94a_554b9e59","line":170,"range":{"start_line":169,"start_character":16,"end_line":170,"end_character":54},"updated":"2016-12-21 17:40:20.000000000","message":"I think you could have used get_current_vif here, as provisioning and cleaning vifs should not be set at this point, but maybe that\u0027s fine.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"50503ec1036bccf5fb7c84509c30ced3c17d55c6","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        pobj_without_vif \u003d 0"},{"line_number":167,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":168,"context_line":"            vif_port_id \u003d ("},{"line_number":169,"context_line":"                port_like_obj.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":170,"context_line":"                port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"            if not vif_port_id:"},{"line_number":173,"context_line":"                pobj_without_vif +\u003d 1"}],"source_content_type":"text/x-python","patch_set":36,"id":"da4df55a_2cbb0ac6","line":170,"range":{"start_line":169,"start_character":16,"end_line":170,"end_character":54},"in_reply_to":"da4df55a_bef1f2cf","updated":"2016-12-22 15:14:05.000000000","message":"after we remove .extra.*, this is going to be port_like_obj.internal_info.get(\u0027tenant_vif_port_id\u0027). Which I prefer since it explicitly sez we want the tenant vif. So I\u0027d prefer if we left this as-is.\n\n(And if you really wanted to change it, I\u0027d prefer it be done in a separate patch since the original code was only looking at .extra() and it \u0027should\u0027 work but if it doesn\u0027t I don\u0027t want to deal with that in this patch :)","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"2e2cafa30f85eff2fd9ad1810f9c5fad94368c9e","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        pobj_without_vif \u003d 0"},{"line_number":167,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":168,"context_line":"            vif_port_id \u003d ("},{"line_number":169,"context_line":"                port_like_obj.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":170,"context_line":"                port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"            if not vif_port_id:"},{"line_number":173,"context_line":"                pobj_without_vif +\u003d 1"}],"source_content_type":"text/x-python","patch_set":36,"id":"da4df55a_bef1f2cf","line":170,"range":{"start_line":169,"start_character":16,"end_line":170,"end_character":54},"in_reply_to":"fa48f94a_554b9e59","updated":"2016-12-22 10:09:15.000000000","message":"good point, I will do this as separate change.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"5fa256771712f2f24abaa3a48ed8a7ce56a5a363","unresolved":false,"context_lines":[{"line_number":239,"context_line":"        ports \u003d [p for p in task.ports if not p.portgroup_id]"},{"line_number":240,"context_line":"        portgroups \u003d task.portgroups"},{"line_number":241,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":242,"context_line":"            vif_port_id \u003d ("},{"line_number":243,"context_line":"                port_like_obj.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":244,"context_line":"                port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":245,"context_line":"            if not vif_port_id:"}],"source_content_type":"text/x-python","patch_set":36,"id":"da4df55a_828204ff","line":242,"updated":"2016-12-22 14:40:50.000000000","message":"nit: Like the nit on line 168, it seems like you could use the helper method here as well.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"50503ec1036bccf5fb7c84509c30ced3c17d55c6","unresolved":false,"context_lines":[{"line_number":239,"context_line":"        ports \u003d [p for p in task.ports if not p.portgroup_id]"},{"line_number":240,"context_line":"        portgroups \u003d task.portgroups"},{"line_number":241,"context_line":"        for port_like_obj in ports + portgroups:"},{"line_number":242,"context_line":"            vif_port_id \u003d ("},{"line_number":243,"context_line":"                port_like_obj.internal_info.get(\u0027tenant_vif_port_id\u0027) or"},{"line_number":244,"context_line":"                port_like_obj.extra.get(\u0027vif_port_id\u0027))"},{"line_number":245,"context_line":"            if not vif_port_id:"}],"source_content_type":"text/x-python","patch_set":36,"id":"da4df55a_0c2ba6ec","line":242,"in_reply_to":"da4df55a_828204ff","updated":"2016-12-22 15:14:05.000000000","message":"after we remove .extra.*, this is going to be port_like_obj.internal_info.get(\u0027tenant_vif_port_id\u0027). Which I prefer since it explicitly sez we want the tenant vif.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"}],"ironic/drivers/modules/network/noop.py":[{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"789d31a7f0d0a066003d814e8ede1dd20c92b202","unresolved":false,"context_lines":[{"line_number":16,"context_line":"class NoopNetwork(base.NetworkInterface):"},{"line_number":17,"context_line":"    \"\"\"Noop network interface.\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"    def attach_vif(self, task, vif):"},{"line_number":20,"context_line":"        pass"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"    def detach_vif(self, task, vif_id):"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_6c12755a","line":19,"updated":"2016-11-14 09:13:18.000000000","message":"please add a docstrings.","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"3fada9727bd045518efb2691be1df82ce9bbd84a","unresolved":false,"context_lines":[{"line_number":16,"context_line":"class NoopNetwork(base.NetworkInterface):"},{"line_number":17,"context_line":"    \"\"\"Noop network interface.\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"    def attach_vif(self, task, vif):"},{"line_number":20,"context_line":"        pass"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"    def detach_vif(self, task, vif_id):"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a629dbe_286220ae","line":19,"in_reply_to":"9a629dbe_6c12755a","updated":"2016-11-14 14:21:30.000000000","message":"Done","commit_id":"fdebfc106efc2d95f790ef33162462306b7ec351"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c6c0b7d0dd6aa15563ac3013da8e3f6242118488","unresolved":false,"context_lines":[{"line_number":34,"context_line":"        \"\"\""},{"line_number":35,"context_line":"        pass"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    def vif_list(self):"},{"line_number":38,"context_line":"        \"\"\"List attached VIF IDs."},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        :param task: A TaskManager instance."}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_06cb9a1f","line":37,"updated":"2016-11-30 02:19:25.000000000","message":"s/self/self, task/","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":34,"context_line":"        \"\"\""},{"line_number":35,"context_line":"        pass"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    def vif_list(self):"},{"line_number":38,"context_line":"        \"\"\"List attached VIF IDs."},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        :param task: A TaskManager instance."}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_e46cad38","line":37,"in_reply_to":"5a74a57a_06cb9a1f","updated":"2016-11-30 16:12:57.000000000","message":"Done","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4d6816a8a3e6b7647b19c23a5f6583547d6b5aa8","unresolved":false,"context_lines":[{"line_number":15,"context_line":""},{"line_number":16,"context_line":"class NoopNetwork(base.NetworkInterface):"},{"line_number":17,"context_line":"    \"\"\"Noop network interface.\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"    def vif_attach(self, task, vif):"},{"line_number":20,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":21,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_ec2a012f","line":18,"updated":"2016-12-07 17:30:39.000000000","message":"Whoops. Missing port_changed()","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":15,"context_line":""},{"line_number":16,"context_line":"class NoopNetwork(base.NetworkInterface):"},{"line_number":17,"context_line":"    \"\"\"Noop network interface.\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"    def vif_attach(self, task, vif):"},{"line_number":20,"context_line":"        \"\"\"Attach a virtual network interface to a node"},{"line_number":21,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_c5a96fe1","line":18,"in_reply_to":"3a71b18c_ec2a012f","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":16,"context_line":"class NoopNetwork(base.NetworkInterface):"},{"line_number":17,"context_line":"    \"\"\"Noop network interface.\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"    def port_changed(self, port_obj):"},{"line_number":20,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"        :param task: a TaskManager instance."}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_1a9f6704","line":19,"updated":"2016-12-13 01:26:36.000000000","message":"should there be a task here?","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":16,"context_line":"class NoopNetwork(base.NetworkInterface):"},{"line_number":17,"context_line":"    \"\"\"Noop network interface.\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"    def port_changed(self, port_obj):"},{"line_number":20,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"        :param task: a TaskManager instance."}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_c18883ea","line":19,"in_reply_to":"1a6eadb0_1a9f6704","updated":"2016-12-13 16:34:13.000000000","message":"Done","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":20,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"        :param task: a TaskManager instance."},{"line_number":23,"context_line":"        :param port: a changed Port object."},{"line_number":24,"context_line":"        :raises: Conflict, FailedToUpdateDHCPOptOnPort"},{"line_number":25,"context_line":"        \"\"\""},{"line_number":26,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_5a89dfc9","line":23,"updated":"2016-12-13 01:26:36.000000000","message":"it is \u0027port\u0027 here, but \u0027port_obj\u0027 at L19","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":20,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"        :param task: a TaskManager instance."},{"line_number":23,"context_line":"        :param port: a changed Port object."},{"line_number":24,"context_line":"        :raises: Conflict, FailedToUpdateDHCPOptOnPort"},{"line_number":25,"context_line":"        \"\"\""},{"line_number":26,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_817e8be2","line":23,"in_reply_to":"1a6eadb0_5a89dfc9","updated":"2016-12-13 16:34:13.000000000","message":"Done","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"703dfea68c1be2c25d7244db9b0111d8fb33acd5","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        \"\"\"List attached VIF IDs for a node."},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"        :param task: A TaskManager instance."},{"line_number":50,"context_line":"        :raises: NetworkError"},{"line_number":51,"context_line":"        \"\"\""},{"line_number":52,"context_line":"        pass"},{"line_number":53,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_33ad4832","line":50,"updated":"2016-12-12 15:17:31.000000000","message":"ditto","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"afd10e14b49e40a4d9c498ee8c8d71cbef0f0e7f","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        \"\"\"List attached VIF IDs for a node."},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"        :param task: A TaskManager instance."},{"line_number":50,"context_line":"        :raises: NetworkError"},{"line_number":51,"context_line":"        \"\"\""},{"line_number":52,"context_line":"        pass"},{"line_number":53,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_217857f2","line":50,"in_reply_to":"1a6eadb0_33ad4832","updated":"2016-12-13 16:34:13.000000000","message":"Done","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":16,"context_line":"class NoopNetwork(base.NetworkInterface):"},{"line_number":17,"context_line":"    \"\"\"Noop network interface.\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"    def port_changed(self, port_obj):"},{"line_number":20,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"        :param task: a TaskManager instance."}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_c64774ba","line":19,"updated":"2016-12-14 19:25:36.000000000","message":"what happened to the task?","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":16,"context_line":"class NoopNetwork(base.NetworkInterface):"},{"line_number":17,"context_line":"    \"\"\"Noop network interface.\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"    def port_changed(self, port_obj):"},{"line_number":20,"context_line":"        \"\"\"Handle any actions required when a port changes"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"        :param task: a TaskManager instance."}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_74df0f0d","line":19,"in_reply_to":"1a6eadb0_c64774ba","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":25,"context_line":"        \"\"\""},{"line_number":26,"context_line":"        pass"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"    def portgroup_changed(self, portgroup_obj):"},{"line_number":29,"context_line":"        \"\"\"Handle any actions required when a portgroup changes"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"        :param task: a TaskManager instance."}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_e64470b8","line":28,"updated":"2016-12-14 19:25:36.000000000","message":"ditto","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":25,"context_line":"        \"\"\""},{"line_number":26,"context_line":"        pass"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"    def portgroup_changed(self, portgroup_obj):"},{"line_number":29,"context_line":"        \"\"\"Handle any actions required when a portgroup changes"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"        :param task: a TaskManager instance."}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_f4d31f02","line":28,"in_reply_to":"1a6eadb0_e64470b8","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":29,"context_line":"        \"\"\"Handle any actions required when a portgroup changes"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"        :param task: a TaskManager instance."},{"line_number":32,"context_line":"        :param portgroup_obj: a changed Port object."},{"line_number":33,"context_line":"        :raises: Conflict, FailedToUpdateDHCPOptOnPort"},{"line_number":34,"context_line":"        \"\"\""},{"line_number":35,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_a625180a","line":32,"updated":"2016-12-14 19:25:36.000000000","message":"s/Port/Portgroup/","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":29,"context_line":"        \"\"\"Handle any actions required when a portgroup changes"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"        :param task: a TaskManager instance."},{"line_number":32,"context_line":"        :param portgroup_obj: a changed Port object."},{"line_number":33,"context_line":"        :raises: Conflict, FailedToUpdateDHCPOptOnPort"},{"line_number":34,"context_line":"        \"\"\""},{"line_number":35,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_54d773ec","line":32,"in_reply_to":"1a6eadb0_a625180a","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        \"\"\"List attached VIF IDs for a node."},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"        :param task: A TaskManager instance."},{"line_number":61,"context_line":"        :raises: NetworkError"},{"line_number":62,"context_line":"        \"\"\""},{"line_number":63,"context_line":"        pass"},{"line_number":64,"context_line":""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_06c96c26","line":61,"updated":"2016-12-14 19:25:36.000000000","message":":returns: ... ?","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        \"\"\"List attached VIF IDs for a node."},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"        :param task: A TaskManager instance."},{"line_number":61,"context_line":"        :raises: NetworkError"},{"line_number":62,"context_line":"        \"\"\""},{"line_number":63,"context_line":"        pass"},{"line_number":64,"context_line":""}],"source_content_type":"text/x-python","patch_set":30,"id":"1a6eadb0_b4fc4773","line":61,"in_reply_to":"1a6eadb0_06c96c26","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"}],"ironic/tests/unit/common/test_network.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":94,"context_line":"        self._test_get_node_vif_ids_two_ports(\u0027extra\u0027)"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":"    def test_get_node_vif_ids_two_ports_int_info(self):"},{"line_number":97,"context_line":"        self._test_get_node_vif_ids_two_ports(\u0027internal_info\u0027)"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"    def _test_get_node_vif_ids_two_portgroups(self, key):"},{"line_number":100,"context_line":"        kwargs1 \u003d {key: {\u0027vif_port_id\u0027: \u0027test-vif-A\u0027}}"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_cabd5303","line":97,"updated":"2016-12-06 22:36:53.000000000","message":"you could even test two ports, one with vif in extra the other in internal_info but NO, I won\u0027t ask you to do that :)","commit_id":"b511580c201844d971e1916391f50d7611525675"}],"ironic/tests/unit/common/test_neutron.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":555,"context_line":"        address \u003d \u0027fe:54:00:77:07:d9\u0027"},{"line_number":556,"context_line":"        port_id \u003d \u0027fake-port-id\u0027"},{"line_number":557,"context_line":"        mock_client.return_value.show_port.return_value \u003d {}"},{"line_number":558,"context_line":""},{"line_number":559,"context_line":"        mock_client.return_value.update_port.side_effect \u003d ("},{"line_number":560,"context_line":"            neutron_client_exc.NeutronClientException())"},{"line_number":561,"context_line":"        self.assertRaises(exception.FailedToUpdateMacOnPort,"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_bf80578c","line":558,"updated":"2016-12-06 22:36:53.000000000","message":"i\u0027m not sure I\u0027d put a blank line here. Maybe after the next line. Or not at all.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":555,"context_line":"        address \u003d \u0027fe:54:00:77:07:d9\u0027"},{"line_number":556,"context_line":"        port_id \u003d \u0027fake-port-id\u0027"},{"line_number":557,"context_line":"        mock_client.return_value.show_port.return_value \u003d {}"},{"line_number":558,"context_line":""},{"line_number":559,"context_line":"        mock_client.return_value.update_port.side_effect \u003d ("},{"line_number":560,"context_line":"            neutron_client_exc.NeutronClientException())"},{"line_number":561,"context_line":"        self.assertRaises(exception.FailedToUpdateMacOnPort,"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_85edb727","line":558,"in_reply_to":"3a71b18c_bf80578c","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":587,"context_line":"        token \u003d \u0027token\u0027"},{"line_number":588,"context_line":"        self.assertRaises(exception.NetworkError, neutron.unbind_neutron_port,"},{"line_number":589,"context_line":"                          port_id, token)"},{"line_number":590,"context_line":"        mock_client.assert_called_once_with(token)"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_ea176f42","line":590,"updated":"2016-12-06 22:36:53.000000000","message":"I suppose you could also do mock_client.return_value.update_port.assert_called_once_with(..)","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":587,"context_line":"        token \u003d \u0027token\u0027"},{"line_number":588,"context_line":"        self.assertRaises(exception.NetworkError, neutron.unbind_neutron_port,"},{"line_number":589,"context_line":"                          port_id, token)"},{"line_number":590,"context_line":"        mock_client.assert_called_once_with(token)"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_05da8778","line":590,"in_reply_to":"3a71b18c_ea176f42","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"}],"ironic/tests/unit/drivers/modules/network/test_common.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"81c615f4665131f07c3bc23ed52e96fab2763bba","unresolved":false,"context_lines":[{"line_number":40,"context_line":"            extra\u003d{\u0027vif_port_id\u0027: uuidutils.generate_uuid()})"},{"line_number":41,"context_line":"        self.neutron_port \u003d {\u0027id\u0027: \u0027132f871f-eaec-4fed-9475-0d54465e0f00\u0027,"},{"line_number":42,"context_line":"                             \u0027mac_address\u0027: \u002752:54:00:cf:2d:32\u0027}"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    def test_vif_list_extra(self):"},{"line_number":45,"context_line":"        vif_id \u003d uuidutils.generate_uuid()"},{"line_number":46,"context_line":"        self.port.extra \u003d {\u0027vif_port_id\u0027: vif_id}"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_7a913f52","line":43,"updated":"2016-12-07 18:03:08.000000000","message":"oh. you should move the port_changed tests from manager.py to here.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f2a78422d87bd283f74467994cdcfff4fc1e74a8","unresolved":false,"context_lines":[{"line_number":60,"context_line":"    def test_vif_list_extra_and_internal_priority(self):"},{"line_number":61,"context_line":"        vif_id \u003d uuidutils.generate_uuid()"},{"line_number":62,"context_line":"        vif_id2 \u003d uuidutils.generate_uuid()"},{"line_number":63,"context_line":"        self.port.extra \u003d {\u0027vif_port_id\u0027: vif_id2}"},{"line_number":64,"context_line":"        self.port.internal_info \u003d {\u0027vif_port_id\u0027: vif_id}"},{"line_number":65,"context_line":"        self.port.save()"},{"line_number":66,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_28407335","line":63,"updated":"2016-12-07 13:30:20.000000000","message":"Looks like this is not normal situation, we shouldn\u0027t be able to map several vifs to single port using different API versions","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":60,"context_line":"    def test_vif_list_extra_and_internal_priority(self):"},{"line_number":61,"context_line":"        vif_id \u003d uuidutils.generate_uuid()"},{"line_number":62,"context_line":"        vif_id2 \u003d uuidutils.generate_uuid()"},{"line_number":63,"context_line":"        self.port.extra \u003d {\u0027vif_port_id\u0027: vif_id2}"},{"line_number":64,"context_line":"        self.port.internal_info \u003d {\u0027vif_port_id\u0027: vif_id}"},{"line_number":65,"context_line":"        self.port.save()"},{"line_number":66,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_853bf79b","line":63,"in_reply_to":"3a71b18c_28407335","updated":"2016-12-08 14:18:02.000000000","message":"It shouldn\u0027t be possible, but if it did occur this test ensures which is picked first.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"f2a78422d87bd283f74467994cdcfff4fc1e74a8","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        self.port.save()"},{"line_number":117,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"},{"line_number":118,"context_line":"            self.assertRaises("},{"line_number":119,"context_line":"                exception.NetworkError, self.interface.vif_attach,"},{"line_number":120,"context_line":"                task, vif)"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    def test_vif_detach_in_extra(self):"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_e8a91b92","line":119,"updated":"2016-12-07 13:30:20.000000000","message":"network error may be raised in different cases, we should check that it was caused by already attached vif by comparing exception message.\n\nAlso please add a test that checks that neutron.update_port_address() is called on vif_attach with/without exception.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        self.port.save()"},{"line_number":117,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"},{"line_number":118,"context_line":"            self.assertRaises("},{"line_number":119,"context_line":"                exception.NetworkError, self.interface.vif_attach,"},{"line_number":120,"context_line":"                task, vif)"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    def test_vif_detach_in_extra(self):"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_e56cab38","line":119,"in_reply_to":"3a71b18c_e8a91b92","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":37,"context_line":"        self.port \u003d obj_utils.create_test_port("},{"line_number":38,"context_line":"            self.context, node_id\u003dself.node.id,"},{"line_number":39,"context_line":"            address\u003d\u002752:54:00:cf:2d:32\u0027,"},{"line_number":40,"context_line":"            extra\u003d{\u0027vif_port_id\u0027: uuidutils.generate_uuid(),"},{"line_number":41,"context_line":"                   \u0027client-id\u0027: \u0027fake1\u0027})"},{"line_number":42,"context_line":"        self.neutron_port \u003d {\u0027id\u0027: \u0027132f871f-eaec-4fed-9475-0d54465e0f00\u0027,"},{"line_number":43,"context_line":"                             \u0027mac_address\u0027: \u002752:54:00:cf:2d:32\u0027}"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_ce6294d8","line":40,"updated":"2016-12-13 01:26:36.000000000","message":"Should we change this to internal_info\u003d... ? Or maybe it doesn\u0027t matter, I\u0027ve lost track of what we\u0027re trying to test here. We\u0027ll have to change this when we delete support for extra[\u0027vif_port_id\u0027] so it\u0027ll be done later anyway.\n\nLooks like a mix of .extra[] and .internal_info[] being used in these unit tests so changing this will probably mess up some tests.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"85fa86a7405378166a5b4d080746e8866c9aedff","unresolved":false,"context_lines":[{"line_number":37,"context_line":"        self.port \u003d obj_utils.create_test_port("},{"line_number":38,"context_line":"            self.context, node_id\u003dself.node.id,"},{"line_number":39,"context_line":"            address\u003d\u002752:54:00:cf:2d:32\u0027,"},{"line_number":40,"context_line":"            extra\u003d{\u0027vif_port_id\u0027: uuidutils.generate_uuid(),"},{"line_number":41,"context_line":"                   \u0027client-id\u0027: \u0027fake1\u0027})"},{"line_number":42,"context_line":"        self.neutron_port \u003d {\u0027id\u0027: \u0027132f871f-eaec-4fed-9475-0d54465e0f00\u0027,"},{"line_number":43,"context_line":"                             \u0027mac_address\u0027: \u002752:54:00:cf:2d:32\u0027}"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_86b106e4","line":40,"in_reply_to":"1a6eadb0_ce6294d8","updated":"2016-12-14 16:16:42.000000000","message":"Lets keep extra.vif_port_id here and change it to internal_info when we deprecate vif_port_id in extra.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"409b583e400b0f073439f55979e1a4b8a84c1de0","unresolved":false,"context_lines":[{"line_number":166,"context_line":""},{"line_number":167,"context_line":"    def test_get_current_vif_internal_info_cleaning(self):"},{"line_number":168,"context_line":"        internal_info \u003d {\u0027cleaning_vif_port_id\u0027: \u0027foo\u0027,"},{"line_number":169,"context_line":"                         \u0027tenant_vif_port_id\u0027: \u0027bar\u0027}"},{"line_number":170,"context_line":"        self.port.internal_info \u003d internal_info"},{"line_number":171,"context_line":"        self.port.save()"},{"line_number":172,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"}],"source_content_type":"text/x-python","patch_set":36,"id":"1a6eadb0_52b5f12e","line":169,"updated":"2016-12-20 17:36:18.000000000","message":"now i don\u0027t remember why we even have cleaning/provisioning/tenant, instead of just one \u0027vif_port_id\u0027 that has the current vif id, BUT I\u0027m not going to look into it :)","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"3daa02a652ef24a4c0aeb8a99b65734ba1875e41","unresolved":false,"context_lines":[{"line_number":166,"context_line":""},{"line_number":167,"context_line":"    def test_get_current_vif_internal_info_cleaning(self):"},{"line_number":168,"context_line":"        internal_info \u003d {\u0027cleaning_vif_port_id\u0027: \u0027foo\u0027,"},{"line_number":169,"context_line":"                         \u0027tenant_vif_port_id\u0027: \u0027bar\u0027}"},{"line_number":170,"context_line":"        self.port.internal_info \u003d internal_info"},{"line_number":171,"context_line":"        self.port.save()"},{"line_number":172,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"}],"source_content_type":"text/x-python","patch_set":36,"id":"fa48f94a_35937aa5","line":169,"in_reply_to":"1a6eadb0_52b5f12e","updated":"2016-12-21 17:40:20.000000000","message":"This was requested for better clarity of what\u0027s going on if I remember correctly.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"50503ec1036bccf5fb7c84509c30ced3c17d55c6","unresolved":false,"context_lines":[{"line_number":166,"context_line":""},{"line_number":167,"context_line":"    def test_get_current_vif_internal_info_cleaning(self):"},{"line_number":168,"context_line":"        internal_info \u003d {\u0027cleaning_vif_port_id\u0027: \u0027foo\u0027,"},{"line_number":169,"context_line":"                         \u0027tenant_vif_port_id\u0027: \u0027bar\u0027}"},{"line_number":170,"context_line":"        self.port.internal_info \u003d internal_info"},{"line_number":171,"context_line":"        self.port.save()"},{"line_number":172,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"}],"source_content_type":"text/x-python","patch_set":36,"id":"da4df55a_cc4efec0","line":169,"in_reply_to":"da4df55a_be6c929d","updated":"2016-12-22 15:14:05.000000000","message":"Thx for explaining.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"525fb44dafc56b4fb14111102133889f7e0420b2","unresolved":false,"context_lines":[{"line_number":166,"context_line":""},{"line_number":167,"context_line":"    def test_get_current_vif_internal_info_cleaning(self):"},{"line_number":168,"context_line":"        internal_info \u003d {\u0027cleaning_vif_port_id\u0027: \u0027foo\u0027,"},{"line_number":169,"context_line":"                         \u0027tenant_vif_port_id\u0027: \u0027bar\u0027}"},{"line_number":170,"context_line":"        self.port.internal_info \u003d internal_info"},{"line_number":171,"context_line":"        self.port.save()"},{"line_number":172,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"}],"source_content_type":"text/x-python","patch_set":36,"id":"da4df55a_cfbef0fe","line":169,"in_reply_to":"da4df55a_cc4efec0","updated":"2016-12-22 15:24:58.000000000","message":"Thinking about this a bit more. Alternatively (but too late now), we could have had two .internal_info things, \u0027current_vif_id\u0027 \u0026 \u0027which_network\u0027 \u003d \u0027provision\u0027, \u0027clean\u0027, \u0027tenant\u0027.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"2e2cafa30f85eff2fd9ad1810f9c5fad94368c9e","unresolved":false,"context_lines":[{"line_number":166,"context_line":""},{"line_number":167,"context_line":"    def test_get_current_vif_internal_info_cleaning(self):"},{"line_number":168,"context_line":"        internal_info \u003d {\u0027cleaning_vif_port_id\u0027: \u0027foo\u0027,"},{"line_number":169,"context_line":"                         \u0027tenant_vif_port_id\u0027: \u0027bar\u0027}"},{"line_number":170,"context_line":"        self.port.internal_info \u003d internal_info"},{"line_number":171,"context_line":"        self.port.save()"},{"line_number":172,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"}],"source_content_type":"text/x-python","patch_set":36,"id":"da4df55a_be6c929d","line":169,"in_reply_to":"fa48f94a_35937aa5","updated":"2016-12-22 10:09:15.000000000","message":"provisioning and tenant VIFs may be associated with the same port in the same time. Nova creates a tenant port and save it to extra[\u0027vif_port_id\u0027]. With multitenancy we create a provisioning port and should map provisioning VIF with the same Ironic port. But we can\u0027t just replace tenant VIF as it will be required when provisioning is done and we should move instance to tenant network (update tenant port). The first version of multitenancy implementation save extra[\u0027vif_port_id\u0027] to other place during provisioning, and than set it back in the end of provisioning. But it was decided there to introduce new keys \u0027cleaning_vif_port_id\u0027 and \u0027provisioning_vif_port_id\u0027 to highlight what is going on with node in specific period of time.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"409b583e400b0f073439f55979e1a4b8a84c1de0","unresolved":false,"context_lines":[{"line_number":464,"context_line":"            self, mac_update_mock):"},{"line_number":465,"context_line":"        pg \u003d obj_utils.create_test_portgroup("},{"line_number":466,"context_line":"            self.context, node_id\u003dself.node.id)"},{"line_number":467,"context_line":"        extra \u003d {\u0027vif_port_id\u0027: \u0027foo\u0027}"},{"line_number":468,"context_line":"        obj_utils.create_test_port("},{"line_number":469,"context_line":"            self.context, node_id\u003dself.node.id, extra\u003dextra,"},{"line_number":470,"context_line":"            pxe_enabled\u003dTrue, portgroup_id\u003dpg.id,"}],"source_content_type":"text/x-python","patch_set":36,"id":"1a6eadb0_f2727d7b","line":467,"updated":"2016-12-20 17:36:18.000000000","message":"since we\u0027re deprecating this, it seems like we should be using internal_info, but I guess we can change this later when we stop supporting extra.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"}],"ironic/tests/unit/drivers/modules/network/test_flat.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":104,"context_line":"                task, self.port.extra[\u0027vif_port_id\u0027])"},{"line_number":105,"context_line":"            self.port.refresh()"},{"line_number":106,"context_line":"            self.assertIsNone(self.port.extra.get(\u0027vif_port_id\u0027))"},{"line_number":107,"context_line":"            self.assertIsNone(self.port.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"    def test_vif_detach_in_internal_info(self):"},{"line_number":110,"context_line":"        self.port.internal_info \u003d {\u0027vif_port_id\u0027: uuidutils.generate_uuid()}"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_15d0e752","line":107,"updated":"2016-11-30 22:09:24.000000000","message":"more specifically, self.assertFalse(\u0027vif_port_id\u0027 in self.port.extra|internal_info)\n\nto distinguish from self.port.extra[\u0027vif_port_id\u0027] \u003d None","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":104,"context_line":"                task, self.port.extra[\u0027vif_port_id\u0027])"},{"line_number":105,"context_line":"            self.port.refresh()"},{"line_number":106,"context_line":"            self.assertIsNone(self.port.extra.get(\u0027vif_port_id\u0027))"},{"line_number":107,"context_line":"            self.assertIsNone(self.port.internal_info.get(\u0027vif_port_id\u0027))"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"    def test_vif_detach_in_internal_info(self):"},{"line_number":110,"context_line":"        self.port.internal_info \u003d {\u0027vif_port_id\u0027: uuidutils.generate_uuid()}"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_bd27bfb4","line":107,"in_reply_to":"5a74a57a_15d0e752","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"409b583e400b0f073439f55979e1a4b8a84c1de0","unresolved":false,"context_lines":[{"line_number":123,"context_line":"        instance_info[\u0027nova_host_id\u0027] \u003d \u0027nova_host_id\u0027"},{"line_number":124,"context_line":"        self.node.instance_info \u003d instance_info"},{"line_number":125,"context_line":"        self.node.save()"},{"line_number":126,"context_line":"        extra \u003d {\u0027vif_port_id\u0027: \u0027foo\u0027}"},{"line_number":127,"context_line":"        utils.create_test_port(self.context, node_id\u003dself.node.id,"},{"line_number":128,"context_line":"                               address\u003d\u002752:54:00:cf:2d:33\u0027, extra\u003dextra,"},{"line_number":129,"context_line":"                               uuid\u003duuidutils.generate_uuid())"}],"source_content_type":"text/x-python","patch_set":36,"id":"1a6eadb0_12f539ca","line":126,"updated":"2016-12-20 17:36:18.000000000","message":"since we\u0027re deprecating this, it seems like we should be using internal_info, but I guess we can change this later when we stop supporting extra.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"}],"ironic/tests/unit/drivers/modules/network/test_neutron.py":[{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"35c76888c40057921b4d63e6a053fc81e7fe90fc","unresolved":false,"context_lines":[{"line_number":336,"context_line":"        }"},{"line_number":337,"context_line":"        port2_body \u003d copy.deepcopy(expected_body)"},{"line_number":338,"context_line":"        port2_body[\u0027port\u0027][\u0027binding:profile\u0027] \u003d {"},{"line_number":339,"context_line":"            \u0027local_link_information\u0027: [second_port.local_link_connection],"},{"line_number":340,"context_line":"        }"},{"line_number":341,"context_line":"        if is_client_id:"},{"line_number":342,"context_line":"            port1_body[\u0027port\u0027][\u0027extra_dhcp_opts\u0027] \u003d ("}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_a34ad9aa","line":339,"range":{"start_line":339,"start_character":73,"end_line":339,"end_character":74},"updated":"2016-11-29 21:33:32.000000000","message":"nit: appears this change is unrelated","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b3d21bc8613b08b9116ce3ab78cd95815d042e9","unresolved":false,"context_lines":[{"line_number":336,"context_line":"        }"},{"line_number":337,"context_line":"        port2_body \u003d copy.deepcopy(expected_body)"},{"line_number":338,"context_line":"        port2_body[\u0027port\u0027][\u0027binding:profile\u0027] \u003d {"},{"line_number":339,"context_line":"            \u0027local_link_information\u0027: [second_port.local_link_connection],"},{"line_number":340,"context_line":"        }"},{"line_number":341,"context_line":"        if is_client_id:"},{"line_number":342,"context_line":"            port1_body[\u0027port\u0027][\u0027extra_dhcp_opts\u0027] \u003d ("}],"source_content_type":"text/x-python","patch_set":26,"id":"5a74a57a_e4766dd7","line":339,"range":{"start_line":339,"start_character":73,"end_line":339,"end_character":74},"in_reply_to":"5a74a57a_a34ad9aa","updated":"2016-11-30 16:12:57.000000000","message":"Done","commit_id":"758c0d15b77f88c4484e8d7d08cdc54b32dc275b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"},{"line_number":132,"context_line":"            self.assertRaises("},{"line_number":133,"context_line":"                exception.NetworkError, self.interface.vif_detach,"},{"line_number":134,"context_line":"                task, \"fake_vif_id\")"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"    def test_init_incorrect_provisioning_net(self):"},{"line_number":137,"context_line":"        self.config(provisioning_network_uuid\u003dNone, group\u003d\u0027neutron\u0027)"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_9520774b","line":134,"updated":"2016-11-30 22:09:24.000000000","message":"I skimmed through these tests, after looking at test_flat.py.\n\nIt seems to me that it would be better if you moved these to a test_common.py. And in these test files, it would be sufflicient to have 4 tests, each mocking the appropriate method in common.VIFPortIDMixin, to show that they are being called.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        with task_manager.acquire(self.context, self.node.id) as task:"},{"line_number":132,"context_line":"            self.assertRaises("},{"line_number":133,"context_line":"                exception.NetworkError, self.interface.vif_detach,"},{"line_number":134,"context_line":"                task, \"fake_vif_id\")"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"    def test_init_incorrect_provisioning_net(self):"},{"line_number":137,"context_line":"        self.config(provisioning_network_uuid\u003dNone, group\u003d\u0027neutron\u0027)"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_4f4c32c8","line":134,"in_reply_to":"5a74a57a_9520774b","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"834abf73c8a8eee9e9617b2bab297e5c2adc87b5","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        self.port \u003d utils.create_test_port("},{"line_number":44,"context_line":"            self.context, node_id\u003dself.node.id,"},{"line_number":45,"context_line":"            address\u003d\u002752:54:00:cf:2d:32\u0027,"},{"line_number":46,"context_line":"            extra\u003d{\u0027vif_port_id\u0027: uuidutils.generate_uuid()})"},{"line_number":47,"context_line":"        self.neutron_port \u003d {\u0027id\u0027: \u0027132f871f-eaec-4fed-9475-0d54465e0f00\u0027,"},{"line_number":48,"context_line":"                             \u0027mac_address\u0027: \u002752:54:00:cf:2d:32\u0027}"},{"line_number":49,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_4e6e84ca","line":46,"updated":"2016-12-13 01:26:36.000000000","message":"Should we change this to internal_info\u003d... ? Or maybe it doesn\u0027t matter, I\u0027ve lost track of what we\u0027re trying to test here. We\u0027ll have to change this when we delete support for extra[\u0027vif_port_id\u0027] so it\u0027ll be done later anyway.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"85fa86a7405378166a5b4d080746e8866c9aedff","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        self.port \u003d utils.create_test_port("},{"line_number":44,"context_line":"            self.context, node_id\u003dself.node.id,"},{"line_number":45,"context_line":"            address\u003d\u002752:54:00:cf:2d:32\u0027,"},{"line_number":46,"context_line":"            extra\u003d{\u0027vif_port_id\u0027: uuidutils.generate_uuid()})"},{"line_number":47,"context_line":"        self.neutron_port \u003d {\u0027id\u0027: \u0027132f871f-eaec-4fed-9475-0d54465e0f00\u0027,"},{"line_number":48,"context_line":"                             \u0027mac_address\u0027: \u002752:54:00:cf:2d:32\u0027}"},{"line_number":49,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a6eadb0_26c1122f","line":46,"in_reply_to":"1a6eadb0_4e6e84ca","updated":"2016-12-14 16:16:42.000000000","message":"ditt as above.","commit_id":"9c1f62fde1a0e46fa9461b4f7e51c33809d580cd"}],"ironic/tests/unit/drivers/test_base.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":439,"context_line":"    def test_vif_list(self, mock_vif, mock_warn):"},{"line_number":440,"context_line":"        network \u003d TestNetwork()"},{"line_number":441,"context_line":"        network.vif_list(mock.MagicMock())"},{"line_number":442,"context_line":"        mock_vif.assert_called_once_with(mock.ANY)"},{"line_number":443,"context_line":"        self.assertTrue(mock_warn.called)"},{"line_number":444,"context_line":""},{"line_number":445,"context_line":"    @mock.patch.object(driver_base.LOG, \u0027warning\u0027, autospec\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_69b308ea","line":442,"updated":"2016-11-30 22:09:24.000000000","message":"the mock.ANY and the mock.MagicMock() above are/should be the same, right?","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":439,"context_line":"    def test_vif_list(self, mock_vif, mock_warn):"},{"line_number":440,"context_line":"        network \u003d TestNetwork()"},{"line_number":441,"context_line":"        network.vif_list(mock.MagicMock())"},{"line_number":442,"context_line":"        mock_vif.assert_called_once_with(mock.ANY)"},{"line_number":443,"context_line":"        self.assertTrue(mock_warn.called)"},{"line_number":444,"context_line":""},{"line_number":445,"context_line":"    @mock.patch.object(driver_base.LOG, \u0027warning\u0027, autospec\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_c13d58de","line":442,"in_reply_to":"5a74a57a_69b308ea","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":444,"context_line":""},{"line_number":445,"context_line":"    @mock.patch.object(driver_base.LOG, \u0027warning\u0027, autospec\u003dTrue)"},{"line_number":446,"context_line":"    @mock.patch.object(net_common.VIFPortIDMixin, \u0027vif_attach\u0027)"},{"line_number":447,"context_line":"    def test_vif_attach(self, mock_at, mock_warn):"},{"line_number":448,"context_line":"        network \u003d TestNetwork()"},{"line_number":449,"context_line":"        network.vif_attach(mock.MagicMock(), {\u0027id\u0027: \u0027fake\u0027})"},{"line_number":450,"context_line":"        mock_at.assert_called_once_with(mock.ANY, {\u0027id\u0027: \u0027fake\u0027})"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_c99fbc5d","line":447,"updated":"2016-11-30 22:09:24.000000000","message":"I think it isn\u0027t too much work to do s/mock_at/mock_attach/","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":444,"context_line":""},{"line_number":445,"context_line":"    @mock.patch.object(driver_base.LOG, \u0027warning\u0027, autospec\u003dTrue)"},{"line_number":446,"context_line":"    @mock.patch.object(net_common.VIFPortIDMixin, \u0027vif_attach\u0027)"},{"line_number":447,"context_line":"    def test_vif_attach(self, mock_at, mock_warn):"},{"line_number":448,"context_line":"        network \u003d TestNetwork()"},{"line_number":449,"context_line":"        network.vif_attach(mock.MagicMock(), {\u0027id\u0027: \u0027fake\u0027})"},{"line_number":450,"context_line":"        mock_at.assert_called_once_with(mock.ANY, {\u0027id\u0027: \u0027fake\u0027})"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_e128949c","line":447,"in_reply_to":"5a74a57a_c99fbc5d","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":452,"context_line":""},{"line_number":453,"context_line":"    @mock.patch.object(driver_base.LOG, \u0027warning\u0027, autospec\u003dTrue)"},{"line_number":454,"context_line":"    @mock.patch.object(net_common.VIFPortIDMixin, \u0027vif_detach\u0027)"},{"line_number":455,"context_line":"    def test_vif_detach(self, mock_de, mock_warn):"},{"line_number":456,"context_line":"        network \u003d TestNetwork()"},{"line_number":457,"context_line":"        network.vif_detach(mock.MagicMock(), \u0027fake-vif-id\u0027)"},{"line_number":458,"context_line":"        mock_de.assert_called_once_with(mock.ANY, \u0027fake-vif-id\u0027)"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_c976dc3d","line":455,"updated":"2016-11-30 22:09:24.000000000","message":"s/mock_de/mock_detach/","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":452,"context_line":""},{"line_number":453,"context_line":"    @mock.patch.object(driver_base.LOG, \u0027warning\u0027, autospec\u003dTrue)"},{"line_number":454,"context_line":"    @mock.patch.object(net_common.VIFPortIDMixin, \u0027vif_detach\u0027)"},{"line_number":455,"context_line":"    def test_vif_detach(self, mock_de, mock_warn):"},{"line_number":456,"context_line":"        network \u003d TestNetwork()"},{"line_number":457,"context_line":"        network.vif_detach(mock.MagicMock(), \u0027fake-vif-id\u0027)"},{"line_number":458,"context_line":"        mock_de.assert_called_once_with(mock.ANY, \u0027fake-vif-id\u0027)"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_a13a1ce5","line":455,"in_reply_to":"5a74a57a_c976dc3d","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":462,"context_line":"    @mock.patch.object(net_common.VIFPortIDMixin, \u0027port_changed\u0027)"},{"line_number":463,"context_line":"    def test_port_changed(self, mock_pc, mock_warn):"},{"line_number":464,"context_line":"        network \u003d TestNetwork()"},{"line_number":465,"context_line":"        port \u003d mock.MagicMock()"},{"line_number":466,"context_line":"        network.port_changed(mock.MagicMock(), port)"},{"line_number":467,"context_line":"        mock_pc.assert_called_once_with(mock.ANY, port)"},{"line_number":468,"context_line":"        self.assertTrue(mock_warn.called)"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_e91558e5","line":465,"updated":"2016-11-30 22:09:24.000000000","message":"you could have also done task \u003d mock... , and passed task as an argument below, so you could see the same task in mock_pc.assert_called_once_with().","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":462,"context_line":"    @mock.patch.object(net_common.VIFPortIDMixin, \u0027port_changed\u0027)"},{"line_number":463,"context_line":"    def test_port_changed(self, mock_pc, mock_warn):"},{"line_number":464,"context_line":"        network \u003d TestNetwork()"},{"line_number":465,"context_line":"        port \u003d mock.MagicMock()"},{"line_number":466,"context_line":"        network.port_changed(mock.MagicMock(), port)"},{"line_number":467,"context_line":"        mock_pc.assert_called_once_with(mock.ANY, port)"},{"line_number":468,"context_line":"        self.assertTrue(mock_warn.called)"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_212feca1","line":465,"in_reply_to":"5a74a57a_e91558e5","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"775c3e16452532aa08d4eb765b9e8c4eb3ee443b","unresolved":false,"context_lines":[{"line_number":465,"context_line":"        port \u003d mock.MagicMock()"},{"line_number":466,"context_line":"        network.port_changed(mock.MagicMock(), port)"},{"line_number":467,"context_line":"        mock_pc.assert_called_once_with(mock.ANY, port)"},{"line_number":468,"context_line":"        self.assertTrue(mock_warn.called)"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a74a57a_29e030cc","line":468,"updated":"2016-11-30 22:09:24.000000000","message":"One of these tests (or a separate test) should make at least two calls for the same method, and show that the warning was logged only once.","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"8b0a48c705c37e83b09e123a261b5f2ca352de3e","unresolved":false,"context_lines":[{"line_number":465,"context_line":"        port \u003d mock.MagicMock()"},{"line_number":466,"context_line":"        network.port_changed(mock.MagicMock(), port)"},{"line_number":467,"context_line":"        mock_pc.assert_called_once_with(mock.ANY, port)"},{"line_number":468,"context_line":"        self.assertTrue(mock_warn.called)"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a71b18c_334e5fc1","line":468,"in_reply_to":"5a74a57a_29e030cc","updated":"2016-12-06 11:43:59.000000000","message":"Done","commit_id":"aeb7bb4fdda36b6ba3253727505026c8e15eac7e"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d78b3c62efef0c0a11325c1dc8488e59de275f8f","unresolved":false,"context_lines":[{"line_number":440,"context_line":"        mock_task \u003d mock.MagicMock()"},{"line_number":441,"context_line":"        network \u003d TestNetwork()"},{"line_number":442,"context_line":"        network.vif_list(mock_task)"},{"line_number":443,"context_line":"        mock_vif.assert_called_once_with(mock_task)"},{"line_number":444,"context_line":"        # Test if the log is only called once even if we recreate a new"},{"line_number":445,"context_line":"        # NetworkInterface and call it again."},{"line_number":446,"context_line":"        # NOTE(sambetts): This must be done inside this test instead of a"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_059e5cb8","line":443,"updated":"2016-12-06 22:36:53.000000000","message":"you might want to do mock_warn.assert_called_once_with() here, to show that it was called here, and not below.","commit_id":"b511580c201844d971e1916391f50d7611525675"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"7f7673986a72d0259df82376d0bfecb77eb8700c","unresolved":false,"context_lines":[{"line_number":440,"context_line":"        mock_task \u003d mock.MagicMock()"},{"line_number":441,"context_line":"        network \u003d TestNetwork()"},{"line_number":442,"context_line":"        network.vif_list(mock_task)"},{"line_number":443,"context_line":"        mock_vif.assert_called_once_with(mock_task)"},{"line_number":444,"context_line":"        # Test if the log is only called once even if we recreate a new"},{"line_number":445,"context_line":"        # NetworkInterface and call it again."},{"line_number":446,"context_line":"        # NOTE(sambetts): This must be done inside this test instead of a"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a71b18c_fb3d2abc","line":443,"in_reply_to":"3a71b18c_059e5cb8","updated":"2016-12-08 14:18:02.000000000","message":"Done","commit_id":"b511580c201844d971e1916391f50d7611525675"}],"ironic_tempest_plugin/tests/api/admin/test_nodes.py":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4febecf11f88997f8ac8c417c742b6f6d44ae0a7","unresolved":false,"context_lines":[{"line_number":170,"context_line":""},{"line_number":171,"context_line":"    @test.idempotent_id(\u0027a3d319d0-cacb-4e55-a3dc-3fa8b74880f1\u0027)"},{"line_number":172,"context_line":"    def test_vifs(self):"},{"line_number":173,"context_line":"        self.useFixture(api_microversion_fixture.APIMicroversionFixture(\u00271.26\u0027))"},{"line_number":174,"context_line":"        _, self.port \u003d self.create_port(self.node[\u0027uuid\u0027],"},{"line_number":175,"context_line":"                                        data_utils.rand_mac_address())"},{"line_number":176,"context_line":"        self.client.vif_attach(self.node[\u0027uuid\u0027], \u0027test-vif\u0027)"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_5fba7524","line":173,"updated":"2016-11-24 12:15:19.000000000","message":"Missing the api_microversion_fixture import, this breaks tempest tests. Also, line too long here.","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"5dcdc280cf5f15a584d3b13c742e45111900e633","unresolved":false,"context_lines":[{"line_number":170,"context_line":""},{"line_number":171,"context_line":"    @test.idempotent_id(\u0027a3d319d0-cacb-4e55-a3dc-3fa8b74880f1\u0027)"},{"line_number":172,"context_line":"    def test_vifs(self):"},{"line_number":173,"context_line":"        self.useFixture(api_microversion_fixture.APIMicroversionFixture(\u00271.26\u0027))"},{"line_number":174,"context_line":"        _, self.port \u003d self.create_port(self.node[\u0027uuid\u0027],"},{"line_number":175,"context_line":"                                        data_utils.rand_mac_address())"},{"line_number":176,"context_line":"        self.client.vif_attach(self.node[\u0027uuid\u0027], \u0027test-vif\u0027)"}],"source_content_type":"text/x-python","patch_set":24,"id":"5a74a57a_7c534d17","line":173,"in_reply_to":"5a74a57a_5fba7524","updated":"2016-11-28 15:35:02.000000000","message":"Done","commit_id":"4cdc3ad5766b3b628344ef2ba4b9d38467d5b768"}],"releasenotes/notes/deprecate-dhcp-update-mac-address-f12a4959432c8e20.yaml":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"51eca6e70a633f2f0f6c41b6cda9d052cfc1638f","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    Added new methods to network interfaces, they will become"},{"line_number":5,"context_line":"    mandatory in Pike release:"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"    * ``vif_list`` - List attached VIF IDs for a node"}],"source_content_type":"text/x-yaml","patch_set":30,"id":"1a6eadb0_06becc64","line":4,"updated":"2016-12-14 19:25:36.000000000","message":"s/Added/Adds/","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"30d29ab524cdb31ea0811e48102587b652540f5d","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    Added new methods to network interfaces, they will become"},{"line_number":5,"context_line":"    mandatory in Pike release:"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"    * ``vif_list`` - List attached VIF IDs for a node"}],"source_content_type":"text/x-yaml","patch_set":30,"id":"1a6eadb0_742d4ffd","line":4,"in_reply_to":"1a6eadb0_06becc64","updated":"2016-12-15 12:04:34.000000000","message":"Done","commit_id":"f325f77c3a9e4118e12c2df8c2c7f7a4fdf15af8"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"5fa256771712f2f24abaa3a48ed8a7ce56a5a363","unresolved":false,"context_lines":[{"line_number":18,"context_line":"    ``update_mac_address`` method in DHCP providers is"},{"line_number":19,"context_line":"    deprecated and will be removed in the Pike release."},{"line_number":20,"context_line":"    The logic should be moved to a custom network"},{"line_number":21,"context_line":"    interface\u0027s ``port_changed`` and ``portgroup_changed``."},{"line_number":22,"context_line":"fixes:"},{"line_number":23,"context_line":"  - |"},{"line_number":24,"context_line":"    An issue when pre-created tenant port was automatically"}],"source_content_type":"text/x-yaml","patch_set":36,"id":"da4df55a_823be4ea","line":21,"updated":"2016-12-22 14:40:50.000000000","message":"nit: s/``./`` methods.\n\nI feel like operators that have implemented some of their network switching code in dhcp are going to feel a little bit confused by this deprecation note.  It would likely be good to indicate that the new methods were newly added in the deprecation note since they can be rendered in different areas, or someone may have a focus on one specific area and not digest the entire release note.","commit_id":"b16631a3d5f10044499f06d186a56a25233ed017"}]}
