)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"2ed3830bb82152833efcc9b6b63bb549af7c7b44","unresolved":false,"context_lines":[{"line_number":18,"context_line":""},{"line_number":19,"context_line":"This patch makes the API exception conversion layer aware of"},{"line_number":20,"context_line":"exceptions containing other exceptions so code no longer has to"},{"line_number":21,"context_line":"catch callback failures if it has no specific error-handling logic."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Multiple exceptions that translate to the same HTTP error code will"},{"line_number":24,"context_line":"be converted into one exception of the same error code with the"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"bab6814e_fd309309","line":21,"updated":"2016-05-24 23:46:53.000000000","message":"though this is not a practice I would violently encourage :)\n\nbubbling up exceptions to the API layers should be accidental rather than intentional IMO, or an exception rather than the norm.\n\nJust my 2c, you don\u0027t have to act on this comment","commit_id":"bfc6a3949350c0c742cad024641af36cc68ab433"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"f98b8d350ffb1dc61b9c1588bbb2cfc16726b593","unresolved":false,"context_lines":[{"line_number":18,"context_line":""},{"line_number":19,"context_line":"This patch makes the API exception conversion layer aware of"},{"line_number":20,"context_line":"exceptions containing other exceptions so code no longer has to"},{"line_number":21,"context_line":"catch callback failures if it has no specific error-handling logic."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Multiple exceptions that translate to the same HTTP error code will"},{"line_number":24,"context_line":"be converted into one exception of the same error code with the"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"bab6814e_4e159de3","line":21,"in_reply_to":"bab6814e_fd309309","updated":"2016-05-25 07:43:16.000000000","message":"I think it depends on what the exception is. If it\u0027s something related to validation then I think it makes sense to let it go back to the API.","commit_id":"bfc6a3949350c0c742cad024641af36cc68ab433"}],"neutron/api/api_common.py":[{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"11faff59ccdb3fc7bfdc983fa7ac3ab385a1c496","unresolved":false,"context_lines":[{"line_number":362,"context_line":"        converted_exceptions \u003d ["},{"line_number":363,"context_line":"            convert_exception_to_http_exc(inner, faults, language)"},{"line_number":364,"context_line":"            for inner in e.inner_exceptions]"},{"line_number":365,"context_line":"        if len(converted_exceptions) \u003e 0:"},{"line_number":366,"context_line":"            codes \u003d {c.code for c in converted_exceptions}"},{"line_number":367,"context_line":"            if len(codes) \u003d\u003d 1:"},{"line_number":368,"context_line":"                # all error codes are the same so we can maintain the code"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_1967f7b7","line":365,"updated":"2016-06-08 12:07:10.000000000","message":"Why not just \u0027if converted_exceptions:\u0027 ?","commit_id":"eeb7016e91b8500e8831f93923775ae28681e030"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"4151550710c8002816b694b61fe1c28d680df824","unresolved":false,"context_lines":[{"line_number":362,"context_line":"        converted_exceptions \u003d ["},{"line_number":363,"context_line":"            convert_exception_to_http_exc(inner, faults, language)"},{"line_number":364,"context_line":"            for inner in e.inner_exceptions]"},{"line_number":365,"context_line":"        if len(converted_exceptions) \u003e 0:"},{"line_number":366,"context_line":"            codes \u003d {c.code for c in converted_exceptions}"},{"line_number":367,"context_line":"            if len(codes) \u003d\u003d 1:"},{"line_number":368,"context_line":"                # all error codes are the same so we can maintain the code"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_503ad399","line":365,"in_reply_to":"7aa08908_1967f7b7","updated":"2016-06-08 18:37:10.000000000","message":"Whoops. This used to be branching differently for 1 exception vs multiple. will fix","commit_id":"eeb7016e91b8500e8831f93923775ae28681e030"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"11faff59ccdb3fc7bfdc983fa7ac3ab385a1c496","unresolved":false,"context_lines":[{"line_number":388,"context_line":"                new_exception.msg \u003d \"\\n\".join(inner_error_strings)"},{"line_number":389,"context_line":"                return convert_exception_to_http_exc("},{"line_number":390,"context_line":"                    new_exception, faults, language)"},{"line_number":391,"context_line":"        else:"},{"line_number":392,"context_line":"            # empty multiple exception type, just pass to let it turn into"},{"line_number":393,"context_line":"            # an internal server error because it\u0027s a bug"},{"line_number":394,"context_line":"            pass"},{"line_number":395,"context_line":""},{"line_number":396,"context_line":"    e \u003d translate(e, language)"},{"line_number":397,"context_line":"    body \u003d serializer.serialize("}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_798b9b1f","line":394,"range":{"start_line":391,"start_character":0,"end_line":394,"end_character":16},"updated":"2016-06-08 12:07:10.000000000","message":"Not needed?","commit_id":"eeb7016e91b8500e8831f93923775ae28681e030"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"4151550710c8002816b694b61fe1c28d680df824","unresolved":false,"context_lines":[{"line_number":388,"context_line":"                new_exception.msg \u003d \"\\n\".join(inner_error_strings)"},{"line_number":389,"context_line":"                return convert_exception_to_http_exc("},{"line_number":390,"context_line":"                    new_exception, faults, language)"},{"line_number":391,"context_line":"        else:"},{"line_number":392,"context_line":"            # empty multiple exception type, just pass to let it turn into"},{"line_number":393,"context_line":"            # an internal server error because it\u0027s a bug"},{"line_number":394,"context_line":"            pass"},{"line_number":395,"context_line":""},{"line_number":396,"context_line":"    e \u003d translate(e, language)"},{"line_number":397,"context_line":"    body \u003d serializer.serialize("}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_9040bb08","line":394,"range":{"start_line":391,"start_character":0,"end_line":394,"end_character":16},"in_reply_to":"7aa08908_798b9b1f","updated":"2016-06-08 18:37:10.000000000","message":"nope, not needed","commit_id":"eeb7016e91b8500e8831f93923775ae28681e030"}],"neutron/common/exceptions.py":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"2ed3830bb82152833efcc9b6b63bb549af7c7b44","unresolved":false,"context_lines":[{"line_number":23,"context_line":"from neutron.common import _deprecate"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"@six.add_metaclass(abc.ABCMeta)"},{"line_number":27,"context_line":"class MultipleExceptions(Exception):"},{"line_number":28,"context_line":"    \"\"\"Container for multiple exceptions encountered."},{"line_number":29,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"bab6814e_1d70f7db","line":26,"updated":"2016-05-24 23:46:53.000000000","message":"I\u0027d avoid using a metaclass and an abstract property as it leads to writing more plumbing code than it\u0027s necessary. It shows in the dependent patches\u0027 tests. Any chance we can figure out a simpler mechanism to expose the inner_exceptions property?","commit_id":"bfc6a3949350c0c742cad024641af36cc68ab433"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"f98b8d350ffb1dc61b9c1588bbb2cfc16726b593","unresolved":false,"context_lines":[{"line_number":23,"context_line":"from neutron.common import _deprecate"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"@six.add_metaclass(abc.ABCMeta)"},{"line_number":27,"context_line":"class MultipleExceptions(Exception):"},{"line_number":28,"context_line":"    \"\"\"Container for multiple exceptions encountered."},{"line_number":29,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"bab6814e_4e711d44","line":26,"in_reply_to":"bab6814e_1d70f7db","updated":"2016-05-25 07:43:16.000000000","message":"Done","commit_id":"bfc6a3949350c0c742cad024641af36cc68ab433"}],"neutron/tests/unit/api/test_api_common.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e3a81f1f0aae868de2d6b1bb9cc269d18a09ba71","unresolved":false,"context_lines":[{"line_number":114,"context_line":"        conv \u003d common.convert_exception_to_http_exc(e, base_v2.FAULT_MAP, None)"},{"line_number":115,"context_line":"        self.assertIsInstance(conv, exc.HTTPNotFound)"},{"line_number":116,"context_line":"        self.assertEqual("},{"line_number":117,"context_line":"            \"Network nid could not be found.\\nPort pid could not be found.\","},{"line_number":118,"context_line":"            jsonutils.loads(conv.body)[\u0027NeutronError\u0027][\u0027message\u0027])"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def test_convert_exception_to_http_exc_multiple_empty_inner(self):"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_e328ed87","line":117,"updated":"2016-06-10 12:09:08.000000000","message":"/me wonders whether it will break for a locale that has translations for those messages...","commit_id":"f7a0c0b04415cb390edbd41eeeba0f90d9e4d36b"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"394e79d9ec3fde3ebe1a6d4ab75259ebc250867c","unresolved":false,"context_lines":[{"line_number":114,"context_line":"        conv \u003d common.convert_exception_to_http_exc(e, base_v2.FAULT_MAP, None)"},{"line_number":115,"context_line":"        self.assertIsInstance(conv, exc.HTTPNotFound)"},{"line_number":116,"context_line":"        self.assertEqual("},{"line_number":117,"context_line":"            \"Network nid could not be found.\\nPort pid could not be found.\","},{"line_number":118,"context_line":"            jsonutils.loads(conv.body)[\u0027NeutronError\u0027][\u0027message\u0027])"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def test_convert_exception_to_http_exc_multiple_empty_inner(self):"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_74e79240","line":117,"in_reply_to":"7aa08908_e328ed87","updated":"2016-06-10 14:08:15.000000000","message":"/me assumes people who use other locales know how to run unit tests in C locale if they encounter such a breakage.","commit_id":"f7a0c0b04415cb390edbd41eeeba0f90d9e4d36b"}]}
