)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"31961f569c44964ca87986ac350384c23487f8c6","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Mitigate restriction for fixed ips per dhcp port"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"When number of dhcp port excess max_fixed_ips_per_port, a dhcp resync"},{"line_number":10,"context_line":"will be triggered."},{"line_number":11,"context_line":"The bug report stated how simply this issue can be triggered."},{"line_number":12,"context_line":"However, it was considered that, because dhcp port is not a tenant port,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"9a1a9d01_f7c5f33c","line":9,"updated":"2015-10-02 22:54:55.000000000","message":"This should be exceed.\n\nI am having a tough time wrapping my head around this patch. Can you state clearly what\u0027s the strategy of your fix? Btw, some tips and pointers on writing good patches:\n\nhttp://docs.openstack.org/developer/neutron/devref/effective_neutron.html","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"0b816e43d2b049fee30affba1f2d840beef78920","unresolved":false,"context_lines":[{"line_number":14,"context_line":""},{"line_number":15,"context_line":"Change-Id: Iaa9ed6949383ba6a7ce0b3ffd9dcced663126317"},{"line_number":16,"context_line":"Co-authored-by: NGUYEN TUONG THANH \u003cthanhnt@vn.fujitsu.com\u003e"},{"line_number":17,"context_line":"Closes-Bug: #1427015"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"9a1a9d01_1c99ac6e","line":17,"updated":"2015-10-02 22:14:26.000000000","message":"this bug was a duplicate of #1179713, which was filed a long time before. Please consider using the latter instead.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"eb8d04940dea88dfc5f8b3de8c5821fc47d8a37a","unresolved":false,"context_lines":[{"line_number":14,"context_line":""},{"line_number":15,"context_line":"Change-Id: Iaa9ed6949383ba6a7ce0b3ffd9dcced663126317"},{"line_number":16,"context_line":"Co-authored-by: NGUYEN TUONG THANH \u003cthanhnt@vn.fujitsu.com\u003e"},{"line_number":17,"context_line":"Closes-Bug: #1427015"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"3a29b11f_75e270a1","line":17,"in_reply_to":"9a1a9d01_1c99ac6e","updated":"2015-10-20 02:22:19.000000000","message":"Hello @Armando Migliaccio,\n\nSure. I will update it. Thanks","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":17776,"name":"Reedip","email":"reedip.banerjee@gmail.com","username":"Reedip"},"change_message_id":"fb618d49f5a55c71bf58024192c473d77d296b2f","unresolved":false,"context_lines":[{"line_number":9,"context_line":"When number of dhcp port excess max_fixed_ips_per_port, a dhcp resync"},{"line_number":10,"context_line":"will be triggered."},{"line_number":11,"context_line":"The bug report stated how simply this issue can be triggered."},{"line_number":12,"context_line":"Moreover, \"max_fixed_ips_per_port\" value should be used for non-DHCP port only"},{"line_number":13,"context_line":"and with DHCP port, the number of fixed ips per port doesn\u0027t exceed the number"},{"line_number":14,"context_line":"of subnets on the network that it\u0027s assigned to."},{"line_number":15,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":16,"id":"fa80f949_5f45e6b0","line":12,"updated":"2015-11-05 05:24:37.000000000","message":"Seems longer than the restriction of 72 characters in the commit body.\nPlease re-indent the same.","commit_id":"97e8cec578ed7d0e5a9f58f038c1afdb7b703964"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"f9f9b9d034c7bff243a67cf2e56aa0ffb0ec15a5","unresolved":false,"context_lines":[{"line_number":9,"context_line":"When number of dhcp port excess max_fixed_ips_per_port, a dhcp resync"},{"line_number":10,"context_line":"will be triggered."},{"line_number":11,"context_line":"The bug report stated how simply this issue can be triggered."},{"line_number":12,"context_line":"Moreover, \"max_fixed_ips_per_port\" value should be used for non-DHCP port only"},{"line_number":13,"context_line":"and with DHCP port, the number of fixed ips per port doesn\u0027t exceed the number"},{"line_number":14,"context_line":"of subnets on the network that it\u0027s assigned to."},{"line_number":15,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":16,"id":"fa80f949_9180f6c1","line":12,"in_reply_to":"fa80f949_5f45e6b0","updated":"2015-11-06 01:58:17.000000000","message":"Hello Reedip, thanks for your time and reviewing. I will update it soon.","commit_id":"97e8cec578ed7d0e5a9f58f038c1afdb7b703964"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"0f3d6bb32f892e3406407b4f8529aa760daa8765","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Mitigate restriction for fixed ips per dhcp port"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"When number of dhcp port excess max_fixed_ips_per_port, a dhcp resync"},{"line_number":10,"context_line":"will be triggered."},{"line_number":11,"context_line":"The bug report stated how simply this issue can be triggered."},{"line_number":12,"context_line":"Moreover, \"max_fixed_ips_per_port\" value should be used for non-DHCP"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":19,"id":"da85f559_e5c9a279","line":9,"updated":"2015-11-10 08:44:16.000000000","message":"excess \u003d\u003e exceeds","commit_id":"58d5328062d47b74888a0eba578e52b3e05af630"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"ac9630e477b959be56de64ab4231b8c8ca78e317","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Mitigate restriction for fixed ips per dhcp port"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"When number of dhcp port excess max_fixed_ips_per_port, a dhcp resync"},{"line_number":10,"context_line":"will be triggered."},{"line_number":11,"context_line":"The bug report stated how simply this issue can be triggered."},{"line_number":12,"context_line":"Moreover, \"max_fixed_ips_per_port\" value should be used for non-DHCP"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":19,"id":"da85f559_2e86a2b9","line":9,"in_reply_to":"da85f559_e5c9a279","updated":"2015-11-10 11:26:42.000000000","message":"Done","commit_id":"58d5328062d47b74888a0eba578e52b3e05af630"}],"neutron/agent/dhcp/agent.py":[{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"82d5a5a06602877193d613e9b3a7b40ede23830c","unresolved":false,"context_lines":[{"line_number":263,"context_line":""},{"line_number":264,"context_line":"        if len(network[\u0027subnets\u0027]) \u003e cfg.CONF.max_fixed_ips_per_port:"},{"line_number":265,"context_line":"            raise RuntimeError(_(\"Number of created subnets excess the \""},{"line_number":266,"context_line":"                                 \"configuration of max_fixed_ips_per_port\"))"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"        old_cidrs \u003d set(s.cidr for s in old_network.subnets if s.enable_dhcp)"},{"line_number":269,"context_line":"        new_cidrs \u003d set(s.cidr for s in network.subnets if s.enable_dhcp)"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba7be1f8_1f5082d3","line":266,"updated":"2015-03-02 03:43:16.000000000","message":"1.shouldn\u0027t we differentiate the dhcp and no dhcp enabled subnets?\n2.we should just error log something here since if we raise an error here, the whole dhcp agent will resync for ever (if I am right). This lead to a very Dos problem. The bad guy could use this to attach the dhcp agents.","commit_id":"5439f35b166ad740d9262d5419a037b2e8e1c2e0"},{"author":{"_account_id":14039,"name":"watanabe isao","email":"watanabe.isao.openstack@gmail.com","username":"watanabe.isao"},"change_message_id":"2d9026fd3b8db5a9b830ec77e9fe0b58fb79a091","unresolved":false,"context_lines":[{"line_number":263,"context_line":""},{"line_number":264,"context_line":"        if len(network[\u0027subnets\u0027]) \u003e cfg.CONF.max_fixed_ips_per_port:"},{"line_number":265,"context_line":"            raise RuntimeError(_(\"Number of created subnets excess the \""},{"line_number":266,"context_line":"                                 \"configuration of max_fixed_ips_per_port\"))"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"        old_cidrs \u003d set(s.cidr for s in old_network.subnets if s.enable_dhcp)"},{"line_number":269,"context_line":"        new_cidrs \u003d set(s.cidr for s in network.subnets if s.enable_dhcp)"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a80dd14_559df064","line":266,"in_reply_to":"ba7be1f8_1f5082d3","updated":"2015-03-16 08:27:50.000000000","message":"Done","commit_id":"5439f35b166ad740d9262d5419a037b2e8e1c2e0"}],"neutron/db/db_base_plugin_v2.py":[{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"1df9a0e5427994cefe43b0ee7233860e1d56a18d","unresolved":false,"context_lines":[{"line_number":1105,"context_line":"                                            subnet_network_id):"},{"line_number":1106,"context_line":"        if subnet.get(\u0027enable_dhcp\u0027, False):"},{"line_number":1107,"context_line":"            filters \u003d {\u0027network_id\u0027: [subnet_network_id]}"},{"line_number":1108,"context_line":"            get_port_for_sub \u003d self.get_ports(context, filters\u003dfilters)"},{"line_number":1109,"context_line":"            # This IF condition is necessary for some unrelated unit tests"},{"line_number":1110,"context_line":"            # mocked port as None."},{"line_number":1111,"context_line":"            if get_port_for_sub:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a80dd14_32cd3f32","line":1108,"updated":"2015-03-19 10:38:04.000000000","message":"just getting a random port on the subnet\u0027s net? I guess your intent was to get dhcp port","commit_id":"5bd6a684173c71bf4018401a047f3f55ede975d8"},{"author":{"_account_id":14039,"name":"watanabe isao","email":"watanabe.isao.openstack@gmail.com","username":"watanabe.isao"},"change_message_id":"318b95c2b8bb550182e3ae62ceae6a34f22de275","unresolved":false,"context_lines":[{"line_number":1105,"context_line":"                                            subnet_network_id):"},{"line_number":1106,"context_line":"        if subnet.get(\u0027enable_dhcp\u0027, False):"},{"line_number":1107,"context_line":"            filters \u003d {\u0027network_id\u0027: [subnet_network_id]}"},{"line_number":1108,"context_line":"            get_port_for_sub \u003d self.get_ports(context, filters\u003dfilters)"},{"line_number":1109,"context_line":"            # This IF condition is necessary for some unrelated unit tests"},{"line_number":1110,"context_line":"            # mocked port as None."},{"line_number":1111,"context_line":"            if get_port_for_sub:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a80dd14_e205707a","line":1108,"in_reply_to":"9a80dd14_32cd3f32","updated":"2015-03-20 01:18:04.000000000","message":"Yes, so I checked the \"enable_dhcp\" parameter first. Could you tell me the correct way, if I was wrong, please?","commit_id":"5bd6a684173c71bf4018401a047f3f55ede975d8"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"1df9a0e5427994cefe43b0ee7233860e1d56a18d","unresolved":false,"context_lines":[{"line_number":1106,"context_line":"        if subnet.get(\u0027enable_dhcp\u0027, False):"},{"line_number":1107,"context_line":"            filters \u003d {\u0027network_id\u0027: [subnet_network_id]}"},{"line_number":1108,"context_line":"            get_port_for_sub \u003d self.get_ports(context, filters\u003dfilters)"},{"line_number":1109,"context_line":"            # This IF condition is necessary for some unrelated unit tests"},{"line_number":1110,"context_line":"            # mocked port as None."},{"line_number":1111,"context_line":"            if get_port_for_sub:"},{"line_number":1112,"context_line":"                port_num_for_sub \u003d len(get_port_for_sub[0][\u0027fixed_ips\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a80dd14_3269bff9","line":1109,"updated":"2015-03-19 10:38:04.000000000","message":"main code should not be driven by unit tests. Anyway I\u0027m not sure this is the right way to go, please see my general comment","commit_id":"5bd6a684173c71bf4018401a047f3f55ede975d8"},{"author":{"_account_id":14039,"name":"watanabe isao","email":"watanabe.isao.openstack@gmail.com","username":"watanabe.isao"},"change_message_id":"318b95c2b8bb550182e3ae62ceae6a34f22de275","unresolved":false,"context_lines":[{"line_number":1106,"context_line":"        if subnet.get(\u0027enable_dhcp\u0027, False):"},{"line_number":1107,"context_line":"            filters \u003d {\u0027network_id\u0027: [subnet_network_id]}"},{"line_number":1108,"context_line":"            get_port_for_sub \u003d self.get_ports(context, filters\u003dfilters)"},{"line_number":1109,"context_line":"            # This IF condition is necessary for some unrelated unit tests"},{"line_number":1110,"context_line":"            # mocked port as None."},{"line_number":1111,"context_line":"            if get_port_for_sub:"},{"line_number":1112,"context_line":"                port_num_for_sub \u003d len(get_port_for_sub[0][\u0027fixed_ips\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a80dd14_22fce871","line":1109,"in_reply_to":"9a80dd14_3269bff9","updated":"2015-03-20 01:18:04.000000000","message":"Done","commit_id":"5bd6a684173c71bf4018401a047f3f55ede975d8"},{"author":{"_account_id":4395,"name":"Aaron Rosen","email":"aaronorosen@gmail.com","username":"arosen"},"change_message_id":"a4f42a97a3767a2d893bd70ae2dba8e001a63577","unresolved":false,"context_lines":[{"line_number":131,"context_line":""},{"line_number":132,"context_line":"        # the new_ips contain all of the fixed_ips that are to be updated"},{"line_number":133,"context_line":"        if (len(new_ips) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":134,"context_line":"            not device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":135,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":136,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":137,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_a2e39932","line":134,"updated":"2015-06-09 03:40:45.000000000","message":"the problem with this is the user could just update the name of his port to be constants.DEVICE_OWNER_DHCP and get around this. I think we need to put a better system in place to prevent this.","commit_id":"01a977c795feefac042d65823c1e63b19a8c9060"},{"author":{"_account_id":14039,"name":"watanabe isao","email":"watanabe.isao.openstack@gmail.com","username":"watanabe.isao"},"change_message_id":"22bffbf47f05fed1bcf19a755721d96245f44e65","unresolved":false,"context_lines":[{"line_number":131,"context_line":""},{"line_number":132,"context_line":"        # the new_ips contain all of the fixed_ips that are to be updated"},{"line_number":133,"context_line":"        if (len(new_ips) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":134,"context_line":"            not device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":135,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":136,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":137,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_223fa9d7","line":134,"in_reply_to":"3afb71cf_a2e39932","updated":"2015-06-09 04:15:22.000000000","message":"Another fix will prevent non-admin user from changing DHCP port\u0027s name and ID.\n\nFor now there is a tempest test in\n- check-tempest-dsvm-neutron-full\n- check-grenade-dsvm-neutron\n- check-neutron-dsvm-api\nchecking whether DHCP port can be changed, and fails Jenkins. (Please see Jenkins result in Patch Set 6.)","commit_id":"01a977c795feefac042d65823c1e63b19a8c9060"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"30cb723c9759729c1d3abf795a8e4e9595d19e29","unresolved":false,"context_lines":[{"line_number":1346,"context_line":"                if tenant_id !\u003d router[\u0027tenant_id\u0027]:"},{"line_number":1347,"context_line":"                    raise n_exc.DeviceIDNotOwnedByTenant(device_id\u003ddevice_id)"},{"line_number":1348,"context_line":""},{"line_number":1349,"context_line":"    def _check_non_admin_user_operation_scope(self, context, device_owner):"},{"line_number":1350,"context_line":"        \"\"\"Forbid non-admin user from DHCP port operation. For DHCP port"},{"line_number":1351,"context_line":"           is not a tenant port."},{"line_number":1352,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_7705ba43","line":1349,"range":{"start_line":1349,"start_character":40,"end_line":1349,"end_character":45},"updated":"2015-10-01 07:58:32.000000000","message":"what does \"scope\" in the name mean?","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":14039,"name":"watanabe isao","email":"watanabe.isao.openstack@gmail.com","username":"watanabe.isao"},"change_message_id":"d434e7bff20a17ab094bf11faf453f3022d4d8d7","unresolved":false,"context_lines":[{"line_number":1346,"context_line":"                if tenant_id !\u003d router[\u0027tenant_id\u0027]:"},{"line_number":1347,"context_line":"                    raise n_exc.DeviceIDNotOwnedByTenant(device_id\u003ddevice_id)"},{"line_number":1348,"context_line":""},{"line_number":1349,"context_line":"    def _check_non_admin_user_operation_scope(self, context, device_owner):"},{"line_number":1350,"context_line":"        \"\"\"Forbid non-admin user from DHCP port operation. For DHCP port"},{"line_number":1351,"context_line":"           is not a tenant port."},{"line_number":1352,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_8d4cd177","line":1349,"in_reply_to":"9a1a9d01_7705ba43","updated":"2015-10-02 05:11:47.000000000","message":"Hello, @YAMAMOTO Takashi\t.\nI was supposed to mean \"authority\". It is to check whether the non-admin user has the permission to do what it wants to do.\n\nDo you have any better idea about the name, please?","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"ab1f2f4e36bb5d082e3c60bc2575e8499e3c8224","unresolved":false,"context_lines":[{"line_number":1346,"context_line":"                if tenant_id !\u003d router[\u0027tenant_id\u0027]:"},{"line_number":1347,"context_line":"                    raise n_exc.DeviceIDNotOwnedByTenant(device_id\u003ddevice_id)"},{"line_number":1348,"context_line":""},{"line_number":1349,"context_line":"    def _check_non_admin_user_operation_scope(self, context, device_owner):"},{"line_number":1350,"context_line":"        \"\"\"Forbid non-admin user from DHCP port operation. For DHCP port"},{"line_number":1351,"context_line":"           is not a tenant port."},{"line_number":1352,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_d7a30f9d","line":1349,"in_reply_to":"9a1a9d01_7c630842","updated":"2015-10-02 22:52:46.000000000","message":"I was looking at it from the wrong angle, discard my last comment.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"0b816e43d2b049fee30affba1f2d840beef78920","unresolved":false,"context_lines":[{"line_number":1346,"context_line":"                if tenant_id !\u003d router[\u0027tenant_id\u0027]:"},{"line_number":1347,"context_line":"                    raise n_exc.DeviceIDNotOwnedByTenant(device_id\u003ddevice_id)"},{"line_number":1348,"context_line":""},{"line_number":1349,"context_line":"    def _check_non_admin_user_operation_scope(self, context, device_owner):"},{"line_number":1350,"context_line":"        \"\"\"Forbid non-admin user from DHCP port operation. For DHCP port"},{"line_number":1351,"context_line":"           is not a tenant port."},{"line_number":1352,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_7c630842","line":1349,"in_reply_to":"9a1a9d01_8d4cd177","updated":"2015-10-02 22:14:26.000000000","message":"I actually don\u0027t understand what this check is for. Besides since [1], it think this cannot longer happen.\n\n[1] Ia64cf16142e0e4be44b5b0ed72c8e00792d770f9","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"eb8d04940dea88dfc5f8b3de8c5821fc47d8a37a","unresolved":false,"context_lines":[{"line_number":1346,"context_line":"                if tenant_id !\u003d router[\u0027tenant_id\u0027]:"},{"line_number":1347,"context_line":"                    raise n_exc.DeviceIDNotOwnedByTenant(device_id\u003ddevice_id)"},{"line_number":1348,"context_line":""},{"line_number":1349,"context_line":"    def _check_non_admin_user_operation_scope(self, context, device_owner):"},{"line_number":1350,"context_line":"        \"\"\"Forbid non-admin user from DHCP port operation. For DHCP port"},{"line_number":1351,"context_line":"           is not a tenant port."},{"line_number":1352,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_a15de67a","line":1349,"in_reply_to":"9a1a9d01_d7a30f9d","updated":"2015-10-20 02:22:19.000000000","message":"Sir Armando Migliaccio: Thank you very much for your time and review.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"a15901d7aedcee258f0b4be8f1607ee47cdc3ad9","unresolved":false,"context_lines":[{"line_number":1348,"context_line":""},{"line_number":1349,"context_line":"    def _check_non_admin_user_operation_scope(self, context, device_owner):"},{"line_number":1350,"context_line":"        \"\"\"Forbid non-admin user from DHCP port operation. For DHCP port"},{"line_number":1351,"context_line":"           is not a tenant port."},{"line_number":1352,"context_line":"        \"\"\""},{"line_number":1353,"context_line":"        if (device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP and"},{"line_number":1354,"context_line":"            not context.is_admin):"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_d70c6f44","line":1351,"updated":"2015-10-02 23:14:12.000000000","message":"forcing admin-only on here isn\u0027t the way to go. the reason these ports are updatable is because people might want to change the IP address that their DHCP port is using.\n\nInstead, please adjust the logic so that DHCP ports are not restricted to max_fixed_ips_per_port but instead are limited to the number of subnets on the network. There is no use case for DHCP ports to have multiple IP addresses on the same subnet so we can just match the number of subnets. That way tenants can still update their DHCP port and keep from exhausting the whole IP space.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"eb8d04940dea88dfc5f8b3de8c5821fc47d8a37a","unresolved":false,"context_lines":[{"line_number":1348,"context_line":""},{"line_number":1349,"context_line":"    def _check_non_admin_user_operation_scope(self, context, device_owner):"},{"line_number":1350,"context_line":"        \"\"\"Forbid non-admin user from DHCP port operation. For DHCP port"},{"line_number":1351,"context_line":"           is not a tenant port."},{"line_number":1352,"context_line":"        \"\"\""},{"line_number":1353,"context_line":"        if (device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP and"},{"line_number":1354,"context_line":"            not context.is_admin):"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_21731617","line":1351,"in_reply_to":"9a1a9d01_d70c6f44","updated":"2015-10-20 02:22:19.000000000","message":"@Kenvin Benton:\n\nThank you very much for your time and comment. \nYour suggestion is greatly reasonable and I will update in next patch set. Hope you can help to review it.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"2c74d348efb15d57509af970796514adbda9b3b9","unresolved":false,"context_lines":[{"line_number":1187,"context_line":"            fixed_ips_list \u003d new_port.get(\u0027fixed_ips\u0027, None)"},{"line_number":1188,"context_line":"            if fixed_ips_list:"},{"line_number":1189,"context_line":"                net_id \u003d db_port.get(\u0027network_id\u0027)"},{"line_number":1190,"context_line":"                network \u003d self.get_network(context, net_id)"},{"line_number":1191,"context_line":"                subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1192,"context_line":"                self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1193,"context_line":"                    fixed_ips_list, subnet_list, current_owner)"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_2b691ff9","line":1190,"updated":"2015-10-23 08:23:27.000000000","message":"this get_network call should not happen until it is determined that the port is already owned by DHCP. Otherwise it\u0027s a performance hit to regular port updates. Move all of this logic into _check_fixed_ips_for_update_dhcp_port and pass in the db_port instead of the subnet_list","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"4365996526de9b457d8317815bdcb7fbf6fb3848","unresolved":false,"context_lines":[{"line_number":1187,"context_line":"            fixed_ips_list \u003d new_port.get(\u0027fixed_ips\u0027, None)"},{"line_number":1188,"context_line":"            if fixed_ips_list:"},{"line_number":1189,"context_line":"                net_id \u003d db_port.get(\u0027network_id\u0027)"},{"line_number":1190,"context_line":"                network \u003d self.get_network(context, net_id)"},{"line_number":1191,"context_line":"                subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1192,"context_line":"                self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1193,"context_line":"                    fixed_ips_list, subnet_list, current_owner)"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_361f42b8","line":1190,"in_reply_to":"3a29b11f_2b691ff9","updated":"2015-10-23 08:51:26.000000000","message":"Hi Mr Kevin Benton:\nI understood and I will update this in next patch set. Thank you very much.","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"2c74d348efb15d57509af970796514adbda9b3b9","unresolved":false,"context_lines":[{"line_number":1190,"context_line":"                network \u003d self.get_network(context, net_id)"},{"line_number":1191,"context_line":"                subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1192,"context_line":"                self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1193,"context_line":"                    fixed_ips_list, subnet_list, current_owner)"},{"line_number":1194,"context_line":""},{"line_number":1195,"context_line":"        if new_mac and new_mac !\u003d db_port[\u0027mac_address\u0027]:"},{"line_number":1196,"context_line":"            self._check_mac_addr_update(context, db_port,"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_cb6bcbef","line":1193,"updated":"2015-10-23 08:23:27.000000000","message":"+1. Right now this is only being called if the device_id changes or the owner changes (L1183). It needs to happen on every fixed_ips update like YAMAMOTO suggested.","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"a608fc21a9f6647da1a6be6a47829bea0e85f748","unresolved":false,"context_lines":[{"line_number":1190,"context_line":"                network \u003d self.get_network(context, net_id)"},{"line_number":1191,"context_line":"                subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1192,"context_line":"                self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1193,"context_line":"                    fixed_ips_list, subnet_list, current_owner)"},{"line_number":1194,"context_line":""},{"line_number":1195,"context_line":"        if new_mac and new_mac !\u003d db_port[\u0027mac_address\u0027]:"},{"line_number":1196,"context_line":"            self._check_mac_addr_update(context, db_port,"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_9e0a0889","line":1193,"updated":"2015-10-22 15:36:11.000000000","message":"this check is necessary even when only fixed_ips is being updated, isn\u0027t it?","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"08ccd76c97e694593a4a0eb9eabc30e2269e7e4e","unresolved":false,"context_lines":[{"line_number":1190,"context_line":"                network \u003d self.get_network(context, net_id)"},{"line_number":1191,"context_line":"                subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1192,"context_line":"                self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1193,"context_line":"                    fixed_ips_list, subnet_list, current_owner)"},{"line_number":1194,"context_line":""},{"line_number":1195,"context_line":"        if new_mac and new_mac !\u003d db_port[\u0027mac_address\u0027]:"},{"line_number":1196,"context_line":"            self._check_mac_addr_update(context, db_port,"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_cbd992f4","line":1193,"in_reply_to":"3a29b11f_9e0a0889","updated":"2015-10-23 04:16:11.000000000","message":"Hello @YAMAMOTO takashi san,\n\nSure, We just care about \"fixed_ips\" when updating DHCP port as I discribed in commit message:\n\n\"and with DHCP port, the number of fixed ips per port doesn\u0027t exceed the number of subnets on the network that it\u0027s assigned to.\"\n\nDo you have any suggestion here?","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"dad2571f429c384bf5cb50fc6baa4a218a603ba1","unresolved":false,"context_lines":[{"line_number":1190,"context_line":"                network \u003d self.get_network(context, net_id)"},{"line_number":1191,"context_line":"                subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1192,"context_line":"                self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1193,"context_line":"                    fixed_ips_list, subnet_list, current_owner)"},{"line_number":1194,"context_line":""},{"line_number":1195,"context_line":"        if new_mac and new_mac !\u003d db_port[\u0027mac_address\u0027]:"},{"line_number":1196,"context_line":"            self._check_mac_addr_update(context, db_port,"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_a8cc5589","line":1193,"in_reply_to":"3a29b11f_bc001a35","updated":"2015-10-23 07:29:37.000000000","message":"Hi YAMAMOTO san:\n\nYour comment is greatly exact. When updating fixed_ips for DHCP port, I don\u0027t need to check changed_device_id or changed_owner. So, the block in L1188 should be separated from the block in L1183. They are independent.\nThank you very much.","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"dd147646224dac602b35d3aff7d9f3d2e51236b9","unresolved":false,"context_lines":[{"line_number":1190,"context_line":"                network \u003d self.get_network(context, net_id)"},{"line_number":1191,"context_line":"                subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1192,"context_line":"                self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1193,"context_line":"                    fixed_ips_list, subnet_list, current_owner)"},{"line_number":1194,"context_line":""},{"line_number":1195,"context_line":"        if new_mac and new_mac !\u003d db_port[\u0027mac_address\u0027]:"},{"line_number":1196,"context_line":"            self._check_mac_addr_update(context, db_port,"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_bc001a35","line":1193,"in_reply_to":"3a29b11f_cbd992f4","updated":"2015-10-23 04:26:48.000000000","message":"look at L1183, this block is executed only when device_id/device_owner is being updated.","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"a608fc21a9f6647da1a6be6a47829bea0e85f748","unresolved":false,"context_lines":[{"line_number":1222,"context_line":"                    new_port[\u0027dns_name\u0027] \u003d \u0027\u0027"},{"line_number":1223,"context_line":"            new_mac \u003d new_port.get(\u0027mac_address\u0027)"},{"line_number":1224,"context_line":"            self._validate_port_for_update(context, port, new_port, new_mac)"},{"line_number":1225,"context_line":""},{"line_number":1226,"context_line":"            changes \u003d self.ipam.update_port_with_ips(context, port,"},{"line_number":1227,"context_line":"                                                     new_port, new_mac)"},{"line_number":1228,"context_line":"            if \u0027dns-integration\u0027 in self.supported_extension_aliases:"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_1eaef8e5","line":1225,"updated":"2015-10-22 15:36:11.000000000","message":"unrelated change","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"08ccd76c97e694593a4a0eb9eabc30e2269e7e4e","unresolved":false,"context_lines":[{"line_number":1222,"context_line":"                    new_port[\u0027dns_name\u0027] \u003d \u0027\u0027"},{"line_number":1223,"context_line":"            new_mac \u003d new_port.get(\u0027mac_address\u0027)"},{"line_number":1224,"context_line":"            self._validate_port_for_update(context, port, new_port, new_mac)"},{"line_number":1225,"context_line":""},{"line_number":1226,"context_line":"            changes \u003d self.ipam.update_port_with_ips(context, port,"},{"line_number":1227,"context_line":"                                                     new_port, new_mac)"},{"line_number":1228,"context_line":"            if \u0027dns-integration\u0027 in self.supported_extension_aliases:"}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_5cc30638","line":1225,"in_reply_to":"3a29b11f_1eaef8e5","updated":"2015-10-23 04:16:11.000000000","message":"Done","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":8976,"name":"shihanzhang","email":"ayshihanzhang@gmail.com","username":"shihanzhang"},"change_message_id":"25a5d24b93feae3ad428fc7f386042015f76975c","unresolved":false,"context_lines":[{"line_number":1360,"context_line":""},{"line_number":1361,"context_line":"    def _check_fixed_ips_for_update_dhcp_port(self, context, port,"},{"line_number":1362,"context_line":"                                              fixed_ips_list, device_owner):"},{"line_number":1363,"context_line":"        \"\"\"The fixed_ips per DHCP port doesn\u0027t exceed the number of"},{"line_number":1364,"context_line":"        subnets on the network where it\u0027s assigned to."},{"line_number":1365,"context_line":"        \"\"\""},{"line_number":1366,"context_line":"        if device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP:"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a29b11f_076d0432","line":1363,"updated":"2015-10-26 06:17:03.000000000","message":"I think the fixed_ips per DHCP port should not exceed the number of subnets which enable DHCP","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"3b080b88d15444a530c218fe2e54c3b9715fa2e9","unresolved":false,"context_lines":[{"line_number":1360,"context_line":""},{"line_number":1361,"context_line":"    def _check_fixed_ips_for_update_dhcp_port(self, context, port,"},{"line_number":1362,"context_line":"                                              fixed_ips_list, device_owner):"},{"line_number":1363,"context_line":"        \"\"\"The fixed_ips per DHCP port doesn\u0027t exceed the number of"},{"line_number":1364,"context_line":"        subnets on the network where it\u0027s assigned to."},{"line_number":1365,"context_line":"        \"\"\""},{"line_number":1366,"context_line":"        if device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP:"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a29b11f_922ab0e6","line":1363,"in_reply_to":"3a29b11f_076d0432","updated":"2015-10-26 07:11:46.000000000","message":"it sounds reasonable.","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"0da4739de59750314028a22d5aa00acf7d71644e","unresolved":false,"context_lines":[{"line_number":1360,"context_line":""},{"line_number":1361,"context_line":"    def _check_fixed_ips_for_update_dhcp_port(self, context, port,"},{"line_number":1362,"context_line":"                                              fixed_ips_list, device_owner):"},{"line_number":1363,"context_line":"        \"\"\"The fixed_ips per DHCP port doesn\u0027t exceed the number of"},{"line_number":1364,"context_line":"        subnets on the network where it\u0027s assigned to."},{"line_number":1365,"context_line":"        \"\"\""},{"line_number":1366,"context_line":"        if device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP:"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a26ad4f_d1417164","line":1363,"in_reply_to":"3a29b11f_922ab0e6","updated":"2015-11-03 08:31:34.000000000","message":"Hello @shihanzhang, YAMAMOTO Takashi san, thank you very much for your comments. \nCurrently, I am following the suggestion from Kevin Benton. The solution is described in commit message.\n\nFor your above solution: Please give me a little time to be able to discuss with Kevin.\n\nMr @Kevin Benton: could you please help me to give some comments here?","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1d9667bda84362e318ac0508fc18f7c538bcb8cf","unresolved":false,"context_lines":[{"line_number":1369,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1370,"context_line":""},{"line_number":1371,"context_line":"            if len(fixed_ips_list) \u003e len(subnet_list):"},{"line_number":1372,"context_line":"                msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port.\u0027)"},{"line_number":1373,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a29b11f_8c629b15","line":1372,"range":{"start_line":1372,"start_character":34,"end_line":1372,"end_character":41},"updated":"2015-10-26 05:46:16.000000000","message":"probably it\u0027s better to use a different message.\n\neg. \"Exceeded maximum amount of fixed ips for a DHCP port.\"","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"0da4739de59750314028a22d5aa00acf7d71644e","unresolved":false,"context_lines":[{"line_number":1369,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":1370,"context_line":""},{"line_number":1371,"context_line":"            if len(fixed_ips_list) \u003e len(subnet_list):"},{"line_number":1372,"context_line":"                msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port.\u0027)"},{"line_number":1373,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a26ad4f_5156c12a","line":1372,"in_reply_to":"3a29b11f_8c629b15","updated":"2015-11-03 08:31:34.000000000","message":"Done","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"242fca48e9e23316f7824f4e8953534979fb38d9","unresolved":false,"context_lines":[{"line_number":1187,"context_line":""},{"line_number":1188,"context_line":"        fixed_ips_list \u003d new_port.get(\u0027fixed_ips\u0027, None)"},{"line_number":1189,"context_line":""},{"line_number":1190,"context_line":"        if fixed_ips_list and current_owner:"},{"line_number":1191,"context_line":"            self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1192,"context_line":"                context, db_port, fixed_ips_list,"},{"line_number":1193,"context_line":"                current_owner)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_4b9b16ca","line":1190,"updated":"2015-11-04 05:02:43.000000000","message":"you want this when either of fixed_ips or device_owner is being updated, right?","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"fb3d27896978137f0fdf0626cd5101eda37586fb","unresolved":false,"context_lines":[{"line_number":1187,"context_line":""},{"line_number":1188,"context_line":"        fixed_ips_list \u003d new_port.get(\u0027fixed_ips\u0027, None)"},{"line_number":1189,"context_line":""},{"line_number":1190,"context_line":"        if fixed_ips_list and current_owner:"},{"line_number":1191,"context_line":"            self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1192,"context_line":"                context, db_port, fixed_ips_list,"},{"line_number":1193,"context_line":"                current_owner)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_ba03ea0e","line":1190,"in_reply_to":"fa80f949_4b9b16ca","updated":"2015-11-04 09:37:44.000000000","message":"Hi Yamamoto san,\nThis check is applied when updating fixed_ips for DHCP port only, not \napplied when updating device_owner. device_owner parameter in this block just \nis used for verifying that updated port is a DHCP port. Thanks","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"cd35bdc02726a2073c50b17d09fae8753c34d1c3","unresolved":false,"context_lines":[{"line_number":1187,"context_line":""},{"line_number":1188,"context_line":"        fixed_ips_list \u003d new_port.get(\u0027fixed_ips\u0027, None)"},{"line_number":1189,"context_line":""},{"line_number":1190,"context_line":"        if fixed_ips_list and current_owner:"},{"line_number":1191,"context_line":"            self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1192,"context_line":"                context, db_port, fixed_ips_list,"},{"line_number":1193,"context_line":"                current_owner)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_ed63d33f","line":1190,"in_reply_to":"fa80f949_adeaabaa","updated":"2015-11-05 04:29:59.000000000","message":"I understood. So, in this block, check fixed_ips_list is enough and I will fix this in next patch. Thanks for your time.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"b4167b2db95fff45d6d4b3b351566e0ffb423367","unresolved":false,"context_lines":[{"line_number":1187,"context_line":""},{"line_number":1188,"context_line":"        fixed_ips_list \u003d new_port.get(\u0027fixed_ips\u0027, None)"},{"line_number":1189,"context_line":""},{"line_number":1190,"context_line":"        if fixed_ips_list and current_owner:"},{"line_number":1191,"context_line":"            self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1192,"context_line":"                context, db_port, fixed_ips_list,"},{"line_number":1193,"context_line":"                current_owner)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_adeaabaa","line":1190,"in_reply_to":"fa80f949_ba03ea0e","updated":"2015-11-05 04:13:01.000000000","message":"i thought you might want to check when device_owner is being changed to/from dhcp.  but it might not be necessary as the operation is restricted by policy.json these days.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"079d9da5a2d334897037b07b3020416441e62c4a","unresolved":false,"context_lines":[{"line_number":1190,"context_line":"        if fixed_ips_list:"},{"line_number":1191,"context_line":"            self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1192,"context_line":"                context, db_port, fixed_ips_list,"},{"line_number":1193,"context_line":"                current_owner)"},{"line_number":1194,"context_line":""},{"line_number":1195,"context_line":"        if new_mac and new_mac !\u003d db_port[\u0027mac_address\u0027]:"},{"line_number":1196,"context_line":"            self._check_mac_addr_update(context, db_port,"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa80f949_ce292239","line":1193,"updated":"2015-11-05 08:52:08.000000000","message":"why do you want to put this check here, rather than the same place as non-dhcp case?","commit_id":"97e8cec578ed7d0e5a9f58f038c1afdb7b703964"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"f9f9b9d034c7bff243a67cf2e56aa0ffb0ec15a5","unresolved":false,"context_lines":[{"line_number":1190,"context_line":"        if fixed_ips_list:"},{"line_number":1191,"context_line":"            self._check_fixed_ips_for_update_dhcp_port("},{"line_number":1192,"context_line":"                context, db_port, fixed_ips_list,"},{"line_number":1193,"context_line":"                current_owner)"},{"line_number":1194,"context_line":""},{"line_number":1195,"context_line":"        if new_mac and new_mac !\u003d db_port[\u0027mac_address\u0027]:"},{"line_number":1196,"context_line":"            self._check_mac_addr_update(context, db_port,"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa80f949_b11e5ab9","line":1193,"in_reply_to":"fa80f949_ce292239","updated":"2015-11-06 01:58:17.000000000","message":"Thanks for your suggestion. Put this check in the same place with \nchecking for Non-dhcp port is probably more reasonable. And I will update this \nin my next patch.","commit_id":"97e8cec578ed7d0e5a9f58f038c1afdb7b703964"}],"neutron/db/ipam_backend_mixin.py":[{"author":{"_account_id":14591,"name":"Lubosz Kosnik (diltram)","email":"lubosz.kosnik@intel.com","username":"diltram"},"change_message_id":"65ab0a5d6be633d801df4ae29715799e068830c9","unresolved":false,"context_lines":[{"line_number":367,"context_line":"                                  new_ips, device_owner):"},{"line_number":368,"context_line":"        \"\"\"Calculate changes in IPs for the port.\"\"\""},{"line_number":369,"context_line":"        # the new_ips contain all of the fixed_ips that are to be updated"},{"line_number":370,"context_line":"        if (len(new_ips) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":371,"context_line":"            not device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":372,"context_line":"            msg \u003d _(\u0027Exceeded maximum amount of fixed ips per port\u0027)"},{"line_number":373,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":12,"id":"3a29b11f_a33bb2ea","line":370,"updated":"2015-10-20 08:27:43.000000000","message":"That parameter is marked as deprecated right now so you should change that","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"2c74d348efb15d57509af970796514adbda9b3b9","unresolved":false,"context_lines":[{"line_number":299,"context_line":""},{"line_number":300,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":301,"context_line":"        if (len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":302,"context_line":"            not device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":303,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":304,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":305,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_eb6ec7fe","line":302,"updated":"2015-10-23 08:23:27.000000000","message":"use \u0027device_owner !\u003d constants.DEVICE_OWNER_DHCP\u0027 instead of \u0027not device_owner \u003d\u003d...\u0027","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"4365996526de9b457d8317815bdcb7fbf6fb3848","unresolved":false,"context_lines":[{"line_number":299,"context_line":""},{"line_number":300,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":301,"context_line":"        if (len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":302,"context_line":"            not device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":303,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":304,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":305,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"3a29b11f_f6c9ca26","line":302,"in_reply_to":"3a29b11f_eb6ec7fe","updated":"2015-10-23 08:51:26.000000000","message":"Done","commit_id":"5aa1e6f63216c206a393398d66fb8e2c28a313a6"},{"author":{"_account_id":14591,"name":"Lubosz Kosnik (diltram)","email":"lubosz.kosnik@intel.com","username":"diltram"},"change_message_id":"cf2fecfed6fee5bd90a6ff0644e894018063469a","unresolved":false,"context_lines":[{"line_number":298,"context_line":"                        subnet_cidr\u003dsubnet_cidr)"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":301,"context_line":"        if (len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":302,"context_line":"            device_owner !\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":303,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":304,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a29b11f_95e4d7ac","line":301,"updated":"2015-10-26 10:26:51.000000000","message":"That parameters is marked as deprecated starting from Mitaka release?","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"0da4739de59750314028a22d5aa00acf7d71644e","unresolved":false,"context_lines":[{"line_number":298,"context_line":"                        subnet_cidr\u003dsubnet_cidr)"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":301,"context_line":"        if (len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":302,"context_line":"            device_owner !\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":303,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":304,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a26ad4f_910e9939","line":301,"in_reply_to":"3a29b11f_95e4d7ac","updated":"2015-11-03 08:31:34.000000000","message":"Hi @Lubosz Kosnik, Thank you very much for your comment.\n       \nBecause of the patch [1] was merged, max_fixed_ips_per_port is maybe marked as deprecated starting from M release. \nBut I am following Kevin\u0027s solution: this parameter is used when updating Non-DHCP port. \nPlease give me a little time to be able to discuss with Kevin about this case.\n\nMr @Kevin Benton: Could you please help me to give some comments regarding to this case?\n    \n[1] https://review.openstack.org/#/c/230696/","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1d9667bda84362e318ac0508fc18f7c538bcb8cf","unresolved":false,"context_lines":[{"line_number":300,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":301,"context_line":"        if (len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":302,"context_line":"            device_owner !\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":303,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":304,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"    def _get_subnet_for_fixed_ip(self, context, fixed, network_id):"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a29b11f_0c5e8b45","line":303,"range":{"start_line":303,"start_character":30,"end_line":303,"end_character":37},"updated":"2015-10-26 05:46:16.000000000","message":"i wonder how these slightly different messages came in.\n(maximim vs maximum)","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"0da4739de59750314028a22d5aa00acf7d71644e","unresolved":false,"context_lines":[{"line_number":300,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":301,"context_line":"        if (len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":302,"context_line":"            device_owner !\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":303,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":304,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"    def _get_subnet_for_fixed_ip(self, context, fixed, network_id):"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a26ad4f_4c32a8f3","line":303,"in_reply_to":"3a29b11f_0c5e8b45","updated":"2015-11-03 08:31:34.000000000","message":"Done","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":8976,"name":"shihanzhang","email":"ayshihanzhang@gmail.com","username":"shihanzhang"},"change_message_id":"87c0f3c5a2174d76a2837fdb222bb13560361838","unresolved":false,"context_lines":[{"line_number":308,"context_line":"            network \u003d self._get_network(context, network_id)"},{"line_number":309,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":310,"context_line":""},{"line_number":311,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":312,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":313,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":314,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_90a616c0","line":311,"updated":"2015-11-09 06:47:50.000000000","message":"I have a comment on patch set 14, I think maximum amount of fixed ips for a DHCP port should not exceeded the subnet which enable DHCP, what do you think?","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":13667,"name":"ZongKai LI","email":"onionpiece@163.com","username":"lzklibj"},"change_message_id":"4b6d52f850534f520218b9d267f810e0d023d1df","unresolved":false,"context_lines":[{"line_number":308,"context_line":"            network \u003d self._get_network(context, network_id)"},{"line_number":309,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":310,"context_line":""},{"line_number":311,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":312,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":313,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":314,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_e22c70ad","line":311,"in_reply_to":"da85f559_90a616c0","updated":"2015-11-09 09:44:02.000000000","message":"Agree with Shi Han.","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"e9e07d769d497f3596d1e2c62529173535cec0a4","unresolved":false,"context_lines":[{"line_number":308,"context_line":"            network \u003d self._get_network(context, network_id)"},{"line_number":309,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":310,"context_line":""},{"line_number":311,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":312,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":313,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":314,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_f6799530","line":311,"in_reply_to":"da85f559_e22c70ad","updated":"2015-11-09 09:57:17.000000000","message":"@shihanzhang, Zongkai LI: Thank you very much for your suggestion. As I replied that comment, I am following the solution from Kevin Benton and currently, I still cannot discuss with him about this issue, he is probably busy. And please give me a little time to negotiate with Kevin about this before I have a final solution.","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"401f05c1dd52637b7e86ef06f3d8924244653642","unresolved":false,"context_lines":[{"line_number":311,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":312,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":313,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":314,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"    def _get_subnet_for_fixed_ip(self, context, fixed, network_id):"},{"line_number":317,"context_line":"        if \u0027subnet_id\u0027 in fixed:"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_8d3cbd94","line":314,"updated":"2015-11-09 05:59:57.000000000","message":"this method would be easier to read if:\n\n  if device_owner \u003d\u003d DHCP:\n   :\n   :\n  else:\n   :\n   :","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"e9e07d769d497f3596d1e2c62529173535cec0a4","unresolved":false,"context_lines":[{"line_number":311,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":312,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":313,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":314,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"    def _get_subnet_for_fixed_ip(self, context, fixed, network_id):"},{"line_number":317,"context_line":"        if \u0027subnet_id\u0027 in fixed:"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_a2a668bf","line":314,"in_reply_to":"da85f559_8d3cbd94","updated":"2015-11-09 09:57:17.000000000","message":"Done","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"401f05c1dd52637b7e86ef06f3d8924244653642","unresolved":false,"context_lines":[{"line_number":375,"context_line":"                    not ipv6_utils.is_ipv6_pd_enabled(subnet))"},{"line_number":376,"context_line":""},{"line_number":377,"context_line":"    def _get_changed_ips_for_port(self, context, original_ips,"},{"line_number":378,"context_line":"                                  new_ips, device_owner, network_id\u003dNone):"},{"line_number":379,"context_line":"        \"\"\"Calculate changes in IPs for the port.\"\"\""},{"line_number":380,"context_line":"        # the new_ips contain all of the fixed_ips that are to be updated"},{"line_number":381,"context_line":"        if network_id:"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_8d635db1","line":378,"updated":"2015-11-09 05:59:57.000000000","message":"for what case network_id\u003dNone is useful?","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"e9e07d769d497f3596d1e2c62529173535cec0a4","unresolved":false,"context_lines":[{"line_number":375,"context_line":"                    not ipv6_utils.is_ipv6_pd_enabled(subnet))"},{"line_number":376,"context_line":""},{"line_number":377,"context_line":"    def _get_changed_ips_for_port(self, context, original_ips,"},{"line_number":378,"context_line":"                                  new_ips, device_owner, network_id\u003dNone):"},{"line_number":379,"context_line":"        \"\"\"Calculate changes in IPs for the port.\"\"\""},{"line_number":380,"context_line":"        # the new_ips contain all of the fixed_ips that are to be updated"},{"line_number":381,"context_line":"        if network_id:"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_b6522ddc","line":378,"in_reply_to":"da85f559_8d635db1","updated":"2015-11-09 09:57:17.000000000","message":"Hi @YAMAMOTO Takashi san: I put  \"network_id\u003dNone\" here because it will helpful for the cases as you can see in \n\nhttps://github.com/openstack/neutron/blob/master/neutron/tests/unit/db/test_ipam_backend_mixin.py\n\nBut, This way maybe is not a best solution and I had another solution, it probably help us solve this issue easier. I will update it in next patch soon.\n\nAgain, thank you very much for your time and comments.","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"0f3d6bb32f892e3406407b4f8529aa760daa8765","unresolved":false,"context_lines":[{"line_number":367,"context_line":"                                  new_ips, device_owner):"},{"line_number":368,"context_line":"        \"\"\"Calculate changes in IPs for the port.\"\"\""},{"line_number":369,"context_line":"        # the new_ips contain all of the fixed_ips that are to be updated"},{"line_number":370,"context_line":"        self._validate_max_ips_per_port(new_ips)"},{"line_number":371,"context_line":""},{"line_number":372,"context_line":"        add_ips \u003d []"},{"line_number":373,"context_line":"        remove_ips \u003d []"}],"source_content_type":"text/x-python","patch_set":19,"id":"da85f559_65837205","side":"PARENT","line":370,"updated":"2015-11-10 08:44:16.000000000","message":"why did you remove this?","commit_id":"ad103befd46f3572620b22a29d45609009a90382"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"ac9630e477b959be56de64ab4231b8c8ca78e317","unresolved":false,"context_lines":[{"line_number":367,"context_line":"                                  new_ips, device_owner):"},{"line_number":368,"context_line":"        \"\"\"Calculate changes in IPs for the port.\"\"\""},{"line_number":369,"context_line":"        # the new_ips contain all of the fixed_ips that are to be updated"},{"line_number":370,"context_line":"        self._validate_max_ips_per_port(new_ips)"},{"line_number":371,"context_line":""},{"line_number":372,"context_line":"        add_ips \u003d []"},{"line_number":373,"context_line":"        remove_ips \u003d []"}],"source_content_type":"text/x-python","patch_set":19,"id":"da85f559_8e38eea1","side":"PARENT","line":370,"in_reply_to":"da85f559_65837205","updated":"2015-11-10 11:26:42.000000000","message":"@garyk: because when modifying this function as you can see in https://review.openstack.org/#/c/160214/19/neutron/db/ipam_backend_mixin.py  line 300, I have to add another argument \"network_id\" into function  _get_changed_ips_for_port (line 366 in this file). So, in an easier way, I moved this check to functions which will call _get_changed_ips_for_port as you can see my changes in https://review.openstack.org/#/c/160214/19/neutron/db/ipam_non_pluggable_backend.py line 319 and https://review.openstack.org/#/c/160214/19/neutron/db/ipam_pluggable_backend.py line 275. Workflow is not change.\n\nThanks.","commit_id":"ad103befd46f3572620b22a29d45609009a90382"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"0f3d6bb32f892e3406407b4f8529aa760daa8765","unresolved":false,"context_lines":[{"line_number":303,"context_line":"            network \u003d self._get_network(context, network_id)"},{"line_number":304,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":307,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":308,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":309,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":19,"id":"da85f559_e5a0c2a1","line":306,"updated":"2015-11-10 08:44:16.000000000","message":"why are we doing this check for the DHCP ports? We should just skip.\nIn addition to this what about router ports?","commit_id":"58d5328062d47b74888a0eba578e52b3e05af630"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"bce7b5f4d8f1faffc2bd2d987e52b237b0028dea","unresolved":false,"context_lines":[{"line_number":303,"context_line":"            network \u003d self._get_network(context, network_id)"},{"line_number":304,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":307,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":308,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":309,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a8ffd7b_3661cb39","line":306,"in_reply_to":"ba8a016a_ba3ef825","updated":"2015-12-24 09:44:39.000000000","message":"@Kevin Benton: thanks a lot for your comment. I will update it in next patch.Please help me to take a look for that patch.","commit_id":"58d5328062d47b74888a0eba578e52b3e05af630"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"2a5faa993bb72b2242afd01d3983e59a147949d7","unresolved":false,"context_lines":[{"line_number":303,"context_line":"            network \u003d self._get_network(context, network_id)"},{"line_number":304,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":307,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":308,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":309,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":19,"id":"ba8a016a_ba3ef825","line":306,"in_reply_to":"da85f559_1a52fddd","updated":"2015-11-19 10:49:19.000000000","message":"Yes, actually we should just skip this check entirely for network owned ports like these.\n\nSo this function just becomes:\n\ndef _validate_max_ips_per_port(self, fixed_ip_list, device_owner):\n    if neutron.common.utils.is_port_trusted({\u0027device_owner\u0027: device_owner}):\n        return\n    if len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port:\n        msg \u003d _(\u0027Exceeded maximum amount of fixed ips per port.\u0027)\n        raise n_exc.InvalidInput(error_message\u003dmsg)\n\n\nMuch simpler!","commit_id":"58d5328062d47b74888a0eba578e52b3e05af630"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"ac9630e477b959be56de64ab4231b8c8ca78e317","unresolved":false,"context_lines":[{"line_number":303,"context_line":"            network \u003d self._get_network(context, network_id)"},{"line_number":304,"context_line":"            subnet_list \u003d network[\u0027subnets\u0027]"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"            if len(fixed_ip_list) \u003e len(subnet_list):"},{"line_number":307,"context_line":"                msg \u003d _(\u0027Exceeded maximum amount of fixed ips \u0027"},{"line_number":308,"context_line":"                        \u0027for a DHCP port.\u0027)"},{"line_number":309,"context_line":"                raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":19,"id":"da85f559_1a52fddd","line":306,"in_reply_to":"da85f559_e5a0c2a1","updated":"2015-11-10 11:26:42.000000000","message":"Hi @garyk: As my current solution which I described in my commit message:\"the number of fixed ips per DHCP port doesn\u0027t\nexceed the number of subnets on the network that it\u0027s assigned to.\", this check just apply for DHCP port, not care about router ports. Moreover, this solution was discussed with Kevin Benton as you can see in https://review.openstack.org/#/c/160214/12/neutron/db/db_base_plugin_v2.py line 1351. And Mr Armando Migliaccio also agree that we care about DHCP port only https://bugs.launchpad.net/neutron/+bug/1179713/comments/14 .\n\nThanks for your time and reviewing.","commit_id":"58d5328062d47b74888a0eba578e52b3e05af630"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"9e33ca5907cb9a3474750e0293cf4a97fbed216b","unresolved":false,"context_lines":[{"line_number":299,"context_line":"                        subnet_cidr\u003dsubnet_cidr)"},{"line_number":300,"context_line":""},{"line_number":301,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":302,"context_line":"        if common_utils.is_port_trusted({\u0027device_owner\u0027: device_owner}):"},{"line_number":303,"context_line":"            return"},{"line_number":304,"context_line":""},{"line_number":305,"context_line":"        if len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port:"}],"source_content_type":"text/x-python","patch_set":21,"id":"1a7b0d38_89a56305","line":302,"updated":"2015-12-24 12:50:11.000000000","message":"where is a unit test for this?","commit_id":"392a51dec96346f5f5336f15a01a296ff933ed16"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"27c5f12e636a91a49bea1f8c1fa2225d91c7a6f8","unresolved":false,"context_lines":[{"line_number":299,"context_line":"                        subnet_cidr\u003dsubnet_cidr)"},{"line_number":300,"context_line":""},{"line_number":301,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":302,"context_line":"        if common_utils.is_port_trusted({\u0027device_owner\u0027: device_owner}):"},{"line_number":303,"context_line":"            return"},{"line_number":304,"context_line":""},{"line_number":305,"context_line":"        if len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port:"}],"source_content_type":"text/x-python","patch_set":21,"id":"1a7b0d38_337ca31e","line":302,"in_reply_to":"1a7b0d38_2d6312de","updated":"2015-12-28 07:33:09.000000000","message":"Hi @garyk @Ryan Moats: Thank you very much for your comments. I will update them in next patch.","commit_id":"392a51dec96346f5f5336f15a01a296ff933ed16"},{"author":{"_account_id":11682,"name":"Ryan Moats","email":"rmoats@us.ibm.com","username":"regXboi"},"change_message_id":"edcbed0b91d2cba20b52416bd37d9ec53ff7a29a","unresolved":false,"context_lines":[{"line_number":299,"context_line":"                        subnet_cidr\u003dsubnet_cidr)"},{"line_number":300,"context_line":""},{"line_number":301,"context_line":"    def _validate_max_ips_per_port(self, fixed_ip_list, device_owner):"},{"line_number":302,"context_line":"        if common_utils.is_port_trusted({\u0027device_owner\u0027: device_owner}):"},{"line_number":303,"context_line":"            return"},{"line_number":304,"context_line":""},{"line_number":305,"context_line":"        if len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port:"}],"source_content_type":"text/x-python","patch_set":21,"id":"1a7b0d38_2d6312de","line":302,"in_reply_to":"1a7b0d38_89a56305","updated":"2015-12-24 18:04:19.000000000","message":"agreed - that needs to be added","commit_id":"392a51dec96346f5f5336f15a01a296ff933ed16"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"9e33ca5907cb9a3474750e0293cf4a97fbed216b","unresolved":false,"context_lines":[{"line_number":302,"context_line":"        if common_utils.is_port_trusted({\u0027device_owner\u0027: device_owner}):"},{"line_number":303,"context_line":"            return"},{"line_number":304,"context_line":""},{"line_number":305,"context_line":"        if len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port:"},{"line_number":306,"context_line":"            msg \u003d _(\u0027Exceeded maximum amount of fixed ips per port.\u0027)"},{"line_number":307,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":308,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"1a7b0d38_6964b7e4","line":305,"updated":"2015-12-24 12:50:11.000000000","message":"my understanding is that we are deprecating this check. So why are we adding this?","commit_id":"392a51dec96346f5f5336f15a01a296ff933ed16"},{"author":{"_account_id":11682,"name":"Ryan Moats","email":"rmoats@us.ibm.com","username":"regXboi"},"change_message_id":"edcbed0b91d2cba20b52416bd37d9ec53ff7a29a","unresolved":false,"context_lines":[{"line_number":302,"context_line":"        if common_utils.is_port_trusted({\u0027device_owner\u0027: device_owner}):"},{"line_number":303,"context_line":"            return"},{"line_number":304,"context_line":""},{"line_number":305,"context_line":"        if len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port:"},{"line_number":306,"context_line":"            msg \u003d _(\u0027Exceeded maximum amount of fixed ips per port.\u0027)"},{"line_number":307,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":308,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"1a7b0d38_6d691abe","line":305,"in_reply_to":"1a7b0d38_6964b7e4","updated":"2015-12-24 18:04:19.000000000","message":"garyk, I don\u0027t think this is being added - it looks like it was moved down from L301 of the original patch.","commit_id":"392a51dec96346f5f5336f15a01a296ff933ed16"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"27c5f12e636a91a49bea1f8c1fa2225d91c7a6f8","unresolved":false,"context_lines":[{"line_number":302,"context_line":"        if common_utils.is_port_trusted({\u0027device_owner\u0027: device_owner}):"},{"line_number":303,"context_line":"            return"},{"line_number":304,"context_line":""},{"line_number":305,"context_line":"        if len(fixed_ip_list) \u003e cfg.CONF.max_fixed_ips_per_port:"},{"line_number":306,"context_line":"            msg \u003d _(\u0027Exceeded maximum amount of fixed ips per port.\u0027)"},{"line_number":307,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":308,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"1a7b0d38_93df970c","line":305,"in_reply_to":"1a7b0d38_6d691abe","updated":"2015-12-28 07:33:09.000000000","message":"@garyk, @Ryan Moats: Non-DHCP port still is restricted by max_fixed_ips_per_port parameter. This parameter will be removed in the near future but it still needs to work now. I discussed about this with Mr YAMAMOTO Takashi as you can refer here:\n\nhttp://eavesdrop.openstack.org/irclogs/%23openstack-neutron/%23openstack-neutron.2015-11-04.log.html#t2015-11-04T07:06:07\n\nSo, this check is neccessary.\n\nThanks.","commit_id":"392a51dec96346f5f5336f15a01a296ff933ed16"}],"neutron/db/ipam_non_pluggable_backend.py":[{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"a15901d7aedcee258f0b4be8f1607ee47cdc3ad9","unresolved":false,"context_lines":[{"line_number":275,"context_line":"                    fixed_ip_set.append({\u0027subnet_id\u0027: subnet[\u0027id\u0027]})"},{"line_number":276,"context_line":""},{"line_number":277,"context_line":"        self._validate_max_ips_per_port(fixed_ip_set)"},{"line_number":278,"context_line":"        if (len(fixed_ip_set) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":279,"context_line":"            not device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":280,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":281,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_57d37f38","line":278,"updated":"2015-10-02 23:14:12.000000000","message":"the line right above this already checks this so it won\u0027t ever make it here.\n\nAdjust the function \"_validate_max_ips_per_port\" in neutron/db/ipam_backend_mixin.py to take device_owner as an extra arg and make the change there.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"eb8d04940dea88dfc5f8b3de8c5821fc47d8a37a","unresolved":false,"context_lines":[{"line_number":275,"context_line":"                    fixed_ip_set.append({\u0027subnet_id\u0027: subnet[\u0027id\u0027]})"},{"line_number":276,"context_line":""},{"line_number":277,"context_line":"        self._validate_max_ips_per_port(fixed_ip_set)"},{"line_number":278,"context_line":"        if (len(fixed_ip_set) \u003e cfg.CONF.max_fixed_ips_per_port and"},{"line_number":279,"context_line":"            not device_owner \u003d\u003d constants.DEVICE_OWNER_DHCP):"},{"line_number":280,"context_line":"            msg \u003d _(\u0027Exceeded maximim amount of fixed ips per port\u0027)"},{"line_number":281,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":12,"id":"7a2fa921_bfcea281","line":278,"in_reply_to":"9a1a9d01_57d37f38","updated":"2015-10-20 02:22:19.000000000","message":"Hi @\tKevin Benton\n\nYour comment really helpful for me. I will fix this in next patch set.\nThanks you very much.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":13667,"name":"ZongKai LI","email":"onionpiece@163.com","username":"lzklibj"},"change_message_id":"aa277c9d38b420c57d679b478b58a5227bd72d90","unresolved":false,"context_lines":[{"line_number":238,"context_line":""},{"line_number":239,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":240,"context_line":"                 InvalidIpForSubnet"},{"line_number":241,"context_line":"        \"\"\""},{"line_number":242,"context_line":"        fixed_ip_set \u003d []"},{"line_number":243,"context_line":"        for fixed in fixed_ips:"},{"line_number":244,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_23759cca","line":241,"updated":"2015-11-04 03:07:17.000000000","message":"Why not move _validate_max_ips_per_port here, if an maximum amount error will raise, we don\u0027t need enter following for loop.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"242fca48e9e23316f7824f4e8953534979fb38d9","unresolved":false,"context_lines":[{"line_number":238,"context_line":""},{"line_number":239,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":240,"context_line":"                 InvalidIpForSubnet"},{"line_number":241,"context_line":"        \"\"\""},{"line_number":242,"context_line":"        fixed_ip_set \u003d []"},{"line_number":243,"context_line":"        for fixed in fixed_ips:"},{"line_number":244,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_cb41463b","line":241,"in_reply_to":"fa80f949_23759cca","updated":"2015-11-04 05:02:43.000000000","message":"ZongKai,\n_validate_max_ips_per_port takes fixed_ip_set computed by the following loop.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":13667,"name":"ZongKai LI","email":"onionpiece@163.com","username":"lzklibj"},"change_message_id":"dc1f9f178e215cf54600e55d44e3ec289c332a64","unresolved":false,"context_lines":[{"line_number":238,"context_line":""},{"line_number":239,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":240,"context_line":"                 InvalidIpForSubnet"},{"line_number":241,"context_line":"        \"\"\""},{"line_number":242,"context_line":"        fixed_ip_set \u003d []"},{"line_number":243,"context_line":"        for fixed in fixed_ips:"},{"line_number":244,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_ee6a181a","line":241,"in_reply_to":"fa80f949_cb41463b","updated":"2015-11-04 06:29:37.000000000","message":"Ye, you\u0027re right, YAMATOTO san. But I still think _test_fixed_ips_for_port can be optimized, well, that\u0027s out of this patch.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"fb3d27896978137f0fdf0626cd5101eda37586fb","unresolved":false,"context_lines":[{"line_number":238,"context_line":""},{"line_number":239,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":240,"context_line":"                 InvalidIpForSubnet"},{"line_number":241,"context_line":"        \"\"\""},{"line_number":242,"context_line":"        fixed_ip_set \u003d []"},{"line_number":243,"context_line":"        for fixed in fixed_ips:"},{"line_number":244,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_9cece3c8","line":241,"in_reply_to":"fa80f949_ee6a181a","updated":"2015-11-04 09:37:44.000000000","message":"@ZongKai Li, Yamamoto san: Thanks for your reviewing.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"}],"neutron/db/ipam_pluggable_backend.py":[{"author":{"_account_id":13667,"name":"ZongKai LI","email":"onionpiece@163.com","username":"lzklibj"},"change_message_id":"aa277c9d38b420c57d679b478b58a5227bd72d90","unresolved":false,"context_lines":[{"line_number":237,"context_line":""},{"line_number":238,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":239,"context_line":"                 InvalidIpForSubnet"},{"line_number":240,"context_line":"        \"\"\""},{"line_number":241,"context_line":"        fixed_ip_list \u003d []"},{"line_number":242,"context_line":"        for fixed in fixed_ips:"},{"line_number":243,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_c3585059","line":240,"updated":"2015-11-04 03:07:17.000000000","message":"Suggest to move _validate_max_ips_per_port here.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"fb3d27896978137f0fdf0626cd5101eda37586fb","unresolved":false,"context_lines":[{"line_number":237,"context_line":""},{"line_number":238,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":239,"context_line":"                 InvalidIpForSubnet"},{"line_number":240,"context_line":"        \"\"\""},{"line_number":241,"context_line":"        fixed_ip_list \u003d []"},{"line_number":242,"context_line":"        for fixed in fixed_ips:"},{"line_number":243,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_7ca57f02","line":240,"in_reply_to":"fa80f949_c3585059","updated":"2015-11-04 09:37:44.000000000","message":"Done","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17776,"name":"Reedip","email":"reedip.banerjee@gmail.com","username":"Reedip"},"change_message_id":"fb618d49f5a55c71bf58024192c473d77d296b2f","unresolved":false,"context_lines":[{"line_number":238,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":239,"context_line":"                 InvalidIpForSubnet"},{"line_number":240,"context_line":"        \"\"\""},{"line_number":241,"context_line":"        fixed_ip_list \u003d []"},{"line_number":242,"context_line":"        for fixed in fixed_ips:"},{"line_number":243,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"},{"line_number":244,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"fa80f949_3f7822f2","line":241,"updated":"2015-11-05 05:24:37.000000000","message":"I think the previous comment from ZongKai li is not addressed here.\n\nhttps://review.openstack.org/#/c/160214/15..16/neutron/db/ipam_pluggable_backend.py","commit_id":"97e8cec578ed7d0e5a9f58f038c1afdb7b703964"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"f9f9b9d034c7bff243a67cf2e56aa0ffb0ec15a5","unresolved":false,"context_lines":[{"line_number":238,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":239,"context_line":"                 InvalidIpForSubnet"},{"line_number":240,"context_line":"        \"\"\""},{"line_number":241,"context_line":"        fixed_ip_list \u003d []"},{"line_number":242,"context_line":"        for fixed in fixed_ips:"},{"line_number":243,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"},{"line_number":244,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"fa80f949_42ae6986","line":241,"in_reply_to":"fa80f949_3f7822f2","updated":"2015-11-06 01:58:17.000000000","message":"@ZongKai LI: thanks for your explaination.\n\n@Reedip: thanks for your time and reviewing.","commit_id":"97e8cec578ed7d0e5a9f58f038c1afdb7b703964"},{"author":{"_account_id":13667,"name":"ZongKai LI","email":"onionpiece@163.com","username":"lzklibj"},"change_message_id":"2a6908c277361b7d582f1ab42f2c53562de56fe2","unresolved":false,"context_lines":[{"line_number":238,"context_line":"        :raises: InvalidInput, IpAddressInUse, InvalidIpForNetwork,"},{"line_number":239,"context_line":"                 InvalidIpForSubnet"},{"line_number":240,"context_line":"        \"\"\""},{"line_number":241,"context_line":"        fixed_ip_list \u003d []"},{"line_number":242,"context_line":"        for fixed in fixed_ips:"},{"line_number":243,"context_line":"            subnet \u003d self._get_subnet_for_fixed_ip(context, fixed, network_id)"},{"line_number":244,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"fa80f949_7869e0bd","line":241,"in_reply_to":"fa80f949_3f7822f2","updated":"2015-11-05 07:34:18.000000000","message":"Well, indeed, comments at https://review.openstack.org/#/c/160214/15/neutron/db/ipam_non_pluggable_backend.py could explain here. Thanks for your review, Reedip.","commit_id":"97e8cec578ed7d0e5a9f58f038c1afdb7b703964"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"9adc7bf270cb7a0963e10165db0dd25fe71e3bb4","unresolved":false,"context_lines":[{"line_number":276,"context_line":"                                        new_ips, port[\u0027device_owner\u0027])"},{"line_number":277,"context_line":"        changes \u003d self._get_changed_ips_for_port("},{"line_number":278,"context_line":"            context, original_ips, new_ips,"},{"line_number":279,"context_line":"            port[\u0027device_owner\u0027])"},{"line_number":280,"context_line":"        # Check if the IP\u0027s to add are OK"},{"line_number":281,"context_line":"        to_add \u003d self._test_fixed_ips_for_port("},{"line_number":282,"context_line":"            context, port[\u0027network_id\u0027], changes.add,"}],"source_content_type":"text/x-python","patch_set":19,"id":"da85f559_3694cbe0","line":279,"updated":"2015-11-10 05:11:35.000000000","message":"is this whitespace change necessary?","commit_id":"58d5328062d47b74888a0eba578e52b3e05af630"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"11b93c82b69d9e6539c228fd0b21797691e6aef3","unresolved":false,"context_lines":[{"line_number":276,"context_line":"                                        new_ips, port[\u0027device_owner\u0027])"},{"line_number":277,"context_line":"        changes \u003d self._get_changed_ips_for_port("},{"line_number":278,"context_line":"            context, original_ips, new_ips,"},{"line_number":279,"context_line":"            port[\u0027device_owner\u0027])"},{"line_number":280,"context_line":"        # Check if the IP\u0027s to add are OK"},{"line_number":281,"context_line":"        to_add \u003d self._test_fixed_ips_for_port("},{"line_number":282,"context_line":"            context, port[\u0027network_id\u0027], changes.add,"}],"source_content_type":"text/x-python","patch_set":19,"id":"da85f559_f4c71b10","line":279,"in_reply_to":"da85f559_3694cbe0","updated":"2015-11-10 07:45:32.000000000","message":"@YAMAMOTO san: this change is not necessary. I am sorry for this mistake and will fix this soon.","commit_id":"58d5328062d47b74888a0eba578e52b3e05af630"}],"neutron/plugins/ml2/plugin.py":[{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"30cb723c9759729c1d3abf795a8e4e9595d19e29","unresolved":false,"context_lines":[{"line_number":960,"context_line":"                                            \u0027ip_address\u0027: ip.ip_address}"},{"line_number":961,"context_line":"                                           for ip in a.port.fixed_ips"},{"line_number":962,"context_line":"                                           if ip.subnet_id !\u003d id]}}"},{"line_number":963,"context_line":"                    try:"},{"line_number":964,"context_line":"                        if (subnet[\u0027enable_dhcp\u0027] is True"},{"line_number":965,"context_line":"                            and not context.is_admin):"},{"line_number":966,"context_line":"                            admin_context \u003d context.elevated()"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_d221349f","line":963,"updated":"2015-10-01 07:58:32.000000000","message":"how about other plugins?","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"738579e1552ebd80dec26e0f12238d232c1ea7c9","unresolved":false,"context_lines":[{"line_number":960,"context_line":"                                            \u0027ip_address\u0027: ip.ip_address}"},{"line_number":961,"context_line":"                                           for ip in a.port.fixed_ips"},{"line_number":962,"context_line":"                                           if ip.subnet_id !\u003d id]}}"},{"line_number":963,"context_line":"                    try:"},{"line_number":964,"context_line":"                        if (subnet[\u0027enable_dhcp\u0027] is True"},{"line_number":965,"context_line":"                            and not context.is_admin):"},{"line_number":966,"context_line":"                            admin_context \u003d context.elevated()"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_a8d74322","line":963,"in_reply_to":"9a1a9d01_7f490c30","updated":"2015-10-02 06:24:45.000000000","message":"if you\u0027re using ml2, sure.  but my question was about other plugin.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"b2e4615fa7bf55585e5111ae06f113ab5c84936f","unresolved":false,"context_lines":[{"line_number":960,"context_line":"                                            \u0027ip_address\u0027: ip.ip_address}"},{"line_number":961,"context_line":"                                           for ip in a.port.fixed_ips"},{"line_number":962,"context_line":"                                           if ip.subnet_id !\u003d id]}}"},{"line_number":963,"context_line":"                    try:"},{"line_number":964,"context_line":"                        if (subnet[\u0027enable_dhcp\u0027] is True"},{"line_number":965,"context_line":"                            and not context.is_admin):"},{"line_number":966,"context_line":"                            admin_context \u003d context.elevated()"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_7f490c30","line":963,"in_reply_to":"9a1a9d01_d221349f","updated":"2015-10-01 10:04:45.000000000","message":"@YAMAMOTO Takashi\n\nBeacause when we delete a subnet, this delete_subnet function:\nhttps://github.com/openstack/neutron/blob/master/neutron/plugins/ml2/plugin.py#L876\n\nalways is invoked. That\u0027s why I just fix in this file (ml2 plugin)","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"30cb723c9759729c1d3abf795a8e4e9595d19e29","unresolved":false,"context_lines":[{"line_number":963,"context_line":"                    try:"},{"line_number":964,"context_line":"                        if (subnet[\u0027enable_dhcp\u0027] is True"},{"line_number":965,"context_line":"                            and not context.is_admin):"},{"line_number":966,"context_line":"                            admin_context \u003d context.elevated()"},{"line_number":967,"context_line":"                            self.update_port(admin_context, a.port_id, data)"},{"line_number":968,"context_line":"                        else:"},{"line_number":969,"context_line":"                            self.update_port(context, a.port_id, data)"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_b26cc0d0","line":966,"updated":"2015-10-01 07:58:32.000000000","message":"can you explain why this is necessary?\n\nyour _validate_port_for_update change only rejects\ndevice_owner/device_id changes, doesn\u0027t it?","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"738579e1552ebd80dec26e0f12238d232c1ea7c9","unresolved":false,"context_lines":[{"line_number":963,"context_line":"                    try:"},{"line_number":964,"context_line":"                        if (subnet[\u0027enable_dhcp\u0027] is True"},{"line_number":965,"context_line":"                            and not context.is_admin):"},{"line_number":966,"context_line":"                            admin_context \u003d context.elevated()"},{"line_number":967,"context_line":"                            self.update_port(admin_context, a.port_id, data)"},{"line_number":968,"context_line":"                        else:"},{"line_number":969,"context_line":"                            self.update_port(context, a.port_id, data)"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_48dc6746","line":966,"in_reply_to":"9a1a9d01_3cd5e2e3","updated":"2015-10-02 06:24:45.000000000","message":"who rejects it?","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"eb8d04940dea88dfc5f8b3de8c5821fc47d8a37a","unresolved":false,"context_lines":[{"line_number":963,"context_line":"                    try:"},{"line_number":964,"context_line":"                        if (subnet[\u0027enable_dhcp\u0027] is True"},{"line_number":965,"context_line":"                            and not context.is_admin):"},{"line_number":966,"context_line":"                            admin_context \u003d context.elevated()"},{"line_number":967,"context_line":"                            self.update_port(admin_context, a.port_id, data)"},{"line_number":968,"context_line":"                        else:"},{"line_number":969,"context_line":"                            self.update_port(context, a.port_id, data)"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_351067a8","line":966,"in_reply_to":"9a1a9d01_48dc6746","updated":"2015-10-20 02:22:19.000000000","message":"Hello @YAMAMOTO Takashi san:\n\nMy current solution is not the best solution. After discussing with Kevin Benton, I changed the direction to fix this bug and will update in next patch set.\nThank you very much and hope you can help to review it.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"84e8fed6c26f8f098bde1c91a190dc4f26ccd1fe","unresolved":false,"context_lines":[{"line_number":963,"context_line":"                    try:"},{"line_number":964,"context_line":"                        if (subnet[\u0027enable_dhcp\u0027] is True"},{"line_number":965,"context_line":"                            and not context.is_admin):"},{"line_number":966,"context_line":"                            admin_context \u003d context.elevated()"},{"line_number":967,"context_line":"                            self.update_port(admin_context, a.port_id, data)"},{"line_number":968,"context_line":"                        else:"},{"line_number":969,"context_line":"                            self.update_port(context, a.port_id, data)"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_3cd5e2e3","line":966,"in_reply_to":"9a1a9d01_b26cc0d0","updated":"2015-10-01 09:25:36.000000000","message":"@YAMAMOTO Takashi\n\n1. This is greatly necessary because when we delete a subnet which is enabled HDCP (*), the corresponding DHCP port will be updated. However, only admin-user can update DHCP port. So the action from non-admin user to delete subnet (*) will be rejected. And in requirement that non-admin user still can delete subnet which is enabled DHCP, when deleting subnet, if user is a non-admin user, I have to invoke corresponding admin user before updating DHCP port.  \n\n2. In my case, non-admin user cannot update port, so if non-admin user changes any attribute of DHCP port, this action will be rejected, not just \ndevice_owner/device_id.","commit_id":"3cdc676805ae657bb9c9b16faf7321608777aae5"}],"neutron/tests/unit/db/test_db_base_plugin_v2.py":[{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1d9667bda84362e318ac0508fc18f7c538bcb8cf","unresolved":false,"context_lines":[{"line_number":956,"context_line":""},{"line_number":957,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":958,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027,"},{"line_number":959,"context_line":"            max_fixed_ips_per_port_by_default\u003d5):"},{"line_number":960,"context_line":"        with self.network() as network:"},{"line_number":961,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":962,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a29b11f_872594af","line":959,"updated":"2015-10-26 05:46:16.000000000","message":"why do you want a copy of the default value (5) here?\ncan\u0027t you use cfg.CONF.max_fixed_ips_per_port?\n\nit\u0027s better to ensure that N succeeds but N+1 fails.\notherwise InvalidInput you get might be due to\na different reason.","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"0da4739de59750314028a22d5aa00acf7d71644e","unresolved":false,"context_lines":[{"line_number":956,"context_line":""},{"line_number":957,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":958,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027,"},{"line_number":959,"context_line":"            max_fixed_ips_per_port_by_default\u003d5):"},{"line_number":960,"context_line":"        with self.network() as network:"},{"line_number":961,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":962,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a26ad4f_0c4fd06b","line":959,"in_reply_to":"3a29b11f_872594af","updated":"2015-11-03 08:31:34.000000000","message":"Hi @YAMAMOTO Takashi san: this comment is really helpful for me. I will fix this in next patch.","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":14591,"name":"Lubosz Kosnik (diltram)","email":"lubosz.kosnik@intel.com","username":"diltram"},"change_message_id":"cf2fecfed6fee5bd90a6ff0644e894018063469a","unresolved":false,"context_lines":[{"line_number":960,"context_line":"        with self.network() as network:"},{"line_number":961,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":962,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":963,"context_line":"                              \u0027ip_address\u0027: \u002710.0.0.\u0027 + str(id)}"},{"line_number":964,"context_line":"                             for id in range(3,"},{"line_number":965,"context_line":"                                 max_fixed_ips_per_port_by_default + 4)]"},{"line_number":966,"context_line":"                res \u003d self._create_port(self.fmt,"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a29b11f_d50b2f2a","line":963,"updated":"2015-10-26 10:26:51.000000000","message":"Why not used string formatting. It\u0027s much safer that executing str on value.","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"0da4739de59750314028a22d5aa00acf7d71644e","unresolved":false,"context_lines":[{"line_number":960,"context_line":"        with self.network() as network:"},{"line_number":961,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":962,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":963,"context_line":"                              \u0027ip_address\u0027: \u002710.0.0.\u0027 + str(id)}"},{"line_number":964,"context_line":"                             for id in range(3,"},{"line_number":965,"context_line":"                                 max_fixed_ips_per_port_by_default + 4)]"},{"line_number":966,"context_line":"                res \u003d self._create_port(self.fmt,"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a26ad4f_ec593436","line":963,"in_reply_to":"3a29b11f_d50b2f2a","updated":"2015-11-03 08:31:34.000000000","message":"Hi @Lubosz Kosnik, I will update in next patch. Thanks.","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"1d9667bda84362e318ac0508fc18f7c538bcb8cf","unresolved":false,"context_lines":[{"line_number":1236,"context_line":"    def check_update_dhcp_port_fixed_ips("},{"line_number":1237,"context_line":"            self, expected_status\u003dwebob.exc.HTTPBadRequest.code,"},{"line_number":1238,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027, subnet\u003dNone,"},{"line_number":1239,"context_line":"            device_owner\u003dDEVICE_OWNER_NOT_COMPUTE, updated_fixed_ips\u003dNone,"},{"line_number":1240,"context_line":"            host_arg\u003d{}, arg_list\u003d[]):"},{"line_number":1241,"context_line":"        with self.port(device_owner\u003ddevice_owner, subnet\u003dsubnet,"},{"line_number":1242,"context_line":"                       arg_list\u003darg_list, **host_arg) as port:"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a29b11f_8c17fb53","line":1239,"range":{"start_line":1239,"start_character":25,"end_line":1239,"end_character":49},"updated":"2015-10-26 05:46:16.000000000","message":"please use DEVICE_OWNER_DHCP when you mean dhcp port.","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"0da4739de59750314028a22d5aa00acf7d71644e","unresolved":false,"context_lines":[{"line_number":1236,"context_line":"    def check_update_dhcp_port_fixed_ips("},{"line_number":1237,"context_line":"            self, expected_status\u003dwebob.exc.HTTPBadRequest.code,"},{"line_number":1238,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027, subnet\u003dNone,"},{"line_number":1239,"context_line":"            device_owner\u003dDEVICE_OWNER_NOT_COMPUTE, updated_fixed_ips\u003dNone,"},{"line_number":1240,"context_line":"            host_arg\u003d{}, arg_list\u003d[]):"},{"line_number":1241,"context_line":"        with self.port(device_owner\u003ddevice_owner, subnet\u003dsubnet,"},{"line_number":1242,"context_line":"                       arg_list\u003darg_list, **host_arg) as port:"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a26ad4f_8c43e041","line":1239,"in_reply_to":"3a29b11f_8c17fb53","updated":"2015-11-03 08:31:34.000000000","message":"Done","commit_id":"c37943f2fb759fb03bf7811a3a2f5d90341cf7e7"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"242fca48e9e23316f7824f4e8953534979fb38d9","unresolved":false,"context_lines":[{"line_number":53,"context_line":""},{"line_number":54,"context_line":"DEVICE_OWNER_COMPUTE \u003d \u0027compute:None\u0027"},{"line_number":55,"context_line":"DEVICE_OWNER_NOT_COMPUTE \u003d constants.DEVICE_OWNER_DHCP"},{"line_number":56,"context_line":"DEVICE_OWNER_DHCP \u003d constants.DEVICE_OWNER_DHCP"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"def optional_ctx(obj, fallback):"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_4b26b6bb","line":56,"updated":"2015-11-04 05:02:43.000000000","message":"what\u0027s the point of having a copy?","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"fb3d27896978137f0fdf0626cd5101eda37586fb","unresolved":false,"context_lines":[{"line_number":53,"context_line":""},{"line_number":54,"context_line":"DEVICE_OWNER_COMPUTE \u003d \u0027compute:None\u0027"},{"line_number":55,"context_line":"DEVICE_OWNER_NOT_COMPUTE \u003d constants.DEVICE_OWNER_DHCP"},{"line_number":56,"context_line":"DEVICE_OWNER_DHCP \u003d constants.DEVICE_OWNER_DHCP"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"def optional_ctx(obj, fallback):"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_3c97f791","line":56,"in_reply_to":"fa80f949_4b26b6bb","updated":"2015-11-04 09:37:44.000000000","message":"Ok, I don\u0027t need to declare this here and I can use \nconstants.DEVICE_OWNER_DHCP directly. I will fix this in next patch. Thanks","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"242fca48e9e23316f7824f4e8953534979fb38d9","unresolved":false,"context_lines":[{"line_number":957,"context_line":""},{"line_number":958,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":959,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027,"},{"line_number":960,"context_line":"            max_fixed_ips_per_port\u003dcfg.CONF.max_fixed_ips_per_port):"},{"line_number":961,"context_line":"        with self.network() as network:"},{"line_number":962,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":963,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_6b04da14","line":960,"updated":"2015-11-04 05:02:43.000000000","message":"accessing cfg.CONF this way is probably not what you intended.\n\nis there any reason to have it in method argument in the first place?","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"fb3d27896978137f0fdf0626cd5101eda37586fb","unresolved":false,"context_lines":[{"line_number":957,"context_line":""},{"line_number":958,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":959,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027,"},{"line_number":960,"context_line":"            max_fixed_ips_per_port\u003dcfg.CONF.max_fixed_ips_per_port):"},{"line_number":961,"context_line":"        with self.network() as network:"},{"line_number":962,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":963,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_bc3767af","line":960,"in_reply_to":"fa80f949_6b04da14","updated":"2015-11-04 09:37:44.000000000","message":"Hi Yamamoto san, I am not clear about you mean. As I understand, I \ndon\u0027t need to declare \"max_fixed_ips_per_port\" as an argument here and I can \nuse cfg.CONF.max_fixed_ips_per_port directly in line 966. \n\t\nIs my understanding right? please correct if any.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"29ed6bce6983089d1fce0b25c09e7423e17d5da8","unresolved":false,"context_lines":[{"line_number":957,"context_line":""},{"line_number":958,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":959,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027,"},{"line_number":960,"context_line":"            max_fixed_ips_per_port\u003dcfg.CONF.max_fixed_ips_per_port):"},{"line_number":961,"context_line":"        with self.network() as network:"},{"line_number":962,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":963,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_cd74cf9d","line":960,"in_reply_to":"fa80f949_bc3767af","updated":"2015-11-05 03:48:29.000000000","message":"right.\n\nthe default value is evaluated on method-defining time.\ni thought your intention was to evaluate it test-running time.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"cd35bdc02726a2073c50b17d09fae8753c34d1c3","unresolved":false,"context_lines":[{"line_number":957,"context_line":""},{"line_number":958,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":959,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027,"},{"line_number":960,"context_line":"            max_fixed_ips_per_port\u003dcfg.CONF.max_fixed_ips_per_port):"},{"line_number":961,"context_line":"        with self.network() as network:"},{"line_number":962,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":963,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_edcaf319","line":960,"in_reply_to":"fa80f949_cd74cf9d","updated":"2015-11-05 04:29:59.000000000","message":"Thanks for your guide. This point was clear.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":13667,"name":"ZongKai LI","email":"onionpiece@163.com","username":"lzklibj"},"change_message_id":"aa277c9d38b420c57d679b478b58a5227bd72d90","unresolved":false,"context_lines":[{"line_number":962,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":963,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":964,"context_line":"                              \u0027ip_address\u0027: \u002710.0.0.%s\u0027 % id}"},{"line_number":965,"context_line":"                             for id in range(3,"},{"line_number":966,"context_line":"                                 max_fixed_ips_per_port + 4)]"},{"line_number":967,"context_line":"                res \u003d self._create_port(self.fmt,"},{"line_number":968,"context_line":"                                        network[\u0027network\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_b51a236d","line":965,"updated":"2015-11-04 03:07:17.000000000","message":"nit: uncomfortable indentation, since the for statement is part of dict, why not keep same indentation as other lines do.","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"fb3d27896978137f0fdf0626cd5101eda37586fb","unresolved":false,"context_lines":[{"line_number":962,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":963,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":964,"context_line":"                              \u0027ip_address\u0027: \u002710.0.0.%s\u0027 % id}"},{"line_number":965,"context_line":"                             for id in range(3,"},{"line_number":966,"context_line":"                                 max_fixed_ips_per_port + 4)]"},{"line_number":967,"context_line":"                res \u003d self._create_port(self.fmt,"},{"line_number":968,"context_line":"                                        network[\u0027network\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_bc5e87e7","line":965,"in_reply_to":"fa80f949_b51a236d","updated":"2015-11-04 09:37:44.000000000","message":"Done","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":13667,"name":"ZongKai LI","email":"onionpiece@163.com","username":"lzklibj"},"change_message_id":"aa277c9d38b420c57d679b478b58a5227bd72d90","unresolved":false,"context_lines":[{"line_number":1279,"context_line":"    def test_update_dhcp_port_fixed_ips(self):"},{"line_number":1280,"context_line":"        with self.subnet() as subnet:"},{"line_number":1281,"context_line":"            updated_fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":1282,"context_line":"                                 \u0027ip_address\u0027: \u002710.0.0.3\u0027},"},{"line_number":1283,"context_line":"                                 {\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":1284,"context_line":"                                 \u0027ip_address\u0027: \u002710.0.0.4\u0027}]"},{"line_number":1285,"context_line":"            self.check_update_dhcp_port_fixed_ips(subnet\u003dsubnet,"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_d56807bd","line":1282,"updated":"2015-11-04 03:07:17.000000000","message":"nit: indentation","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"fb3d27896978137f0fdf0626cd5101eda37586fb","unresolved":false,"context_lines":[{"line_number":1279,"context_line":"    def test_update_dhcp_port_fixed_ips(self):"},{"line_number":1280,"context_line":"        with self.subnet() as subnet:"},{"line_number":1281,"context_line":"            updated_fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":1282,"context_line":"                                 \u0027ip_address\u0027: \u002710.0.0.3\u0027},"},{"line_number":1283,"context_line":"                                 {\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":1284,"context_line":"                                 \u0027ip_address\u0027: \u002710.0.0.4\u0027}]"},{"line_number":1285,"context_line":"            self.check_update_dhcp_port_fixed_ips(subnet\u003dsubnet,"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa80f949_9c8863e9","line":1282,"in_reply_to":"fa80f949_d56807bd","updated":"2015-11-04 09:37:44.000000000","message":"Done","commit_id":"781a1295dd6737dda61a191963d9ecb5c419506b"},{"author":{"_account_id":13667,"name":"ZongKai LI","email":"onionpiece@163.com","username":"lzklibj"},"change_message_id":"67d38d1e72aabbdb2a2a7a994d91914971ea7e32","unresolved":false,"context_lines":[{"line_number":1282,"context_line":"                                 {\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":1283,"context_line":"                                  \u0027ip_address\u0027: \u002710.0.0.4\u0027}]"},{"line_number":1284,"context_line":"            self.check_update_dhcp_port_fixed_ips(subnet\u003dsubnet,"},{"line_number":1285,"context_line":"                                       updated_fixed_ips\u003dupdated_fixed_ips)"},{"line_number":1286,"context_line":""},{"line_number":1287,"context_line":"    def test_update_port_mac(self):"},{"line_number":1288,"context_line":"        self.check_update_port_mac()"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_cd22c6b9","line":1285,"updated":"2015-11-09 05:41:03.000000000","message":"Except the exception case, shall we also test the success case? If not, I think it\u0027s better to update test case name in L1278, to specify the test case, just like L957.","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"e9e07d769d497f3596d1e2c62529173535cec0a4","unresolved":false,"context_lines":[{"line_number":1282,"context_line":"                                 {\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":1283,"context_line":"                                  \u0027ip_address\u0027: \u002710.0.0.4\u0027}]"},{"line_number":1284,"context_line":"            self.check_update_dhcp_port_fixed_ips(subnet\u003dsubnet,"},{"line_number":1285,"context_line":"                                       updated_fixed_ips\u003dupdated_fixed_ips)"},{"line_number":1286,"context_line":""},{"line_number":1287,"context_line":"    def test_update_port_mac(self):"},{"line_number":1288,"context_line":"        self.check_update_port_mac()"}],"source_content_type":"text/x-python","patch_set":17,"id":"da85f559_36b07df4","line":1285,"in_reply_to":"da85f559_cd22c6b9","updated":"2015-11-09 09:57:17.000000000","message":"Hi @ZongKai Li: It is reasonable and I will update it in next patch.\nThank you very much for your comment.","commit_id":"f4c053458a888d11cc8897dfc5eef7349db427bf"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"06fdeafd2db0282bacbec18483a7b5fcec77cc09","unresolved":false,"context_lines":[{"line_number":962,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":963,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027):"},{"line_number":964,"context_line":"        with self.network() as network:"},{"line_number":965,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":966,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":967,"context_line":"                              \u0027ip_address\u0027: \u002710.0.0.%s\u0027 % id}"},{"line_number":968,"context_line":"                             for id in range(3,"}],"source_content_type":"text/x-python","patch_set":22,"id":"1a7b0d38_b0bc04dd","line":965,"updated":"2015-12-28 09:53:32.000000000","message":"the bug states that the problem happens when there are X subnets created on the network and X \u003e max_fixed_ips_per_port\n\nCan you please add a test for this.","commit_id":"67e267fe7ed6f9b67be539ec8817ee79c815bef9"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"5af46e81dff21cc7147e5954450465cb9d352059","unresolved":false,"context_lines":[{"line_number":962,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":963,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027):"},{"line_number":964,"context_line":"        with self.network() as network:"},{"line_number":965,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":966,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"},{"line_number":967,"context_line":"                              \u0027ip_address\u0027: \u002710.0.0.%s\u0027 % id}"},{"line_number":968,"context_line":"                             for id in range(3,"}],"source_content_type":"text/x-python","patch_set":22,"id":"1a7b0d38_197baff6","line":965,"in_reply_to":"1a7b0d38_b0bc04dd","updated":"2015-12-29 01:29:27.000000000","message":"hi @garyk:\nThanks for your review and suggestion.\nThis test case is greatly neccessary.\nI will update this.","commit_id":"67e267fe7ed6f9b67be539ec8817ee79c815bef9"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"1ab9e56261fc7502795862ea48d2d86515815e55","unresolved":false,"context_lines":[{"line_number":960,"context_line":"                self.assertEqual(msg, data[\u0027NeutronError\u0027][\u0027message\u0027])"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":963,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027):"},{"line_number":964,"context_line":"        with self.network() as network:"},{"line_number":965,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":966,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_3ea073f4","line":963,"range":{"start_line":963,"start_character":12,"end_line":963,"end_character":26},"updated":"2015-12-30 08:50:58.000000000","message":"why need parameter here?","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"447af8067de373825e364a0754f3c980f5c8852a","unresolved":false,"context_lines":[{"line_number":960,"context_line":"                self.assertEqual(msg, data[\u0027NeutronError\u0027][\u0027message\u0027])"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":963,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027):"},{"line_number":964,"context_line":"        with self.network() as network:"},{"line_number":965,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":966,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_3de859e2","line":963,"range":{"start_line":963,"start_character":12,"end_line":963,"end_character":26},"in_reply_to":"fa69d971_1db7953a","updated":"2015-12-31 08:20:43.000000000","message":"@Oleg Bondarev: I understood. Thanks","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"48ee8d028270102a5d9576595cb3edda5554fbe8","unresolved":false,"context_lines":[{"line_number":960,"context_line":"                self.assertEqual(msg, data[\u0027NeutronError\u0027][\u0027message\u0027])"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":963,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027):"},{"line_number":964,"context_line":"        with self.network() as network:"},{"line_number":965,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":966,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_dcd106fd","line":963,"range":{"start_line":963,"start_character":12,"end_line":963,"end_character":26},"in_reply_to":"fa69d971_3ea073f4","updated":"2015-12-31 01:36:18.000000000","message":"Hi @Oleg Bondarev:\nI expected that this case will raise the error output as \"InvalidInput\" and this is a fixed error output. That\u0027s why I put \"expected_error\u003d\u0027InvalidInput\u0027\" here.\n\nThanks","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"b6d1356932b0a415bad7085c4716d247c764275f","unresolved":false,"context_lines":[{"line_number":960,"context_line":"                self.assertEqual(msg, data[\u0027NeutronError\u0027][\u0027message\u0027])"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"    def test_create_port_with_too_many_fixed_ips(self,"},{"line_number":963,"context_line":"            expected_error\u003d\u0027InvalidInput\u0027):"},{"line_number":964,"context_line":"        with self.network() as network:"},{"line_number":965,"context_line":"            with self.subnet(network\u003dnetwork, cidr\u003d\u002710.0.0.0/24\u0027) as subnet:"},{"line_number":966,"context_line":"                fixed_ips \u003d [{\u0027subnet_id\u0027: subnet[\u0027subnet\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_1db7953a","line":963,"range":{"start_line":963,"start_character":12,"end_line":963,"end_character":26},"in_reply_to":"fa69d971_dcd106fd","updated":"2015-12-31 08:10:19.000000000","message":"you don\u0027t need parameter since nobody will call this method with any other parameter","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"1ab9e56261fc7502795862ea48d2d86515815e55","unresolved":false,"context_lines":[{"line_number":1229,"context_line":"        req \u003d self.new_update_request(\u0027ports\u0027, data, port[\u0027id\u0027])"},{"line_number":1230,"context_line":"        return req.get_response(self.api), new_mac"},{"line_number":1231,"context_line":""},{"line_number":1232,"context_line":"    def check_update_dhcp_port_fixed_ips(self,"},{"line_number":1233,"context_line":"            expected_status\u003dwebob.exc.HTTPOk.code,"},{"line_number":1234,"context_line":"            subnet\u003dNone,"},{"line_number":1235,"context_line":"            device_owner\u003dconstants.DEVICE_OWNER_DHCP,"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_1ee9ef1a","line":1232,"range":{"start_line":1232,"start_character":8,"end_line":1232,"end_character":40},"updated":"2015-12-30 08:50:58.000000000","message":"why separate method? Can\u0027t this just be a single test case?","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"48ee8d028270102a5d9576595cb3edda5554fbe8","unresolved":false,"context_lines":[{"line_number":1229,"context_line":"        req \u003d self.new_update_request(\u0027ports\u0027, data, port[\u0027id\u0027])"},{"line_number":1230,"context_line":"        return req.get_response(self.api), new_mac"},{"line_number":1231,"context_line":""},{"line_number":1232,"context_line":"    def check_update_dhcp_port_fixed_ips(self,"},{"line_number":1233,"context_line":"            expected_status\u003dwebob.exc.HTTPOk.code,"},{"line_number":1234,"context_line":"            subnet\u003dNone,"},{"line_number":1235,"context_line":"            device_owner\u003dconstants.DEVICE_OWNER_DHCP,"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_474eb6c2","line":1232,"range":{"start_line":1232,"start_character":8,"end_line":1232,"end_character":40},"in_reply_to":"fa69d971_1ee9ef1a","updated":"2015-12-31 01:36:18.000000000","message":"Hi @Oleg Bondarev,\n\n1. I separated this method because I wish this check can be used for other tests regarding to fixed_ips of DHCP port if needed.\n\n2. This can be a single test case. And you mean is I don\u0027t need to separate \"check_update_dhcp_port_fixed_ips\" and \" test_update_dhcp_port_with_exceeding_fixed_ips\". Is it right?\nPlease help me to explain if I misunderstood you mean and What I should do in this case for more reasonable?\n\nThanks for your time and review.","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"b6d1356932b0a415bad7085c4716d247c764275f","unresolved":false,"context_lines":[{"line_number":1229,"context_line":"        req \u003d self.new_update_request(\u0027ports\u0027, data, port[\u0027id\u0027])"},{"line_number":1230,"context_line":"        return req.get_response(self.api), new_mac"},{"line_number":1231,"context_line":""},{"line_number":1232,"context_line":"    def check_update_dhcp_port_fixed_ips(self,"},{"line_number":1233,"context_line":"            expected_status\u003dwebob.exc.HTTPOk.code,"},{"line_number":1234,"context_line":"            subnet\u003dNone,"},{"line_number":1235,"context_line":"            device_owner\u003dconstants.DEVICE_OWNER_DHCP,"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_ddeedd21","line":1232,"range":{"start_line":1232,"start_character":8,"end_line":1232,"end_character":40},"in_reply_to":"fa69d971_474eb6c2","updated":"2015-12-31 08:10:19.000000000","message":"I meant YAGNI. I don\u0027t see any other test using this method except test_update_dhcp_port_with_exceeding_fixed_ips, so just make it a single test case.","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"447af8067de373825e364a0754f3c980f5c8852a","unresolved":false,"context_lines":[{"line_number":1229,"context_line":"        req \u003d self.new_update_request(\u0027ports\u0027, data, port[\u0027id\u0027])"},{"line_number":1230,"context_line":"        return req.get_response(self.api), new_mac"},{"line_number":1231,"context_line":""},{"line_number":1232,"context_line":"    def check_update_dhcp_port_fixed_ips(self,"},{"line_number":1233,"context_line":"            expected_status\u003dwebob.exc.HTTPOk.code,"},{"line_number":1234,"context_line":"            subnet\u003dNone,"},{"line_number":1235,"context_line":"            device_owner\u003dconstants.DEVICE_OWNER_DHCP,"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_bdd3e937","line":1232,"range":{"start_line":1232,"start_character":8,"end_line":1232,"end_character":40},"in_reply_to":"fa69d971_ddeedd21","updated":"2015-12-31 08:20:43.000000000","message":"Hi @Oleg Bondarev,\nOk, I understood. Thanks for your explanation.","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"1ab9e56261fc7502795862ea48d2d86515815e55","unresolved":false,"context_lines":[{"line_number":3469,"context_line":"        self.assertEqual(subnet[\u0027subnet\u0027][\u0027allocation_pools\u0027],"},{"line_number":3470,"context_line":"                         allocation_pools)"},{"line_number":3471,"context_line":""},{"line_number":3472,"context_line":"    def test_create_exceeding_subnets_with_dhcp_enabled_return_201(self):"},{"line_number":3473,"context_line":"        cfg.CONF.set_override(\u0027max_fixed_ips_per_port\u0027, 1)"},{"line_number":3474,"context_line":"        with self.network() as network:"},{"line_number":3475,"context_line":"            self._create_subnet(self.fmt, net_id\u003dnetwork[\u0027network\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_9e687fbc","line":3472,"range":{"start_line":3472,"start_character":8,"end_line":3472,"end_character":66},"updated":"2015-12-30 08:50:58.000000000","message":"This test passes both with and without the fix. The reason is that subnet creation does not lead to dhcp port create/update by itself. It is dhcp agent who does it. So I don\u0027t see the value in this test. IMO test_update_dhcp_port_with_exceeding_fixed_ips should be enough.","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"5a9f748c25533f41f82d564f10cd8bd004aaa192","unresolved":false,"context_lines":[{"line_number":3469,"context_line":"        self.assertEqual(subnet[\u0027subnet\u0027][\u0027allocation_pools\u0027],"},{"line_number":3470,"context_line":"                         allocation_pools)"},{"line_number":3471,"context_line":""},{"line_number":3472,"context_line":"    def test_create_exceeding_subnets_with_dhcp_enabled_return_201(self):"},{"line_number":3473,"context_line":"        cfg.CONF.set_override(\u0027max_fixed_ips_per_port\u0027, 1)"},{"line_number":3474,"context_line":"        with self.network() as network:"},{"line_number":3475,"context_line":"            self._create_subnet(self.fmt, net_id\u003dnetwork[\u0027network\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_de57d7c8","line":3472,"range":{"start_line":3472,"start_character":8,"end_line":3472,"end_character":66},"in_reply_to":"fa69d971_9e687fbc","updated":"2015-12-30 08:53:35.000000000","message":"I requested this test as this was part of the description for the bug. But we can drop this","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"},{"author":{"_account_id":17958,"name":"NGUYEN TUONG THANH","email":"ngtthanh1010@gmail.com","username":"thanhnt"},"change_message_id":"48ee8d028270102a5d9576595cb3edda5554fbe8","unresolved":false,"context_lines":[{"line_number":3469,"context_line":"        self.assertEqual(subnet[\u0027subnet\u0027][\u0027allocation_pools\u0027],"},{"line_number":3470,"context_line":"                         allocation_pools)"},{"line_number":3471,"context_line":""},{"line_number":3472,"context_line":"    def test_create_exceeding_subnets_with_dhcp_enabled_return_201(self):"},{"line_number":3473,"context_line":"        cfg.CONF.set_override(\u0027max_fixed_ips_per_port\u0027, 1)"},{"line_number":3474,"context_line":"        with self.network() as network:"},{"line_number":3475,"context_line":"            self._create_subnet(self.fmt, net_id\u003dnetwork[\u0027network\u0027][\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa69d971_0cb6a5dc","line":3472,"range":{"start_line":3472,"start_character":8,"end_line":3472,"end_character":66},"in_reply_to":"fa69d971_de57d7c8","updated":"2015-12-31 01:36:18.000000000","message":"@Oleg Bondarev, garyk:\nAbout your explanation, It really is reasonable. I will update this in next patch. Please take a look for that. Thanks.","commit_id":"4ba8d1a14730912623e9fdbccfe0b5bd27509153"}]}
