)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":27909,"name":"Aija Jauntēva","email":"code@clusums.eu","username":"ajya"},"change_message_id":"7cb9030f93d5aed888c9e76886ad88a39cfd2def","unresolved":false,"context_lines":[{"line_number":19,"context_line":"provided in the \u0027Location\u0027 header of the response to a previous request,"},{"line_number":20,"context_line":"instead of failing."},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"[1] http:/http://redfish.dmtf.org/schemas/DSP0266_1.11.0.html#asynchronous-operations/redfish.dmtf.org/schemas/DSP0266_1.11.0.html#asynchronous-operations"},{"line_number":23,"context_line":"[2] Pushkala Iyer et al., \"Server Cloning with Server Configuration"},{"line_number":24,"context_line":"Profiles\", (Dell Inc., version 1.1, July 2016),"},{"line_number":25,"context_line":"https://downloads.dell.com/solutions/dell-management-solution-resources/Server"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"9f560f44_557c371f","line":22,"range":{"start_line":22,"start_character":4,"end_line":22,"end_character":153},"updated":"2020-09-22 08:14:55.000000000","message":"faulty link, should it be \n\nhttp://redfish.dmtf.org/schemas/DSP0266_1.11.0.html#asynchronous-operations ?","commit_id":"e5d0bb9a2f20cc75c9afe050a519b2cd338ddbbf"},{"author":{"_account_id":23847,"name":"Richard G. Pioso","email":"richard.pioso@gmail.com","username":"richard.pioso"},"change_message_id":"b3926d21b674c332f988ed679971c75606f2ce0a","unresolved":false,"context_lines":[{"line_number":19,"context_line":"provided in the \u0027Location\u0027 header of the response to a previous request,"},{"line_number":20,"context_line":"instead of failing."},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"[1] http:/http://redfish.dmtf.org/schemas/DSP0266_1.11.0.html#asynchronous-operations/redfish.dmtf.org/schemas/DSP0266_1.11.0.html#asynchronous-operations"},{"line_number":23,"context_line":"[2] Pushkala Iyer et al., \"Server Cloning with Server Configuration"},{"line_number":24,"context_line":"Profiles\", (Dell Inc., version 1.1, July 2016),"},{"line_number":25,"context_line":"https://downloads.dell.com/solutions/dell-management-solution-resources/Server"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"9f560f44_380feee0","line":22,"range":{"start_line":22,"start_character":4,"end_line":22,"end_character":153},"in_reply_to":"9f560f44_557c371f","updated":"2020-09-22 15:45:46.000000000","message":"Done","commit_id":"e5d0bb9a2f20cc75c9afe050a519b2cd338ddbbf"}],"sushy_oem_idrac/asynchronous.py":[{"author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"tag":"autogenerated:zuul:check","change_message_id":"99a040fe16e0f38f3db0123fefdabc5740829be8","unresolved":false,"context_lines":[{"line_number":56,"context_line":"            retry_after \u003d response.headers.get(\u0027retry-after\u0027)"},{"line_number":57,"context_line":"            if retry_after:"},{"line_number":58,"context_line":"                retry_after \u003d _to_datetime(retry_after)"},{"line_number":59,"context_line":"                sleep_for \u003d max(0, (retry_after - datetime.now()).total_seconds())"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"            LOG.debug(\u0027Sleeping for %d secs before retrying HTTP GET \u0027"},{"line_number":62,"context_line":"                      \u0027%s\u0027, sleep_for, location)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1f493fa4_9902aa0a","line":59,"updated":"2020-05-08 03:02:35.000000000","message":"pep8: E501 line too long (82 \u003e 79 characters)","commit_id":"cededcbad9602be2bf42c74492c0efdd8a029062"},{"author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"tag":"autogenerated:zuul:check","change_message_id":"dacb35273b86266b73966770d68a11de8285a5d6","unresolved":false,"context_lines":[{"line_number":56,"context_line":"            retry_after \u003d response.headers.get(\u0027retry-after\u0027)"},{"line_number":57,"context_line":"            if retry_after:"},{"line_number":58,"context_line":"                retry_after \u003d _to_datetime(retry_after)"},{"line_number":59,"context_line":"                sleep_for \u003d max(0, (retry_after -"},{"line_number":60,"context_line":"                                    datetime.now()).total_seconds())"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"            LOG.debug(\u0027Sleeping for %d secs before retrying HTTP GET \u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"1f493fa4_74452515","line":59,"updated":"2020-05-08 03:43:31.000000000","message":"pep8: W504 line break after binary operator","commit_id":"b0012a28d1b747e2698ce685bf360605348732b3"},{"author":{"_account_id":27909,"name":"Aija Jauntēva","email":"code@clusums.eu","username":"ajya"},"change_message_id":"5de501c4bfa3b8b8914bf2298677b9fe7b4674aa","unresolved":false,"context_lines":[{"line_number":70,"context_line":"                      \u0027%d\u0027, location, response.status_code)"},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"            if response.status_code \u003d\u003d 202:"},{"line_number":73,"context_line":"                new_location \u003d response.headers.get(\u0027location\u0027)"},{"line_number":74,"context_line":"                if new_location:"},{"line_number":75,"context_line":"                    location \u003d new_location"},{"line_number":76,"context_line":"                elif not emitted_get_no_location:"},{"line_number":77,"context_line":"                    LOG.debug(\u0027Response %d to HTTP GET does not include \u0027"},{"line_number":78,"context_line":"                              \u0027Location: in header. Using %s\u0027,"},{"line_number":79,"context_line":"                              response.status_code, location)"},{"line_number":80,"context_line":"                    emitted_get_no_location \u003d True"},{"line_number":81,"context_line":"            else:"},{"line_number":82,"context_line":"                break"},{"line_number":83,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"ff570b3c_050fa32e","line":80,"range":{"start_line":73,"start_character":16,"end_line":80,"end_character":50},"updated":"2020-05-11 15:07:18.000000000","message":"I\u0027m wondering if this is necessary at all. Reading some Redfish PDFs, could it be the workflow is like this: \n\n1) POST a job\n2) sync POST response - 202 returned with Location indicating where to check the status of async op\n3) loop while 202 and keep GET-ing the given location (that should be smth like \u0027/redfish/v1/TaskService/Tasks/JID_892208666137\u0027), the location is the same again and again, it\u0027s not like the location will change as it\u0027s the same task that is monitored.\n\nThis could simplify the loop.","commit_id":"a9e3f8be76899efee0c41d23d4fd6214219d41c8"}],"sushy_oem_idrac/tests/unit/test_asynchronous.py":[{"author":{"_account_id":27909,"name":"Aija Jauntēva","email":"code@clusums.eu","username":"ajya"},"change_message_id":"7cb9030f93d5aed888c9e76886ad88a39cfd2def","unresolved":false,"context_lines":[{"line_number":28,"context_line":"        super(AsychronousTestCase, self).setUp()"},{"line_number":29,"context_line":"        self.conn \u003d mock.Mock()"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def test_post_accepted(self):"},{"line_number":32,"context_line":"        mock_post_response \u003d self.conn.post.return_value"},{"line_number":33,"context_line":"        mock_post_response.status_code \u003d 202"},{"line_number":34,"context_line":"        mock_post_response.headers.get.return_value \u003d \u00271\u0027"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f560f44_b5e033ce","line":31,"range":{"start_line":31,"start_character":8,"end_line":31,"end_character":27},"updated":"2020-09-22 08:14:55.000000000","message":"here and below, better include tested method name (e.g. `test_http_call_post_accepted`)","commit_id":"e5d0bb9a2f20cc75c9afe050a519b2cd338ddbbf"},{"author":{"_account_id":23847,"name":"Richard G. Pioso","email":"richard.pioso@gmail.com","username":"richard.pioso"},"change_message_id":"b3926d21b674c332f988ed679971c75606f2ce0a","unresolved":false,"context_lines":[{"line_number":28,"context_line":"        super(AsychronousTestCase, self).setUp()"},{"line_number":29,"context_line":"        self.conn \u003d mock.Mock()"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def test_post_accepted(self):"},{"line_number":32,"context_line":"        mock_post_response \u003d self.conn.post.return_value"},{"line_number":33,"context_line":"        mock_post_response.status_code \u003d 202"},{"line_number":34,"context_line":"        mock_post_response.headers.get.return_value \u003d \u00271\u0027"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f560f44_b8893e70","line":31,"range":{"start_line":31,"start_character":8,"end_line":31,"end_character":27},"in_reply_to":"9f560f44_b5e033ce","updated":"2020-09-22 15:45:46.000000000","message":"Done","commit_id":"e5d0bb9a2f20cc75c9afe050a519b2cd338ddbbf"},{"author":{"_account_id":27909,"name":"Aija Jauntēva","email":"code@clusums.eu","username":"ajya"},"change_message_id":"7cb9030f93d5aed888c9e76886ad88a39cfd2def","unresolved":false,"context_lines":[{"line_number":29,"context_line":"        self.conn \u003d mock.Mock()"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def test_post_accepted(self):"},{"line_number":32,"context_line":"        mock_post_response \u003d self.conn.post.return_value"},{"line_number":33,"context_line":"        mock_post_response.status_code \u003d 202"},{"line_number":34,"context_line":"        mock_post_response.headers.get.return_value \u003d \u00271\u0027"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"        mock_get_202_response \u003d mock.Mock()"},{"line_number":37,"context_line":"        mock_get_202_response.status_code \u003d 202"},{"line_number":38,"context_line":"        mock_get_202_response.headers.get.return_value \u003d \u00271\u0027"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        mock_get_200_response \u003d mock.Mock()"},{"line_number":41,"context_line":"        mock_get_200_response.status_code \u003d 200"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"        self.conn.get.side_effect \u003d ["},{"line_number":44,"context_line":"            mock_get_202_response, mock_get_200_response]"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f560f44_75eb3ba3","line":41,"range":{"start_line":32,"start_character":0,"end_line":41,"end_character":47},"updated":"2020-09-22 08:14:55.000000000","message":"should this somewhere mock \u0027location\u0027 header? What\u0027s the scenario being tested here?","commit_id":"e5d0bb9a2f20cc75c9afe050a519b2cd338ddbbf"},{"author":{"_account_id":23847,"name":"Richard G. Pioso","email":"richard.pioso@gmail.com","username":"richard.pioso"},"change_message_id":"b3926d21b674c332f988ed679971c75606f2ce0a","unresolved":false,"context_lines":[{"line_number":29,"context_line":"        self.conn \u003d mock.Mock()"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def test_post_accepted(self):"},{"line_number":32,"context_line":"        mock_post_response \u003d self.conn.post.return_value"},{"line_number":33,"context_line":"        mock_post_response.status_code \u003d 202"},{"line_number":34,"context_line":"        mock_post_response.headers.get.return_value \u003d \u00271\u0027"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"        mock_get_202_response \u003d mock.Mock()"},{"line_number":37,"context_line":"        mock_get_202_response.status_code \u003d 202"},{"line_number":38,"context_line":"        mock_get_202_response.headers.get.return_value \u003d \u00271\u0027"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        mock_get_200_response \u003d mock.Mock()"},{"line_number":41,"context_line":"        mock_get_200_response.status_code \u003d 200"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"        self.conn.get.side_effect \u003d ["},{"line_number":44,"context_line":"            mock_get_202_response, mock_get_200_response]"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f560f44_98727a7b","line":41,"range":{"start_line":32,"start_character":0,"end_line":41,"end_character":47},"in_reply_to":"9f560f44_75eb3ba3","updated":"2020-09-22 15:45:46.000000000","message":"I believe the \u0027Location\u0027 header is effectively mocked on lines 34 and 38 above.\n\nThis is testing the asynchronous operation happy path: POST returns a 202 with a \u0027Location\u0027 header, the first GET of the task monitor also returns a 202 without a \u0027Location\u0027 header, and the second GET returns a 200 without a \u0027Location\u0027 header.\n\nThere may be a better way to mock the first GET response, so it returns the existing value of the \u0027location\u0027 function variable, instead of hardcoding its value.","commit_id":"e5d0bb9a2f20cc75c9afe050a519b2cd338ddbbf"},{"author":{"_account_id":27909,"name":"Aija Jauntēva","email":"code@clusums.eu","username":"ajya"},"change_message_id":"7cb9030f93d5aed888c9e76886ad88a39cfd2def","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        self.conn.get.side_effect \u003d ["},{"line_number":44,"context_line":"            mock_get_202_response, mock_get_200_response]"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"        http_call(self.conn, \u0027POST\u0027)"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def test_post_accepted_no_location(self):"},{"line_number":49,"context_line":"        mock_response \u003d self.conn.post.return_value"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f560f44_75d21bff","line":46,"updated":"2020-09-22 08:14:55.000000000","message":"there are no asserts for this test, but `http_call` returns a value, could assert that.","commit_id":"e5d0bb9a2f20cc75c9afe050a519b2cd338ddbbf"},{"author":{"_account_id":23847,"name":"Richard G. Pioso","email":"richard.pioso@gmail.com","username":"richard.pioso"},"change_message_id":"b3926d21b674c332f988ed679971c75606f2ce0a","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        self.conn.get.side_effect \u003d ["},{"line_number":44,"context_line":"            mock_get_202_response, mock_get_200_response]"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"        http_call(self.conn, \u0027POST\u0027)"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def test_post_accepted_no_location(self):"},{"line_number":49,"context_line":"        mock_response \u003d self.conn.post.return_value"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f560f44_b865beb1","line":46,"in_reply_to":"9f560f44_75d21bff","updated":"2020-09-22 15:45:46.000000000","message":"Done","commit_id":"e5d0bb9a2f20cc75c9afe050a519b2cd338ddbbf"}]}
