)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Artur Korzeniewski \u003cartur.korzeniewski@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-06-27 16:23:17 +0200"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"objects: Subnet object adjustment, RBAC and tenant_id compatibility."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This patch is prerequisite for Subnet object usage changes."},{"line_number":10,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3aaa91ec_acaf0a93","line":7,"updated":"2016-06-28 11:37:21.000000000","message":"As discussed in IRC meeting, this patch should be split into pieces.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Artur Korzeniewski \u003cartur.korzeniewski@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-06-27 16:23:17 +0200"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"objects: Subnet object adjustment, RBAC and tenant_id compatibility."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This patch is prerequisite for Subnet object usage changes."},{"line_number":10,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1aa78d24_08138467","line":7,"in_reply_to":"3aaa91ec_0401ce6a","updated":"2016-07-05 12:07:50.000000000","message":"Done:\nhttps://review.openstack.org/337539 objects: Add update_fields method in base class.\n\nhttps://review.openstack.org/337634 objects: Add RBAC to Subnet OV","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Artur Korzeniewski \u003cartur.korzeniewski@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-06-27 16:23:17 +0200"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"objects: Subnet object adjustment, RBAC and tenant_id compatibility."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This patch is prerequisite for Subnet object usage changes."},{"line_number":10,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3aaa91ec_0401ce6a","line":7,"in_reply_to":"3aaa91ec_acaf0a93","updated":"2016-06-28 12:25:50.000000000","message":"Yes, I will split it.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":9,"context_line":"This patch is prerequisite for Subnet object usage changes."},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"In subnet object, added \u0027shared\u0027 field based on Network RBAC state."},{"line_number":12,"context_line":"Also obj_extra_fields with \u0027tenant_id\u0027 added to return project_id as"},{"line_number":13,"context_line":"tenant_id."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"Modified the rbac_db methods to easy calculate the shared state within"},{"line_number":16,"context_line":"already opened session."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3aaa91ec_b8c900af","line":13,"range":{"start_line":12,"start_character":0,"end_line":13,"end_character":10},"updated":"2016-06-28 11:37:21.000000000","message":"tenant_id management is a candidate for a separate patch.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":12,"context_line":"Also obj_extra_fields with \u0027tenant_id\u0027 added to return project_id as"},{"line_number":13,"context_line":"tenant_id."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"Modified the rbac_db methods to easy calculate the shared state within"},{"line_number":16,"context_line":"already opened session."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"In base object, added update_fields() method to update the fields that"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3aaa91ec_98a9a4e2","line":15,"range":{"start_line":15,"start_character":32,"end_line":15,"end_character":36},"updated":"2016-06-28 11:37:21.000000000","message":"easily","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":15,"context_line":"Modified the rbac_db methods to easy calculate the shared state within"},{"line_number":16,"context_line":"already opened session."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"In base object, added update_fields() method to update the fields that"},{"line_number":19,"context_line":"are not in fields_no_update with one method in base class. Added it to"},{"line_number":20,"context_line":"SubnetPool integration place in db_base_plugin_v2."},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"Change-Id: I0d4a9934af9253321593a6bd64edfd6f660c26f1"},{"line_number":23,"context_line":"Partially-Implements: blueprint adopt-oslo-versioned-objects-for-db"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3aaa91ec_58d45c46","line":20,"range":{"start_line":18,"start_character":0,"end_line":20,"end_character":50},"updated":"2016-06-28 11:37:21.000000000","message":"that is a candidate for a separate change.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":15,"context_line":"Modified the rbac_db methods to easy calculate the shared state within"},{"line_number":16,"context_line":"already opened session."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"In base object, added update_fields() method to update the fields that"},{"line_number":19,"context_line":"are not in fields_no_update with one method in base class. Added it to"},{"line_number":20,"context_line":"SubnetPool integration place in db_base_plugin_v2."},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"Change-Id: I0d4a9934af9253321593a6bd64edfd6f660c26f1"},{"line_number":23,"context_line":"Partially-Implements: blueprint adopt-oslo-versioned-objects-for-db"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1aa78d24_8807741b","line":20,"range":{"start_line":18,"start_character":0,"end_line":20,"end_character":50},"in_reply_to":"3aaa91ec_58d45c46","updated":"2016-07-05 12:07:50.000000000","message":"Done: https://review.openstack.org/337539 objects: Add update_fields method in base class.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"aaad0b1bda82dc88418bdc2f33cfd683bc3a3d32","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"objects: Adjust Subnet fields, add tenant_id and segment_id"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Fields types and nullable parameters were adjusted according to usage model"},{"line_number":10,"context_line":"and tests expectations."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Introduced tenant_id as read-only property using obj_extra_fields, which"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"1aa78d24_f1fc8074","line":9,"range":{"start_line":9,"start_character":71,"end_line":9,"end_character":75},"updated":"2016-07-07 21:31:50.000000000","message":"It seems like the description exceeds the limit.","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"9e6f423399c1d14d15653b39a09988df167f21bf","unresolved":false,"context_lines":[{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Introduced tenant_id as read-only property using obj_extra_fields, which"},{"line_number":13,"context_line":"exposes additional attributes for objects and expose the value in to_dict()."},{"line_number":14,"context_line":"The tenant_id cannot be used directly on Subnet object as value for"},{"line_number":15,"context_line":"sorting/filtering. As well as tenant_id cannot be modified."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Added segment_id as it was added in Subnet DB model in Newton."},{"line_number":18,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"1aa78d24_41dd1ddf","line":15,"range":{"start_line":14,"start_character":55,"end_line":15,"end_character":17},"updated":"2016-07-06 15:36:41.000000000","message":"this contradicts a requirement of the spec [1]\n\n\"Also, tenant_id is used as a filter parameter in Neutron API. It is a requirement that this use-case will continue to work.\"\n\nam I missing something?\n\n[1]https://specs.openstack.org/openstack/neutron-specs/specs/newton/moving-to-keystone-v3.html","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"f89ab4ea3af3d570e8018a939a9359bda8cef245","unresolved":false,"context_lines":[{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Introduced tenant_id as read-only property using obj_extra_fields, which"},{"line_number":13,"context_line":"exposes additional attributes for objects and expose the value in to_dict()."},{"line_number":14,"context_line":"The tenant_id cannot be used directly on Subnet object as value for"},{"line_number":15,"context_line":"sorting/filtering. As well as tenant_id cannot be modified."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Added segment_id as it was added in Subnet DB model in Newton."},{"line_number":18,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"1aa78d24_3108b628","line":15,"range":{"start_line":14,"start_character":55,"end_line":15,"end_character":17},"in_reply_to":"1aa78d24_41dd1ddf","updated":"2016-07-08 08:26:59.000000000","message":"So the tenand_id cannot be used when passing filters to object, but we have to ensure on API level the translation between tenant_id to project_id, before filters reach the object. This means that neutron API will be backward compatible with tenant_id filtering, but Subnet object will be operating on project_id translated value.","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"}],"neutron/objects/base.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":210,"context_line":"        for base in itertools.chain([cls], bases):"},{"line_number":211,"context_line":"            if hasattr(base, \u0027primary_keys\u0027):"},{"line_number":212,"context_line":"                cls.fields_no_update +\u003d base.primary_keys"},{"line_number":213,"context_line":"            if hasattr(base, \u0027obj_extra_fields\u0027):"},{"line_number":214,"context_line":"                cls.fields_no_update +\u003d base.obj_extra_fields"},{"line_number":215,"context_line":"        # avoid duplicate entries"},{"line_number":216,"context_line":"        cls.fields_no_update \u003d list(set(cls.fields_no_update))"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_783678b5","line":213,"range":{"start_line":213,"start_character":30,"end_line":213,"end_character":46},"updated":"2016-06-28 11:37:21.000000000","message":"I guess you should add the attribute to the base class, and document it with a comment.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"8c42460778148f4ec00709e9765ba84881ff520a","unresolved":false,"context_lines":[{"line_number":210,"context_line":"        for base in itertools.chain([cls], bases):"},{"line_number":211,"context_line":"            if hasattr(base, \u0027primary_keys\u0027):"},{"line_number":212,"context_line":"                cls.fields_no_update +\u003d base.primary_keys"},{"line_number":213,"context_line":"            if hasattr(base, \u0027obj_extra_fields\u0027):"},{"line_number":214,"context_line":"                cls.fields_no_update +\u003d base.obj_extra_fields"},{"line_number":215,"context_line":"        # avoid duplicate entries"},{"line_number":216,"context_line":"        cls.fields_no_update \u003d list(set(cls.fields_no_update))"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_789af8c6","line":213,"updated":"2016-06-28 11:10:46.000000000","message":"let\u0027s not add yet another magic list of fields. We can handle the project_id/tenant_id problem in another way, see my comment in the subnet file","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":210,"context_line":"        for base in itertools.chain([cls], bases):"},{"line_number":211,"context_line":"            if hasattr(base, \u0027primary_keys\u0027):"},{"line_number":212,"context_line":"                cls.fields_no_update +\u003d base.primary_keys"},{"line_number":213,"context_line":"            if hasattr(base, \u0027obj_extra_fields\u0027):"},{"line_number":214,"context_line":"                cls.fields_no_update +\u003d base.obj_extra_fields"},{"line_number":215,"context_line":"        # avoid duplicate entries"},{"line_number":216,"context_line":"        cls.fields_no_update \u003d list(set(cls.fields_no_update))"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_84013e09","line":213,"range":{"start_line":213,"start_character":30,"end_line":213,"end_character":46},"in_reply_to":"3aaa91ec_783678b5","updated":"2016-06-28 12:25:50.000000000","message":"obj_extra_fields is defined in oslo [1], so it is no new magic list of fields ;) \nI can add it to Neutron base object with comment what it is for and how it can be used.\n\n[1] https://github.com/openstack/oslo.versionedobjects/blob/master/oslo_versionedobjects/base.py#L275","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":448,"context_line":""},{"line_number":449,"context_line":"        :returns: None"},{"line_number":450,"context_line":"        \"\"\""},{"line_number":451,"context_line":"        self.update_fields(obj_data, self.primary_keys, reset_changes)"},{"line_number":452,"context_line":""},{"line_number":453,"context_line":"    def update_fields(self, obj_data, forbidden_keys\u003dNone,"},{"line_number":454,"context_line":"                      reset_changes\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_1869348c","line":451,"range":{"start_line":451,"start_character":37,"end_line":451,"end_character":54},"updated":"2016-06-28 11:37:21.000000000","message":"maybe add a keyword name here so that it\u0027s clear what\u0027s the usage for the parameter.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":448,"context_line":""},{"line_number":449,"context_line":"        :returns: None"},{"line_number":450,"context_line":"        \"\"\""},{"line_number":451,"context_line":"        self.update_fields(obj_data, self.primary_keys, reset_changes)"},{"line_number":452,"context_line":""},{"line_number":453,"context_line":"    def update_fields(self, obj_data, forbidden_keys\u003dNone,"},{"line_number":454,"context_line":"                      reset_changes\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_c3267fb9","line":451,"range":{"start_line":451,"start_character":37,"end_line":451,"end_character":54},"in_reply_to":"3aaa91ec_1869348c","updated":"2016-07-05 12:07:50.000000000","message":"Done: https://review.openstack.org/#/c/337539/1/neutron/objects/base.py@449","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"8c42460778148f4ec00709e9765ba84881ff520a","unresolved":false,"context_lines":[{"line_number":450,"context_line":"        \"\"\""},{"line_number":451,"context_line":"        self.update_fields(obj_data, self.primary_keys, reset_changes)"},{"line_number":452,"context_line":""},{"line_number":453,"context_line":"    def update_fields(self, obj_data, forbidden_keys\u003dNone,"},{"line_number":454,"context_line":"                      reset_changes\u003dFalse):"},{"line_number":455,"context_line":"        \"\"\"Updates fields of an object that are not forbidden to be updated."},{"line_number":456,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_1852d4dd","line":453,"updated":"2016-06-28 11:10:46.000000000","message":"why do we need this new method? It seems we don\u0027t use the param forbidden_keys, so it can be removed","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":450,"context_line":"        \"\"\""},{"line_number":451,"context_line":"        self.update_fields(obj_data, self.primary_keys, reset_changes)"},{"line_number":452,"context_line":""},{"line_number":453,"context_line":"    def update_fields(self, obj_data, forbidden_keys\u003dNone,"},{"line_number":454,"context_line":"                      reset_changes\u003dFalse):"},{"line_number":455,"context_line":"        \"\"\"Updates fields of an object that are not forbidden to be updated."},{"line_number":456,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_c7b868ca","line":453,"in_reply_to":"3aaa91ec_1852d4dd","updated":"2016-06-28 12:25:50.000000000","message":"We need this method to get easier way of updating allowed fields in object. This is kind of common pattern when you integrate the objects in Neutron code base. When user is passing via REST API new values, we need to update every field since there is no info which one was updated. \nThe forbidden_keys is passed in line 451 in update_nonidentifying_fields() method, so we have 2 possibilities: 1) forbidden_keys is None and it will load the fields_no_update. 2) caller of the function will specify what list of fields should not be updated.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":457,"context_line":"        :param obj_data: the full set of object data"},{"line_number":458,"context_line":"        :type obj_data: dict"},{"line_number":459,"context_line":"        :param forbidden_keys: list of fields names that are forbidden to be"},{"line_number":460,"context_line":"                    updated, if not passed, fields_no_update is set by default"},{"line_number":461,"context_line":"        :type forbidden_keys list"},{"line_number":462,"context_line":"        :param reset_changes: indicates whether the object\u0027s current set of"},{"line_number":463,"context_line":"                              changed fields should be cleared"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_38c87074","line":460,"range":{"start_line":460,"start_character":64,"end_line":460,"end_character":67},"updated":"2016-06-28 11:37:21.000000000","message":"-\u003e used?","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":457,"context_line":"        :param obj_data: the full set of object data"},{"line_number":458,"context_line":"        :type obj_data: dict"},{"line_number":459,"context_line":"        :param forbidden_keys: list of fields names that are forbidden to be"},{"line_number":460,"context_line":"                    updated, if not passed, fields_no_update is set by default"},{"line_number":461,"context_line":"        :type forbidden_keys list"},{"line_number":462,"context_line":"        :param reset_changes: indicates whether the object\u0027s current set of"},{"line_number":463,"context_line":"                              changed fields should be cleared"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_18ee54ec","line":460,"range":{"start_line":460,"start_character":27,"end_line":460,"end_character":28},"updated":"2016-06-28 11:37:21.000000000","message":"replace with ; to make syntax more clear","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":457,"context_line":"        :param obj_data: the full set of object data"},{"line_number":458,"context_line":"        :type obj_data: dict"},{"line_number":459,"context_line":"        :param forbidden_keys: list of fields names that are forbidden to be"},{"line_number":460,"context_line":"                    updated, if not passed, fields_no_update is set by default"},{"line_number":461,"context_line":"        :type forbidden_keys list"},{"line_number":462,"context_line":"        :param reset_changes: indicates whether the object\u0027s current set of"},{"line_number":463,"context_line":"                              changed fields should be cleared"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_e35a9b29","line":460,"range":{"start_line":460,"start_character":64,"end_line":460,"end_character":67},"in_reply_to":"3aaa91ec_38c87074","updated":"2016-07-05 12:07:50.000000000","message":"Done and done: https://review.openstack.org/#/c/337539/1/neutron/objects/base.py@459","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":466,"context_line":"        :returns: None"},{"line_number":467,"context_line":"        \"\"\""},{"line_number":468,"context_line":"        if not forbidden_keys:"},{"line_number":469,"context_line":"            forbidden_keys \u003d self.fields_no_update"},{"line_number":470,"context_line":"        if reset_changes:"},{"line_number":471,"context_line":"            self.obj_reset_changes()"},{"line_number":472,"context_line":"        for k, v in obj_data.items():"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_b898e06b","line":469,"updated":"2016-06-28 11:37:21.000000000","message":"Shouldn\u0027t we append fields_no_update to passed forbidden_keys anyway? It would be weird that the method would allow to set non-updatable fields.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":466,"context_line":"        :returns: None"},{"line_number":467,"context_line":"        \"\"\""},{"line_number":468,"context_line":"        if not forbidden_keys:"},{"line_number":469,"context_line":"            forbidden_keys \u003d self.fields_no_update"},{"line_number":470,"context_line":"        if reset_changes:"},{"line_number":471,"context_line":"            self.obj_reset_changes()"},{"line_number":472,"context_line":"        for k, v in obj_data.items():"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_874940ba","line":469,"in_reply_to":"3aaa91ec_b898e06b","updated":"2016-06-28 12:25:50.000000000","message":"I do not know why in the first place someone added a method that would allow to update fields that are not primary_keys. From git history, it was added for QoS stuff.\nIn my understanding, we should not allow to update any field that is in fields_no_update. And in fields_no_update are: primary_keys + obj_extra_fields + everything that is defined by object definition.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"8c42460778148f4ec00709e9765ba84881ff520a","unresolved":false,"context_lines":[{"line_number":470,"context_line":"        if reset_changes:"},{"line_number":471,"context_line":"            self.obj_reset_changes()"},{"line_number":472,"context_line":"        for k, v in obj_data.items():"},{"line_number":473,"context_line":"            if k not in forbidden_keys:"},{"line_number":474,"context_line":"                setattr(self, k, v)"},{"line_number":475,"context_line":""},{"line_number":476,"context_line":"    def update(self):"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_7804b8c5","line":473,"updated":"2016-06-28 11:10:46.000000000","message":"you should check it\u0027s not a primary key too","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":470,"context_line":"        if reset_changes:"},{"line_number":471,"context_line":"            self.obj_reset_changes()"},{"line_number":472,"context_line":"        for k, v in obj_data.items():"},{"line_number":473,"context_line":"            if k not in forbidden_keys:"},{"line_number":474,"context_line":"                setattr(self, k, v)"},{"line_number":475,"context_line":""},{"line_number":476,"context_line":"    def update(self):"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_c797c8e9","line":473,"in_reply_to":"3aaa91ec_7804b8c5","updated":"2016-06-28 12:25:50.000000000","message":"primary_keys are included in forbidden_keys.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"9e6f423399c1d14d15653b39a09988df167f21bf","unresolved":false,"context_lines":[{"line_number":247,"context_line":"    # Handling of obj_extra_fields is in oslo versionedobjects."},{"line_number":248,"context_line":"    # The extra fields can be accessed as read only property and are exposed"},{"line_number":249,"context_line":"    # in to_dict()"},{"line_number":250,"context_line":"    obj_extra_fields \u003d []"},{"line_number":251,"context_line":""},{"line_number":252,"context_line":"    def from_db_object(self, *objs):"},{"line_number":253,"context_line":"        db_objs \u003d [self.modify_fields_from_db(db_obj) for db_obj in objs]"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aa78d24_9e6920fc","line":250,"updated":"2016-07-06 15:36:41.000000000","message":"it\u0027s defined in VersionedObject, we don\u0027t need to redefine it in the child class, right?","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"f89ab4ea3af3d570e8018a939a9359bda8cef245","unresolved":false,"context_lines":[{"line_number":247,"context_line":"    # Handling of obj_extra_fields is in oslo versionedobjects."},{"line_number":248,"context_line":"    # The extra fields can be accessed as read only property and are exposed"},{"line_number":249,"context_line":"    # in to_dict()"},{"line_number":250,"context_line":"    obj_extra_fields \u003d []"},{"line_number":251,"context_line":""},{"line_number":252,"context_line":"    def from_db_object(self, *objs):"},{"line_number":253,"context_line":"        db_objs \u003d [self.modify_fields_from_db(db_obj) for db_obj in objs]"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aa78d24_311f165d","line":250,"in_reply_to":"1aa78d24_0b363de7","updated":"2016-07-08 08:26:59.000000000","message":"I can comment the 250 line.","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"aaad0b1bda82dc88418bdc2f33cfd683bc3a3d32","unresolved":false,"context_lines":[{"line_number":247,"context_line":"    # Handling of obj_extra_fields is in oslo versionedobjects."},{"line_number":248,"context_line":"    # The extra fields can be accessed as read only property and are exposed"},{"line_number":249,"context_line":"    # in to_dict()"},{"line_number":250,"context_line":"    obj_extra_fields \u003d []"},{"line_number":251,"context_line":""},{"line_number":252,"context_line":"    def from_db_object(self, *objs):"},{"line_number":253,"context_line":"        db_objs \u003d [self.modify_fields_from_db(db_obj) for db_obj in objs]"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aa78d24_0b363de7","line":250,"in_reply_to":"1aa78d24_9e6920fc","updated":"2016-07-07 21:31:50.000000000","message":"Yes, it is.  The only thing missing there is the documentation\n\nhttps://github.com/openstack/oslo.versionedobjects/blob/master/oslo_versionedobjects/base.py#L275","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fae0d44c710970a850648fe897ef36c9beddd0e9","unresolved":false,"context_lines":[{"line_number":208,"context_line":"    def __init__(cls, name, bases, dct):"},{"line_number":209,"context_line":"        super(DeclarativeObject, cls).__init__(name, bases, dct)"},{"line_number":210,"context_line":"        if \u0027project_id\u0027 in cls.fields:"},{"line_number":211,"context_line":"            obj_extra_fields_set \u003d set(cls.obj_extra_fields)"},{"line_number":212,"context_line":"            obj_extra_fields_set.add(\u0027tenant_id\u0027)"},{"line_number":213,"context_line":"            cls.obj_extra_fields \u003d list(obj_extra_fields_set)"},{"line_number":214,"context_line":"            setattr(cls, \u0027tenant_id\u0027, property(lambda x: x.project_id))"},{"line_number":215,"context_line":""},{"line_number":216,"context_line":"        fields_no_update_set \u003d set(cls.fields_no_update)"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_cd566bcd","line":213,"range":{"start_line":211,"start_character":12,"end_line":213,"end_character":61},"updated":"2016-07-21 12:46:25.000000000","message":"if \u0027tenant_id\u0027 not in cls.obj_extra_fields:\n    cls.obj_extra_fields.append(\u0027tenant_id\u0027)","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"69e23148bff252ff00779b75626d22d1cb6137e9","unresolved":false,"context_lines":[{"line_number":208,"context_line":"    def __init__(cls, name, bases, dct):"},{"line_number":209,"context_line":"        super(DeclarativeObject, cls).__init__(name, bases, dct)"},{"line_number":210,"context_line":"        if \u0027project_id\u0027 in cls.fields:"},{"line_number":211,"context_line":"            obj_extra_fields_set \u003d set(cls.obj_extra_fields)"},{"line_number":212,"context_line":"            obj_extra_fields_set.add(\u0027tenant_id\u0027)"},{"line_number":213,"context_line":"            cls.obj_extra_fields \u003d list(obj_extra_fields_set)"},{"line_number":214,"context_line":"            setattr(cls, \u0027tenant_id\u0027, property(lambda x: x.project_id))"},{"line_number":215,"context_line":""},{"line_number":216,"context_line":"        fields_no_update_set \u003d set(cls.fields_no_update)"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_220389b9","line":213,"range":{"start_line":211,"start_character":12,"end_line":213,"end_character":61},"in_reply_to":"dada55a8_49850b58","updated":"2016-07-21 15:06:30.000000000","message":"Oh right. Maybe a test case could be of value to make sure we don\u0027t break it in the future.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"57b98351903c979e579f5a6635030105e221b0ea","unresolved":false,"context_lines":[{"line_number":208,"context_line":"    def __init__(cls, name, bases, dct):"},{"line_number":209,"context_line":"        super(DeclarativeObject, cls).__init__(name, bases, dct)"},{"line_number":210,"context_line":"        if \u0027project_id\u0027 in cls.fields:"},{"line_number":211,"context_line":"            obj_extra_fields_set \u003d set(cls.obj_extra_fields)"},{"line_number":212,"context_line":"            obj_extra_fields_set.add(\u0027tenant_id\u0027)"},{"line_number":213,"context_line":"            cls.obj_extra_fields \u003d list(obj_extra_fields_set)"},{"line_number":214,"context_line":"            setattr(cls, \u0027tenant_id\u0027, property(lambda x: x.project_id))"},{"line_number":215,"context_line":""},{"line_number":216,"context_line":"        fields_no_update_set \u003d set(cls.fields_no_update)"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_49850b58","line":213,"range":{"start_line":211,"start_character":12,"end_line":213,"end_character":61},"in_reply_to":"dada55a8_cd566bcd","updated":"2016-07-21 13:37:16.000000000","message":"I have tried that and that was not working, I have discussed it with Jakub and we have figured it out that cls may reference to base class (NeutronDbObject), so we are adding tenant_id to every derived classes if you do it your way.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fae0d44c710970a850648fe897ef36c9beddd0e9","unresolved":false,"context_lines":[{"line_number":211,"context_line":"            obj_extra_fields_set \u003d set(cls.obj_extra_fields)"},{"line_number":212,"context_line":"            obj_extra_fields_set.add(\u0027tenant_id\u0027)"},{"line_number":213,"context_line":"            cls.obj_extra_fields \u003d list(obj_extra_fields_set)"},{"line_number":214,"context_line":"            setattr(cls, \u0027tenant_id\u0027, property(lambda x: x.project_id))"},{"line_number":215,"context_line":""},{"line_number":216,"context_line":"        fields_no_update_set \u003d set(cls.fields_no_update)"},{"line_number":217,"context_line":"        for base in itertools.chain([cls], bases):"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_ad121707","line":214,"updated":"2016-07-21 12:46:25.000000000","message":"Should we trigger a deprecation warning when accessing the old property?","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"69e23148bff252ff00779b75626d22d1cb6137e9","unresolved":false,"context_lines":[{"line_number":211,"context_line":"            obj_extra_fields_set \u003d set(cls.obj_extra_fields)"},{"line_number":212,"context_line":"            obj_extra_fields_set.add(\u0027tenant_id\u0027)"},{"line_number":213,"context_line":"            cls.obj_extra_fields \u003d list(obj_extra_fields_set)"},{"line_number":214,"context_line":"            setattr(cls, \u0027tenant_id\u0027, property(lambda x: x.project_id))"},{"line_number":215,"context_line":""},{"line_number":216,"context_line":"        fields_no_update_set \u003d set(cls.fields_no_update)"},{"line_number":217,"context_line":"        for base in itertools.chain([cls], bases):"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_0215a5e3","line":214,"in_reply_to":"dada55a8_29d6d74e","updated":"2016-07-21 15:06:30.000000000","message":"you can always pass the lambda to a debtcollector decorator.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"57b98351903c979e579f5a6635030105e221b0ea","unresolved":false,"context_lines":[{"line_number":211,"context_line":"            obj_extra_fields_set \u003d set(cls.obj_extra_fields)"},{"line_number":212,"context_line":"            obj_extra_fields_set.add(\u0027tenant_id\u0027)"},{"line_number":213,"context_line":"            cls.obj_extra_fields \u003d list(obj_extra_fields_set)"},{"line_number":214,"context_line":"            setattr(cls, \u0027tenant_id\u0027, property(lambda x: x.project_id))"},{"line_number":215,"context_line":""},{"line_number":216,"context_line":"        fields_no_update_set \u003d set(cls.fields_no_update)"},{"line_number":217,"context_line":"        for base in itertools.chain([cls], bases):"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_29d6d74e","line":214,"in_reply_to":"dada55a8_ad121707","updated":"2016-07-21 13:37:16.000000000","message":"I guess we can, but how to added deprecation warning for lambda?","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fae0d44c710970a850648fe897ef36c9beddd0e9","unresolved":false,"context_lines":[{"line_number":274,"context_line":""},{"line_number":275,"context_line":"    # obj_extra_fields defines properties that are not part of the model"},{"line_number":276,"context_line":"    # but we want to expose them for easier usage of the object."},{"line_number":277,"context_line":"    # Handling of obj_extra_fields is in oslo versionedobjects."},{"line_number":278,"context_line":"    # The extra fields can be accessed as read only property and are exposed"},{"line_number":279,"context_line":"    # in to_dict()"},{"line_number":280,"context_line":"    # obj_extra_fields \u003d []"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_ad85f707","line":277,"range":{"start_line":277,"start_character":41,"end_line":277,"end_character":62},"updated":"2016-07-21 12:46:25.000000000","message":"nit: oslo.versionedobjects","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"57b98351903c979e579f5a6635030105e221b0ea","unresolved":false,"context_lines":[{"line_number":274,"context_line":""},{"line_number":275,"context_line":"    # obj_extra_fields defines properties that are not part of the model"},{"line_number":276,"context_line":"    # but we want to expose them for easier usage of the object."},{"line_number":277,"context_line":"    # Handling of obj_extra_fields is in oslo versionedobjects."},{"line_number":278,"context_line":"    # The extra fields can be accessed as read only property and are exposed"},{"line_number":279,"context_line":"    # in to_dict()"},{"line_number":280,"context_line":"    # obj_extra_fields \u003d []"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_b81fb259","line":277,"range":{"start_line":277,"start_character":41,"end_line":277,"end_character":62},"in_reply_to":"dada55a8_ad85f707","updated":"2016-07-21 13:37:16.000000000","message":"Done","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":5367,"name":"boden","email":"bodenvmw@gmail.com","username":"boden"},"change_message_id":"4dcdd5cbff13c3f51090556a3bc4dd7dee9c0120","unresolved":false,"context_lines":[{"line_number":277,"context_line":"    # Handling of obj_extra_fields is in oslo versionedobjects."},{"line_number":278,"context_line":"    # The extra fields can be accessed as read only property and are exposed"},{"line_number":279,"context_line":"    # in to_dict()"},{"line_number":280,"context_line":"    # obj_extra_fields \u003d []"},{"line_number":281,"context_line":""},{"line_number":282,"context_line":"    def from_db_object(self, *objs):"},{"line_number":283,"context_line":"        db_objs \u003d [self.modify_fields_from_db(db_obj) for db_obj in objs]"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_5f655c43","line":280,"range":{"start_line":280,"start_character":6,"end_line":280,"end_character":22},"updated":"2016-07-18 22:06:44.000000000","message":"OVO newbie question: how is obj_extra_fields different from synthetic_fields?","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"8ae4d49b85bf50feb8358b215a72c0300de2b5d5","unresolved":false,"context_lines":[{"line_number":277,"context_line":"    # Handling of obj_extra_fields is in oslo versionedobjects."},{"line_number":278,"context_line":"    # The extra fields can be accessed as read only property and are exposed"},{"line_number":279,"context_line":"    # in to_dict()"},{"line_number":280,"context_line":"    # obj_extra_fields \u003d []"},{"line_number":281,"context_line":""},{"line_number":282,"context_line":"    def from_db_object(self, *objs):"},{"line_number":283,"context_line":"        db_objs \u003d [self.modify_fields_from_db(db_obj) for db_obj in objs]"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_600fd42e","line":280,"range":{"start_line":280,"start_character":6,"end_line":280,"end_character":22},"in_reply_to":"dada55a8_5f655c43","updated":"2016-07-19 06:03:54.000000000","message":"obj_extra_fields are not defined in model so you wont have them in obj_to_primitive(), they has no type and they are read-only. Synthetic fields is concept of nested objects inside defined model, they have strict type and are callable\n\nobj_to_primitive() is a string representation of OVO containing object metadata. In neutron this is send over RPC wire.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"}],"neutron/objects/rbac_db.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        # is shared to the calling tenant via an RBAC entry."},{"line_number":58,"context_line":"        matches \u003d (\u0027*\u0027,) + ((context.tenant_id,) if context else ())"},{"line_number":59,"context_line":"        for entry in rbac_entries:"},{"line_number":60,"context_line":"            if (entry.action \u003d\u003d \u0027access_as_shared\u0027 and"},{"line_number":61,"context_line":"                    entry.target_tenant in matches):"},{"line_number":62,"context_line":"                return True"},{"line_number":63,"context_line":"        return False"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_332ff1a2","line":60,"range":{"start_line":60,"start_character":32,"end_line":60,"end_character":50},"updated":"2016-06-28 11:37:21.000000000","message":"models.ACCESS_SHARED?","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        # is shared to the calling tenant via an RBAC entry."},{"line_number":58,"context_line":"        matches \u003d (\u0027*\u0027,) + ((context.tenant_id,) if context else ())"},{"line_number":59,"context_line":"        for entry in rbac_entries:"},{"line_number":60,"context_line":"            if (entry.action \u003d\u003d \u0027access_as_shared\u0027 and"},{"line_number":61,"context_line":"                    entry.target_tenant in matches):"},{"line_number":62,"context_line":"                return True"},{"line_number":63,"context_line":"        return False"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_a781dc91","line":60,"range":{"start_line":60,"start_character":32,"end_line":60,"end_character":50},"in_reply_to":"3aaa91ec_332ff1a2","updated":"2016-06-28 12:25:50.000000000","message":"Good point, I have copied it from [1]\nIt is added to reduce the number of queries when fetching the subnets.\n\n[1] https://github.com/openstack/neutron/blob/master/neutron/db/db_base_plugin_common.py#L293","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        # is shared to the calling tenant via an RBAC entry."},{"line_number":58,"context_line":"        matches \u003d (\u0027*\u0027,) + ((context.tenant_id,) if context else ())"},{"line_number":59,"context_line":"        for entry in rbac_entries:"},{"line_number":60,"context_line":"            if (entry.action \u003d\u003d \u0027access_as_shared\u0027 and"},{"line_number":61,"context_line":"                    entry.target_tenant in matches):"},{"line_number":62,"context_line":"                return True"},{"line_number":63,"context_line":"        return False"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_2364a3e3","line":60,"range":{"start_line":60,"start_character":32,"end_line":60,"end_character":50},"in_reply_to":"3aaa91ec_a781dc91","updated":"2016-07-05 12:07:50.000000000","message":"Done: https://review.openstack.org/#/c/337634/1/neutron/objects/rbac_db.py@61","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"}],"neutron/objects/subnet.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":133,"context_line":""},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"@obj_base.VersionedObjectRegistry.register"},{"line_number":136,"context_line":"class Subnet(base.NeutronDbObject):"},{"line_number":137,"context_line":"    # Version 1.0: Initial version"},{"line_number":138,"context_line":"    VERSION \u003d \u00271.0\u0027"},{"line_number":139,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_0eaa8e70","line":136,"updated":"2016-06-28 11:37:21.000000000","message":"Can you describe in a comment here why applying the RBAC metaclass is not applicable to the object? (I assume the reason is that the field is read-only).","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":133,"context_line":""},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"@obj_base.VersionedObjectRegistry.register"},{"line_number":136,"context_line":"class Subnet(base.NeutronDbObject):"},{"line_number":137,"context_line":"    # Version 1.0: Initial version"},{"line_number":138,"context_line":"    VERSION \u003d \u00271.0\u0027"},{"line_number":139,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_e7176452","line":136,"in_reply_to":"3aaa91ec_0eaa8e70","updated":"2016-06-28 12:25:50.000000000","message":"Ok, I will add. To add it also here: \u0027shared\u0027 attribute of subnet is dependent of network \u0027shared\u0027 state, so it cannot be changed with Subnet object.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":133,"context_line":""},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"@obj_base.VersionedObjectRegistry.register"},{"line_number":136,"context_line":"class Subnet(base.NeutronDbObject):"},{"line_number":137,"context_line":"    # Version 1.0: Initial version"},{"line_number":138,"context_line":"    VERSION \u003d \u00271.0\u0027"},{"line_number":139,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_c39b1fc8","line":136,"in_reply_to":"3aaa91ec_e7176452","updated":"2016-07-05 12:07:50.000000000","message":"Done: https://review.openstack.org/#/c/337634/1/neutron/objects/subnet.py@135","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":141,"context_line":""},{"line_number":142,"context_line":"    fields \u003d {"},{"line_number":143,"context_line":"        \u0027id\u0027: obj_fields.UUIDField(),"},{"line_number":144,"context_line":"        \u0027project_id\u0027: obj_fields.UUIDField(nullable\u003dTrue),"},{"line_number":145,"context_line":"        \u0027name\u0027: obj_fields.StringField(nullable\u003dTrue),"},{"line_number":146,"context_line":"        \u0027network_id\u0027: obj_fields.UUIDField(),"},{"line_number":147,"context_line":"        \u0027segment_id\u0027: obj_fields.UUIDField(nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_3306d120","line":144,"range":{"start_line":144,"start_character":33,"end_line":144,"end_character":42},"updated":"2016-06-28 11:37:21.000000000","message":"This should actually be StringField, since tenant_ids can be non-UUID.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":141,"context_line":""},{"line_number":142,"context_line":"    fields \u003d {"},{"line_number":143,"context_line":"        \u0027id\u0027: obj_fields.UUIDField(),"},{"line_number":144,"context_line":"        \u0027project_id\u0027: obj_fields.UUIDField(nullable\u003dTrue),"},{"line_number":145,"context_line":"        \u0027name\u0027: obj_fields.StringField(nullable\u003dTrue),"},{"line_number":146,"context_line":"        \u0027network_id\u0027: obj_fields.UUIDField(),"},{"line_number":147,"context_line":"        \u0027segment_id\u0027: obj_fields.UUIDField(nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_4a3abf35","line":144,"range":{"start_line":144,"start_character":33,"end_line":144,"end_character":42},"in_reply_to":"3aaa91ec_3306d120","updated":"2016-06-28 12:25:50.000000000","message":"Where tenant_id can be non-UUID?","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":141,"context_line":""},{"line_number":142,"context_line":"    fields \u003d {"},{"line_number":143,"context_line":"        \u0027id\u0027: obj_fields.UUIDField(),"},{"line_number":144,"context_line":"        \u0027project_id\u0027: obj_fields.UUIDField(nullable\u003dTrue),"},{"line_number":145,"context_line":"        \u0027name\u0027: obj_fields.StringField(nullable\u003dTrue),"},{"line_number":146,"context_line":"        \u0027network_id\u0027: obj_fields.UUIDField(),"},{"line_number":147,"context_line":"        \u0027segment_id\u0027: obj_fields.UUIDField(nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_23ab03d8","line":144,"range":{"start_line":144,"start_character":33,"end_line":144,"end_character":42},"in_reply_to":"3aaa91ec_333b6aed","updated":"2016-07-05 12:07:50.000000000","message":"Done in PS6.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e615e4e15667630a68d6630486b700ea90f3dcb0","unresolved":false,"context_lines":[{"line_number":141,"context_line":""},{"line_number":142,"context_line":"    fields \u003d {"},{"line_number":143,"context_line":"        \u0027id\u0027: obj_fields.UUIDField(),"},{"line_number":144,"context_line":"        \u0027project_id\u0027: obj_fields.UUIDField(nullable\u003dTrue),"},{"line_number":145,"context_line":"        \u0027name\u0027: obj_fields.StringField(nullable\u003dTrue),"},{"line_number":146,"context_line":"        \u0027network_id\u0027: obj_fields.UUIDField(),"},{"line_number":147,"context_line":"        \u0027segment_id\u0027: obj_fields.UUIDField(nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_333b6aed","line":144,"range":{"start_line":144,"start_character":33,"end_line":144,"end_character":42},"in_reply_to":"3aaa91ec_4a3abf35","updated":"2016-06-28 13:09:20.000000000","message":"In a non-keystone based installation. See: I93488701c824a51b5588093b9aba499068ba36e8","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":152,"context_line":"        \u0027allocation_pools\u0027: obj_fields.ListOfObjectsField(\u0027IPAllocationPool\u0027,"},{"line_number":153,"context_line":"                                                          nullable\u003dTrue),"},{"line_number":154,"context_line":"        \u0027enable_dhcp\u0027: obj_fields.BooleanField(nullable\u003dTrue),"},{"line_number":155,"context_line":"        \u0027shared\u0027: obj_fields.BooleanField(nullable\u003dTrue),"},{"line_number":156,"context_line":"        \u0027dns_nameservers\u0027: obj_fields.ListOfObjectsField(\u0027DNSNameServer\u0027,"},{"line_number":157,"context_line":"                                                         nullable\u003dTrue),"},{"line_number":158,"context_line":"        \u0027host_routes\u0027: obj_fields.ListOfObjectsField(\u0027Route\u0027, nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_6e307208","line":155,"updated":"2016-06-28 11:37:21.000000000","message":"Should it be fields_no_update?","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e615e4e15667630a68d6630486b700ea90f3dcb0","unresolved":false,"context_lines":[{"line_number":152,"context_line":"        \u0027allocation_pools\u0027: obj_fields.ListOfObjectsField(\u0027IPAllocationPool\u0027,"},{"line_number":153,"context_line":"                                                          nullable\u003dTrue),"},{"line_number":154,"context_line":"        \u0027enable_dhcp\u0027: obj_fields.BooleanField(nullable\u003dTrue),"},{"line_number":155,"context_line":"        \u0027shared\u0027: obj_fields.BooleanField(nullable\u003dTrue),"},{"line_number":156,"context_line":"        \u0027dns_nameservers\u0027: obj_fields.ListOfObjectsField(\u0027DNSNameServer\u0027,"},{"line_number":157,"context_line":"                                                         nullable\u003dTrue),"},{"line_number":158,"context_line":"        \u0027host_routes\u0027: obj_fields.ListOfObjectsField(\u0027Route\u0027, nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_13158e48","line":155,"in_reply_to":"3aaa91ec_2a577303","updated":"2016-06-28 13:09:20.000000000","message":"Ah right, sorry.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":152,"context_line":"        \u0027allocation_pools\u0027: obj_fields.ListOfObjectsField(\u0027IPAllocationPool\u0027,"},{"line_number":153,"context_line":"                                                          nullable\u003dTrue),"},{"line_number":154,"context_line":"        \u0027enable_dhcp\u0027: obj_fields.BooleanField(nullable\u003dTrue),"},{"line_number":155,"context_line":"        \u0027shared\u0027: obj_fields.BooleanField(nullable\u003dTrue),"},{"line_number":156,"context_line":"        \u0027dns_nameservers\u0027: obj_fields.ListOfObjectsField(\u0027DNSNameServer\u0027,"},{"line_number":157,"context_line":"                                                         nullable\u003dTrue),"},{"line_number":158,"context_line":"        \u0027host_routes\u0027: obj_fields.ListOfObjectsField(\u0027Route\u0027, nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_2a577303","line":155,"in_reply_to":"3aaa91ec_6e307208","updated":"2016-06-28 12:25:50.000000000","message":"generally speaking, \u0027shared\u0027 is included in synthetic_fields and synthetic_fields cannot be changed [1] so...\n\n[1] https://github.com/openstack/neutron/blob/master/neutron/objects/base.py#L367","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":169,"context_line":"        \u0027project_id\u0027: \u0027tenant_id\u0027"},{"line_number":170,"context_line":"    }"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    # obj_extra_fields defines properties that are not part of the model"},{"line_number":173,"context_line":"    # but we want to expose them for easier usage of the object."},{"line_number":174,"context_line":"    # Handling is implemented in oslo."},{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_ae6d3ace","line":172,"updated":"2016-06-28 11:37:21.000000000","message":"I guess the comment belongs to the base class.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":169,"context_line":"        \u0027project_id\u0027: \u0027tenant_id\u0027"},{"line_number":170,"context_line":"    }"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    # obj_extra_fields defines properties that are not part of the model"},{"line_number":173,"context_line":"    # but we want to expose them for easier usage of the object."},{"line_number":174,"context_line":"    # Handling is implemented in oslo."},{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_a385335a","line":172,"in_reply_to":"3aaa91ec_ae6d3ace","updated":"2016-07-05 12:07:50.000000000","message":"Done in PS6.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    # obj_extra_fields defines properties that are not part of the model"},{"line_number":173,"context_line":"    # but we want to expose them for easier usage of the object."},{"line_number":174,"context_line":"    # Handling is implemented in oslo."},{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_6e36b2b5","line":174,"range":{"start_line":174,"start_character":30,"end_line":174,"end_character":37},"updated":"2016-06-28 11:37:21.000000000","message":"Handling of what? I don\u0027t think there is any logic in oslo library to handle fields in any specific way.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e615e4e15667630a68d6630486b700ea90f3dcb0","unresolved":false,"context_lines":[{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    # obj_extra_fields defines properties that are not part of the model"},{"line_number":173,"context_line":"    # but we want to expose them for easier usage of the object."},{"line_number":174,"context_line":"    # Handling is implemented in oslo."},{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_fefec903","line":174,"range":{"start_line":174,"start_character":30,"end_line":174,"end_character":37},"in_reply_to":"3aaa91ec_4a6d9f98","updated":"2016-06-28 13:09:20.000000000","message":"Wow.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    # obj_extra_fields defines properties that are not part of the model"},{"line_number":173,"context_line":"    # but we want to expose them for easier usage of the object."},{"line_number":174,"context_line":"    # Handling is implemented in oslo."},{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_4a6d9f98","line":174,"range":{"start_line":174,"start_character":30,"end_line":174,"end_character":37},"in_reply_to":"3aaa91ec_6e36b2b5","updated":"2016-06-28 12:25:50.000000000","message":"Handling of obj_extra_fields is implemented in oslo versionedobjects, obj_extra_fields are read-only and are exposed in to_dict() [1], [2]\n\n[1] https://github.com/openstack/oslo.versionedobjects/blob/master/oslo_versionedobjects/base.py#L667\n[2] https://github.com/openstack/oslo.versionedobjects/blob/master/oslo_versionedobjects/base.py#L704","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":174,"context_line":"    # Handling is implemented in oslo."},{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"    @property"},{"line_number":178,"context_line":"    def tenant_id(self):"},{"line_number":179,"context_line":"        return self.project_id"},{"line_number":180,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_eeae22e6","line":177,"updated":"2016-06-28 11:37:21.000000000","message":"don\u0027t we need a setter too?","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":174,"context_line":"    # Handling is implemented in oslo."},{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"    @property"},{"line_number":178,"context_line":"    def tenant_id(self):"},{"line_number":179,"context_line":"        return self.project_id"},{"line_number":180,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_2a0f73e2","line":177,"in_reply_to":"3aaa91ec_eeae22e6","updated":"2016-06-28 12:25:50.000000000","message":"setters are not allowed. I have tried it, and from oslo implementation, it does not seem to handle the obj_extra_fields as read-write, it is read-only.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"8c42460778148f4ec00709e9765ba84881ff520a","unresolved":false,"context_lines":[{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"    @property"},{"line_number":178,"context_line":"    def tenant_id(self):"},{"line_number":179,"context_line":"        return self.project_id"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    def obj_load_attr(self, attrname):"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_53039d0d","line":178,"updated":"2016-06-28 11:10:46.000000000","message":"this is a bit confusing, I am pretty sure oslo versionedobject creates the tenant_id field in the object since it\u0027s defined in the db model. It\u0027s probably better to modify the way we handle fields_need_translation in the base class and populate both tenant_id and project_id","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"    @property"},{"line_number":178,"context_line":"    def tenant_id(self):"},{"line_number":179,"context_line":"        return self.project_id"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    def obj_load_attr(self, attrname):"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_aa1a4315","line":178,"in_reply_to":"3aaa91ec_0e48ce5a","updated":"2016-06-28 12:25:50.000000000","message":"When using the obj_extra_fields, values are also exposed in to_dict() with value defined in @property method.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":175,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"    @property"},{"line_number":178,"context_line":"    def tenant_id(self):"},{"line_number":179,"context_line":"        return self.project_id"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    def obj_load_attr(self, attrname):"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_0e48ce5a","line":178,"in_reply_to":"3aaa91ec_53039d0d","updated":"2016-06-28 11:37:21.000000000","message":"Hm. We don\u0027t want to expose tenant_id as a field on the object. We may still want to set it in to_dict() for resources that already have tenant_id right now though.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"8c42460778148f4ec00709e9765ba84881ff520a","unresolved":false,"context_lines":[{"line_number":181,"context_line":"    def obj_load_attr(self, attrname):"},{"line_number":182,"context_line":"        if attrname \u003d\u003d \u0027shared\u0027:"},{"line_number":183,"context_line":"            self.load_shared()"},{"line_number":184,"context_line":"            return"},{"line_number":185,"context_line":"        super(Subnet, self).obj_load_attr(attrname)"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def load_shared(self, obj\u003dNone):"}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_13bbd50f","line":184,"range":{"start_line":184,"start_character":11,"end_line":184,"end_character":18},"updated":"2016-06-28 11:10:46.000000000","message":"this could be return self.load_shared() or simply use if/else","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":181,"context_line":"    def obj_load_attr(self, attrname):"},{"line_number":182,"context_line":"        if attrname \u003d\u003d \u0027shared\u0027:"},{"line_number":183,"context_line":"            self.load_shared()"},{"line_number":184,"context_line":"            return"},{"line_number":185,"context_line":"        super(Subnet, self).obj_load_attr(attrname)"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def load_shared(self, obj\u003dNone):"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_e3f61bf8","line":184,"range":{"start_line":184,"start_character":11,"end_line":184,"end_character":18},"in_reply_to":"3aaa91ec_13bbd50f","updated":"2016-07-05 12:07:50.000000000","message":"Done: https://review.openstack.org/#/c/337634/1/neutron/objects/subnet.py@184","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":184,"context_line":"            return"},{"line_number":185,"context_line":"        super(Subnet, self).obj_load_attr(attrname)"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def load_shared(self, obj\u003dNone):"},{"line_number":188,"context_line":"        if obj:"},{"line_number":189,"context_line":"            rbac_entries \u003d obj.get(\u0027rbac_entries\u0027) or {}"},{"line_number":190,"context_line":"            shared \u003d (rbac_db.RbacNeutronDbObjectMixin."}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_ee1f4207","line":187,"range":{"start_line":187,"start_character":26,"end_line":187,"end_character":29},"updated":"2016-06-28 11:37:21.000000000","message":"is it really an \u0027object\u0027? I would think it\u0027s a model?..","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":184,"context_line":"            return"},{"line_number":185,"context_line":"        super(Subnet, self).obj_load_attr(attrname)"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def load_shared(self, obj\u003dNone):"},{"line_number":188,"context_line":"        if obj:"},{"line_number":189,"context_line":"            rbac_entries \u003d obj.get(\u0027rbac_entries\u0027) or {}"},{"line_number":190,"context_line":"            shared \u003d (rbac_db.RbacNeutronDbObjectMixin."}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_83e8f711","line":187,"range":{"start_line":187,"start_character":26,"end_line":187,"end_character":29},"in_reply_to":"3aaa91ec_8a9ae76c","updated":"2016-07-05 12:07:50.000000000","message":"Done: https://review.openstack.org/#/c/337634/1/neutron/objects/subnet.py@187","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":184,"context_line":"            return"},{"line_number":185,"context_line":"        super(Subnet, self).obj_load_attr(attrname)"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def load_shared(self, obj\u003dNone):"},{"line_number":188,"context_line":"        if obj:"},{"line_number":189,"context_line":"            rbac_entries \u003d obj.get(\u0027rbac_entries\u0027) or {}"},{"line_number":190,"context_line":"            shared \u003d (rbac_db.RbacNeutronDbObjectMixin."}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_8a9ae76c","line":187,"range":{"start_line":187,"start_character":26,"end_line":187,"end_character":29},"in_reply_to":"3aaa91ec_ee1f4207","updated":"2016-06-28 12:25:50.000000000","message":"Yes, it can be called model.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"d6aa0a484579e88f968a14410af33876fce1fabe","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        setattr(self, \u0027shared\u0027, shared)"},{"line_number":199,"context_line":"        self.obj_reset_changes([\u0027shared\u0027])"},{"line_number":200,"context_line":""},{"line_number":201,"context_line":"    def from_db_object(self, *objs):"},{"line_number":202,"context_line":"        super(Subnet, self).from_db_object(*objs)"},{"line_number":203,"context_line":"        self.load_shared(objs[0])"},{"line_number":204,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_4e1656a8","line":201,"updated":"2016-06-28 11:37:21.000000000","message":"Should we instead redefine load_synthetic_db_fields that seems to be public part of object API instead of that helper method?","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"654607faeb92041979176161c5552b2e7824897c","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        setattr(self, \u0027shared\u0027, shared)"},{"line_number":199,"context_line":"        self.obj_reset_changes([\u0027shared\u0027])"},{"line_number":200,"context_line":""},{"line_number":201,"context_line":"    def from_db_object(self, *objs):"},{"line_number":202,"context_line":"        super(Subnet, self).from_db_object(*objs)"},{"line_number":203,"context_line":"        self.load_shared(objs[0])"},{"line_number":204,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3aaa91ec_ea30cb09","line":201,"in_reply_to":"3aaa91ec_4e1656a8","updated":"2016-06-28 12:25:50.000000000","message":"I have found from_db_object a nice place to get access to db model with its side-loaded resources. It is used in get, update and create methods, so we can modify/load any new values.","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"d757b75c6829fd293b8679b4382d3c2966c59827","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        setattr(self, \u0027shared\u0027, shared)"},{"line_number":199,"context_line":"        self.obj_reset_changes([\u0027shared\u0027])"},{"line_number":200,"context_line":""},{"line_number":201,"context_line":"    def from_db_object(self, *objs):"},{"line_number":202,"context_line":"        super(Subnet, self).from_db_object(*objs)"},{"line_number":203,"context_line":"        self.load_shared(objs[0])"},{"line_number":204,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_8891349c","line":201,"in_reply_to":"3aaa91ec_ea30cb09","updated":"2016-07-05 12:07:50.000000000","message":"I can reworked it after patch [1] is merged.\n\n[1] https://review.openstack.org/#/c/334380","commit_id":"6e01ea18e43c66c8927bf8e3d20986635e235cc2"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"9e6f423399c1d14d15653b39a09988df167f21bf","unresolved":false,"context_lines":[{"line_number":179,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    @property"},{"line_number":182,"context_line":"    def tenant_id(self):"},{"line_number":183,"context_line":"        return self.project_id"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"    def __init__(self, context\u003dNone, **kwargs):"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aa78d24_01079518","line":182,"updated":"2016-07-06 15:36:41.000000000","message":"most of the object will have to access this property. It\u0027s better to generalize it so that we don\u0027t have to add these lines in all the object that have a tenant_id. Thoughts?","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"aaad0b1bda82dc88418bdc2f33cfd683bc3a3d32","unresolved":false,"context_lines":[{"line_number":179,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    @property"},{"line_number":182,"context_line":"    def tenant_id(self):"},{"line_number":183,"context_line":"        return self.project_id"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"    def __init__(self, context\u003dNone, **kwargs):"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aa78d24_ee9dbf0b","line":182,"in_reply_to":"1aa78d24_01079518","updated":"2016-07-07 21:31:50.000000000","message":"I could be an interesting implementation given that this is depends on the content of fields dict.  I\u0027m in favor on this but I\u0027m not sure if this could add extra complexity.","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"f89ab4ea3af3d570e8018a939a9359bda8cef245","unresolved":false,"context_lines":[{"line_number":179,"context_line":"    obj_extra_fields \u003d [\u0027tenant_id\u0027]"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    @property"},{"line_number":182,"context_line":"    def tenant_id(self):"},{"line_number":183,"context_line":"        return self.project_id"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"    def __init__(self, context\u003dNone, **kwargs):"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aa78d24_b1f026cb","line":182,"in_reply_to":"1aa78d24_ee9dbf0b","updated":"2016-07-08 08:26:59.000000000","message":"I can try to move it to base class and apply only when object has project_id. Will see how about complexity.","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":5367,"name":"boden","email":"bodenvmw@gmail.com","username":"boden"},"change_message_id":"4dcdd5cbff13c3f51090556a3bc4dd7dee9c0120","unresolved":false,"context_lines":[{"line_number":75,"context_line":"        # TODO(korzen) remove this method when IP and CIDR decorator ready"},{"line_number":76,"context_line":"        result \u003d super(Route, cls).modify_fields_from_db(db_obj)"},{"line_number":77,"context_line":"        if \u0027destination\u0027 in result:"},{"line_number":78,"context_line":"            result[\u0027destination\u0027] \u003d utils.AuthenticIPNetwork("},{"line_number":79,"context_line":"                result[\u0027destination\u0027])"},{"line_number":80,"context_line":"        if \u0027nexthop\u0027 in result:"},{"line_number":81,"context_line":"            result[\u0027nexthop\u0027] \u003d netaddr.IPAddress(result[\u0027nexthop\u0027])"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_7f4ae084","line":78,"updated":"2016-07-18 22:06:44.000000000","message":"FYI: coverage on tests.unit.objects.test_base is showing this doesn\u0027t get tested.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"8ae4d49b85bf50feb8358b215a72c0300de2b5d5","unresolved":false,"context_lines":[{"line_number":75,"context_line":"        # TODO(korzen) remove this method when IP and CIDR decorator ready"},{"line_number":76,"context_line":"        result \u003d super(Route, cls).modify_fields_from_db(db_obj)"},{"line_number":77,"context_line":"        if \u0027destination\u0027 in result:"},{"line_number":78,"context_line":"            result[\u0027destination\u0027] \u003d utils.AuthenticIPNetwork("},{"line_number":79,"context_line":"                result[\u0027destination\u0027])"},{"line_number":80,"context_line":"        if \u0027nexthop\u0027 in result:"},{"line_number":81,"context_line":"            result[\u0027nexthop\u0027] \u003d netaddr.IPAddress(result[\u0027nexthop\u0027])"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_00837857","line":78,"in_reply_to":"dada55a8_7f4ae084","updated":"2016-07-19 06:03:54.000000000","message":"hmm, it is invoked pretty often, each time you will call get_objects on Route object. I have put raise here and over 30 unit tests failed on master branch...","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":5367,"name":"boden","email":"bodenvmw@gmail.com","username":"boden"},"change_message_id":"4dcdd5cbff13c3f51090556a3bc4dd7dee9c0120","unresolved":false,"context_lines":[{"line_number":216,"context_line":"        # TODO(korzen) remove this method when IP and CIDR decorator ready"},{"line_number":217,"context_line":"        result \u003d super(Subnet, cls).modify_fields_from_db(db_obj)"},{"line_number":218,"context_line":"        if \u0027cidr\u0027 in result:"},{"line_number":219,"context_line":"            result[\u0027cidr\u0027] \u003d utils.AuthenticIPNetwork(result[\u0027cidr\u0027])"},{"line_number":220,"context_line":"        if \u0027gateway_ip\u0027 in result and result[\u0027gateway_ip\u0027] is not None:"},{"line_number":221,"context_line":"            result[\u0027gateway_ip\u0027] \u003d netaddr.IPAddress(result[\u0027gateway_ip\u0027])"},{"line_number":222,"context_line":"        return result"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_5f4f1c92","line":219,"updated":"2016-07-18 22:06:44.000000000","message":"FYI: coverage on tests.unit.objects.test_base is showing this doesn\u0027t get tested.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"8ae4d49b85bf50feb8358b215a72c0300de2b5d5","unresolved":false,"context_lines":[{"line_number":216,"context_line":"        # TODO(korzen) remove this method when IP and CIDR decorator ready"},{"line_number":217,"context_line":"        result \u003d super(Subnet, cls).modify_fields_from_db(db_obj)"},{"line_number":218,"context_line":"        if \u0027cidr\u0027 in result:"},{"line_number":219,"context_line":"            result[\u0027cidr\u0027] \u003d utils.AuthenticIPNetwork(result[\u0027cidr\u0027])"},{"line_number":220,"context_line":"        if \u0027gateway_ip\u0027 in result and result[\u0027gateway_ip\u0027] is not None:"},{"line_number":221,"context_line":"            result[\u0027gateway_ip\u0027] \u003d netaddr.IPAddress(result[\u0027gateway_ip\u0027])"},{"line_number":222,"context_line":"        return result"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_c091609b","line":219,"in_reply_to":"dada55a8_5f4f1c92","updated":"2016-07-19 06:03:54.000000000","message":"ditto line 78","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"}],"neutron/tests/unit/objects/test_base.py":[{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"aaad0b1bda82dc88418bdc2f33cfd683bc3a3d32","unresolved":false,"context_lines":[{"line_number":755,"context_line":"        test_segment \u003d {"},{"line_number":756,"context_line":"            \u0027network_id\u0027: network[\u0027id\u0027],"},{"line_number":757,"context_line":"            \u0027network_type\u0027: \u0027vxlan\u0027,"},{"line_number":758,"context_line":"        }"},{"line_number":759,"context_line":"        self._segment \u003d obj_db_api.create_object(self.context,"},{"line_number":760,"context_line":"                                                 segments_db.NetworkSegment,"},{"line_number":761,"context_line":"                                                 test_segment)"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aa78d24_d1e064fd","line":758,"updated":"2016-07-07 21:31:50.000000000","message":"# TODO(korzen): replace with segment.create() once we get an object implementation for segments","commit_id":"7e22ec72f7ef95fdd22e551df3e51c63851cb687"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fae0d44c710970a850648fe897ef36c9beddd0e9","unresolved":false,"context_lines":[{"line_number":574,"context_line":"        obj \u003d self._test_class(self.context, **self.obj_fields[0])"},{"line_number":575,"context_line":"        for field in self._test_class.obj_extra_fields:"},{"line_number":576,"context_line":"            # field is accessible and cannot be set by any value"},{"line_number":577,"context_line":"            getattr(obj, field)"},{"line_number":578,"context_line":"            self.assertTrue(field in obj.to_dict().keys())"},{"line_number":579,"context_line":"            self.assertRaises(AttributeError, setattr, obj, field, \"1\")"},{"line_number":580,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_c398bc7a","line":577,"updated":"2016-07-21 12:46:25.000000000","message":"Is it always a valid assumption that it won\u0027t raise? Eg. if project_id is not set, in case of tenant_id property?","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"57b98351903c979e579f5a6635030105e221b0ea","unresolved":false,"context_lines":[{"line_number":574,"context_line":"        obj \u003d self._test_class(self.context, **self.obj_fields[0])"},{"line_number":575,"context_line":"        for field in self._test_class.obj_extra_fields:"},{"line_number":576,"context_line":"            # field is accessible and cannot be set by any value"},{"line_number":577,"context_line":"            getattr(obj, field)"},{"line_number":578,"context_line":"            self.assertTrue(field in obj.to_dict().keys())"},{"line_number":579,"context_line":"            self.assertRaises(AttributeError, setattr, obj, field, \"1\")"},{"line_number":580,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_6911ef03","line":577,"in_reply_to":"dada55a8_c398bc7a","updated":"2016-07-21 13:37:16.000000000","message":"for unit test we should have all fields populated by default...","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fae0d44c710970a850648fe897ef36c9beddd0e9","unresolved":false,"context_lines":[{"line_number":583,"context_line":"        for field in self._test_class.fields_no_update:"},{"line_number":584,"context_line":"            self.assertTrue(hasattr(obj, field))"},{"line_number":585,"context_line":""},{"line_number":586,"context_line":"    def test_get_tenant_id(self):"},{"line_number":587,"context_line":"        if not hasattr(self._test_class, \u0027project_id\u0027):"},{"line_number":588,"context_line":"            self.skipTest("},{"line_number":589,"context_line":"                \u0027Test class %r has no project_id field\u0027 % self._test_class)"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_237f18e1","line":586,"updated":"2016-07-21 12:46:25.000000000","message":"Should we have a test only object that would ensure that the test is triggered at least once? At the moment, it\u0027s tested implicitly because subnet has the field, but it does not seem targeted, which is prone to regressions in case subnet is changed in some way later.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"57b98351903c979e579f5a6635030105e221b0ea","unresolved":false,"context_lines":[{"line_number":583,"context_line":"        for field in self._test_class.fields_no_update:"},{"line_number":584,"context_line":"            self.assertTrue(hasattr(obj, field))"},{"line_number":585,"context_line":""},{"line_number":586,"context_line":"    def test_get_tenant_id(self):"},{"line_number":587,"context_line":"        if not hasattr(self._test_class, \u0027project_id\u0027):"},{"line_number":588,"context_line":"            self.skipTest("},{"line_number":589,"context_line":"                \u0027Test class %r has no project_id field\u0027 % self._test_class)"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_e4e1862b","line":586,"in_reply_to":"dada55a8_237f18e1","updated":"2016-07-21 13:37:16.000000000","message":"I can add one. Added.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fae0d44c710970a850648fe897ef36c9beddd0e9","unresolved":false,"context_lines":[{"line_number":818,"context_line":"            \u0027name\u0027: \u0027test-subnet1\u0027,"},{"line_number":819,"context_line":"            \u0027network_id\u0027: network[\u0027id\u0027],"},{"line_number":820,"context_line":"            \u0027ip_version\u0027: 4,"},{"line_number":821,"context_line":"            \u0027cidr\u0027: common_utils.AuthenticIPNetwork(\u002710.0.0.0/24\u0027),"},{"line_number":822,"context_line":"            \u0027gateway_ip\u0027: \u002710.0.0.1\u0027,"},{"line_number":823,"context_line":"            \u0027enable_dhcp\u0027: 1,"},{"line_number":824,"context_line":"            \u0027ipv6_ra_mode\u0027: None,"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_8311a45f","line":821,"updated":"2016-07-21 12:46:25.000000000","message":"why do you need it here? It\u0027s only needed when you care about exact str() representation later. Do you?","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"69e23148bff252ff00779b75626d22d1cb6137e9","unresolved":false,"context_lines":[{"line_number":818,"context_line":"            \u0027name\u0027: \u0027test-subnet1\u0027,"},{"line_number":819,"context_line":"            \u0027network_id\u0027: network[\u0027id\u0027],"},{"line_number":820,"context_line":"            \u0027ip_version\u0027: 4,"},{"line_number":821,"context_line":"            \u0027cidr\u0027: common_utils.AuthenticIPNetwork(\u002710.0.0.0/24\u0027),"},{"line_number":822,"context_line":"            \u0027gateway_ip\u0027: \u002710.0.0.1\u0027,"},{"line_number":823,"context_line":"            \u0027enable_dhcp\u0027: 1,"},{"line_number":824,"context_line":"            \u0027ipv6_ra_mode\u0027: None,"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_02712544","line":821,"in_reply_to":"dada55a8_583796fe","updated":"2016-07-21 15:06:30.000000000","message":"yeah, I only suggested there is no clear reason to use the authentic version of it.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"57b98351903c979e579f5a6635030105e221b0ea","unresolved":false,"context_lines":[{"line_number":818,"context_line":"            \u0027name\u0027: \u0027test-subnet1\u0027,"},{"line_number":819,"context_line":"            \u0027network_id\u0027: network[\u0027id\u0027],"},{"line_number":820,"context_line":"            \u0027ip_version\u0027: 4,"},{"line_number":821,"context_line":"            \u0027cidr\u0027: common_utils.AuthenticIPNetwork(\u002710.0.0.0/24\u0027),"},{"line_number":822,"context_line":"            \u0027gateway_ip\u0027: \u002710.0.0.1\u0027,"},{"line_number":823,"context_line":"            \u0027enable_dhcp\u0027: 1,"},{"line_number":824,"context_line":"            \u0027ipv6_ra_mode\u0027: None,"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_a40aee23","line":821,"in_reply_to":"dada55a8_8311a45f","updated":"2016-07-21 13:37:16.000000000","message":"I\u0027m getting \u0027ValueError: Field value 10.0.0.0/24 is not a netaddr.IPNetwork\u0027 for every test that is creating subnet...\nIt is correct, because we have to give IPNetwork cidr as argument to subnet creation. Well I can change it to netaddr.IPNetwork form base string value.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"5aad41b29d650f96fdb00cc4d597ea7d36c9bc78","unresolved":false,"context_lines":[{"line_number":818,"context_line":"            \u0027name\u0027: \u0027test-subnet1\u0027,"},{"line_number":819,"context_line":"            \u0027network_id\u0027: network[\u0027id\u0027],"},{"line_number":820,"context_line":"            \u0027ip_version\u0027: 4,"},{"line_number":821,"context_line":"            \u0027cidr\u0027: common_utils.AuthenticIPNetwork(\u002710.0.0.0/24\u0027),"},{"line_number":822,"context_line":"            \u0027gateway_ip\u0027: \u002710.0.0.1\u0027,"},{"line_number":823,"context_line":"            \u0027enable_dhcp\u0027: 1,"},{"line_number":824,"context_line":"            \u0027ipv6_ra_mode\u0027: None,"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_583796fe","line":821,"in_reply_to":"dada55a8_a40aee23","updated":"2016-07-21 13:39:05.000000000","message":"s/form/from/","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"79fbb4bf6fb524c4b292cdd397ab82d14331425b","unresolved":false,"context_lines":[{"line_number":13,"context_line":"import collections"},{"line_number":14,"context_line":"import copy"},{"line_number":15,"context_line":"import itertools"},{"line_number":16,"context_line":"import netaddr"},{"line_number":17,"context_line":"import random"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"import mock"}],"source_content_type":"text/x-python","patch_set":8,"id":"dada55a8_c2e54d09","line":16,"updated":"2016-07-21 15:06:06.000000000","message":"this is 3party lib, move to the next section","commit_id":"313f48b41365f634c6d83e124d630ca9a61d8698"}],"neutron/tests/unit/objects/test_subnet.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fae0d44c710970a850648fe897ef36c9beddd0e9","unresolved":false,"context_lines":[{"line_number":216,"context_line":""},{"line_number":217,"context_line":"        self.assertEqual(obj, result[0])"},{"line_number":218,"context_line":""},{"line_number":219,"context_line":"    def test_get_tenant_id(self):"},{"line_number":220,"context_line":"        obj \u003d self._make_object(self.obj_fields[0])"},{"line_number":221,"context_line":"        obj.create()"},{"line_number":222,"context_line":"        project_id \u003d self.obj_fields[0][\u0027project_id\u0027]"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_7e1fe75a","line":219,"updated":"2016-07-21 12:46:25.000000000","message":"This property is already validated in base class, isn\u0027t it?","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"57b98351903c979e579f5a6635030105e221b0ea","unresolved":false,"context_lines":[{"line_number":216,"context_line":""},{"line_number":217,"context_line":"        self.assertEqual(obj, result[0])"},{"line_number":218,"context_line":""},{"line_number":219,"context_line":"    def test_get_tenant_id(self):"},{"line_number":220,"context_line":"        obj \u003d self._make_object(self.obj_fields[0])"},{"line_number":221,"context_line":"        obj.create()"},{"line_number":222,"context_line":"        project_id \u003d self.obj_fields[0][\u0027project_id\u0027]"}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_8943836b","line":219,"in_reply_to":"dada55a8_7e1fe75a","updated":"2016-07-21 13:37:16.000000000","message":"It should be. I can remove this test case.","commit_id":"27c2ad4b8d4de29eb9b6bb7b5eb95511388152ee"}]}
