)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"f678e86ad6af22220fad88927b83eae6c7b26f57","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"objects: switch base plugin class to using subnetpool object"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Among non-obvious changes, the base object class was extended to allow"},{"line_number":10,"context_line":"for additional filter hook generation. This is needed to support"},{"line_number":11,"context_line":"timestamp based filter (changed_since) that is available for subnetpools"},{"line_number":12,"context_line":"and other standardattributes based objects."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"7aa08908_5b1baf1c","line":9,"updated":"2016-06-10 11:17:00.000000000","message":"This change is probably worth a separate patch...","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"736e49d1be1ce67a738cfa8f8594ab131f46a6a7","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"objects: switch base plugin class to using subnetpool object"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Among non-obvious changes, the base object class was extended to allow"},{"line_number":10,"context_line":"for additional filter hook generation. This is needed to support"},{"line_number":11,"context_line":"timestamp based filter (changed_since) that is available for subnetpools"},{"line_number":12,"context_line":"and other standardattributes based objects."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"7aa08908_23b9557a","line":9,"in_reply_to":"7aa08908_5b1baf1c","updated":"2016-06-10 12:22:20.000000000","message":"I\u0027ll do that though introducing hooking mechanism for filter names is YAGNI at this point.","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"}],"neutron/db/address_scope_db.py":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"a148d6a0e0e0996f7ab3169bac6d7616f7d20bcd","unresolved":false,"context_lines":[{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def delete_address_scope(self, context, id):"},{"line_number":124,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":125,"context_line":"            if self._get_subnetpools_by_address_scope_id(context, id):"},{"line_number":126,"context_line":"                raise ext_address_scope.AddressScopeInUse(address_scope_id\u003did)"},{"line_number":127,"context_line":"            address_scope \u003d self._get_address_scope(context, id)"},{"line_number":128,"context_line":"            context.session.delete(address_scope)"}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_abd2c1ce","side":"PARENT","line":125,"updated":"2016-06-14 10:33:15.000000000","message":"I see in next file the function has been removed, good :)","commit_id":"3ead5f959e0c507da9457c6aa93cd039a973a3f8"}],"neutron/db/db_base_plugin_v2.py":[{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"5255ceb1c614500355eb34c496b7c6f5a55c4bc0","unresolved":false,"context_lines":[{"line_number":981,"context_line":"        self._validate_address_scope_id(context, sp_reader.address_scope_id,"},{"line_number":982,"context_line":"                                        id, sp_reader.prefixes,"},{"line_number":983,"context_line":"                                        sp_reader.ip_version)"},{"line_number":984,"context_line":"        pool_args \u003d {\u0027tenant_id\u0027: sp[\u0027tenant_id\u0027],"},{"line_number":985,"context_line":"                     \u0027id\u0027: sp_reader.id,"},{"line_number":986,"context_line":"                     \u0027name\u0027: sp_reader.name,"},{"line_number":987,"context_line":"                     \u0027ip_version\u0027: sp_reader.ip_version,"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_7b164156","line":984,"range":{"start_line":984,"start_character":21,"end_line":984,"end_character":49},"updated":"2016-06-07 12:08:24.000000000","message":"how about effort to rename the tenant_id to project_id, can it be done with OVO adoption?\nBut still, if we want to be backward compatible, then we need to return the tenant_id at the client side using OVO.\nMaybe it is not related to create method, but general suggestion.","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"02ddffbcc677f9930a8ebd75a8f6f800fa60e6c1","unresolved":false,"context_lines":[{"line_number":998,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool(context, **pool_args)"},{"line_number":999,"context_line":"        subnetpool.create()"},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"        return self._make_subnetpool_dict(subnetpool)"},{"line_number":1002,"context_line":""},{"line_number":1003,"context_line":"    def _updated_subnetpool_dict(self, orig_pool, new_pool):"},{"line_number":1004,"context_line":"        updated \u003d {}"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_a00d1739","line":1001,"range":{"start_line":1001,"start_character":15,"end_line":1001,"end_character":53},"updated":"2016-06-07 11:08:32.000000000","message":"do we still want to return the subnetpool dict? or should we return the object instead?","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"5255ceb1c614500355eb34c496b7c6f5a55c4bc0","unresolved":false,"context_lines":[{"line_number":998,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool(context, **pool_args)"},{"line_number":999,"context_line":"        subnetpool.create()"},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"        return self._make_subnetpool_dict(subnetpool)"},{"line_number":1002,"context_line":""},{"line_number":1003,"context_line":"    def _updated_subnetpool_dict(self, orig_pool, new_pool):"},{"line_number":1004,"context_line":"        updated \u003d {}"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_fb54f121","line":1001,"range":{"start_line":1001,"start_character":15,"end_line":1001,"end_character":53},"in_reply_to":"7aa08908_98a6930e","updated":"2016-06-07 12:08:24.000000000","message":"Sounds good.","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"5f8ddb3fee1a3045776d7ac632b62525874dcab8","unresolved":false,"context_lines":[{"line_number":998,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool(context, **pool_args)"},{"line_number":999,"context_line":"        subnetpool.create()"},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"        return self._make_subnetpool_dict(subnetpool)"},{"line_number":1002,"context_line":""},{"line_number":1003,"context_line":"    def _updated_subnetpool_dict(self, orig_pool, new_pool):"},{"line_number":1004,"context_line":"        updated \u003d {}"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_98a6930e","line":1001,"range":{"start_line":1001,"start_character":15,"end_line":1001,"end_character":53},"in_reply_to":"7aa08908_a00d1739","updated":"2016-06-07 11:32:48.000000000","message":"Good point, I talked with Ihar about that and the plan is to just replace using db interaction in order to make live upgrade possible, keeping the API of db plugin using dicts. Then we can switch to objects.","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"02ddffbcc677f9930a8ebd75a8f6f800fa60e6c1","unresolved":false,"context_lines":[{"line_number":1028,"context_line":""},{"line_number":1029,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1030,"context_line":"            orig_sp \u003d subnetpool_obj.SubnetPool.get_object(context, id\u003did)"},{"line_number":1031,"context_line":"            updated \u003d self._updated_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1032,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1033,"context_line":"            if reader.is_default and not orig_sp.is_default:"},{"line_number":1034,"context_line":"                self._check_default_subnetpool_exists(context,"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_9b7210ac","line":1031,"range":{"start_line":1031,"start_character":28,"end_line":1031,"end_character":51},"updated":"2016-06-07 11:08:32.000000000","message":"_update_subnetpool_object? Get rid of dict?","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"5f8ddb3fee1a3045776d7ac632b62525874dcab8","unresolved":false,"context_lines":[{"line_number":1028,"context_line":""},{"line_number":1029,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1030,"context_line":"            orig_sp \u003d subnetpool_obj.SubnetPool.get_object(context, id\u003did)"},{"line_number":1031,"context_line":"            updated \u003d self._updated_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1032,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1033,"context_line":"            if reader.is_default and not orig_sp.is_default:"},{"line_number":1034,"context_line":"                self._check_default_subnetpool_exists(context,"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_d8977b8e","line":1031,"range":{"start_line":1031,"start_character":28,"end_line":1031,"end_character":51},"in_reply_to":"7aa08908_9b7210ac","updated":"2016-06-07 11:32:48.000000000","message":"Hmm, maybe you\u0027re right. I need to look what is the SubnetPoolReader, its code is so confusing.","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"02ddffbcc677f9930a8ebd75a8f6f800fa60e6c1","unresolved":false,"context_lines":[{"line_number":1064,"context_line":"                                          updated, orig_sp)"},{"line_number":1065,"context_line":"        return updated"},{"line_number":1066,"context_line":""},{"line_number":1067,"context_line":"    def get_subnetpool(self, context, id, fields\u003dNone, filters\u003dNone):"},{"line_number":1068,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool.get_object(context, id\u003did)"},{"line_number":1069,"context_line":"        if not subnetpool:"},{"line_number":1070,"context_line":"            raise n_exc.SubnetPoolNotFound(subnetpool_id\u003did)"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_60a5efb3","line":1067,"range":{"start_line":1067,"start_character":55,"end_line":1067,"end_character":67},"updated":"2016-06-07 11:08:32.000000000","message":"Filters not used?","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"5f8ddb3fee1a3045776d7ac632b62525874dcab8","unresolved":false,"context_lines":[{"line_number":1064,"context_line":"                                          updated, orig_sp)"},{"line_number":1065,"context_line":"        return updated"},{"line_number":1066,"context_line":""},{"line_number":1067,"context_line":"    def get_subnetpool(self, context, id, fields\u003dNone, filters\u003dNone):"},{"line_number":1068,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool.get_object(context, id\u003did)"},{"line_number":1069,"context_line":"        if not subnetpool:"},{"line_number":1070,"context_line":"            raise n_exc.SubnetPoolNotFound(subnetpool_id\u003did)"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_b8d9cf85","line":1067,"range":{"start_line":1067,"start_character":55,"end_line":1067,"end_character":67},"in_reply_to":"7aa08908_60a5efb3","updated":"2016-06-07 11:32:48.000000000","message":"Good catch, thanks!","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"02ddffbcc677f9930a8ebd75a8f6f800fa60e6c1","unresolved":false,"context_lines":[{"line_number":1068,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool.get_object(context, id\u003did)"},{"line_number":1069,"context_line":"        if not subnetpool:"},{"line_number":1070,"context_line":"            raise n_exc.SubnetPoolNotFound(subnetpool_id\u003did)"},{"line_number":1071,"context_line":"        return self._make_subnetpool_dict(subnetpool, fields)"},{"line_number":1072,"context_line":""},{"line_number":1073,"context_line":"    def get_subnetpools(self, context, filters\u003dNone, fields\u003dNone,"},{"line_number":1074,"context_line":"                        sorts\u003dNone, limit\u003dNone, marker\u003dNone,"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_40f393d6","line":1071,"range":{"start_line":1071,"start_character":21,"end_line":1071,"end_character":41},"updated":"2016-06-07 11:08:32.000000000","message":"The same line 1001.","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"5f8ddb3fee1a3045776d7ac632b62525874dcab8","unresolved":false,"context_lines":[{"line_number":1068,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool.get_object(context, id\u003did)"},{"line_number":1069,"context_line":"        if not subnetpool:"},{"line_number":1070,"context_line":"            raise n_exc.SubnetPoolNotFound(subnetpool_id\u003did)"},{"line_number":1071,"context_line":"        return self._make_subnetpool_dict(subnetpool, fields)"},{"line_number":1072,"context_line":""},{"line_number":1073,"context_line":"    def get_subnetpools(self, context, filters\u003dNone, fields\u003dNone,"},{"line_number":1074,"context_line":"                        sorts\u003dNone, limit\u003dNone, marker\u003dNone,"}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_f8e35731","line":1071,"range":{"start_line":1071,"start_character":21,"end_line":1071,"end_character":41},"in_reply_to":"7aa08908_40f393d6","updated":"2016-06-07 11:32:48.000000000","message":"The same answer :)","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"02ddffbcc677f9930a8ebd75a8f6f800fa60e6c1","unresolved":false,"context_lines":[{"line_number":1077,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1078,"context_line":"            context, _pager\u003dpager, **filters)"},{"line_number":1079,"context_line":"        return ["},{"line_number":1080,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1081,"context_line":"            for pool in subnetpools"},{"line_number":1082,"context_line":"        ]"},{"line_number":1083,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_c0de633e","line":1080,"range":{"start_line":1080,"start_character":17,"end_line":1080,"end_character":38},"updated":"2016-06-07 11:08:32.000000000","message":"The same line 1001.","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"5f8ddb3fee1a3045776d7ac632b62525874dcab8","unresolved":false,"context_lines":[{"line_number":1077,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1078,"context_line":"            context, _pager\u003dpager, **filters)"},{"line_number":1079,"context_line":"        return ["},{"line_number":1080,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1081,"context_line":"            for pool in subnetpools"},{"line_number":1082,"context_line":"        ]"},{"line_number":1083,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"7aa08908_38d4bf45","line":1080,"range":{"start_line":1080,"start_character":17,"end_line":1080,"end_character":38},"in_reply_to":"7aa08908_c0de633e","updated":"2016-06-07 11:32:48.000000000","message":"The same answer :)","commit_id":"2ac6c9f7be7653208bf8a6eabff0fed08ada5bc8"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"5b30bcd546e07b6390ea1c0d59824a75cb18a049","unresolved":false,"context_lines":[{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"        return self._make_subnetpool_dict(subnetpool)"},{"line_number":1002,"context_line":""},{"line_number":1003,"context_line":"    def _updated_subnetpool_dict(self, orig_pool, new_pool):"},{"line_number":1004,"context_line":"        updated \u003d {}"},{"line_number":1005,"context_line":"        new_prefixes \u003d new_pool.get(\u0027prefixes\u0027, attributes.ATTR_NOT_SPECIFIED)"},{"line_number":1006,"context_line":"        if new_prefixes is not attributes.ATTR_NOT_SPECIFIED:"}],"source_content_type":"text/x-python","patch_set":7,"id":"7aa08908_dcf6fd8d","line":1003,"range":{"start_line":1003,"start_character":15,"end_line":1003,"end_character":16},"updated":"2016-06-08 12:30:34.000000000","message":"Ah, so it was probably me, who changed this to \"updated\". I was wondering why it\u0027s called that way when reading code :)","commit_id":"049cbe5e436c9675fc70b91886577e00b36aad6a"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":974,"context_line":"            raise exc.InvalidInput(error_message\u003dmsg)"},{"line_number":975,"context_line":""},{"line_number":976,"context_line":"    def create_subnetpool(self, context, subnetpool):"},{"line_number":977,"context_line":"        \"\"\"Create a subnetpool\"\"\""},{"line_number":978,"context_line":""},{"line_number":979,"context_line":"        sp \u003d subnetpool[\u0027subnetpool\u0027]"},{"line_number":980,"context_line":"        sp_reader \u003d subnet_alloc.SubnetPoolReader(sp)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_c0a1e747","side":"PARENT","line":977,"range":{"start_line":977,"start_character":7,"end_line":977,"end_character":33},"updated":"2016-06-08 14:42:08.000000000","message":"So useful.","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":1041,"context_line":"            self._write_key(key, updated, model, new_pool)"},{"line_number":1042,"context_line":"        return updated"},{"line_number":1043,"context_line":""},{"line_number":1044,"context_line":"    def _write_key(self, key, update, orig, new_dict):"},{"line_number":1045,"context_line":"        new_val \u003d new_dict.get(key, constants.ATTR_NOT_SPECIFIED)"},{"line_number":1046,"context_line":"        if new_val is not constants.ATTR_NOT_SPECIFIED:"},{"line_number":1047,"context_line":"            update[key] \u003d new_dict[key]"},{"line_number":1048,"context_line":"        else:"},{"line_number":1049,"context_line":"            update[key] \u003d orig[key]"},{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"    def update_subnetpool(self, context, id, subnetpool):"},{"line_number":1052,"context_line":"        \"\"\"Update a subnetpool\"\"\""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_b6ad059d","side":"PARENT","line":1049,"range":{"start_line":1044,"start_character":8,"end_line":1049,"end_character":35},"updated":"2016-06-08 14:42:08.000000000","message":"That\u0027s ridiculous.","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":1049,"context_line":"            update[key] \u003d orig[key]"},{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"    def update_subnetpool(self, context, id, subnetpool):"},{"line_number":1052,"context_line":"        \"\"\"Update a subnetpool\"\"\""},{"line_number":1053,"context_line":"        new_sp \u003d subnetpool[\u0027subnetpool\u0027]"},{"line_number":1054,"context_line":""},{"line_number":1055,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_d698916c","side":"PARENT","line":1052,"range":{"start_line":1052,"start_character":8,"end_line":1052,"end_character":33},"updated":"2016-06-08 14:42:08.000000000","message":"Another useful comment. Now that I read it, it\u0027s all clear.","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":1055,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1056,"context_line":"            orig_sp \u003d self._get_subnetpool(context, id)"},{"line_number":1057,"context_line":"            updated \u003d self._updated_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1058,"context_line":"            updated[\u0027tenant_id\u0027] \u003d orig_sp.tenant_id"},{"line_number":1059,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1060,"context_line":"            if reader.is_default and not orig_sp.is_default:"},{"line_number":1061,"context_line":"                self._check_default_subnetpool_exists(context,"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_1671790f","side":"PARENT","line":1058,"range":{"start_line":1058,"start_character":12,"end_line":1058,"end_character":52},"updated":"2016-06-08 14:42:08.000000000","message":"I think it should stay. At least until SubnetPoolReader considers that value.","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":1055,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1056,"context_line":"            orig_sp \u003d self._get_subnetpool(context, id)"},{"line_number":1057,"context_line":"            updated \u003d self._updated_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1058,"context_line":"            updated[\u0027tenant_id\u0027] \u003d orig_sp.tenant_id"},{"line_number":1059,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1060,"context_line":"            if reader.is_default and not orig_sp.is_default:"},{"line_number":1061,"context_line":"                self._check_default_subnetpool_exists(context,"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_22eb8be0","side":"PARENT","line":1058,"range":{"start_line":1058,"start_character":12,"end_line":1058,"end_character":52},"in_reply_to":"7aa08908_1671790f","updated":"2016-06-08 15:00:35.000000000","message":"It\u0027s implicitly executed on L1020","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e57079da6647257dc303dac6dee3bbab74834096","unresolved":false,"context_lines":[{"line_number":1055,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1056,"context_line":"            orig_sp \u003d self._get_subnetpool(context, id)"},{"line_number":1057,"context_line":"            updated \u003d self._updated_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1058,"context_line":"            updated[\u0027tenant_id\u0027] \u003d orig_sp.tenant_id"},{"line_number":1059,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1060,"context_line":"            if reader.is_default and not orig_sp.is_default:"},{"line_number":1061,"context_line":"                self._check_default_subnetpool_exists(context,"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_472fc63e","side":"PARENT","line":1058,"range":{"start_line":1058,"start_character":12,"end_line":1058,"end_character":52},"in_reply_to":"7aa08908_22eb8be0","updated":"2016-06-08 15:09:25.000000000","message":"Not really: if new_pool has the key, the new_pool one will be used. And here, we try to guard against API rewriting ownership.","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"e1cb42ad063051d5c86272524599c5226d1bc20b","unresolved":false,"context_lines":[{"line_number":1055,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1056,"context_line":"            orig_sp \u003d self._get_subnetpool(context, id)"},{"line_number":1057,"context_line":"            updated \u003d self._updated_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1058,"context_line":"            updated[\u0027tenant_id\u0027] \u003d orig_sp.tenant_id"},{"line_number":1059,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1060,"context_line":"            if reader.is_default and not orig_sp.is_default:"},{"line_number":1061,"context_line":"                self._check_default_subnetpool_exists(context,"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_8aaa5583","side":"PARENT","line":1058,"range":{"start_line":1058,"start_character":12,"end_line":1058,"end_character":52},"in_reply_to":"7aa08908_472fc63e","updated":"2016-06-08 15:17:04.000000000","message":"This is guarded on L1049, no?","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0d14d4cc13326fc7fe975d3b3b752f7490505df1","unresolved":false,"context_lines":[{"line_number":1055,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1056,"context_line":"            orig_sp \u003d self._get_subnetpool(context, id)"},{"line_number":1057,"context_line":"            updated \u003d self._updated_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1058,"context_line":"            updated[\u0027tenant_id\u0027] \u003d orig_sp.tenant_id"},{"line_number":1059,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1060,"context_line":"            if reader.is_default and not orig_sp.is_default:"},{"line_number":1061,"context_line":"                self._check_default_subnetpool_exists(context,"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_cdd477ed","side":"PARENT","line":1058,"range":{"start_line":1058,"start_character":12,"end_line":1058,"end_character":52},"in_reply_to":"7aa08908_8aaa5583","updated":"2016-06-08 15:27:45.000000000","message":"You are right, sorry. :)","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":1112,"context_line":""},{"line_number":1113,"context_line":"    def get_default_subnetpool(self, context, ip_version):"},{"line_number":1114,"context_line":"        \"\"\"Retrieve the default subnetpool for the given IP version.\"\"\""},{"line_number":1115,"context_line":"        filters \u003d {\u0027is_default\u0027: [True],"},{"line_number":1116,"context_line":"                   \u0027ip_version\u0027: [ip_version]}"},{"line_number":1117,"context_line":"        subnetpool \u003d self.get_subnetpools(context, filters\u003dfilters)"},{"line_number":1118,"context_line":"        if subnetpool:"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_712f27a1","side":"PARENT","line":1115,"range":{"start_line":1115,"start_character":33,"end_line":1115,"end_character":39},"updated":"2016-06-08 14:42:08.000000000","message":"NICE","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e57079da6647257dc303dac6dee3bbab74834096","unresolved":false,"context_lines":[{"line_number":1112,"context_line":""},{"line_number":1113,"context_line":"    def get_default_subnetpool(self, context, ip_version):"},{"line_number":1114,"context_line":"        \"\"\"Retrieve the default subnetpool for the given IP version.\"\"\""},{"line_number":1115,"context_line":"        filters \u003d {\u0027is_default\u0027: [True],"},{"line_number":1116,"context_line":"                   \u0027ip_version\u0027: [ip_version]}"},{"line_number":1117,"context_line":"        subnetpool \u003d self.get_subnetpools(context, filters\u003dfilters)"},{"line_number":1118,"context_line":"        if subnetpool:"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_07c81e73","side":"PARENT","line":1115,"range":{"start_line":1115,"start_character":33,"end_line":1115,"end_character":39},"in_reply_to":"7aa08908_02af6f2a","updated":"2016-06-08 15:09:25.000000000","message":"But it\u0027s a tad cleaner.","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":1112,"context_line":""},{"line_number":1113,"context_line":"    def get_default_subnetpool(self, context, ip_version):"},{"line_number":1114,"context_line":"        \"\"\"Retrieve the default subnetpool for the given IP version.\"\"\""},{"line_number":1115,"context_line":"        filters \u003d {\u0027is_default\u0027: [True],"},{"line_number":1116,"context_line":"                   \u0027ip_version\u0027: [ip_version]}"},{"line_number":1117,"context_line":"        subnetpool \u003d self.get_subnetpools(context, filters\u003dfilters)"},{"line_number":1118,"context_line":"        if subnetpool:"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_02af6f2a","side":"PARENT","line":1115,"range":{"start_line":1115,"start_character":33,"end_line":1115,"end_character":39},"in_reply_to":"7aa08908_712f27a1","updated":"2016-06-08 15:00:35.000000000","message":"It actually doesn\u0027t matter now :)","commit_id":"9e7137f7f6c54e19821adf4aad7c3d1fd1e5ad6e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":994,"context_line":"                     \u0027default_quota\u0027: sp_reader.default_quota,"},{"line_number":995,"context_line":"                     \u0027address_scope_id\u0027: sp_reader.address_scope_id,"},{"line_number":996,"context_line":"                     \u0027description\u0027: sp_reader.description,"},{"line_number":997,"context_line":"                     \u0027prefixes\u0027: sp[\u0027prefixes\u0027]}"},{"line_number":998,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool(context, **pool_args)"},{"line_number":999,"context_line":"        subnetpool.create()"},{"line_number":1000,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_2029cb9e","line":997,"range":{"start_line":997,"start_character":33,"end_line":997,"end_character":47},"updated":"2016-06-08 14:42:08.000000000","message":"I think we still need to use sp.prefixes because there is some pre-processing for prefixes, specifically in _compact_subnetpool_prefix_list.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":994,"context_line":"                     \u0027default_quota\u0027: sp_reader.default_quota,"},{"line_number":995,"context_line":"                     \u0027address_scope_id\u0027: sp_reader.address_scope_id,"},{"line_number":996,"context_line":"                     \u0027description\u0027: sp_reader.description,"},{"line_number":997,"context_line":"                     \u0027prefixes\u0027: sp[\u0027prefixes\u0027]}"},{"line_number":998,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool(context, **pool_args)"},{"line_number":999,"context_line":"        subnetpool.create()"},{"line_number":1000,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_67064521","line":997,"range":{"start_line":997,"start_character":33,"end_line":997,"end_character":47},"in_reply_to":"7aa08908_2029cb9e","updated":"2016-06-08 15:00:35.000000000","message":"You mean sp_reader.prefixes, right?","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e57079da6647257dc303dac6dee3bbab74834096","unresolved":false,"context_lines":[{"line_number":994,"context_line":"                     \u0027default_quota\u0027: sp_reader.default_quota,"},{"line_number":995,"context_line":"                     \u0027address_scope_id\u0027: sp_reader.address_scope_id,"},{"line_number":996,"context_line":"                     \u0027description\u0027: sp_reader.description,"},{"line_number":997,"context_line":"                     \u0027prefixes\u0027: sp[\u0027prefixes\u0027]}"},{"line_number":998,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool(context, **pool_args)"},{"line_number":999,"context_line":"        subnetpool.create()"},{"line_number":1000,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_4750660b","line":997,"range":{"start_line":997,"start_character":33,"end_line":997,"end_character":47},"in_reply_to":"7aa08908_67064521","updated":"2016-06-08 15:09:25.000000000","message":"Eh, right.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":1017,"context_line":"            updated[\u0027prefixes\u0027] \u003d [str(prefix)"},{"line_number":1018,"context_line":"                                   for prefix in orig_pool.prefixes]"},{"line_number":1019,"context_line":""},{"line_number":1020,"context_line":"        keys_to_update \u003d list(subnetpool_obj.SubnetPool.fields.keys())"},{"line_number":1021,"context_line":"        keys_to_update.remove(\u0027prefixes\u0027)"},{"line_number":1022,"context_line":"        for key in keys_to_update:"},{"line_number":1023,"context_line":"            updated[key] \u003d new_pool.get(key, orig_pool[key])"},{"line_number":1024,"context_line":"        return updated"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_561ae117","line":1021,"range":{"start_line":1020,"start_character":8,"end_line":1021,"end_character":41},"updated":"2016-06-08 14:42:08.000000000","message":"keys_to_update \u003d (\n    set(subnetpool_obj.SubnetPool.fields.keys()) - \\\n    set(subnetpool_obj.SubnetPool.synthetic_fields\n)\n\nMaybe it\u0027s worth adding a method for that in base class? Not sure.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":1017,"context_line":"            updated[\u0027prefixes\u0027] \u003d [str(prefix)"},{"line_number":1018,"context_line":"                                   for prefix in orig_pool.prefixes]"},{"line_number":1019,"context_line":""},{"line_number":1020,"context_line":"        keys_to_update \u003d list(subnetpool_obj.SubnetPool.fields.keys())"},{"line_number":1021,"context_line":"        keys_to_update.remove(\u0027prefixes\u0027)"},{"line_number":1022,"context_line":"        for key in keys_to_update:"},{"line_number":1023,"context_line":"            updated[key] \u003d new_pool.get(key, orig_pool[key])"},{"line_number":1024,"context_line":"        return updated"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_a23adb96","line":1021,"range":{"start_line":1020,"start_character":8,"end_line":1021,"end_character":41},"in_reply_to":"7aa08908_561ae117","updated":"2016-06-08 15:00:35.000000000","message":"Hmm, does it mean we should explicitly handle other synthetic_fields here? I removed it because prefixes are handled on L1014 and L1017","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e57079da6647257dc303dac6dee3bbab74834096","unresolved":false,"context_lines":[{"line_number":1017,"context_line":"            updated[\u0027prefixes\u0027] \u003d [str(prefix)"},{"line_number":1018,"context_line":"                                   for prefix in orig_pool.prefixes]"},{"line_number":1019,"context_line":""},{"line_number":1020,"context_line":"        keys_to_update \u003d list(subnetpool_obj.SubnetPool.fields.keys())"},{"line_number":1021,"context_line":"        keys_to_update.remove(\u0027prefixes\u0027)"},{"line_number":1022,"context_line":"        for key in keys_to_update:"},{"line_number":1023,"context_line":"            updated[key] \u003d new_pool.get(key, orig_pool[key])"},{"line_number":1024,"context_line":"        return updated"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_a7adcaea","line":1021,"range":{"start_line":1020,"start_character":8,"end_line":1021,"end_character":41},"in_reply_to":"7aa08908_a23adb96","updated":"2016-06-08 15:09:25.000000000","message":"I think for subnetpools, the only synthetic is prefixes here, so it doesn\u0027t matter much. it just seems to me that .remove(prefixes) is a bit ad-hoc, but I don\u0027t insist.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":1064,"context_line":"                                          updated, orig_sp)"},{"line_number":1065,"context_line":"        return updated"},{"line_number":1066,"context_line":""},{"line_number":1067,"context_line":"    def get_subnetpool(self, context, id, fields\u003dNone, filters\u003dNone):"},{"line_number":1068,"context_line":"        filters \u003d filters or {}"},{"line_number":1069,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool.get_object("},{"line_number":1070,"context_line":"            context, id\u003did, **filters)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_b12eaff8","line":1067,"range":{"start_line":1067,"start_character":53,"end_line":1067,"end_character":67},"updated":"2016-06-08 14:42:08.000000000","message":"Hm, why does the method support filters? I don\u0027t think that filters are ever passed from API layer?.. https://github.com/openstack/neutron/blob/master/neutron/api/v2/base.py#L320","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e57079da6647257dc303dac6dee3bbab74834096","unresolved":false,"context_lines":[{"line_number":1064,"context_line":"                                          updated, orig_sp)"},{"line_number":1065,"context_line":"        return updated"},{"line_number":1066,"context_line":""},{"line_number":1067,"context_line":"    def get_subnetpool(self, context, id, fields\u003dNone, filters\u003dNone):"},{"line_number":1068,"context_line":"        filters \u003d filters or {}"},{"line_number":1069,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool.get_object("},{"line_number":1070,"context_line":"            context, id\u003did, **filters)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_47bd06d7","line":1067,"range":{"start_line":1067,"start_character":53,"end_line":1067,"end_character":67},"in_reply_to":"7aa08908_228d4bd6","updated":"2016-06-08 15:09:25.000000000","message":"get_object in db_api supports multiple keys because we want to be able to pass multiple primary keys. But API does not support fetching with multiple keys. On API, only ID is exposed.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":1064,"context_line":"                                          updated, orig_sp)"},{"line_number":1065,"context_line":"        return updated"},{"line_number":1066,"context_line":""},{"line_number":1067,"context_line":"    def get_subnetpool(self, context, id, fields\u003dNone, filters\u003dNone):"},{"line_number":1068,"context_line":"        filters \u003d filters or {}"},{"line_number":1069,"context_line":"        subnetpool \u003d subnetpool_obj.SubnetPool.get_object("},{"line_number":1070,"context_line":"            context, id\u003did, **filters)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_228d4bd6","line":1067,"range":{"start_line":1067,"start_character":53,"end_line":1067,"end_character":67},"in_reply_to":"7aa08908_b12eaff8","updated":"2016-06-08 15:00:35.000000000","message":"Aha, I put it there according get_object() from db api that supports filtering.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"fdfeaa2edb16d570a2cda176fd0e31d87a33a7b1","unresolved":false,"context_lines":[{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"        return self._make_subnetpool_dict(subnetpool)"},{"line_number":1002,"context_line":""},{"line_number":1003,"context_line":"    def _update_subnetpool_dict(self, orig_pool, new_pool):"},{"line_number":1004,"context_line":"        keys_to_update \u003d ("},{"line_number":1005,"context_line":"            set(orig_pool.fields.keys()) - set(orig_pool.synthetic_fields))"},{"line_number":1006,"context_line":"        updated \u003d {k: new_pool.get(k, orig_pool[k]) for k in keys_to_update}"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_10779da0","line":1003,"updated":"2016-06-09 00:10:21.000000000","message":"Nit: self is not used so this can be a @staticmethod.","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"05eec6a263b07cf0e8bce847d0c3d7e24ed625dd","unresolved":false,"context_lines":[{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"        return self._make_subnetpool_dict(subnetpool)"},{"line_number":1002,"context_line":""},{"line_number":1003,"context_line":"    def _update_subnetpool_dict(self, orig_pool, new_pool):"},{"line_number":1004,"context_line":"        keys_to_update \u003d ("},{"line_number":1005,"context_line":"            set(orig_pool.fields.keys()) - set(orig_pool.synthetic_fields))"},{"line_number":1006,"context_line":"        updated \u003d {k: new_pool.get(k, orig_pool[k]) for k in keys_to_update}"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_c51a677c","line":1003,"in_reply_to":"7aa08908_10779da0","updated":"2016-06-09 09:00:17.000000000","message":"I moved it outside of the class.","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"fdfeaa2edb16d570a2cda176fd0e31d87a33a7b1","unresolved":false,"context_lines":[{"line_number":1005,"context_line":"            set(orig_pool.fields.keys()) - set(orig_pool.synthetic_fields))"},{"line_number":1006,"context_line":"        updated \u003d {k: new_pool.get(k, orig_pool[k]) for k in keys_to_update}"},{"line_number":1007,"context_line":""},{"line_number":1008,"context_line":"        new_prefixes \u003d new_pool.get(\u0027prefixes\u0027, attributes.ATTR_NOT_SPECIFIED)"},{"line_number":1009,"context_line":"        if new_prefixes is not attributes.ATTR_NOT_SPECIFIED:"},{"line_number":1010,"context_line":"            orig_ip_set \u003d netaddr.IPSet(orig_pool.prefixes)"},{"line_number":1011,"context_line":"            new_ip_set \u003d netaddr.IPSet(new_prefixes)"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_90442d4a","line":1008,"range":{"start_line":1008,"start_character":48,"end_line":1008,"end_character":58},"updated":"2016-06-09 00:10:21.000000000","message":"constants","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"05eec6a263b07cf0e8bce847d0c3d7e24ed625dd","unresolved":false,"context_lines":[{"line_number":1005,"context_line":"            set(orig_pool.fields.keys()) - set(orig_pool.synthetic_fields))"},{"line_number":1006,"context_line":"        updated \u003d {k: new_pool.get(k, orig_pool[k]) for k in keys_to_update}"},{"line_number":1007,"context_line":""},{"line_number":1008,"context_line":"        new_prefixes \u003d new_pool.get(\u0027prefixes\u0027, attributes.ATTR_NOT_SPECIFIED)"},{"line_number":1009,"context_line":"        if new_prefixes is not attributes.ATTR_NOT_SPECIFIED:"},{"line_number":1010,"context_line":"            orig_ip_set \u003d netaddr.IPSet(orig_pool.prefixes)"},{"line_number":1011,"context_line":"            new_ip_set \u003d netaddr.IPSet(new_prefixes)"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_e8213a9f","line":1008,"range":{"start_line":1008,"start_character":48,"end_line":1008,"end_character":58},"in_reply_to":"7aa08908_90442d4a","updated":"2016-06-09 09:00:17.000000000","message":"Done","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"fdfeaa2edb16d570a2cda176fd0e31d87a33a7b1","unresolved":false,"context_lines":[{"line_number":1006,"context_line":"        updated \u003d {k: new_pool.get(k, orig_pool[k]) for k in keys_to_update}"},{"line_number":1007,"context_line":""},{"line_number":1008,"context_line":"        new_prefixes \u003d new_pool.get(\u0027prefixes\u0027, attributes.ATTR_NOT_SPECIFIED)"},{"line_number":1009,"context_line":"        if new_prefixes is not attributes.ATTR_NOT_SPECIFIED:"},{"line_number":1010,"context_line":"            orig_ip_set \u003d netaddr.IPSet(orig_pool.prefixes)"},{"line_number":1011,"context_line":"            new_ip_set \u003d netaddr.IPSet(new_prefixes)"},{"line_number":1012,"context_line":"            if not orig_ip_set.issubset(new_ip_set):"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_703f01b4","line":1009,"range":{"start_line":1009,"start_character":31,"end_line":1009,"end_character":41},"updated":"2016-06-09 00:10:21.000000000","message":"constants","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"05eec6a263b07cf0e8bce847d0c3d7e24ed625dd","unresolved":false,"context_lines":[{"line_number":1006,"context_line":"        updated \u003d {k: new_pool.get(k, orig_pool[k]) for k in keys_to_update}"},{"line_number":1007,"context_line":""},{"line_number":1008,"context_line":"        new_prefixes \u003d new_pool.get(\u0027prefixes\u0027, attributes.ATTR_NOT_SPECIFIED)"},{"line_number":1009,"context_line":"        if new_prefixes is not attributes.ATTR_NOT_SPECIFIED:"},{"line_number":1010,"context_line":"            orig_ip_set \u003d netaddr.IPSet(orig_pool.prefixes)"},{"line_number":1011,"context_line":"            new_ip_set \u003d netaddr.IPSet(new_prefixes)"},{"line_number":1012,"context_line":"            if not orig_ip_set.issubset(new_ip_set):"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_483deec2","line":1009,"range":{"start_line":1009,"start_character":31,"end_line":1009,"end_character":41},"in_reply_to":"7aa08908_703f01b4","updated":"2016-06-09 09:00:17.000000000","message":"Done","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"aeb92e02112340da5b9da343e3e1664a5eb6778a","unresolved":false,"context_lines":[{"line_number":1043,"context_line":"                orig_sp.address_scope_id !\u003d reader.address_scope_id)"},{"line_number":1044,"context_line":""},{"line_number":1045,"context_line":"            for k, v in dict(reader.subnetpool).items():"},{"line_number":1046,"context_line":"                # TODO(ihrachys): we should probably have some helper method in"},{"line_number":1047,"context_line":"                # base object to update just updatable fields"},{"line_number":1048,"context_line":"                if k not in subnetpool_obj.SubnetPool.fields_no_update:"},{"line_number":1049,"context_line":"                    orig_sp[k] \u003d v"},{"line_number":1050,"context_line":"            orig_sp.update()"}],"source_content_type":"text/x-python","patch_set":10,"id":"7aa08908_f710f25b","line":1047,"range":{"start_line":1046,"start_character":16,"end_line":1047,"end_character":61},"updated":"2016-06-09 10:57:31.000000000","message":"There is a method update_nonidentifying_fields()[1] in base, maybe we can reuse it here? or modify it...\n\n[1] https://github.com/openstack/neutron/blob/master/neutron/objects/base.py#L376","commit_id":"a84dfa297d745eba3d64f3957b22230e24f1d93f"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"f678e86ad6af22220fad88927b83eae6c7b26f57","unresolved":false,"context_lines":[{"line_number":85,"context_line":"        raise exc.SubnetInUse(subnet_id\u003dsubnet_id, reason\u003de)"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"def _update_subnetpool_dict(orig_pool, new_pool):"},{"line_number":89,"context_line":"    keys_to_update \u003d ("},{"line_number":90,"context_line":"        set(orig_pool.fields.keys()) - set(orig_pool.synthetic_fields))"},{"line_number":91,"context_line":"    updated \u003d {k: new_pool.get(k, orig_pool[k]) for k in keys_to_update}"}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_69dd0970","line":88,"updated":"2016-06-10 11:17:00.000000000","message":"not related to this patch. At some point we will have to do some refactoring and move all these subnetnetpool related methods in their own file, instead of having this huge db_base_plugin_v2 file.","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7278c4dfd03a04429a3fccf3d781227ec3dbb167","unresolved":false,"context_lines":[{"line_number":85,"context_line":"        raise exc.SubnetInUse(subnet_id\u003dsubnet_id, reason\u003de)"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"def _update_subnetpool_dict(orig_pool, new_pool):"},{"line_number":89,"context_line":"    keys_to_update \u003d ("},{"line_number":90,"context_line":"        set(orig_pool.fields.keys()) - set(orig_pool.synthetic_fields))"},{"line_number":91,"context_line":"    updated \u003d {k: new_pool.get(k, orig_pool[k]) for k in keys_to_update}"}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_10d3c139","line":88,"in_reply_to":"7aa08908_69dd0970","updated":"2016-06-10 12:05:10.000000000","message":"Henry pointed out it doesn\u0027t need self in previous PS, should I move it back to the plugin?","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"a148d6a0e0e0996f7ab3169bac6d7616f7d20bcd","unresolved":false,"context_lines":[{"line_number":1044,"context_line":""},{"line_number":1045,"context_line":"            for k, v in dict(reader.subnetpool).items():"},{"line_number":1046,"context_line":"                # TODO(ihrachys): we should probably have some helper method in"},{"line_number":1047,"context_line":"                # base object to update just updatable fields"},{"line_number":1048,"context_line":"                if k not in subnetpool_obj.SubnetPool.fields_no_update:"},{"line_number":1049,"context_line":"                    orig_sp[k] \u003d v"},{"line_number":1050,"context_line":"            orig_sp.update()"}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_20deebdc","line":1047,"updated":"2016-06-14 10:33:15.000000000","message":"sounds reasonable, yes.","commit_id":"315d1f765280ee3ce1695cabc5340df0f4e778bf"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"7faf64c0d7a17b626442b7b9e84c8c824e1e80d1","unresolved":false,"context_lines":[{"line_number":1026,"context_line":"        new_sp \u003d subnetpool[\u0027subnetpool\u0027]"},{"line_number":1027,"context_line":""},{"line_number":1028,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1029,"context_line":"            orig_sp \u003d subnetpool_obj.SubnetPool.get_object(context, id\u003did)"},{"line_number":1030,"context_line":"            updated \u003d _update_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1031,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1032,"context_line":"            if reader.is_default and not orig_sp.is_default:"}],"source_content_type":"text/x-python","patch_set":16,"id":"7aa08908_f9493561","line":1029,"range":{"start_line":1029,"start_character":22,"end_line":1029,"end_character":58},"updated":"2016-06-14 13:49:18.000000000","message":"previous version of _get_subnetpool was raising exception when subnetpool was not found. I wonder if it is relevant here or in any other places where _get_subnetpool is replaced by get_object...","commit_id":"b91839b9621e0430b8a903eecf5652a59a401b18"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"465c90e7c139bb64d130e859c1a24f9742704b8d","unresolved":false,"context_lines":[{"line_number":1026,"context_line":"        new_sp \u003d subnetpool[\u0027subnetpool\u0027]"},{"line_number":1027,"context_line":""},{"line_number":1028,"context_line":"        with context.session.begin(subtransactions\u003dTrue):"},{"line_number":1029,"context_line":"            orig_sp \u003d subnetpool_obj.SubnetPool.get_object(context, id\u003did)"},{"line_number":1030,"context_line":"            updated \u003d _update_subnetpool_dict(orig_sp, new_sp)"},{"line_number":1031,"context_line":"            reader \u003d subnet_alloc.SubnetPoolReader(updated)"},{"line_number":1032,"context_line":"            if reader.is_default and not orig_sp.is_default:"}],"source_content_type":"text/x-python","patch_set":16,"id":"7aa08908_d9fc39b7","line":1029,"range":{"start_line":1029,"start_character":22,"end_line":1029,"end_character":58},"in_reply_to":"7aa08908_f9493561","updated":"2016-06-14 13:52:54.000000000","message":"I think you are onto something here: get_object() returns None if no object found.","commit_id":"b91839b9621e0430b8a903eecf5652a59a401b18"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"83200e346b68f9745bec8bf68018bc6c4d9ec623","unresolved":false,"context_lines":[{"line_number":1065,"context_line":""},{"line_number":1066,"context_line":"    def get_subnetpool(self, context, id, fields\u003dNone):"},{"line_number":1067,"context_line":"        subnetpool \u003d self._get_subnetpool(context, id)"},{"line_number":1068,"context_line":"        if not subnetpool:"},{"line_number":1069,"context_line":"            raise n_exc.SubnetPoolNotFound(subnetpool_id\u003did)"},{"line_number":1070,"context_line":"        return self._make_subnetpool_dict(subnetpool, fields)"},{"line_number":1071,"context_line":""},{"line_number":1072,"context_line":"    def get_subnetpools(self, context, filters\u003dNone, fields\u003dNone,"}],"source_content_type":"text/x-python","patch_set":17,"id":"7aa08908_2e540ec8","line":1069,"range":{"start_line":1068,"start_character":0,"end_line":1069,"end_character":60},"updated":"2016-06-14 14:19:22.000000000","message":"Ouch","commit_id":"f8a8a0018e52c53ca8b8ca147287b5a1eb3ed42d"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"679f5252c08b857ef1eadde972232bdc8df545f0","unresolved":false,"context_lines":[{"line_number":1065,"context_line":""},{"line_number":1066,"context_line":"    def get_subnetpool(self, context, id, fields\u003dNone):"},{"line_number":1067,"context_line":"        subnetpool \u003d self._get_subnetpool(context, id)"},{"line_number":1068,"context_line":"        if not subnetpool:"},{"line_number":1069,"context_line":"            raise n_exc.SubnetPoolNotFound(subnetpool_id\u003did)"},{"line_number":1070,"context_line":"        return self._make_subnetpool_dict(subnetpool, fields)"},{"line_number":1071,"context_line":""},{"line_number":1072,"context_line":"    def get_subnetpools(self, context, filters\u003dNone, fields\u003dNone,"}],"source_content_type":"text/x-python","patch_set":17,"id":"7aa08908_eed04621","line":1069,"range":{"start_line":1068,"start_character":0,"end_line":1069,"end_character":60},"in_reply_to":"7aa08908_2e540ec8","updated":"2016-06-14 14:20:38.000000000","message":"yeah :D","commit_id":"f8a8a0018e52c53ca8b8ca147287b5a1eb3ed42d"}],"neutron/db/ipam_non_pluggable_backend.py":[{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"3f727d61eb9dbfa6099874ae2876877ff18d384f","unresolved":false,"context_lines":[{"line_number":465,"context_line":"    def allocate_subnet(self, context, network, subnet, subnetpool_id):"},{"line_number":466,"context_line":"        subnetpool \u003d None"},{"line_number":467,"context_line":"        if subnetpool_id and not subnetpool_id \u003d\u003d constants.IPV6_PD_POOL_ID:"},{"line_number":468,"context_line":"            subnetpool \u003d subnetpool_obj.SubnetPool.get_object("},{"line_number":469,"context_line":"                context, id\u003dsubnetpool_id)"},{"line_number":470,"context_line":"            self._validate_ip_version_with_subnetpool(subnet, subnetpool)"},{"line_number":471,"context_line":""}],"source_content_type":"text/x-python","patch_set":17,"id":"7aa08908_eefa0674","line":468,"range":{"start_line":468,"start_character":25,"end_line":468,"end_character":61},"updated":"2016-06-14 14:24:04.000000000","message":"ouch","commit_id":"f8a8a0018e52c53ca8b8ca147287b5a1eb3ed42d"}],"neutron/db/ipam_pluggable_backend.py":[{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"3f727d61eb9dbfa6099874ae2876877ff18d384f","unresolved":false,"context_lines":[{"line_number":428,"context_line":"        subnetpool \u003d None"},{"line_number":429,"context_line":""},{"line_number":430,"context_line":"        if subnetpool_id and not subnetpool_id \u003d\u003d constants.IPV6_PD_POOL_ID:"},{"line_number":431,"context_line":"            subnetpool \u003d subnetpool_obj.SubnetPool.get_object("},{"line_number":432,"context_line":"                context, id\u003dsubnetpool_id)"},{"line_number":433,"context_line":"            self._validate_ip_version_with_subnetpool(subnet, subnetpool)"},{"line_number":434,"context_line":""}],"source_content_type":"text/x-python","patch_set":17,"id":"7aa08908_4e307a56","line":431,"range":{"start_line":431,"start_character":25,"end_line":431,"end_character":61},"updated":"2016-06-14 14:24:04.000000000","message":"ouch","commit_id":"f8a8a0018e52c53ca8b8ca147287b5a1eb3ed42d"}],"neutron/ipam/subnet_alloc.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":104,"context_line":"    def _check_subnetpool_tenant_quota(self, tenant_id, prefixlen):"},{"line_number":105,"context_line":"        quota_unit \u003d self._sp_helper.ip_version_subnetpool_quota_unit("},{"line_number":106,"context_line":"                                               self._subnetpool[\u0027ip_version\u0027])"},{"line_number":107,"context_line":"        quota \u003d self._subnetpool[\u0027default_quota\u0027]"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"        if quota:"},{"line_number":110,"context_line":"            used \u003d self._allocations_used_by_tenant(quota_unit)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_6c03ccb8","line":107,"range":{"start_line":107,"start_character":32,"end_line":107,"end_character":49},"updated":"2016-06-08 14:42:08.000000000","message":"(No action required) You leave it dict-y here (not accessing the attribute with .) to stay on safe side in case some external code passes a dict here, right?","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":104,"context_line":"    def _check_subnetpool_tenant_quota(self, tenant_id, prefixlen):"},{"line_number":105,"context_line":"        quota_unit \u003d self._sp_helper.ip_version_subnetpool_quota_unit("},{"line_number":106,"context_line":"                                               self._subnetpool[\u0027ip_version\u0027])"},{"line_number":107,"context_line":"        quota \u003d self._subnetpool[\u0027default_quota\u0027]"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"        if quota:"},{"line_number":110,"context_line":"            used \u003d self._allocations_used_by_tenant(quota_unit)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_24055810","line":107,"range":{"start_line":107,"start_character":32,"end_line":107,"end_character":49},"in_reply_to":"7aa08908_6c03ccb8","updated":"2016-06-08 15:00:35.000000000","message":"That\u0027s correct. Now thinking about that, we should probably leave get() here in case someone passes dict not containing default_quota. Objects always return a value.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"}],"neutron/objects/base.py":[{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"425511723fa3a1240dcf8bb6df8acb1d59a362bd","unresolved":false,"context_lines":[{"line_number":281,"context_line":"        potential_fields \u003d (list(cls.fields.keys()) +"},{"line_number":282,"context_line":"                            list(cls.fields_need_translation.values()))"},{"line_number":283,"context_line":"        result \u003d {field: db_obj[field] for field in potential_fields"},{"line_number":284,"context_line":"                  if field in db_obj}"},{"line_number":285,"context_line":"        for field, field_db in cls.fields_need_translation.items():"},{"line_number":286,"context_line":"            if field_db in result:"},{"line_number":287,"context_line":"                result[field] \u003d result.pop(field_db)"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_178c7334","line":284,"updated":"2016-06-02 18:57:09.000000000","message":"It is something I wanted to push in patch [1].\nIt is needed for dict compatibility, we need to set the fields as None in order to provide the backward compatibility. Many places are getting the atribute and then compare it to None, if this change won\u0027t be merged, those places will fail with exception...\n\n[1] https://review.openstack.org/#/c/308441/4/neutron/objects/base.py","commit_id":"38065b8683267f94e92727c223b9c7e48b3868c2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":167,"context_line":""},{"line_number":168,"context_line":"        Filter names are validated in validate_filters() method which by"},{"line_number":169,"context_line":"        default allows filters based on fields\u0027 names.  Extensions can create"},{"line_number":170,"context_line":"        new filter names.  Such names must be register to particular object"},{"line_number":171,"context_line":"        with this method."},{"line_number":172,"context_line":"        \"\"\""},{"line_number":173,"context_line":"        cls.extra_filter_names.append(filter_name)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_ace014ce","line":170,"range":{"start_line":170,"start_character":46,"end_line":170,"end_character":54},"updated":"2016-06-08 14:42:08.000000000","message":"registered","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":167,"context_line":""},{"line_number":168,"context_line":"        Filter names are validated in validate_filters() method which by"},{"line_number":169,"context_line":"        default allows filters based on fields\u0027 names.  Extensions can create"},{"line_number":170,"context_line":"        new filter names.  Such names must be register to particular object"},{"line_number":171,"context_line":"        with this method."},{"line_number":172,"context_line":"        \"\"\""},{"line_number":173,"context_line":"        cls.extra_filter_names.append(filter_name)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_c4a614ad","line":170,"range":{"start_line":170,"start_character":46,"end_line":170,"end_character":54},"in_reply_to":"7aa08908_ace014ce","updated":"2016-06-08 15:00:35.000000000","message":"Done","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"fdfeaa2edb16d570a2cda176fd0e31d87a33a7b1","unresolved":false,"context_lines":[{"line_number":27,"context_line":"from neutron.objects.db import api as obj_db_api"},{"line_number":28,"context_line":"from neutron.objects.extensions import standardattributes"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"_NO_DB_MODEL \u003d object()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"#TODO(jlibosva): Move these classes to exceptions module"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_90fb8d78","line":30,"updated":"2016-06-09 00:10:21.000000000","message":"You should probably use an unchanging sentinel object like [1]. It can avoid surprises and be useful for tests.\n\n\n[1] https://github.com/openstack/neutron-lib/blob/0.2.0/neutron_lib/constants.py#L252","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"05eec6a263b07cf0e8bce847d0c3d7e24ed625dd","unresolved":false,"context_lines":[{"line_number":27,"context_line":"from neutron.objects.db import api as obj_db_api"},{"line_number":28,"context_line":"from neutron.objects.extensions import standardattributes"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"_NO_DB_MODEL \u003d object()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"#TODO(jlibosva): Move these classes to exceptions module"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_be392ca6","line":30,"in_reply_to":"7aa08908_90fb8d78","updated":"2016-06-09 09:00:17.000000000","message":"I\u0027m not sure I understand correctly the unchanging part.","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"f5171a955e9a2afd1b8b07ef0f7b8b31feefa6d6","unresolved":false,"context_lines":[{"line_number":27,"context_line":"from neutron.objects.db import api as obj_db_api"},{"line_number":28,"context_line":"from neutron.objects.extensions import standardattributes"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"_NO_DB_MODEL \u003d object()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"#TODO(jlibosva): Move these classes to exceptions module"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_fd39f3f3","line":30,"in_reply_to":"7aa08908_be392ca6","updated":"2016-06-09 11:32:08.000000000","message":"You can ask Brandon what happened to cause him to file https://bugs.launchpad.net/neutron/+bug/1577571","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"9da1e55ad836f6fb0105c72e2735401f058f89b5","unresolved":false,"context_lines":[{"line_number":27,"context_line":"from neutron.objects.db import api as obj_db_api"},{"line_number":28,"context_line":"from neutron.objects.extensions import standardattributes"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"_NO_DB_MODEL \u003d object()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"#TODO(jlibosva): Move these classes to exceptions module"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_c8d1d331","line":30,"in_reply_to":"7aa08908_fd39f3f3","updated":"2016-06-09 11:40:17.000000000","message":"I was wondering why deepcopy in particular is implemented. According the commit message [1], attribute was used in dictionaries which were copied. This _NO_DB_MODEL is just a placeholder for for objects not implementing db_model, it\u0027s not used in any dictionary. So I think we\u0027re good here :)\n\n[1] https://github.com/openstack/neutron-lib/commit/d33b62b0e785d09ae59b14e18fd183bd7d2fb206","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"fdfeaa2edb16d570a2cda176fd0e31d87a33a7b1","unresolved":false,"context_lines":[{"line_number":190,"context_line":"    def create(self):"},{"line_number":191,"context_line":"        raise NotImplementedError()"},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"    def update(self):"},{"line_number":194,"context_line":"        raise NotImplementedError()"},{"line_number":195,"context_line":""},{"line_number":196,"context_line":"    def delete(self):"}],"source_content_type":"text/x-python","patch_set":9,"id":"7aa08908_d01fd5b4","line":193,"updated":"2016-06-09 00:10:21.000000000","message":"I noticed that this does not match the signature of VersionedObjectDictCompat.update(self, updates). Not sure if this is a problem. It\u0027s not something to address in this patch anyway.","commit_id":"6aa2da61f8e1b56d20ad3e89450c8b655d8d3e7e"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"f0ebb8e8100ebbbf4a14f9a1cd720bc1f6ff6873","unresolved":false,"context_lines":[{"line_number":32,"context_line":"    pass"},{"line_number":33,"context_line":""},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"_NO_DB_MODEL \u003d NoDbModelSentinel()"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"#TODO(jlibosva): Move these classes to exceptions module"}],"source_content_type":"text/x-python","patch_set":10,"id":"7aa08908_de135863","line":35,"updated":"2016-06-09 09:13:35.000000000","message":"Not sure I follow that change from the original version using object(). I don\u0027t feel like we have a use for that (what it buys us is merely allowing to check whether it\u0027s an instance of NoDbModelSentinel, and I don\u0027t see a use case for that). I prefer we stick to the easier original version.\n\nHenry?","commit_id":"a84dfa297d745eba3d64f3957b22230e24f1d93f"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"344cbf3ca5150bf98048a383ff2c6d3d394295bd","unresolved":false,"context_lines":[{"line_number":32,"context_line":"    pass"},{"line_number":33,"context_line":""},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"_NO_DB_MODEL \u003d NoDbModelSentinel()"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"#TODO(jlibosva): Move these classes to exceptions module"}],"source_content_type":"text/x-python","patch_set":10,"id":"7aa08908_d7ea16ac","line":35,"in_reply_to":"7aa08908_de135863","updated":"2016-06-09 10:51:58.000000000","message":"Done","commit_id":"a84dfa297d745eba3d64f3957b22230e24f1d93f"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"f678e86ad6af22220fad88927b83eae6c7b26f57","unresolved":false,"context_lines":[{"line_number":79,"context_line":"def get_object_class_by_model(model):"},{"line_number":80,"context_line":"    for obj_class in obj_base.VersionedObjectRegistry.obj_classes().values():"},{"line_number":81,"context_line":"        obj_class \u003d obj_class[0]"},{"line_number":82,"context_line":"        if getattr(obj_class, \u0027db_model\u0027, _NO_DB_MODEL) is model:"},{"line_number":83,"context_line":"            return obj_class"},{"line_number":84,"context_line":"    raise NeutronDbObjectNotFoundByModel(model\u003dmodel.__name__)"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_6ff989c8","line":82,"updated":"2016-06-10 11:17:00.000000000","message":"why do we need _NO_DB_MODEL? db_model is None by default (see line 220...we can just use None, right?","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"693bfeece0b9e9c98d344e137b24527a8fdd8a69","unresolved":false,"context_lines":[{"line_number":79,"context_line":"def get_object_class_by_model(model):"},{"line_number":80,"context_line":"    for obj_class in obj_base.VersionedObjectRegistry.obj_classes().values():"},{"line_number":81,"context_line":"        obj_class \u003d obj_class[0]"},{"line_number":82,"context_line":"        if getattr(obj_class, \u0027db_model\u0027, _NO_DB_MODEL) is model:"},{"line_number":83,"context_line":"            return obj_class"},{"line_number":84,"context_line":"    raise NeutronDbObjectNotFoundByModel(model\u003dmodel.__name__)"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_db979fe9","line":82,"in_reply_to":"7aa08908_6ff989c8","updated":"2016-06-10 11:27:15.000000000","message":"I think the point here is that some objects may be not NeutronDbObject.","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7278c4dfd03a04429a3fccf3d781227ec3dbb167","unresolved":false,"context_lines":[{"line_number":79,"context_line":"def get_object_class_by_model(model):"},{"line_number":80,"context_line":"    for obj_class in obj_base.VersionedObjectRegistry.obj_classes().values():"},{"line_number":81,"context_line":"        obj_class \u003d obj_class[0]"},{"line_number":82,"context_line":"        if getattr(obj_class, \u0027db_model\u0027, _NO_DB_MODEL) is model:"},{"line_number":83,"context_line":"            return obj_class"},{"line_number":84,"context_line":"    raise NeutronDbObjectNotFoundByModel(model\u003dmodel.__name__)"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_b0a8ed78","line":82,"in_reply_to":"7aa08908_db979fe9","updated":"2016-06-10 12:05:10.000000000","message":"If we wouldn\u0027t use _NO_DB_MODEL than we won\u0027t be able to search for None model. It might be a YAGNI at this point but I wanted to make it generic.","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"f678e86ad6af22220fad88927b83eae6c7b26f57","unresolved":false,"context_lines":[{"line_number":118,"context_line":"                    obj_base.ComparableVersionedObject):"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    synthetic_fields \u003d []"},{"line_number":121,"context_line":"    extra_filter_names \u003d []"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def __init__(self, context\u003dNone, **kwargs):"},{"line_number":124,"context_line":"        super(NeutronObject, self).__init__(context, **kwargs)"}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_9b5077d6","line":121,"updated":"2016-06-10 11:17:00.000000000","message":"can you add a unit test for the extra_filter?","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7278c4dfd03a04429a3fccf3d781227ec3dbb167","unresolved":false,"context_lines":[{"line_number":118,"context_line":"                    obj_base.ComparableVersionedObject):"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    synthetic_fields \u003d []"},{"line_number":121,"context_line":"    extra_filter_names \u003d []"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def __init__(self, context\u003dNone, **kwargs):"},{"line_number":124,"context_line":"        super(NeutronObject, self).__init__(context, **kwargs)"}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_90db31ed","line":121,"in_reply_to":"7aa08908_9b5077d6","updated":"2016-06-10 12:05:10.000000000","message":"I\u0027ll add it.","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"f678e86ad6af22220fad88927b83eae6c7b26f57","unresolved":false,"context_lines":[{"line_number":302,"context_line":"        \"\"\"Return None for nullable unknown values."},{"line_number":303,"context_line":""},{"line_number":304,"context_line":"        In case model attribute is not present in database, value stored under"},{"line_number":305,"context_line":"        ``attrname\u0027\u0027 field will be unknown. In such cases if the field"},{"line_number":306,"context_line":"        ``attrname\u0027\u0027 is a nullable Field return None"},{"line_number":307,"context_line":"        \"\"\""},{"line_number":308,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_9b2fd787","line":305,"range":{"start_line":305,"start_character":35,"end_line":305,"end_character":42},"updated":"2016-06-10 11:17:00.000000000","message":"what does unknown mean? do we get an exception?","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7278c4dfd03a04429a3fccf3d781227ec3dbb167","unresolved":false,"context_lines":[{"line_number":302,"context_line":"        \"\"\"Return None for nullable unknown values."},{"line_number":303,"context_line":""},{"line_number":304,"context_line":"        In case model attribute is not present in database, value stored under"},{"line_number":305,"context_line":"        ``attrname\u0027\u0027 field will be unknown. In such cases if the field"},{"line_number":306,"context_line":"        ``attrname\u0027\u0027 is a nullable Field return None"},{"line_number":307,"context_line":"        \"\"\""},{"line_number":308,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_500c2994","line":305,"range":{"start_line":305,"start_character":35,"end_line":305,"end_character":42},"in_reply_to":"7aa08908_9b2fd787","updated":"2016-06-10 12:05:10.000000000","message":"unknown is that \"\u003c?\u003e\" you can see if you print an object not defining a value. If you access such field, you\u0027ll get NotImplementedError by default, as it\u0027s probably supposed to load attribute lazily from database.\n\nNullable fields can be undefined so it doesn\u0027t make any sense to try loading them. This method sets them to None if they are accessed from the outside and are not defined.","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"f678e86ad6af22220fad88927b83eae6c7b26f57","unresolved":false,"context_lines":[{"line_number":308,"context_line":"        try:"},{"line_number":309,"context_line":"            is_attr_nullable \u003d self.fields[attrname].nullable"},{"line_number":310,"context_line":"        except KeyError:"},{"line_number":311,"context_line":"            return super(NeutronDbObject, self).obj_load_attr(attrname)"},{"line_number":312,"context_line":"        if is_attr_nullable:"},{"line_number":313,"context_line":"            self[attrname] \u003d None"},{"line_number":314,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_db395fa5","line":311,"updated":"2016-06-10 11:17:00.000000000","message":"in the base VersionedObject this method is not define and you get a NotImplemented exception...should we just throw the KeyError instead?","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7278c4dfd03a04429a3fccf3d781227ec3dbb167","unresolved":false,"context_lines":[{"line_number":308,"context_line":"        try:"},{"line_number":309,"context_line":"            is_attr_nullable \u003d self.fields[attrname].nullable"},{"line_number":310,"context_line":"        except KeyError:"},{"line_number":311,"context_line":"            return super(NeutronDbObject, self).obj_load_attr(attrname)"},{"line_number":312,"context_line":"        if is_attr_nullable:"},{"line_number":313,"context_line":"            self[attrname] \u003d None"},{"line_number":314,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"7aa08908_b072ad0f","line":311,"in_reply_to":"7aa08908_db395fa5","updated":"2016-06-10 12:05:10.000000000","message":"The meaning behind this is just to implement setting None for nullable fields that are not set. Otherwise it keeps the original behavior.","commit_id":"6b26bb8c56034202c492892c27c3efabae7f7292"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"a148d6a0e0e0996f7ab3169bac6d7616f7d20bcd","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        return obj"},{"line_number":300,"context_line":""},{"line_number":301,"context_line":"    def obj_load_attr(self, attrname):"},{"line_number":302,"context_line":"        \"\"\"Return None for nullable unknown values."},{"line_number":303,"context_line":""},{"line_number":304,"context_line":"        In case model attribute is not present in database, value stored under"},{"line_number":305,"context_line":"        ``attrname\u0027\u0027 field will be unknown. In such cases if the field"}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_3352c735","line":302,"range":{"start_line":302,"start_character":11,"end_line":302,"end_character":17},"updated":"2016-06-14 10:33:15.000000000","message":"It doesn\u0027t seem to return anything, the docstring is missleading.\n\nMay be \"Extends base obj_load_attr to load None for nullable unknown values.\"  ?","commit_id":"315d1f765280ee3ce1695cabc5340df0f4e778bf"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"1ec596d6ac1dc40a7a095ec1c0d06d65d386aa52","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        return obj"},{"line_number":300,"context_line":""},{"line_number":301,"context_line":"    def obj_load_attr(self, attrname):"},{"line_number":302,"context_line":"        \"\"\"Return None for nullable unknown values."},{"line_number":303,"context_line":""},{"line_number":304,"context_line":"        In case model attribute is not present in database, value stored under"},{"line_number":305,"context_line":"        ``attrname\u0027\u0027 field will be unknown. In such cases if the field"}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_2228ab99","line":302,"range":{"start_line":302,"start_character":11,"end_line":302,"end_character":17},"in_reply_to":"7aa08908_3352c735","updated":"2016-06-14 11:59:00.000000000","message":"Done","commit_id":"315d1f765280ee3ce1695cabc5340df0f4e778bf"}],"neutron/objects/db/api.py":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"a148d6a0e0e0996f7ab3169bac6d7616f7d20bcd","unresolved":false,"context_lines":[{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"def _kwargs_to_filters(**kwargs):"},{"line_number":29,"context_line":"    return {k: v if isinstance(v, list) else [v]"},{"line_number":30,"context_line":"            for k, v in kwargs.items()}"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_d61ed15d","line":29,"updated":"2016-06-14 10:33:15.000000000","message":"hmm, I suspect this is related to the issue we have with the some versions of the databse or database lib in qos, which are unable to construct a good query from a list, where there is supposed not to be a list.\n\nCan  we separate that bit to another patch in front? This way it\u0027d be backportable if this fixes the other issue.\n\nhttps://bugs.launchpad.net/neutron/+bug/1589969","commit_id":"315d1f765280ee3ce1695cabc5340df0f4e778bf"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fec4c1b84b0d28cb4fe5a276b599f61fbd3962de","unresolved":false,"context_lines":[{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"def _kwargs_to_filters(**kwargs):"},{"line_number":29,"context_line":"    return {k: v if isinstance(v, list) else [v]"},{"line_number":30,"context_line":"            for k, v in kwargs.items()}"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_b1d50f1d","line":29,"in_reply_to":"7aa08908_7133a7f6","updated":"2016-06-14 10:50:56.000000000","message":"Miguel, please try to backport db/api.py change switching to _get_collection from https://review.openstack.org/#/c/300055/ into stable branches and validate with psql. I think it may help.","commit_id":"315d1f765280ee3ce1695cabc5340df0f4e778bf"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"1ec596d6ac1dc40a7a095ec1c0d06d65d386aa52","unresolved":false,"context_lines":[{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"def _kwargs_to_filters(**kwargs):"},{"line_number":29,"context_line":"    return {k: v if isinstance(v, list) else [v]"},{"line_number":30,"context_line":"            for k, v in kwargs.items()}"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_42a4d749","line":29,"in_reply_to":"7aa08908_b1d50f1d","updated":"2016-06-14 11:59:00.000000000","message":"1589969 is a different issue.","commit_id":"315d1f765280ee3ce1695cabc5340df0f4e778bf"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ac0b281738e3af3780431a1a1d599f486355f3b9","unresolved":false,"context_lines":[{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"def _kwargs_to_filters(**kwargs):"},{"line_number":29,"context_line":"    return {k: v if isinstance(v, list) else [v]"},{"line_number":30,"context_line":"            for k, v in kwargs.items()}"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_7133a7f6","line":29,"in_reply_to":"7aa08908_d61ed15d","updated":"2016-06-14 10:46:16.000000000","message":"It is not.\n\n[12:41:36]  \u003cihrachys\u003e\tI believe it\u0027s sqla/psql integration that is at fault\n[12:41:37]  \u003cihrachys\u003e\tsee https://groups.google.com/forum/#!topic/sqlalchemy/1O9sW7n6Ws4\n[12:41:48]  \u003cihrachys\u003e\tand the snippet does not attempt to solve that for you\n[12:42:03]  \u003cihrachys\u003e\tit merely avoids double nested lists as filters\n[12:42:12]  \u003cihrachys\u003e\tbut it\u0027s still always a list in the end\n[12:43:42]  \u003cihrachys\u003e\tmaybe _apply_filters_to_query in common db mixin needs some hacks for psql, but that\u0027s, again, not the goal of the patch","commit_id":"315d1f765280ee3ce1695cabc5340df0f4e778bf"}],"neutron/services/timestamp/timestamp_db.py":[{"author":{"_account_id":6542,"name":"j_king","email":"james@agentultra.com","username":"james-agentultra"},"change_message_id":"7d572e3d291e40b5cd8b581168e5ff6441fa68c5","unresolved":false,"context_lines":[{"line_number":50,"context_line":"            datetime.datetime.fromtimestamp(time.mktime("},{"line_number":51,"context_line":"                time.strptime(data,"},{"line_number":52,"context_line":"                              self.ISO8601_TIME_FORMAT)))"},{"line_number":53,"context_line":"        except Exception:"},{"line_number":54,"context_line":"            msg \u003d _LW(\"The input %s must be in the \""},{"line_number":55,"context_line":"                      \"following format: YYYY-MM-DDTHH:MM:SS\") % CHANGED_SINCE"},{"line_number":56,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":19,"id":"7aa08908_351d7973","line":53,"range":{"start_line":53,"start_character":15,"end_line":53,"end_character":24},"updated":"2016-06-14 15:38:58.000000000","message":"Could you be more specific about the exceptions that could be thrown in this block? There are three functions in this block which can throw a mixture of ValueError and OverflowError depending on the function and platform.","commit_id":"a68c42524165d7b361475e00978fbc3499efcce4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"bb83890268fdeedd835a1dceefa54f4081f50a65","unresolved":false,"context_lines":[{"line_number":50,"context_line":"            datetime.datetime.fromtimestamp(time.mktime("},{"line_number":51,"context_line":"                time.strptime(data,"},{"line_number":52,"context_line":"                              self.ISO8601_TIME_FORMAT)))"},{"line_number":53,"context_line":"        except Exception:"},{"line_number":54,"context_line":"            msg \u003d _LW(\"The input %s must be in the \""},{"line_number":55,"context_line":"                      \"following format: YYYY-MM-DDTHH:MM:SS\") % CHANGED_SINCE"},{"line_number":56,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":19,"id":"7aa08908_7aac0ded","line":53,"range":{"start_line":53,"start_character":15,"end_line":53,"end_character":24},"in_reply_to":"7aa08908_351d7973","updated":"2016-06-14 15:42:56.000000000","message":"I am sorry, but how is this patch related to the issue you point out? I suggest you to send a separate patch to tackle the problem.","commit_id":"a68c42524165d7b361475e00978fbc3499efcce4"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"9909668c8ff03557d20dc899a8bd3ef6711cc9e1","unresolved":false,"context_lines":[{"line_number":50,"context_line":"            datetime.datetime.fromtimestamp(time.mktime("},{"line_number":51,"context_line":"                time.strptime(data,"},{"line_number":52,"context_line":"                              self.ISO8601_TIME_FORMAT)))"},{"line_number":53,"context_line":"        except Exception:"},{"line_number":54,"context_line":"            msg \u003d _LW(\"The input %s must be in the \""},{"line_number":55,"context_line":"                      \"following format: YYYY-MM-DDTHH:MM:SS\") % CHANGED_SINCE"},{"line_number":56,"context_line":"            raise n_exc.InvalidInput(error_message\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":19,"id":"7aa08908_c0ea6ed7","line":53,"range":{"start_line":53,"start_character":15,"end_line":53,"end_character":24},"in_reply_to":"7aa08908_351d7973","updated":"2016-06-14 16:23:02.000000000","message":"Purpose of changing this file is just to define the filter name so we can re-use it when registering hook.","commit_id":"a68c42524165d7b361475e00978fbc3499efcce4"}],"neutron/services/timestamp/timestamp_plugin.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":42,"context_line":"                None,"},{"line_number":43,"context_line":"                None,"},{"line_number":44,"context_line":"                self._change_since_result_filter_hook)"},{"line_number":45,"context_line":"        # TODO(jlibosva): Move this to register_model_query_hook"},{"line_number":46,"context_line":"        base_obj.register_filter_hook_on_model("},{"line_number":47,"context_line":"            models_v2.SubnetPool, ts_db.CHANGED_SINCE)"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_67c80575","line":45,"range":{"start_line":45,"start_character":8,"end_line":45,"end_character":64},"updated":"2016-06-08 14:42:08.000000000","message":"Yeah, but it seems that the common_db_mixin registration function does not accept filter name.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":42,"context_line":"                None,"},{"line_number":43,"context_line":"                None,"},{"line_number":44,"context_line":"                self._change_since_result_filter_hook)"},{"line_number":45,"context_line":"        # TODO(jlibosva): Move this to register_model_query_hook"},{"line_number":46,"context_line":"        base_obj.register_filter_hook_on_model("},{"line_number":47,"context_line":"            models_v2.SubnetPool, ts_db.CHANGED_SINCE)"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_a4f6688c","line":45,"range":{"start_line":45,"start_character":8,"end_line":45,"end_character":64},"in_reply_to":"7aa08908_67c80575","updated":"2016-06-08 15:00:35.000000000","message":"Yep, that\u0027s why I left it for future generations.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":6542,"name":"j_king","email":"james@agentultra.com","username":"james-agentultra"},"change_message_id":"7d572e3d291e40b5cd8b581168e5ff6441fa68c5","unresolved":false,"context_lines":[{"line_number":42,"context_line":"                None,"},{"line_number":43,"context_line":"                None,"},{"line_number":44,"context_line":"                self._change_since_result_filter_hook)"},{"line_number":45,"context_line":"        # TODO(jlibosva): Move this to register_model_query_hook"},{"line_number":46,"context_line":"        base_obj.register_filter_hook_on_model("},{"line_number":47,"context_line":"            models_v2.SubnetPool, ts_db.CHANGED_SINCE)"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"7aa08908_9056fbcb","line":45,"updated":"2016-06-14 15:38:58.000000000","message":"nit: if it\u0027s a small change is it possible to just do this now instead of leaving a comment to do it later?","commit_id":"a68c42524165d7b361475e00978fbc3499efcce4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"796d4d29d98349d671b0bed92f23c447d933cbde","unresolved":false,"context_lines":[{"line_number":42,"context_line":"                None,"},{"line_number":43,"context_line":"                None,"},{"line_number":44,"context_line":"                self._change_since_result_filter_hook)"},{"line_number":45,"context_line":"        # TODO(jlibosva): Move this to register_model_query_hook"},{"line_number":46,"context_line":"        base_obj.register_filter_hook_on_model("},{"line_number":47,"context_line":"            models_v2.SubnetPool, ts_db.CHANGED_SINCE)"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"7aa08908_da49c161","line":45,"in_reply_to":"7aa08908_9056fbcb","updated":"2016-06-14 15:42:12.000000000","message":"It is *not* a simple change: the common_db_mixin hook does not receive filter name.","commit_id":"a68c42524165d7b361475e00978fbc3499efcce4"}],"neutron/tests/unit/extensions/test_timestamp_core.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":183,"context_line":""},{"line_number":184,"context_line":"    def test_list_subnetpools_with_changed_since(self):"},{"line_number":185,"context_line":"        prefixes \u003d [\u00273.3.3.3/24\u0027, \u00274.4.4.4/24\u0027]"},{"line_number":186,"context_line":"        with self.subnetpool(prefixes, tenant_id\u003dself._tenant_id,"},{"line_number":187,"context_line":"                             name\u003d\u0027sp_test02\u0027) as subnetpool:"},{"line_number":188,"context_line":"            self._list_resources_with_changed_since(subnetpool)"},{"line_number":189,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_e70b557b","line":186,"range":{"start_line":186,"start_character":49,"end_line":186,"end_character":64},"updated":"2016-06-08 14:42:08.000000000","message":"Can you elaborate how this change is relevant to the patch? Is it so that we don\u0027t use non-uuid tenant IDs that are triggering warnings from oslo.versionedobjects?","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e57079da6647257dc303dac6dee3bbab74834096","unresolved":false,"context_lines":[{"line_number":183,"context_line":""},{"line_number":184,"context_line":"    def test_list_subnetpools_with_changed_since(self):"},{"line_number":185,"context_line":"        prefixes \u003d [\u00273.3.3.3/24\u0027, \u00274.4.4.4/24\u0027]"},{"line_number":186,"context_line":"        with self.subnetpool(prefixes, tenant_id\u003dself._tenant_id,"},{"line_number":187,"context_line":"                             name\u003d\u0027sp_test02\u0027) as subnetpool:"},{"line_number":188,"context_line":"            self._list_resources_with_changed_since(subnetpool)"},{"line_number":189,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_c7a616ad","line":186,"range":{"start_line":186,"start_character":49,"end_line":186,"end_character":64},"in_reply_to":"7aa08908_c4573456","updated":"2016-06-08 15:09:25.000000000","message":"Oh, so now it\u0027s enforced!","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":183,"context_line":""},{"line_number":184,"context_line":"    def test_list_subnetpools_with_changed_since(self):"},{"line_number":185,"context_line":"        prefixes \u003d [\u00273.3.3.3/24\u0027, \u00274.4.4.4/24\u0027]"},{"line_number":186,"context_line":"        with self.subnetpool(prefixes, tenant_id\u003dself._tenant_id,"},{"line_number":187,"context_line":"                             name\u003d\u0027sp_test02\u0027) as subnetpool:"},{"line_number":188,"context_line":"            self._list_resources_with_changed_since(subnetpool)"},{"line_number":189,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_c4573456","line":186,"range":{"start_line":186,"start_character":49,"end_line":186,"end_character":64},"in_reply_to":"7aa08908_e70b557b","updated":"2016-06-08 15:00:35.000000000","message":"IIRC fields.corece failed for non-uuid tenant_id fields.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"}],"neutron/tests/unit/ipam/test_subnet_alloc.py":[{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"5b30bcd546e07b6390ea1c0d59824a75cb18a049","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        return plugin.create_subnetpool(ctx, subnetpool)"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    def _get_subnetpool(self, ctx, id):"},{"line_number":61,"context_line":"        return subnetpool_obj.SubnetPool.get_object(ctx, id\u003did)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def test_allocate_any_subnet(self):"},{"line_number":64,"context_line":"        prefix_list \u003d [\u002710.1.0.0/16\u0027, \u0027192.168.1.0/24\u0027]"}],"source_content_type":"text/x-python","patch_set":7,"id":"7aa08908_ff42cbac","line":61,"range":{"start_line":61,"start_character":15,"end_line":61,"end_character":63},"updated":"2016-06-08 12:30:34.000000000","message":"This probably shouldn\u0027t be changed.","commit_id":"049cbe5e436c9675fc70b91886577e00b36aad6a"}],"neutron/tests/unit/objects/test_objects.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"0b1a30a53352c7b8892e1e090ea3a2741adb58f5","unresolved":false,"context_lines":[{"line_number":41,"context_line":"    \u0027SubnetPool\u0027: \u00271.0-2c4a485c7d550bee0e01258c03d2a0c7\u0027,"},{"line_number":42,"context_line":"    \u0027SubnetPoolPrefix\u0027: \u00271.0-13c15144135eb869faa4a76dc3ee3b6c\u0027,"},{"line_number":43,"context_line":"    \u0027SubPort\u0027: \u00271.0-72c8471068db1f0491b5480fe49b52bb\u0027,"},{"line_number":44,"context_line":"    \u0027Trunk\u0027: \u00271.0-0b5b5c82824c2fc367405fe4140d8b8c\u0027,"},{"line_number":45,"context_line":"}"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_07dca171","line":44,"range":{"start_line":44,"start_character":5,"end_line":44,"end_character":10},"updated":"2016-06-08 14:42:08.000000000","message":"I guess we are safe to change it without compatibility layer because the object is not used on the wire anywhere yet?","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"61bbda5a1cb15cb2793a1e9fcb1359165caa37b8","unresolved":false,"context_lines":[{"line_number":41,"context_line":"    \u0027SubnetPool\u0027: \u00271.0-2c4a485c7d550bee0e01258c03d2a0c7\u0027,"},{"line_number":42,"context_line":"    \u0027SubnetPoolPrefix\u0027: \u00271.0-13c15144135eb869faa4a76dc3ee3b6c\u0027,"},{"line_number":43,"context_line":"    \u0027SubPort\u0027: \u00271.0-72c8471068db1f0491b5480fe49b52bb\u0027,"},{"line_number":44,"context_line":"    \u0027Trunk\u0027: \u00271.0-0b5b5c82824c2fc367405fe4140d8b8c\u0027,"},{"line_number":45,"context_line":"}"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_c48c54dc","line":44,"range":{"start_line":44,"start_character":5,"end_line":44,"end_character":10},"in_reply_to":"7aa08908_07dca171","updated":"2016-06-08 15:00:35.000000000","message":"I think this is required due to making \"description\" nullable in standard attribute. All objects using standard attribute get influenced by the change.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e57079da6647257dc303dac6dee3bbab74834096","unresolved":false,"context_lines":[{"line_number":41,"context_line":"    \u0027SubnetPool\u0027: \u00271.0-2c4a485c7d550bee0e01258c03d2a0c7\u0027,"},{"line_number":42,"context_line":"    \u0027SubnetPoolPrefix\u0027: \u00271.0-13c15144135eb869faa4a76dc3ee3b6c\u0027,"},{"line_number":43,"context_line":"    \u0027SubPort\u0027: \u00271.0-72c8471068db1f0491b5480fe49b52bb\u0027,"},{"line_number":44,"context_line":"    \u0027Trunk\u0027: \u00271.0-0b5b5c82824c2fc367405fe4140d8b8c\u0027,"},{"line_number":45,"context_line":"}"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_a724aa0c","line":44,"range":{"start_line":44,"start_character":5,"end_line":44,"end_character":10},"in_reply_to":"7aa08908_c48c54dc","updated":"2016-06-08 15:09:25.000000000","message":"Right. But the future approach would be providing backporting rules for every change. But I guess we can skip it until we actually need to backport the thing.\n\nJust want to make sure we don\u0027t catch up that as a way to go in the future.","commit_id":"11c8fb1bb7391e245ae40a7af1f8fc2589f714ff"}]}
