)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"78ade1a3e490cbad03c27ad73421624c2736d144","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     LiuNanke \u003cnanke.liu@easystack.cn\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-12-30 00:22:40 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Use new log style when LOG.error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Use new log style where Logger.exception() is used"},{"line_number":10,"context_line":"by passing an exception object as the first argument[1]."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"fa69d971_7010684f","line":7,"updated":"2015-12-29 16:40:27.000000000","message":"This commit message doesn\u0027t match at all what is being done in the patch.\n\nThis patch actually corrects unicode handling when formatting strings for exception messages.","commit_id":"429c8db5a7999a84eb7fa5f1a3653ca05c8f419a"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"94254b9a3d63f37ac9b33499a1230711314a7b00","unresolved":false,"context_lines":[{"line_number":10,"context_line":""},{"line_number":11,"context_line":"1.corrects unicode handling when formatting strings"},{"line_number":12,"context_line":"  for exception messages."},{"line_number":13,"context_line":"2.Use new log style where Logger.exception() is used"},{"line_number":14,"context_line":"  by passing an exception object as the first argument[1]."},{"line_number":15,"context_line":"  [1]http://docs.openstack.org/developer/oslo.log/usage.html"},{"line_number":16,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"fa69d971_304bd0b2","line":13,"updated":"2015-12-29 16:58:52.000000000","message":"Again, this isn\u0027t consistent at all with the patch. No logging statements are changed here.\n\nAnd the statement is incorrect - an exception does not get passed to LOG.exception, only LOG.error. The \"new style, preferred approach\" is to use LOG.exception with just the message to print as that will automatically write out any exception in scope. The exception message can be passed to LOG.error to accomplish the same thing.","commit_id":"c3b39e6b8249f633fd12fd64796b08f6705ed468"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"383def1dbf0091ffe4d672d5ed1ce4b363cfb580","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     LiuNanke \u003cnanke.liu@easystack.cn\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-12-29 17:43:51 +0000"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Use new log style when LOG.error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Use new log style where Logger.exception() is used"},{"line_number":10,"context_line":"by passing an exception object as the first argument[1]."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"fa69d971_14d55942","line":7,"range":{"start_line":7,"start_character":17,"end_line":7,"end_character":18},"updated":"2015-12-29 22:27:05.000000000","message":"Not sure how else to put this to explain what I\u0027m trying to say, but this commit message still is completely different than what the code change is trying to do.","commit_id":"a2c186a214e3a3df76d5148a8c5cb01c2a7e3b5e"}],"cinder/volume/drivers/emc/emc_vmax_https.py":[{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"468a99bee834057d73af7bbbc07e71449d591834","unresolved":false,"context_lines":[{"line_number":196,"context_line":"            except Exception as e:"},{"line_number":197,"context_line":"                msg \u003d (_(\"Unable to load cert from %(cert)s %(e)s.\")"},{"line_number":198,"context_line":"                       % {\u0027cert\u0027: self.cert_file,"},{"line_number":199,"context_line":"                          \u0027e\u0027: six.text_type(e)})"},{"line_number":200,"context_line":"                raise pywbem.cim_http.AuthError(msg)"},{"line_number":201,"context_line":"            if self.key_file is None:"},{"line_number":202,"context_line":"                # We support having key and cert in same file."}],"source_content_type":"text/x-python","patch_set":3,"id":"fa69d971_f10457c7","line":199,"updated":"2015-12-29 20:57:49.000000000","message":"I don\u0027t know why six.text_type is needed here.  It was formatted to unicode string by using _ in the original code.  The oslo.log doc stated \"the error should be converted to unicode either by calling six.text_type() or by using a unicode formatting string to provide context.\"  So I don\u0027t see why it is needed here as it was already converted to unicode by using _ in the original code.","commit_id":"a2c186a214e3a3df76d5148a8c5cb01c2a7e3b5e"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"62d305531805838d405e29cc82033b52852eca4a","unresolved":false,"context_lines":[{"line_number":196,"context_line":"            except Exception as e:"},{"line_number":197,"context_line":"                msg \u003d (_(\"Unable to load cert from %(cert)s %(e)s.\")"},{"line_number":198,"context_line":"                       % {\u0027cert\u0027: self.cert_file,"},{"line_number":199,"context_line":"                          \u0027e\u0027: six.text_type(e)})"},{"line_number":200,"context_line":"                raise pywbem.cim_http.AuthError(msg)"},{"line_number":201,"context_line":"            if self.key_file is None:"},{"line_number":202,"context_line":"                # We support having key and cert in same file."}],"source_content_type":"text/x-python","patch_set":3,"id":"fa69d971_f4176552","line":199,"in_reply_to":"fa69d971_146319b3","updated":"2015-12-29 22:37:18.000000000","message":"Good catch Xing. Looking in to this a bit more, oslo.i18n  ends up using ugettext when using python2.x:\n\nhttps://github.com/openstack/oslo.i18n/blob/89bbb9838f92557fb5e0f8dcaf42d1413e69ae0f/oslo_i18n/_factory.py#L78\n\nAnd I\u0027ve verified that when passed a standard string, if a translation is not found and it uses the fallback, the fallback does end up being a unicode string as well. \n\nhttp://paste.openstack.org/show/482832/\n\nSo I think you are right. This change is not needed.","commit_id":"a2c186a214e3a3df76d5148a8c5cb01c2a7e3b5e"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"383def1dbf0091ffe4d672d5ed1ce4b363cfb580","unresolved":false,"context_lines":[{"line_number":196,"context_line":"            except Exception as e:"},{"line_number":197,"context_line":"                msg \u003d (_(\"Unable to load cert from %(cert)s %(e)s.\")"},{"line_number":198,"context_line":"                       % {\u0027cert\u0027: self.cert_file,"},{"line_number":199,"context_line":"                          \u0027e\u0027: six.text_type(e)})"},{"line_number":200,"context_line":"                raise pywbem.cim_http.AuthError(msg)"},{"line_number":201,"context_line":"            if self.key_file is None:"},{"line_number":202,"context_line":"                # We support having key and cert in same file."}],"source_content_type":"text/x-python","patch_set":3,"id":"fa69d971_146319b3","line":199,"in_reply_to":"fa69d971_f10457c7","updated":"2015-12-29 22:27:05.000000000","message":"I\u0027m not entirely sure putting the string in _() means that it will be a unicode formatting string. If there\u0027s not a translation for the string in the catalog, my understanding was that it will just return the original string. In the case of python 2.7 this is just a base string that is not unicode.\n\nGuess I should look at the oslo.log code again. Which I probably should have done before writing this comment. ;)","commit_id":"a2c186a214e3a3df76d5148a8c5cb01c2a7e3b5e"}]}
