)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"e10c0d492c9ac0e7d2ffec22f2f05af19b9338d5","unresolved":false,"context_lines":[{"line_number":18,"context_line":"While doing this it became clear that the limited Exception catching"},{"line_number":19,"context_line":"in handler.py was redundant if FaultWrapper and the Microversion"},{"line_number":20,"context_line":"middlewares (both required for the operation of the system) are"},{"line_number":21,"context_line":"invoved, so that has been removed, with a comment."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"This should not require a microversion as the structure of successful"},{"line_number":24,"context_line":"responses and expected error responses does not change. What does"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"7f96bb07_97387eee","line":21,"range":{"start_line":21,"start_character":0,"end_line":21,"end_character":7},"updated":"2018-01-16 04:52:16.000000000","message":"involved","commit_id":"fdd2b2c5da1e4bd60571169015c26433091e37d6"}],"nova/api/openstack/placement/fault_wrap.py":[{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"82c0cbb892c0d13715f7f432ee4f0aaee61e1708","unresolved":false,"context_lines":[{"line_number":27,"context_line":"class FaultWrapper(object):"},{"line_number":28,"context_line":"    \"\"\"Turn an uncaught exception into a status 500."},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    Uncaught exceptions usually shouldn\u0027t happen, if it does it"},{"line_number":31,"context_line":"    means there is a bug in the placement service, which should be"},{"line_number":32,"context_line":"    fixed."},{"line_number":33,"context_line":"    \"\"\""}],"source_content_type":"text/x-python","patch_set":5,"id":"3fa0c359_3e329760","line":30,"updated":"2018-02-09 09:11:16.000000000","message":"Are things like PolicyNotAuthorized caught before getting here?","commit_id":"c49a7388ebb34ea5b88ecc2eff397b1c5e623485"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"e2e295c556e851ed9ed38381d49f1202d39d152c","unresolved":false,"context_lines":[{"line_number":27,"context_line":"class FaultWrapper(object):"},{"line_number":28,"context_line":"    \"\"\"Turn an uncaught exception into a status 500."},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    Uncaught exceptions usually shouldn\u0027t happen, if it does it"},{"line_number":31,"context_line":"    means there is a bug in the placement service, which should be"},{"line_number":32,"context_line":"    fixed."},{"line_number":33,"context_line":"    \"\"\""}],"source_content_type":"text/x-python","patch_set":5,"id":"3fa0c359_4d5257e0","line":30,"in_reply_to":"3fa0c359_3e329760","updated":"2018-02-09 11:47:58.000000000","message":"Placement doesn\u0027t yet raise that, it has a simplified authorization set up in handler.py. However when it does it will either be caught in the wsgify wrapper or in the big dispatcher in handler.py.\n\nWe very much want this to be the catcher-of-last-resort so that expected exceptions are as explicit and visible as possible.\n\nAnything caught here is unexpected and deserve a traceback and indicates a bug somewhere within the stack that should be fixed.","commit_id":"c49a7388ebb34ea5b88ecc2eff397b1c5e623485"},{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"72c363c4102a915b0717979e7fbd52e08ab3dbf0","unresolved":false,"context_lines":[{"line_number":27,"context_line":"class FaultWrapper(object):"},{"line_number":28,"context_line":"    \"\"\"Turn an uncaught exception into a status 500."},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    Uncaught exceptions usually shouldn\u0027t happen, if it does it"},{"line_number":31,"context_line":"    means there is a bug in the placement service, which should be"},{"line_number":32,"context_line":"    fixed."},{"line_number":33,"context_line":"    \"\"\""}],"source_content_type":"text/x-python","patch_set":5,"id":"3fa0c359_3edfec0d","line":30,"in_reply_to":"3fa0c359_4d5257e0","updated":"2018-02-09 15:41:07.000000000","message":"sounds good, just making sure. Thanks.","commit_id":"c49a7388ebb34ea5b88ecc2eff397b1c5e623485"}],"nova/api/openstack/placement/handler.py":[{"author":{"_account_id":10608,"name":"Matthew Edmonds","email":"edmondsw@us.ibm.com","username":"edmondsw"},"change_message_id":"82c0cbb892c0d13715f7f432ee4f0aaee61e1708","unresolved":false,"context_lines":[{"line_number":228,"context_line":"        # transformed into legit HTTP error responses (with microversion"},{"line_number":229,"context_line":"        # headers added), and then to the FaultWrapper middleware which will"},{"line_number":230,"context_line":"        # catch anything else and transform them into 500 responses."},{"line_number":231,"context_line":"        # NOTE(cdent): There should be very few uncaught exceptions which are"},{"line_number":232,"context_line":"        # WebOb exceptions at this stage as the handlers are contained by the"},{"line_number":233,"context_line":"        # wsgify decorator which will transform those exceptions to responses"},{"line_number":234,"context_line":"        # itself."}],"source_content_type":"text/x-python","patch_set":5,"id":"3fa0c359_febaef6b","line":231,"updated":"2018-02-09 09:11:16.000000000","message":"Are not?","commit_id":"c49a7388ebb34ea5b88ecc2eff397b1c5e623485"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"e2e295c556e851ed9ed38381d49f1202d39d152c","unresolved":false,"context_lines":[{"line_number":228,"context_line":"        # transformed into legit HTTP error responses (with microversion"},{"line_number":229,"context_line":"        # headers added), and then to the FaultWrapper middleware which will"},{"line_number":230,"context_line":"        # catch anything else and transform them into 500 responses."},{"line_number":231,"context_line":"        # NOTE(cdent): There should be very few uncaught exceptions which are"},{"line_number":232,"context_line":"        # WebOb exceptions at this stage as the handlers are contained by the"},{"line_number":233,"context_line":"        # wsgify decorator which will transform those exceptions to responses"},{"line_number":234,"context_line":"        # itself."}],"source_content_type":"text/x-python","patch_set":5,"id":"3fa0c359_cd7bc778","line":231,"in_reply_to":"3fa0c359_febaef6b","updated":"2018-02-09 11:47:58.000000000","message":"yes good catch","commit_id":"c49a7388ebb34ea5b88ecc2eff397b1c5e623485"}],"nova/tests/unit/api/openstack/placement/test_fault_wrap.py":[{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"e10c0d492c9ac0e7d2ffec22f2f05af19b9338d5","unresolved":false,"context_lines":[{"line_number":45,"context_line":""},{"line_number":46,"context_line":"    def test_fault_is_wrapped(self):"},{"line_number":47,"context_line":"        response \u003d self.fail_app(self.environ, self.start_response_mock)"},{"line_number":48,"context_line":"        error_struct \u003d jsonutils.loads(\u0027\u0027.join(response))"},{"line_number":49,"context_line":"        first_error \u003d error_struct[\u0027errors\u0027][0]"},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"        self.assertIn(ERROR_MESSAGE, first_error[\u0027detail\u0027])"}],"source_content_type":"text/x-python","patch_set":1,"id":"7f96bb07_c20ba221","line":48,"range":{"start_line":48,"start_character":39,"end_line":48,"end_character":41},"updated":"2018-01-16 04:52:16.000000000","message":"seems py35 complain about this..","commit_id":"fdd2b2c5da1e4bd60571169015c26433091e37d6"}]}
