)]}'
{"cinder/objects/base.py":[{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"b6a396058017a12df3800cabaee1b1bb2f8ed84a","unresolved":false,"context_lines":[{"line_number":407,"context_line":""},{"line_number":408,"context_line":"        current \u003d self.get_by_id(self._context, self.id)"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        # Copy contents retrieved from the DB into self"},{"line_number":411,"context_line":"        my_data \u003d vars(self)"},{"line_number":412,"context_line":"        my_data.clear()"},{"line_number":413,"context_line":"        my_data.update(vars(current))"},{"line_number":414,"context_line":""},{"line_number":415,"context_line":"        # Reset changes in case there were some changes made before the refresh"},{"line_number":416,"context_line":"        self.obj_reset_changes()"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_fbd7dbbc","line":413,"range":{"start_line":410,"start_character":0,"end_line":413,"end_character":37},"updated":"2016-07-05 13:46:45.000000000","message":"That\u0027s pretty radical, especially considering that o.vo is doing some magic inside of them. I wonder if that\u0027s not dangerous in some cases.","commit_id":"ea8777b9365a221b1c7cf0a93bd81de69e51fc5d"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"d1b2d5f3c7e9e357f2a09901529988823fbc26f6","unresolved":false,"context_lines":[{"line_number":407,"context_line":""},{"line_number":408,"context_line":"        current \u003d self.get_by_id(self._context, self.id)"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        # Copy contents retrieved from the DB into self"},{"line_number":411,"context_line":"        my_data \u003d vars(self)"},{"line_number":412,"context_line":"        my_data.clear()"},{"line_number":413,"context_line":"        my_data.update(vars(current))"},{"line_number":414,"context_line":""},{"line_number":415,"context_line":"        # Reset changes in case there were some changes made before the refresh"},{"line_number":416,"context_line":"        self.obj_reset_changes()"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_02006ea9","line":413,"range":{"start_line":410,"start_character":0,"end_line":413,"end_character":37},"in_reply_to":"1aa78d24_fbd7dbbc","updated":"2016-07-06 08:10:30.000000000","message":"The whole point of copying the dictionary is to be \"magic agnostic\".  What we really want is to replace the existing object with the new OVO that we have retrieved, so the easiest way is to just copy the dictionary.  This would be a bad idea if we used `current` variable for something else, but we are not.\n\nWe could do it using normal methods, but in this case I believe it\u0027s overkill and less readable as we would have to delete all currently set fields and then copy just the fields that are set in the newly retrieved OVO.","commit_id":"ea8777b9365a221b1c7cf0a93bd81de69e51fc5d"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"b6a396058017a12df3800cabaee1b1bb2f8ed84a","unresolved":false,"context_lines":[{"line_number":412,"context_line":"        my_data.clear()"},{"line_number":413,"context_line":"        my_data.update(vars(current))"},{"line_number":414,"context_line":""},{"line_number":415,"context_line":"        # Reset changes in case there were some changes made before the refresh"},{"line_number":416,"context_line":"        self.obj_reset_changes()"},{"line_number":417,"context_line":""},{"line_number":418,"context_line":"    @classmethod"},{"line_number":419,"context_line":"    def exists(cls, context, id_):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_bbba736c","line":416,"range":{"start_line":415,"start_character":0,"end_line":416,"end_character":32},"updated":"2016-07-05 13:46:45.000000000","message":"In lines 410-413 we\u0027ve literally reset everything inside that object, including _changed_fields. Do we still need that?","commit_id":"ea8777b9365a221b1c7cf0a93bd81de69e51fc5d"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"d1b2d5f3c7e9e357f2a09901529988823fbc26f6","unresolved":false,"context_lines":[{"line_number":412,"context_line":"        my_data.clear()"},{"line_number":413,"context_line":"        my_data.update(vars(current))"},{"line_number":414,"context_line":""},{"line_number":415,"context_line":"        # Reset changes in case there were some changes made before the refresh"},{"line_number":416,"context_line":"        self.obj_reset_changes()"},{"line_number":417,"context_line":""},{"line_number":418,"context_line":"    @classmethod"},{"line_number":419,"context_line":"    def exists(cls, context, id_):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_221c8a11","line":416,"range":{"start_line":415,"start_character":0,"end_line":416,"end_character":32},"in_reply_to":"1aa78d24_bbba736c","updated":"2016-07-06 08:10:30.000000000","message":"Yup, we don\u0027t need this.  This was leftover (including the comment) when I was looking into the other approach (which I didn\u0027t like).","commit_id":"ea8777b9365a221b1c7cf0a93bd81de69e51fc5d"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"f597e0bf6ffe13f3d6d4cf98930c822dafedae47","unresolved":false,"context_lines":[{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        manifest \u003d OBJ_VERSIONS[version_cap]"},{"line_number":144,"context_line":"        target_version \u003d manifest[self.obj_name()]"},{"line_number":145,"context_line":"        entity \u003d self.obj_to_primitive(target_version, manifest)"},{"line_number":146,"context_line":"        return self.obj_from_primitive(entity, self._context)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"    def obj_to_primitive(self, target_version\u003dNone, version_manifest\u003dNone,"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_956091d0","line":145,"updated":"2016-07-13 15:37:58.000000000","message":"-1: This is missing the version_cap that should be passed, so a refresh will make it lose the version version and the second refresh will not honor the cap.","commit_id":"c64db992bee12178b1cb7b76621118dd496a1bd6"},{"author":{"_account_id":15961,"name":"lisali","email":"xiaoyan.li@intel.com","username":"lisali"},"change_message_id":"bef3a3d7782b1cb1f21adb69d8976c24c4740563","unresolved":false,"context_lines":[{"line_number":162,"context_line":"                        recursively_set_cap(getattr(ovo, field), version_cap)"},{"line_number":163,"context_line":"                    elif isinstance(field_type, fields.ListOfObjectsField):"},{"line_number":164,"context_line":"                        for element in getattr(ovo, field):"},{"line_number":165,"context_line":"                            recursively_set_cap(getattr(ovo, field),"},{"line_number":166,"context_line":"                                                version_cap)"},{"line_number":167,"context_line":""},{"line_number":168,"context_line":"        version_cap \u003d primitive.pop(\u0027_version_cap\u0027, None)"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_135c107c","line":165,"updated":"2016-07-12 09:29:29.000000000","message":"seems it should be \n\nrecursively_set_cap(element, version_cap)?","commit_id":"c64db992bee12178b1cb7b76621118dd496a1bd6"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"87bee20fbf9f8d1e44e2d24a3fceba60845b6cad","unresolved":false,"context_lines":[{"line_number":162,"context_line":"                        recursively_set_cap(getattr(ovo, field), version_cap)"},{"line_number":163,"context_line":"                    elif isinstance(field_type, fields.ListOfObjectsField):"},{"line_number":164,"context_line":"                        for element in getattr(ovo, field):"},{"line_number":165,"context_line":"                            recursively_set_cap(getattr(ovo, field),"},{"line_number":166,"context_line":"                                                version_cap)"},{"line_number":167,"context_line":""},{"line_number":168,"context_line":"        version_cap \u003d primitive.pop(\u0027_version_cap\u0027, None)"}],"source_content_type":"text/x-python","patch_set":5,"id":"1aa78d24_1465d11c","line":165,"in_reply_to":"1aa78d24_135c107c","updated":"2016-07-13 13:56:56.000000000","message":"Good catch!\n\nAnd this means that the unitests are lacking because they aren\u0027t catching this. :-(","commit_id":"c64db992bee12178b1cb7b76621118dd496a1bd6"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"7ef60fe1076fdc532ad4b10671a90800434d4400","unresolved":false,"context_lines":[{"line_number":133,"context_line":"    # version compatibility."},{"line_number":134,"context_line":"    VERSION_COMPATIBILITY \u003d {\u00277.0.0\u0027: \u00271.0\u0027}"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"    # NOTE(geguileo): This will store the version cap used to backport an OVO"},{"line_number":137,"context_line":"    # when serializing it so we can know all its relationships on the other end"},{"line_number":138,"context_line":"    # if we want to refresh it.."},{"line_number":139,"context_line":"    _version_cap \u003d None"},{"line_number":140,"context_line":""},{"line_number":141,"context_line":"    def cinder_obj_get_changes(self):"},{"line_number":142,"context_line":"        \"\"\"Returns a dict of changed fields with tz unaware datetimes."}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_960dd139","line":139,"range":{"start_line":136,"start_character":0,"end_line":139,"end_character":23},"updated":"2016-07-19 16:28:47.000000000","message":"I think we don\u0027t need this one now.","commit_id":"8dc82a3ef9bc6271b6f578b297374e4612403f29"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"25b9fc0d42f6bdc3622c891be73c91dc4a0705bc","unresolved":false,"context_lines":[{"line_number":133,"context_line":"    # version compatibility."},{"line_number":134,"context_line":"    VERSION_COMPATIBILITY \u003d {\u00277.0.0\u0027: \u00271.0\u0027}"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"    # NOTE(geguileo): This will store the version cap used to backport an OVO"},{"line_number":137,"context_line":"    # when serializing it so we can know all its relationships on the other end"},{"line_number":138,"context_line":"    # if we want to refresh it.."},{"line_number":139,"context_line":"    _version_cap \u003d None"},{"line_number":140,"context_line":""},{"line_number":141,"context_line":"    def cinder_obj_get_changes(self):"},{"line_number":142,"context_line":"        \"\"\"Returns a dict of changed fields with tz unaware datetimes."}],"source_content_type":"text/x-python","patch_set":7,"id":"dada55a8_081fdfb7","line":139,"range":{"start_line":136,"start_character":0,"end_line":139,"end_character":23},"in_reply_to":"dada55a8_960dd139","updated":"2016-07-20 08:02:37.000000000","message":"Done","commit_id":"8dc82a3ef9bc6271b6f578b297374e4612403f29"}]}
