)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":9171,"name":"Vipin Balachandran","email":"vipin.bl@gmail.com","username":"vbala"},"change_message_id":"241be3f8a08c47b2067738d3be08671e35f16b04","unresolved":false,"context_lines":[{"line_number":13,"context_line":"tzinfo_aware argument, so it takes DateTime default value (True)."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"In our sqlalchemy model definitions we are defining our datetime fields"},{"line_number":16,"context_line":"as Colum(DateTime) which will take sqlalchemy default: class"},{"line_number":17,"context_line":"sqlalchemy.types.DateTime(timezone\u003dFalse)"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"In most cases we are accessing those fields directly through the DB"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba3cc151_55ccf588","line":16,"updated":"2015-06-30 04:57:59.000000000","message":"Column","commit_id":"fe1a4db9a6925396ca43876a76cb7969287e8877"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"4e90a9ecd2929a844a984b7966dd3dca499353f4","unresolved":false,"context_lines":[{"line_number":13,"context_line":"tzinfo_aware argument, so it takes DateTime default value (True)."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"In our sqlalchemy model definitions we are defining our datetime fields"},{"line_number":16,"context_line":"as Colum(DateTime) which will take sqlalchemy default: class"},{"line_number":17,"context_line":"sqlalchemy.types.DateTime(timezone\u003dFalse)"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"In most cases we are accessing those fields directly through the DB"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba3cc151_048e3d78","line":16,"in_reply_to":"ba3cc151_55ccf588","updated":"2015-06-30 07:50:27.000000000","message":"Will update if I need to submit another patch.","commit_id":"fe1a4db9a6925396ca43876a76cb7969287e8877"}],"cinder/objects/base.py":[{"author":{"_account_id":8247,"name":"Thang Pham","email":"thang.g.pham@gmail.com","username":"thang.pham"},"change_message_id":"536464a912c9616455683c640cf7991289e656e1","unresolved":false,"context_lines":[{"line_number":46,"context_line":"    # from one another."},{"line_number":47,"context_line":"    OBJ_PROJECT_NAMESPACE \u003d \u0027cinder\u0027"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def obj_get_changes(self):"},{"line_number":50,"context_line":"        \"\"\"Returns a dict of changed fields with tz unaware datetimes."},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        Any timezone aware datetime field will be converted to UTC timezone"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa32b979_5e93c600","line":49,"updated":"2015-06-26 15:27:44.000000000","message":"Based on dansmith\u0027s advice - We should have a def obj_cinder_get_changes() which has your code below and object_get_changes will call it, so that it is a \"cinderism\".","commit_id":"15d19203e9a210ae443a7f6f937b87b199afc27c"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"e979aa7c46c123d08170ad74d797854d56be14be","unresolved":false,"context_lines":[{"line_number":46,"context_line":"    # from one another."},{"line_number":47,"context_line":"    OBJ_PROJECT_NAMESPACE \u003d \u0027cinder\u0027"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def obj_get_changes(self):"},{"line_number":50,"context_line":"        \"\"\"Returns a dict of changed fields with tz unaware datetimes."},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        Any timezone aware datetime field will be converted to UTC timezone"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba3cc151_db093d33","line":49,"in_reply_to":"ba3cc151_23be1400","updated":"2015-06-29 12:22:26.000000000","message":"Yes I believe that\u0027s what he meant. Rename this method and call the new method from Cinder Objects instead of oslo\u0027s method.\n\nI think it\u0027s better to overwrite oslo\u0027s method (so we don\u0027t call original method by mistake) like I\u0027m doing here, but I\u0027ll follow Dan\u0027s advice and change it.","commit_id":"15d19203e9a210ae443a7f6f937b87b199afc27c"},{"author":{"_account_id":8247,"name":"Thang Pham","email":"thang.g.pham@gmail.com","username":"thang.pham"},"change_message_id":"ef4da01dc5a5250da3a5e1f58682bbb0747c4779","unresolved":false,"context_lines":[{"line_number":46,"context_line":"    # from one another."},{"line_number":47,"context_line":"    OBJ_PROJECT_NAMESPACE \u003d \u0027cinder\u0027"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def obj_get_changes(self):"},{"line_number":50,"context_line":"        \"\"\"Returns a dict of changed fields with tz unaware datetimes."},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        Any timezone aware datetime field will be converted to UTC timezone"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba3cc151_23be1400","line":49,"in_reply_to":"fa32b979_5e93c600","updated":"2015-06-28 23:40:07.000000000","message":"Actually, I believe he meant this def here should be named cinder_obj_get_changes().  Then we have to replace the object_get_changes() in the cinder objects with cinder_obj_get_changes(), so it is a \"cinder-ism\".  This is to keep the native oslo_versionedobjects methods separate from the cinder part of oslo_versionedobjects.","commit_id":"15d19203e9a210ae443a7f6f937b87b199afc27c"},{"author":{"_account_id":9171,"name":"Vipin Balachandran","email":"vipin.bl@gmail.com","username":"vbala"},"change_message_id":"241be3f8a08c47b2067738d3be08671e35f16b04","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        # Get dirtied/changed fields"},{"line_number":59,"context_line":"        changes \u003d self.obj_get_changes()"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"        # Look for datetime objects that contain timzeone information"},{"line_number":62,"context_line":"        for k, v in changes.items():"},{"line_number":63,"context_line":"            if isinstance(v, datetime.datetime) and v.tzinfo:"},{"line_number":64,"context_line":"                # Remove timezone information and adjust the time according to"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba3cc151_959efd54","line":61,"updated":"2015-06-30 04:57:59.000000000","message":"timezone","commit_id":"fe1a4db9a6925396ca43876a76cb7969287e8877"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"4e90a9ecd2929a844a984b7966dd3dca499353f4","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        # Get dirtied/changed fields"},{"line_number":59,"context_line":"        changes \u003d self.obj_get_changes()"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"        # Look for datetime objects that contain timzeone information"},{"line_number":62,"context_line":"        for k, v in changes.items():"},{"line_number":63,"context_line":"            if isinstance(v, datetime.datetime) and v.tzinfo:"},{"line_number":64,"context_line":"                # Remove timezone information and adjust the time according to"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba3cc151_24dee16d","line":61,"in_reply_to":"ba3cc151_959efd54","updated":"2015-06-30 07:50:27.000000000","message":"Will update if I need to submit another patch.","commit_id":"fe1a4db9a6925396ca43876a76cb7969287e8877"},{"author":{"_account_id":2759,"name":"Huang Zhiteng","email":"winston.d@gmail.com","username":"zhiteng-huang"},"change_message_id":"69d87b011207fc740633543ee41aec3ff0d6b1e0","unresolved":false,"context_lines":[{"line_number":47,"context_line":"    OBJ_PROJECT_NAMESPACE \u003d \u0027cinder\u0027"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def cinder_obj_get_changes(self):"},{"line_number":50,"context_line":"        \"\"\"Returns a dict of changed fields with tz unaware datetimes."},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        Any timezone aware datetime field will be converted to UTC timezone"},{"line_number":53,"context_line":"        and returned as timezone unaware datetime."}],"source_content_type":"text/x-python","patch_set":10,"id":"ba3cc151_dd3c15ca","line":50,"updated":"2015-07-09 08:34:52.000000000","message":"tz unaware or UTC timezone?","commit_id":"4bfb819ab26ea5a2ec1a45e37f96fcf171b94362"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"87c4dc616d80dcaee769a7af8c2d809039eca81d","unresolved":false,"context_lines":[{"line_number":47,"context_line":"    OBJ_PROJECT_NAMESPACE \u003d \u0027cinder\u0027"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def cinder_obj_get_changes(self):"},{"line_number":50,"context_line":"        \"\"\"Returns a dict of changed fields with tz unaware datetimes."},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        Any timezone aware datetime field will be converted to UTC timezone"},{"line_number":53,"context_line":"        and returned as timezone unaware datetime."}],"source_content_type":"text/x-python","patch_set":10,"id":"ba3cc151_210ab726","line":50,"in_reply_to":"ba3cc151_dd3c15ca","updated":"2015-07-09 10:44:38.000000000","message":"The docstring is correct, if you read the code you\u0027ll see we are changing datetime fields to tz unaware.\n\nAs all tz unaware datetimes in OpenStack, these are implicitly UTC.","commit_id":"4bfb819ab26ea5a2ec1a45e37f96fcf171b94362"}],"cinder/tests/unit/objects/test_base.py":[{"author":{"_account_id":8247,"name":"Thang Pham","email":"thang.g.pham@gmail.com","username":"thang.pham"},"change_message_id":"536464a912c9616455683c640cf7991289e656e1","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from cinder import context"},{"line_number":19,"context_line":"from cinder.objects import base"},{"line_number":20,"context_line":"from cinder.tests.unit import objects as test_objects"},{"line_number":21,"context_line":"from iso8601 import iso8601"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"@base.CinderObjectRegistry.register"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa32b979_3e7042dc","line":21,"updated":"2015-06-26 15:27:44.000000000","message":"Should this import go above?","commit_id":"15d19203e9a210ae443a7f6f937b87b199afc27c"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"e979aa7c46c123d08170ad74d797854d56be14be","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from cinder import context"},{"line_number":19,"context_line":"from cinder.objects import base"},{"line_number":20,"context_line":"from cinder.tests.unit import objects as test_objects"},{"line_number":21,"context_line":"from iso8601 import iso8601"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"@base.CinderObjectRegistry.register"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba3cc151_5bd52d41","line":21,"in_reply_to":"fa32b979_3e7042dc","updated":"2015-06-29 12:22:26.000000000","message":"Yes it should, thanks.","commit_id":"15d19203e9a210ae443a7f6f937b87b199afc27c"},{"author":{"_account_id":9171,"name":"Vipin Balachandran","email":"vipin.bl@gmail.com","username":"vbala"},"change_message_id":"241be3f8a08c47b2067738d3be08671e35f16b04","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"class TestCinderObject(test_objects.BaseObjectsTestCase):"},{"line_number":35,"context_line":"    \"\"\"Tests cinder_obj_get_changes from CinderObject.\"\"\""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    def setUp(self):"},{"line_number":38,"context_line":"        super(TestCinderObject, self).setUp()"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba3cc151_759fb903","line":35,"updated":"2015-06-30 04:57:59.000000000","message":"We may add more methods in CinderObject, it is better to write \"Tests methods from CinderObject\".","commit_id":"fe1a4db9a6925396ca43876a76cb7969287e8877"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"4e90a9ecd2929a844a984b7966dd3dca499353f4","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"class TestCinderObject(test_objects.BaseObjectsTestCase):"},{"line_number":35,"context_line":"    \"\"\"Tests cinder_obj_get_changes from CinderObject.\"\"\""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    def setUp(self):"},{"line_number":38,"context_line":"        super(TestCinderObject, self).setUp()"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba3cc151_e40319b7","line":35,"in_reply_to":"ba3cc151_759fb903","updated":"2015-06-30 07:50:27.000000000","message":"I opted to be more specific in the comments.  And if we add more methods, then comment should be updated to reflect it.  I don\u0027t have a strong feeling about this, so I\u0027ll update if I have to submit another patch.","commit_id":"fe1a4db9a6925396ca43876a76cb7969287e8877"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"86b1b76a15ad888aed9faffa427818591422ed0e","unresolved":false,"context_lines":[{"line_number":39,"context_line":"        # NOTE (e0ne): base tests contains original RequestContext from"},{"line_number":40,"context_line":"        # oslo_context. We change it to our RequestContext implementation"},{"line_number":41,"context_line":"        # to have \u0027elevated\u0027 method"},{"line_number":42,"context_line":"        self.context \u003d context.RequestContext(self.user_id, self.project_id,"},{"line_number":43,"context_line":"                                              is_admin\u003dFalse)"},{"line_number":44,"context_line":"        self.obj \u003d TestObject("},{"line_number":45,"context_line":"            scheduled_at\u003dNone,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba3cc151_8d54a921","line":42,"updated":"2015-06-30 12:22:46.000000000","message":"This is not needed here (same applies to the comment above of course).","commit_id":"fe1a4db9a6925396ca43876a76cb7969287e8877"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"051750c45a6215c46cb0dc11aab5fe41951f7c90","unresolved":false,"context_lines":[{"line_number":39,"context_line":"        # NOTE (e0ne): base tests contains original RequestContext from"},{"line_number":40,"context_line":"        # oslo_context. We change it to our RequestContext implementation"},{"line_number":41,"context_line":"        # to have \u0027elevated\u0027 method"},{"line_number":42,"context_line":"        self.context \u003d context.RequestContext(self.user_id, self.project_id,"},{"line_number":43,"context_line":"                                              is_admin\u003dFalse)"},{"line_number":44,"context_line":"        self.obj \u003d TestObject("},{"line_number":45,"context_line":"            scheduled_at\u003dNone,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba3cc151_bf21904f","line":42,"in_reply_to":"ba3cc151_8d54a921","updated":"2015-06-30 12:33:33.000000000","message":"Oh, right, I was thinking on the delete test in the backup patch when doing this...  Thanks!  :-)","commit_id":"fe1a4db9a6925396ca43876a76cb7969287e8877"}]}
