)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":25277,"name":"Mariusz Karpiarz","email":"mariusz.karpiarz@codethink.co.uk","username":"mkarpiarz"},"change_message_id":"dc646eaf596c56441255823217604a1fb4610d31","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"d38405cc_e83bd2ef","updated":"2022-10-26 16:59:45.000000000","message":"Please add release notes and mention this functionality in API docs/reference. 😊","commit_id":"57dc7fa590ddfc6746fc43b78a4fcd97aed144e3"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"bcd95a4b616365abcb96433bd66e315c670323d2","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"91604dd3_cced4a67","updated":"2022-10-19 00:31:42.000000000","message":"Thanks Pedro!\n\nWhat about adding a reno note here?","commit_id":"57dc7fa590ddfc6746fc43b78a4fcd97aed144e3"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"4e110dc46d0d2b1aaf2e65983b15b441a6760275","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"a779073b_59428240","updated":"2022-10-27 20:07:23.000000000","message":"Hello Mariusz, thanks for the reply 😊.","commit_id":"0c1eabc364999f02d42978c3dbac961f96eb893a"},{"author":{"_account_id":25277,"name":"Mariusz Karpiarz","email":"mariusz.karpiarz@codethink.co.uk","username":"mkarpiarz"},"change_message_id":"bd0479f4612f1912fce1c10a353fa843b3ccfc09","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"d80d6652_438c84ec","updated":"2022-10-28 10:37:24.000000000","message":"Thank you for the patch and your changes!\nI\u0027d like to see a mention of the requirement about the reprocessing period having to be aligned to the collection period either in `doc/source/api-reference/v2/task/reprocessing.inc` or `doc/source/api-reference/v2/task/reprocessing_parameters.yml` but since the API will throw an easy to understand error message, I don\u0027t think this is all that necessary.\nEither way, the code looks good to me now but let\u0027s give Pierre time to review this change before merging it.","commit_id":"0c1eabc364999f02d42978c3dbac961f96eb893a"}],"cloudkitty/api/v2/task/reprocess.py":[{"author":{"_account_id":25277,"name":"Mariusz Karpiarz","email":"mariusz.karpiarz@codethink.co.uk","username":"mkarpiarz"},"change_message_id":"dc646eaf596c56441255823217604a1fb4610d31","unresolved":true,"context_lines":[{"line_number":108,"context_line":"            start)"},{"line_number":109,"context_line":"        end_overflow \u003d ReprocessSchedulerPostApi.get_date_period_overflow(end)"},{"line_number":110,"context_line":"        if start_overflow or end_overflow:"},{"line_number":111,"context_line":"            return [str(ReprocessSchedulerPostApi.get_valid_period_date("},{"line_number":112,"context_line":"                start)),"},{"line_number":113,"context_line":"                str(ReprocessSchedulerPostApi.get_valid_period_date(end))]"},{"line_number":114,"context_line":""},{"line_number":115,"context_line":"    @staticmethod"},{"line_number":116,"context_line":"    def validate_inputs("}],"source_content_type":"text/x-python","patch_set":2,"id":"2b38eb4f_54090c01","line":113,"range":{"start_line":111,"start_character":19,"end_line":113,"end_character":74},"updated":"2022-10-26 16:59:45.000000000","message":"An interesting idea! Personally, I\u0027d do something along the lines of `[start, start + timedelta(seconds\u003dround(range_td.seconds / period) * period]`, where `range_td \u003d abs(end - start)` but your method is definitely easier to follow.\nPlease note that for ranges shorter than the collection period, this will return an empty range (for example with start\u003d00:00:00, end\u003d00:01:00 and period\u003d300, the result would be [00:00:00, 00:00:00]) but it\u0027s probably not worth rewriting this code just to handle such an edge case.","commit_id":"57dc7fa590ddfc6746fc43b78a4fcd97aed144e3"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"4e110dc46d0d2b1aaf2e65983b15b441a6760275","unresolved":false,"context_lines":[{"line_number":108,"context_line":"            start)"},{"line_number":109,"context_line":"        end_overflow \u003d ReprocessSchedulerPostApi.get_date_period_overflow(end)"},{"line_number":110,"context_line":"        if start_overflow or end_overflow:"},{"line_number":111,"context_line":"            return [str(ReprocessSchedulerPostApi.get_valid_period_date("},{"line_number":112,"context_line":"                start)),"},{"line_number":113,"context_line":"                str(ReprocessSchedulerPostApi.get_valid_period_date(end))]"},{"line_number":114,"context_line":""},{"line_number":115,"context_line":"    @staticmethod"},{"line_number":116,"context_line":"    def validate_inputs("}],"source_content_type":"text/x-python","patch_set":2,"id":"b06c5d08_c661d000","line":113,"range":{"start_line":111,"start_character":19,"end_line":113,"end_character":74},"in_reply_to":"2b38eb4f_54090c01","updated":"2022-10-27 20:07:23.000000000","message":"it makes sense, I will validate it to avoid suggest to the user an invalid input like  [00:00:00, 00:00:00], thanks.","commit_id":"57dc7fa590ddfc6746fc43b78a4fcd97aed144e3"},{"author":{"_account_id":25277,"name":"Mariusz Karpiarz","email":"mariusz.karpiarz@codethink.co.uk","username":"mkarpiarz"},"change_message_id":"dc646eaf596c56441255823217604a1fb4610d31","unresolved":true,"context_lines":[{"line_number":133,"context_line":"        if periods_overflows:"},{"line_number":134,"context_line":"            raise http_exceptions.BadRequest("},{"line_number":135,"context_line":"                \"The provided reprocess time window does not comply with \""},{"line_number":136,"context_line":"                \"the the configured collector period. A valid time window \""},{"line_number":137,"context_line":"                \"near the provided one is %s\" % periods_overflows)"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"    @staticmethod"}],"source_content_type":"text/x-python","patch_set":2,"id":"004689b8_6f055c28","line":136,"range":{"start_line":136,"start_character":17,"end_line":136,"end_character":24},"updated":"2022-10-26 16:59:45.000000000","message":"typo","commit_id":"57dc7fa590ddfc6746fc43b78a4fcd97aed144e3"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"4e110dc46d0d2b1aaf2e65983b15b441a6760275","unresolved":false,"context_lines":[{"line_number":133,"context_line":"        if periods_overflows:"},{"line_number":134,"context_line":"            raise http_exceptions.BadRequest("},{"line_number":135,"context_line":"                \"The provided reprocess time window does not comply with \""},{"line_number":136,"context_line":"                \"the the configured collector period. A valid time window \""},{"line_number":137,"context_line":"                \"near the provided one is %s\" % periods_overflows)"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"    @staticmethod"}],"source_content_type":"text/x-python","patch_set":2,"id":"3cc8280d_4f62c287","line":136,"range":{"start_line":136,"start_character":17,"end_line":136,"end_character":24},"in_reply_to":"004689b8_6f055c28","updated":"2022-10-27 20:07:23.000000000","message":"Done","commit_id":"57dc7fa590ddfc6746fc43b78a4fcd97aed144e3"}],"cloudkitty/tests/api/v2/task/test_reprocess.py":[{"author":{"_account_id":25277,"name":"Mariusz Karpiarz","email":"mariusz.karpiarz@codethink.co.uk","username":"mkarpiarz"},"change_message_id":"dc646eaf596c56441255823217604a1fb4610d31","unresolved":true,"context_lines":[{"line_number":107,"context_line":"        self.end_reprocess_time +\u003d datetime.timedelta(seconds\u003d1)"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"        expected_message \u003d \"400 Bad Request: The provided reprocess time \" \\"},{"line_number":110,"context_line":"                           \"window does not comply with the the configured\" \\"},{"line_number":111,"context_line":"                           \" collector period. A valid time window near \" \\"},{"line_number":112,"context_line":"                           \"the provided one is [\u0027%s\u0027, \u0027%s\u0027]\" % ("},{"line_number":113,"context_line":"                               self.start_reprocess_time,"}],"source_content_type":"text/x-python","patch_set":2,"id":"934572a1_e925a4f2","line":110,"range":{"start_line":110,"start_character":56,"end_line":110,"end_character":63},"updated":"2022-10-26 16:59:45.000000000","message":"typo","commit_id":"57dc7fa590ddfc6746fc43b78a4fcd97aed144e3"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"4e110dc46d0d2b1aaf2e65983b15b441a6760275","unresolved":false,"context_lines":[{"line_number":107,"context_line":"        self.end_reprocess_time +\u003d datetime.timedelta(seconds\u003d1)"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"        expected_message \u003d \"400 Bad Request: The provided reprocess time \" \\"},{"line_number":110,"context_line":"                           \"window does not comply with the the configured\" \\"},{"line_number":111,"context_line":"                           \" collector period. A valid time window near \" \\"},{"line_number":112,"context_line":"                           \"the provided one is [\u0027%s\u0027, \u0027%s\u0027]\" % ("},{"line_number":113,"context_line":"                               self.start_reprocess_time,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ec8c595a_19429647","line":110,"range":{"start_line":110,"start_character":56,"end_line":110,"end_character":63},"in_reply_to":"934572a1_e925a4f2","updated":"2022-10-27 20:07:23.000000000","message":"Done","commit_id":"57dc7fa590ddfc6746fc43b78a4fcd97aed144e3"}]}
