)]}'
{"neutron/plugins/cisco/db/n1kv_db_v2.py":[{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"05598da3fcc4c09b4fe5c69f4b35b66a7cb57f79","unresolved":false,"context_lines":[{"line_number":1420,"context_line":"                if net_p[\"name\"] \u003d\u003d name:"},{"line_number":1421,"context_line":"                    msg \u003d (_(\"NetworkProfile name %s already exists\") %"},{"line_number":1422,"context_line":"                           net_p[\"name\"])"},{"line_number":1423,"context_line":"                    LOG.error(msg)"},{"line_number":1424,"context_line":"                    raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":1425,"context_line":"                if (c_const.NETWORK_TYPE_MULTI_SEGMENT in"},{"line_number":1426,"context_line":"                    [profile.segment_type, net_p[\"segment_type\"]] or"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_07145a42","line":1423,"updated":"2014-12-22 06:29:00.000000000","message":"how about: LOG.error(_(\"NetworkProfile name %s already exists\") , net_p[\"name\"])?","commit_id":"96f40c2c80eee96dc9475d17a7248eeb78ccc383"},{"author":{"_account_id":11279,"name":"Angus Lees","email":"gus@inodes.org","username":"gus"},"change_message_id":"2d9b62e7e11bbef4caa9a95c913642db9e74448c","unresolved":false,"context_lines":[{"line_number":1420,"context_line":"                if net_p[\"name\"] \u003d\u003d name:"},{"line_number":1421,"context_line":"                    msg \u003d (_(\"NetworkProfile name %s already exists\") %"},{"line_number":1422,"context_line":"                           net_p[\"name\"])"},{"line_number":1423,"context_line":"                    LOG.error(msg)"},{"line_number":1424,"context_line":"                    raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":1425,"context_line":"                if (c_const.NETWORK_TYPE_MULTI_SEGMENT in"},{"line_number":1426,"context_line":"                    [profile.segment_type, net_p[\"segment_type\"]] or"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_2a1e6870","line":1423,"in_reply_to":"3a961159_07145a42","updated":"2014-12-22 23:44:31.000000000","message":"No, I believe both of these are incorrect in this case.\n\nThe message is used in both LOG.error() and the exception error_message.  The exception requires it gets unconditionally expanded into a regular string, and so that should be reused rather than expanded again inside LOG.error().\n\nSimilarly, because the exception is always raised and may be logged elsewhere with an unclear severity, the translation string should be marked with _ and not _LE.\n\n\nSee http://docs.openstack.org/developer/oslo.i18n/guidelines.html\n\"\"\"\nA common pattern is to define a single message object and use it more than once, for the log call and the exception. In that case, _() must be used because the message is going to appear in an exception that may be presented to the user.\n\"\"\"","commit_id":"96f40c2c80eee96dc9475d17a7248eeb78ccc383"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"77434635b013fcc2ced9b0673ffde38c4cb30f8a","unresolved":false,"context_lines":[{"line_number":1420,"context_line":"                if net_p[\"name\"] \u003d\u003d name:"},{"line_number":1421,"context_line":"                    msg \u003d (_(\"NetworkProfile name %s already exists\") %"},{"line_number":1422,"context_line":"                           net_p[\"name\"])"},{"line_number":1423,"context_line":"                    LOG.error(msg)"},{"line_number":1424,"context_line":"                    raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":1425,"context_line":"                if (c_const.NETWORK_TYPE_MULTI_SEGMENT in"},{"line_number":1426,"context_line":"                    [profile.segment_type, net_p[\"segment_type\"]] or"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_0852a666","line":1423,"in_reply_to":"3a961159_07145a42","updated":"2014-12-22 12:03:25.000000000","message":"Then _LE should be used","commit_id":"96f40c2c80eee96dc9475d17a7248eeb78ccc383"}]}
