)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":7715,"name":"Hirofumi Ichihara","email":"ichihara.hirofumi@gmail.com","username":"Hirofumi-Ichihara"},"change_message_id":"5d08008f889180c825ecb0285b43e3ca803648b6","unresolved":false,"context_lines":[{"line_number":9,"context_line":"When a port is manually created with an invalid mac address like"},{"line_number":10,"context_line":"\u002700:00:00:00:00:00\u0027 and associated to neutron router, we see an"},{"line_number":11,"context_line":"exception in L3-agent logs. Since we do not have any valid use-case"},{"line_number":12,"context_line":"to have a port with a mac_address of all zeros, this patch disables"},{"line_number":13,"context_line":"the corresponding port creation/updation request."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"DocImpact"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"3a50d1a3_cd893528","line":12,"updated":"2015-07-21 13:53:03.000000000","message":"nit: Can you update since current patch checks broadcast address as well?","commit_id":"dc5f398dc588474b954e211560b85e4522a2d46b"},{"author":{"_account_id":11682,"name":"Ryan Moats","email":"rmoats@us.ibm.com","username":"regXboi"},"change_message_id":"76381266999d8e55b4b733d294fac5f623f0cea0","unresolved":false,"context_lines":[{"line_number":9,"context_line":"When a port is manually created with an invalid mac address like"},{"line_number":10,"context_line":"\u002700:00:00:00:00:00\u0027 and associated to neutron router, we see an"},{"line_number":11,"context_line":"exception in L3-agent logs. Since we do not have any valid use-case"},{"line_number":12,"context_line":"to have a port with a mac_address of all zeros, this patch disables"},{"line_number":13,"context_line":"the corresponding port creation/updation request."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"DocImpact"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"3a50d1a3_889191f3","line":12,"in_reply_to":"3a50d1a3_33ccb369","updated":"2015-07-22 16:28:52.000000000","message":"since the bug addresses all zeros only, I think adding a message here that broadcast mac has also been included as an invalid mac is reasonable.","commit_id":"dc5f398dc588474b954e211560b85e4522a2d46b"},{"author":{"_account_id":10257,"name":"Sridhar Gaddam","email":"sgaddam@redhat.com","username":"sridhargaddam"},"change_message_id":"65eb1244cce4c85d43f0d3a8b8daf7935189169b","unresolved":false,"context_lines":[{"line_number":9,"context_line":"When a port is manually created with an invalid mac address like"},{"line_number":10,"context_line":"\u002700:00:00:00:00:00\u0027 and associated to neutron router, we see an"},{"line_number":11,"context_line":"exception in L3-agent logs. Since we do not have any valid use-case"},{"line_number":12,"context_line":"to have a port with a mac_address of all zeros, this patch disables"},{"line_number":13,"context_line":"the corresponding port creation/updation request."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"DocImpact"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"3a50d1a3_4a3a7d9a","line":12,"in_reply_to":"3a50d1a3_889191f3","updated":"2015-07-23 07:25:34.000000000","message":"Done","commit_id":"dc5f398dc588474b954e211560b85e4522a2d46b"},{"author":{"_account_id":10257,"name":"Sridhar Gaddam","email":"sgaddam@redhat.com","username":"sridhargaddam"},"change_message_id":"71b4691f59d661e07e4d1d4ffaef34440b7a9eef","unresolved":false,"context_lines":[{"line_number":9,"context_line":"When a port is manually created with an invalid mac address like"},{"line_number":10,"context_line":"\u002700:00:00:00:00:00\u0027 and associated to neutron router, we see an"},{"line_number":11,"context_line":"exception in L3-agent logs. Since we do not have any valid use-case"},{"line_number":12,"context_line":"to have a port with a mac_address of all zeros, this patch disables"},{"line_number":13,"context_line":"the corresponding port creation/updation request."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"DocImpact"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"3a50d1a3_33ccb369","line":12,"in_reply_to":"3a50d1a3_cd893528","updated":"2015-07-21 15:11:40.000000000","message":"@Hirofumi, as this patch is addressing the Bug#1472243, I\u0027ve used the example of \u002700:00:00:00:00:00\u0027. Validation against \u0027FF:FF:FF:FF:FF\u0027 was also included based on the review comments.\n\nI\u0027m fine to update the commit message if other reviewers feel the same. \nThanks for the review.","commit_id":"dc5f398dc588474b954e211560b85e4522a2d46b"}],"neutron/api/v2/attributes.py":[{"author":{"_account_id":4656,"name":"Sean M. Collins","email":"sean@coreitpro.com","username":"scollins"},"change_message_id":"608d0a89d91d86feaa3bf1320edbf0d8d4d11898","unresolved":false,"context_lines":[{"line_number":175,"context_line":"        for invalid_mac_addr in constants.INVALID_MAC_ADDRESSES:"},{"line_number":176,"context_line":"            if netaddr.EUI(data) \u003d\u003d netaddr.EUI(invalid_mac_addr):"},{"line_number":177,"context_line":"                valid_mac \u003d False"},{"line_number":178,"context_line":"                break"},{"line_number":179,"context_line":"    # TODO(arosen): The code in this file should be refactored"},{"line_number":180,"context_line":"    # so it catches the correct exceptions. _validate_no_whitespace"},{"line_number":181,"context_line":"    # raises AttributeError if data is None."}],"source_content_type":"text/x-python","patch_set":3,"id":"3a50d1a3_224f316c","line":178,"updated":"2015-07-22 19:47:26.000000000","message":"This can be replaced with:\n\n\nvalid_mac \u003d not netaddr.EUI(ourmac) in map(lambda x: netaddr.EUI(x), constants.INVALID_MAC_ADDRESSES)","commit_id":"dc5f398dc588474b954e211560b85e4522a2d46b"},{"author":{"_account_id":10257,"name":"Sridhar Gaddam","email":"sgaddam@redhat.com","username":"sridhargaddam"},"change_message_id":"65eb1244cce4c85d43f0d3a8b8daf7935189169b","unresolved":false,"context_lines":[{"line_number":175,"context_line":"        for invalid_mac_addr in constants.INVALID_MAC_ADDRESSES:"},{"line_number":176,"context_line":"            if netaddr.EUI(data) \u003d\u003d netaddr.EUI(invalid_mac_addr):"},{"line_number":177,"context_line":"                valid_mac \u003d False"},{"line_number":178,"context_line":"                break"},{"line_number":179,"context_line":"    # TODO(arosen): The code in this file should be refactored"},{"line_number":180,"context_line":"    # so it catches the correct exceptions. _validate_no_whitespace"},{"line_number":181,"context_line":"    # raises AttributeError if data is None."}],"source_content_type":"text/x-python","patch_set":3,"id":"3a50d1a3_6a3df98d","line":178,"in_reply_to":"3a50d1a3_224f316c","updated":"2015-07-23 07:25:34.000000000","message":"Done","commit_id":"dc5f398dc588474b954e211560b85e4522a2d46b"}],"neutron/common/constants.py":[{"author":{"_account_id":105,"name":"Kyle Mestery","email":"mestery@mestery.com","username":"mestery"},"change_message_id":"f582a45f8af22c7ae7be80e3d64c88f1b5c754a5","unresolved":false,"context_lines":[{"line_number":72,"context_line":"IPv4_BITS \u003d 32"},{"line_number":73,"context_line":"IPv6_BITS \u003d 128"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"INVALID_MAC_ADDRESS \u003d 0"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"IPv4_ANY \u003d \u00270.0.0.0/0\u0027"},{"line_number":78,"context_line":"IPv6_ANY \u003d \u0027::/0\u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a41bdd9_83428366","line":75,"updated":"2015-07-16 14:01:34.000000000","message":"No-action-necessary: It seems odd to have an INVALID _MAC_ADDRESS as a literal zero rather than having it formed as a valid MAC address.","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"d9a7539f95be4bfae61137974f7908b186208ddc","unresolved":false,"context_lines":[{"line_number":72,"context_line":"IPv4_BITS \u003d 32"},{"line_number":73,"context_line":"IPv6_BITS \u003d 128"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"INVALID_MAC_ADDRESS \u003d 0"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"IPv4_ANY \u003d \u00270.0.0.0/0\u0027"},{"line_number":78,"context_line":"IPv6_ANY \u003d \u0027::/0\u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a50d1a3_f6c6a015","line":75,"updated":"2015-07-19 09:18:56.000000000","message":"When I see mac address i expect the standard all zeros format, having an integer is unintuitive. I would prefer the EUI method you described since you have to cast in the comparison anyway.\n\nAlso, this should probably be a list and be called INVALID_MAC_ADDRESSES unless there is only one mac address we intend to reject.","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"},{"author":{"_account_id":10257,"name":"Sridhar Gaddam","email":"sgaddam@redhat.com","username":"sridhargaddam"},"change_message_id":"a13e5ced619218da3f4a1c780fbcc5871bf88330","unresolved":false,"context_lines":[{"line_number":72,"context_line":"IPv4_BITS \u003d 32"},{"line_number":73,"context_line":"IPv6_BITS \u003d 128"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"INVALID_MAC_ADDRESS \u003d 0"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"IPv4_ANY \u003d \u00270.0.0.0/0\u0027"},{"line_number":78,"context_line":"IPv6_ANY \u003d \u0027::/0\u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a41bdd9_df859cad","line":75,"in_reply_to":"9a41bdd9_57bae2c1","updated":"2015-07-17 03:12:09.000000000","message":"Since an All Zeros MAC address can be framed in multiple ways (i.e., 0:0:0:0:0:0, 00:00:00:00:00:00, 0 etc), I\u0027ve used it this way. \nThe other option is to define it as \"00:00:00:00:00:00\" and while comparing use EUI(INVALID_MAC_ADDRESS) instead of comparing it as an int.","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"20189c0e590af550150cb487cb0dd0e83e856a78","unresolved":false,"context_lines":[{"line_number":72,"context_line":"IPv4_BITS \u003d 32"},{"line_number":73,"context_line":"IPv6_BITS \u003d 128"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"INVALID_MAC_ADDRESS \u003d 0"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"IPv4_ANY \u003d \u00270.0.0.0/0\u0027"},{"line_number":78,"context_line":"IPv6_ANY \u003d \u0027::/0\u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a41bdd9_57bae2c1","line":75,"in_reply_to":"9a41bdd9_83428366","updated":"2015-07-16 19:55:56.000000000","message":"+1, it\u0027s really confusing","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"}],"neutron/db/db_base_plugin_v2.py":[{"author":{"_account_id":14605,"name":"vikram.choudhary","email":"vikschw@gmail.com","username":"vikram.choudhary"},"change_message_id":"c013db117980379ca4c66bf53883536599bf0025","unresolved":false,"context_lines":[{"line_number":766,"context_line":"            context.session.delete(subnetpool)"},{"line_number":767,"context_line":""},{"line_number":768,"context_line":"    def _check_mac_addr_update(self, context, port, new_mac, device_owner):"},{"line_number":769,"context_line":"        if int(netaddr.EUI(new_mac)) \u003d\u003d 0:"},{"line_number":770,"context_line":"            raise n_exc.InvalidMacAddress(mac\u003dnew_mac)"},{"line_number":771,"context_line":""},{"line_number":772,"context_line":"        if (device_owner and device_owner.startswith(\u0027network:\u0027)):"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a41bdd9_2c2c7f01","line":769,"updated":"2015-07-13 14:06:37.000000000","message":"How about using a macro which states what 0 is meant for, probably INVALID_MAC or something.","commit_id":"748a5fa0ca3e1a5226391ab6c3038b3c211055d8"},{"author":{"_account_id":4656,"name":"Sean M. Collins","email":"sean@coreitpro.com","username":"scollins"},"change_message_id":"901111b455370ff08017472338c73763228e0845","unresolved":false,"context_lines":[{"line_number":766,"context_line":"            context.session.delete(subnetpool)"},{"line_number":767,"context_line":""},{"line_number":768,"context_line":"    def _check_mac_addr_update(self, context, port, new_mac, device_owner):"},{"line_number":769,"context_line":"        if int(netaddr.EUI(new_mac)) \u003d\u003d 0:"},{"line_number":770,"context_line":"            raise n_exc.InvalidMacAddress(mac\u003dnew_mac)"},{"line_number":771,"context_line":""},{"line_number":772,"context_line":"        if (device_owner and device_owner.startswith(\u0027network:\u0027)):"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a41bdd9_8ce10b9d","line":769,"in_reply_to":"9a41bdd9_2c2c7f01","updated":"2015-07-13 14:10:52.000000000","message":"Agree - would be useful for clarity - since we also may in the future want to exapand INVALID_MAC to cover other cases","commit_id":"748a5fa0ca3e1a5226391ab6c3038b3c211055d8"},{"author":{"_account_id":10257,"name":"Sridhar Gaddam","email":"sgaddam@redhat.com","username":"sridhargaddam"},"change_message_id":"b1822bff6240a81dd61e397dae44bdc2b5cfdad5","unresolved":false,"context_lines":[{"line_number":766,"context_line":"            context.session.delete(subnetpool)"},{"line_number":767,"context_line":""},{"line_number":768,"context_line":"    def _check_mac_addr_update(self, context, port, new_mac, device_owner):"},{"line_number":769,"context_line":"        if int(netaddr.EUI(new_mac)) \u003d\u003d 0:"},{"line_number":770,"context_line":"            raise n_exc.InvalidMacAddress(mac\u003dnew_mac)"},{"line_number":771,"context_line":""},{"line_number":772,"context_line":"        if (device_owner and device_owner.startswith(\u0027network:\u0027)):"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a41bdd9_18f3e79f","line":769,"in_reply_to":"9a41bdd9_58de4f6e","updated":"2015-07-13 18:30:54.000000000","message":"Thanks @all for the review. I\u0027ll update the patch with the macro.","commit_id":"748a5fa0ca3e1a5226391ab6c3038b3c211055d8"},{"author":{"_account_id":11682,"name":"Ryan Moats","email":"rmoats@us.ibm.com","username":"regXboi"},"change_message_id":"72d60e798cee08dd519dfd6c707771e642bde8ad","unresolved":false,"context_lines":[{"line_number":766,"context_line":"            context.session.delete(subnetpool)"},{"line_number":767,"context_line":""},{"line_number":768,"context_line":"    def _check_mac_addr_update(self, context, port, new_mac, device_owner):"},{"line_number":769,"context_line":"        if int(netaddr.EUI(new_mac)) \u003d\u003d 0:"},{"line_number":770,"context_line":"            raise n_exc.InvalidMacAddress(mac\u003dnew_mac)"},{"line_number":771,"context_line":""},{"line_number":772,"context_line":"        if (device_owner and device_owner.startswith(\u0027network:\u0027)):"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a41bdd9_f90c1296","line":769,"in_reply_to":"9a41bdd9_8ce10b9d","updated":"2015-07-13 15:09:59.000000000","message":"+1 to these comments - pep8/tox probably need to be augmented to whine about \"magic numbers\"","commit_id":"748a5fa0ca3e1a5226391ab6c3038b3c211055d8"},{"author":{"_account_id":14605,"name":"vikram.choudhary","email":"vikschw@gmail.com","username":"vikram.choudhary"},"change_message_id":"88c1154600643f2daa9f524074c69365ba9c1988","unresolved":false,"context_lines":[{"line_number":766,"context_line":"            context.session.delete(subnetpool)"},{"line_number":767,"context_line":""},{"line_number":768,"context_line":"    def _check_mac_addr_update(self, context, port, new_mac, device_owner):"},{"line_number":769,"context_line":"        if int(netaddr.EUI(new_mac)) \u003d\u003d 0:"},{"line_number":770,"context_line":"            raise n_exc.InvalidMacAddress(mac\u003dnew_mac)"},{"line_number":771,"context_line":""},{"line_number":772,"context_line":"        if (device_owner and device_owner.startswith(\u0027network:\u0027)):"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a41bdd9_58de4f6e","line":769,"in_reply_to":"9a41bdd9_f90c1296","updated":"2015-07-13 18:17:25.000000000","message":"@Ryan: +1 :-)","commit_id":"748a5fa0ca3e1a5226391ab6c3038b3c211055d8"},{"author":{"_account_id":17096,"name":"Aditi Rajagopal","email":"arajagopal@us.ibm.com","username":"aditirajagopal"},"change_message_id":"1dffa15a7ab19ef519017451082d0121b8922d83","unresolved":false,"context_lines":[{"line_number":834,"context_line":"                db_port \u003d self._create_port(context, network_id, port_data)"},{"line_number":835,"context_line":"                p[\u0027mac_address\u0027] \u003d db_port[\u0027mac_address\u0027]"},{"line_number":836,"context_line":"            else:"},{"line_number":837,"context_line":"                if int(netaddr.EUI(p[\u0027mac_address\u0027])) \u003d\u003d 0:"},{"line_number":838,"context_line":"                    raise n_exc.InvalidMacAddress(mac\u003dp[\u0027mac_address\u0027])"},{"line_number":839,"context_line":""},{"line_number":840,"context_line":"                db_port \u003d self._create_port_with_mac("}],"source_content_type":"text/x-python","patch_set":1,"id":"9a41bdd9_ac996570","line":837,"updated":"2015-07-13 16:55:15.000000000","message":"nit: make sure you make the appropriate changes here too","commit_id":"748a5fa0ca3e1a5226391ab6c3038b3c211055d8"},{"author":{"_account_id":105,"name":"Kyle Mestery","email":"mestery@mestery.com","username":"mestery"},"change_message_id":"f582a45f8af22c7ae7be80e3d64c88f1b5c754a5","unresolved":false,"context_lines":[{"line_number":766,"context_line":"            context.session.delete(subnetpool)"},{"line_number":767,"context_line":""},{"line_number":768,"context_line":"    def _check_mac_addr_update(self, context, port, new_mac, device_owner):"},{"line_number":769,"context_line":"        if int(netaddr.EUI(new_mac)) \u003d\u003d constants.INVALID_MAC_ADDRESS:"},{"line_number":770,"context_line":"            raise n_exc.InvalidMacAddress(mac\u003dnew_mac)"},{"line_number":771,"context_line":""},{"line_number":772,"context_line":"        if (device_owner and device_owner.startswith(\u0027network:\u0027)):"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a41bdd9_4328fb99","line":769,"updated":"2015-07-16 14:01:34.000000000","message":"No-action-necessary: Following from my comment on how INVALID_MAC_ADDRESS is defined: But it makes the check for validity pretty nice. :)","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"20189c0e590af550150cb487cb0dd0e83e856a78","unresolved":false,"context_lines":[{"line_number":834,"context_line":"                db_port \u003d self._create_port(context, network_id, port_data)"},{"line_number":835,"context_line":"                p[\u0027mac_address\u0027] \u003d db_port[\u0027mac_address\u0027]"},{"line_number":836,"context_line":"            else:"},{"line_number":837,"context_line":"                if (int(netaddr.EUI(p[\u0027mac_address\u0027])) \u003d\u003d"},{"line_number":838,"context_line":"                    constants.INVALID_MAC_ADDRESS):"},{"line_number":839,"context_line":"                    raise n_exc.InvalidMacAddress(mac\u003dp[\u0027mac_address\u0027])"},{"line_number":840,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9a41bdd9_f758d68c","line":837,"updated":"2015-07-16 19:55:56.000000000","message":"Why performing such check in db transaction?","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"},{"author":{"_account_id":10257,"name":"Sridhar Gaddam","email":"sgaddam@redhat.com","username":"sridhargaddam"},"change_message_id":"6dec9d06b9cb603d8ae25818cb7c329fad309c0d","unresolved":false,"context_lines":[{"line_number":834,"context_line":"                db_port \u003d self._create_port(context, network_id, port_data)"},{"line_number":835,"context_line":"                p[\u0027mac_address\u0027] \u003d db_port[\u0027mac_address\u0027]"},{"line_number":836,"context_line":"            else:"},{"line_number":837,"context_line":"                if (int(netaddr.EUI(p[\u0027mac_address\u0027])) \u003d\u003d"},{"line_number":838,"context_line":"                    constants.INVALID_MAC_ADDRESS):"},{"line_number":839,"context_line":"                    raise n_exc.InvalidMacAddress(mac\u003dp[\u0027mac_address\u0027])"},{"line_number":840,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a50d1a3_6e1706a4","line":837,"in_reply_to":"3a50d1a3_56e2f4a0","updated":"2015-07-20 10:12:39.000000000","message":"Sure @Kevin, thanks I\u0027ll update the patch.","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"d9a7539f95be4bfae61137974f7908b186208ddc","unresolved":false,"context_lines":[{"line_number":834,"context_line":"                db_port \u003d self._create_port(context, network_id, port_data)"},{"line_number":835,"context_line":"                p[\u0027mac_address\u0027] \u003d db_port[\u0027mac_address\u0027]"},{"line_number":836,"context_line":"            else:"},{"line_number":837,"context_line":"                if (int(netaddr.EUI(p[\u0027mac_address\u0027])) \u003d\u003d"},{"line_number":838,"context_line":"                    constants.INVALID_MAC_ADDRESS):"},{"line_number":839,"context_line":"                    raise n_exc.InvalidMacAddress(mac\u003dp[\u0027mac_address\u0027])"},{"line_number":840,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a50d1a3_56e2f4a0","line":837,"in_reply_to":"9a41bdd9_dbba8f0a","updated":"2015-07-19 09:18:56.000000000","message":"this should be done right at the API layer since it doesn\u0027t require context or rely on other attributes.\n\nhttps://github.com/openstack/neutron/blob/215217feed3929487359a6eaeedbf03f3be1aeb6/neutron/api/v2/attributes.py#L168-L179\n\nthat will handle any user provided input","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"},{"author":{"_account_id":10257,"name":"Sridhar Gaddam","email":"sgaddam@redhat.com","username":"sridhargaddam"},"change_message_id":"a13e5ced619218da3f4a1c780fbcc5871bf88330","unresolved":false,"context_lines":[{"line_number":834,"context_line":"                db_port \u003d self._create_port(context, network_id, port_data)"},{"line_number":835,"context_line":"                p[\u0027mac_address\u0027] \u003d db_port[\u0027mac_address\u0027]"},{"line_number":836,"context_line":"            else:"},{"line_number":837,"context_line":"                if (int(netaddr.EUI(p[\u0027mac_address\u0027])) \u003d\u003d"},{"line_number":838,"context_line":"                    constants.INVALID_MAC_ADDRESS):"},{"line_number":839,"context_line":"                    raise n_exc.InvalidMacAddress(mac\u003dp[\u0027mac_address\u0027])"},{"line_number":840,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9a41bdd9_dbba8f0a","line":837,"in_reply_to":"9a41bdd9_f758d68c","updated":"2015-07-17 03:12:09.000000000","message":"As we already have some checks to verify that port[\u0027mac_address\u0027] attribute is set, I\u0027ve added this validation here. Do you prefer that I move this outside the transaction?\n\nIf so, since we can do the validation at various places, is it ok if we have it in the same  API (i.e., create_port, update_port but outside transaction) or some other file?","commit_id":"33542d3d2c59b816033e67f670b3c2f037e1af19"}]}
