)]}'
{"tempest/lib/services/network/base.py":[{"author":{"_account_id":7715,"name":"Hirofumi Ichihara","email":"ichihara.hirofumi@gmail.com","username":"Hirofumi-Ichihara"},"change_message_id":"5a415414c29bc57515e7998c727f813d886955c0","unresolved":false,"context_lines":[{"line_number":61,"context_line":"        # NOTE: RFC allows both a valid non-empty body and an empty body for"},{"line_number":62,"context_line":"        # response of POST API. If a body is expected not empty, we decode the"},{"line_number":63,"context_line":"        # body. Otherwise we returns the body as it is."},{"line_number":64,"context_line":"        if not expect_empty_body:"},{"line_number":65,"context_line":"            body \u003d json.loads(body)"},{"line_number":66,"context_line":"        else:"},{"line_number":67,"context_line":"            # TODO(hichihara): Remove the cleanup once bug/1555921 is closed"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_b9f8da4a","line":64,"updated":"2016-08-22 02:31:04.000000000","message":"Now: When create_router_on_l3_agent runs, neutron server returns \u0027null\u0027 and then json.loads(\u0027null\u0027) will be None, that is passed without error.\nFuture: When create_router_on_l3_agent runs, we would make None returned. In the case, body is empty string(\"\") from self.post() on L60. The body happens error in rest_client.ResponseBody(). So I would make body to be empty dict here.","commit_id":"fe0267c5cc9a953c0a59a1188087482883036cc7"},{"author":{"_account_id":6167,"name":"Ken\u0027ichi Ohmichi","email":"ken1ohmichi@gmail.com","username":"oomichi"},"change_message_id":"f24724d66d975085e305b4e50beaa94888a4210c","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        if not expect_empty_body:"},{"line_number":65,"context_line":"            body \u003d json.loads(body)"},{"line_number":66,"context_line":"        else:"},{"line_number":67,"context_line":"            # TODO(hichihara): Remove the cleanup once bug/1555921 is closed"},{"line_number":68,"context_line":"            body \u003d {}"},{"line_number":69,"context_line":"        self.expected_success(201, resp.status)"},{"line_number":70,"context_line":"        return rest_client.ResponseBody(resp, body)"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_fceee9ea","line":67,"range":{"start_line":67,"start_character":12,"end_line":67,"end_character":76},"updated":"2016-08-19 20:25:46.000000000","message":"I am not sure which part this \"cleanup\" specify..\nI am afraid that this is library interface as tempest.lib and this should be stable.\nSo we cannot change the interface because of backwards compatibility, but this TODO seems removing something under tempest.lib.","commit_id":"fe0267c5cc9a953c0a59a1188087482883036cc7"},{"author":{"_account_id":7715,"name":"Hirofumi Ichihara","email":"ichihara.hirofumi@gmail.com","username":"Hirofumi-Ichihara"},"change_message_id":"5a415414c29bc57515e7998c727f813d886955c0","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        if not expect_empty_body:"},{"line_number":65,"context_line":"            body \u003d json.loads(body)"},{"line_number":66,"context_line":"        else:"},{"line_number":67,"context_line":"            # TODO(hichihara): Remove the cleanup once bug/1555921 is closed"},{"line_number":68,"context_line":"            body \u003d {}"},{"line_number":69,"context_line":"        self.expected_success(201, resp.status)"},{"line_number":70,"context_line":"        return rest_client.ResponseBody(resp, body)"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_beba8008","line":67,"range":{"start_line":67,"start_character":12,"end_line":67,"end_character":76},"in_reply_to":"1ac06dbe_fceee9ea","updated":"2016-08-22 02:31:04.000000000","message":"Actually this change is not needed after the bug has been closed. However, I understand your point. I\u0027m OK. I\u0027ll remove it.","commit_id":"fe0267c5cc9a953c0a59a1188087482883036cc7"},{"author":{"_account_id":6167,"name":"Ken\u0027ichi Ohmichi","email":"ken1ohmichi@gmail.com","username":"oomichi"},"change_message_id":"1af81a6413a35e132f00d801ada7fc3d356909ed","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        if not expect_empty_body:"},{"line_number":65,"context_line":"            body \u003d json.loads(body)"},{"line_number":66,"context_line":"        else:"},{"line_number":67,"context_line":"            body \u003d {}"},{"line_number":68,"context_line":"        self.expected_success(201, resp.status)"},{"line_number":69,"context_line":"        return rest_client.ResponseBody(resp, body)"},{"line_number":70,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_e14d3d3f","line":67,"range":{"start_line":67,"start_character":19,"end_line":67,"end_character":21},"updated":"2016-08-22 23:11:24.000000000","message":"I tend to prefer None instead of {} because the API doesn\u0027t return {} actually.\nAnd the following code covers such case:\n\n 917 class ResponseBody(dict):\n 918     \"\"\"Class that wraps an http response and dict body into a single value.\n 919\n 920     Callers that receive this object will normally use it as a dict but\n 921     can extract the response if needed.\n 922     \"\"\"\n 923\n 924     def __init__(self, response, body\u003dNone):\n 925         body_data \u003d body or {}\n 926         self.update(body_data)\n 927         self.response \u003d response\n\nThe result is the same, but this caller side handling seems a little magic..","commit_id":"a9c4cdac636dc35d32f59497428258ad3af926ec"},{"author":{"_account_id":7715,"name":"Hirofumi Ichihara","email":"ichihara.hirofumi@gmail.com","username":"Hirofumi-Ichihara"},"change_message_id":"834ee7b3656950572418d46885e8c0fb56539e6c","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        if not expect_empty_body:"},{"line_number":65,"context_line":"            body \u003d json.loads(body)"},{"line_number":66,"context_line":"        else:"},{"line_number":67,"context_line":"            body \u003d {}"},{"line_number":68,"context_line":"        self.expected_success(201, resp.status)"},{"line_number":69,"context_line":"        return rest_client.ResponseBody(resp, body)"},{"line_number":70,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_85a3b4b1","line":67,"range":{"start_line":67,"start_character":19,"end_line":67,"end_character":21},"in_reply_to":"1ac06dbe_e14d3d3f","updated":"2016-08-22 23:37:25.000000000","message":"I thought that current code is consistent with json decode on L65 but I\u0027m OK. I\u0027ll change.","commit_id":"a9c4cdac636dc35d32f59497428258ad3af926ec"},{"author":{"_account_id":5689,"name":"Masayuki Igawa","email":"masayuki@igawa.io","username":"igawa"},"change_message_id":"7fa47ffd80259244372b156b708f9491e5a73efb","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        if not expect_empty_body:"},{"line_number":65,"context_line":"            body \u003d json.loads(body)"},{"line_number":66,"context_line":"        else:"},{"line_number":67,"context_line":"            body \u003d None"},{"line_number":68,"context_line":"        self.expected_success(201, resp.status)"},{"line_number":69,"context_line":"        return rest_client.ResponseBody(resp, body)"},{"line_number":70,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"fa7ab95a_ae739c14","line":67,"range":{"start_line":67,"start_character":12,"end_line":67,"end_character":23},"updated":"2016-08-31 07:37:19.000000000","message":"Why do we need to set None to the body explicitly?\nI was thinking that body is expected None(or empty) when we set the expect_empty_body True.","commit_id":"e4e8897732457e32aa00c024edf24b75f349a588"},{"author":{"_account_id":7715,"name":"Hirofumi Ichihara","email":"ichihara.hirofumi@gmail.com","username":"Hirofumi-Ichihara"},"change_message_id":"b01fb0fcca83ae02a41d368c8052742d1d316ced","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        if not expect_empty_body:"},{"line_number":65,"context_line":"            body \u003d json.loads(body)"},{"line_number":66,"context_line":"        else:"},{"line_number":67,"context_line":"            body \u003d None"},{"line_number":68,"context_line":"        self.expected_success(201, resp.status)"},{"line_number":69,"context_line":"        return rest_client.ResponseBody(resp, body)"},{"line_number":70,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"fa7ab95a_73aedce8","line":67,"range":{"start_line":67,"start_character":12,"end_line":67,"end_character":23},"in_reply_to":"fa7ab95a_ae739c14","updated":"2016-08-31 08:06:32.000000000","message":"Because now \"null\" is passed as body. Empty string will be passed once the bug is fixed[1] and then the setting will be not needed.\n\n[1]: https://review.openstack.org/#/c/291545/","commit_id":"e4e8897732457e32aa00c024edf24b75f349a588"},{"author":{"_account_id":5689,"name":"Masayuki Igawa","email":"masayuki@igawa.io","username":"igawa"},"change_message_id":"7fa47ffd80259244372b156b708f9491e5a73efb","unresolved":false,"context_lines":[{"line_number":78,"context_line":"        if not expect_empty_body:"},{"line_number":79,"context_line":"            body \u003d json.loads(body)"},{"line_number":80,"context_line":"        else:"},{"line_number":81,"context_line":"            body \u003d None"},{"line_number":82,"context_line":"        self.expected_success(200, resp.status)"},{"line_number":83,"context_line":"        return rest_client.ResponseBody(resp, body)"}],"source_content_type":"text/x-python","patch_set":5,"id":"fa7ab95a_ee63e43f","line":81,"range":{"start_line":81,"start_character":12,"end_line":81,"end_character":23},"updated":"2016-08-31 07:37:19.000000000","message":"ditto","commit_id":"e4e8897732457e32aa00c024edf24b75f349a588"}]}
