)]}'
{"rally/cli/commands/task.py":[{"author":{"_account_id":12395,"name":"Roman Vasylets","email":"pomeo92@gmail.com","username":"rvasilets"},"change_message_id":"e4c10c2abc36f33d2f38ea1945bebcdf876806ae","unresolved":false,"context_lines":[{"line_number":526,"context_line":"        else:"},{"line_number":527,"context_line":"            print(_(\"The task %s marked as \u0027%s\u0027. Results \""},{"line_number":528,"context_line":"                    \"available when it is \u0027%s\u0027 .\") % ("},{"line_number":529,"context_line":"                task_id, consts.TaskStatus.FAILED, consts.TaskStatus.FINISHED))"},{"line_number":530,"context_line":"            return(1)"},{"line_number":531,"context_line":""},{"line_number":532,"context_line":"    @cliutils.args(\"--deployment\", dest\u003d\"deployment\", type\u003dstr,"}],"source_content_type":"text/x-python","patch_set":4,"id":"1af94dfe_ef3f89d4","side":"PARENT","line":529,"updated":"2016-03-15 12:44:24.000000000","message":"Why not to replace consts.TaskStatus.FAILED by current task status to fix that bug. And not to add possibility of the race condition","commit_id":"916a11cfe963b74e4dcadbb3255c7a74cefbbefc"},{"author":{"_account_id":12395,"name":"Roman Vasylets","email":"pomeo92@gmail.com","username":"rvasilets"},"change_message_id":"e4c10c2abc36f33d2f38ea1945bebcdf876806ae","unresolved":false,"context_lines":[{"line_number":517,"context_line":"        \"\"\""},{"line_number":518,"context_line":"        task \u003d api.Task.get(task_id)"},{"line_number":519,"context_line":"        finished_statuses \u003d (consts.TaskStatus.FINISHED,"},{"line_number":520,"context_line":"                             consts.TaskStatus.ABORTED)"},{"line_number":521,"context_line":"        if task[\"status\"] not in finished_statuses:"},{"line_number":522,"context_line":"            print(_(\"The task %s marked as %s. Results \""},{"line_number":523,"context_line":"                    \"available when it is one of %s.\") % ("}],"source_content_type":"text/x-python","patch_set":4,"id":"3afc51ec_fe9fdd4d","line":520,"updated":"2016-03-15 12:44:24.000000000","message":"Do we assume failed task as finished for now? In the future this is true because of this https://bugs.launchpad.net/rally/+bug/1468261","commit_id":"ca03ead9492c3a6af47ef2e125b5f42d61a6ef42"},{"author":{"_account_id":9545,"name":"Andriy Kurilin","email":"andr.kurilin@gmail.com","username":"akurilin"},"change_message_id":"55e79046e6f1eacd09a9abc421350a5b7e5543f0","unresolved":false,"context_lines":[{"line_number":517,"context_line":"        \"\"\""},{"line_number":518,"context_line":"        task \u003d api.Task.get(task_id)"},{"line_number":519,"context_line":"        finished_statuses \u003d (consts.TaskStatus.FINISHED,"},{"line_number":520,"context_line":"                             consts.TaskStatus.ABORTED)"},{"line_number":521,"context_line":"        if task[\"status\"] not in finished_statuses:"},{"line_number":522,"context_line":"            print(_(\"The task %s marked as %s. Results \""},{"line_number":523,"context_line":"                    \"available when it is one of %s.\") % ("}],"source_content_type":"text/x-python","patch_set":4,"id":"1af94dfe_f002c66e","line":520,"in_reply_to":"3afc51ec_fe9fdd4d","updated":"2016-03-15 13:31:06.000000000","message":"No, failed task is a task which has some problems while running it. do not confuse with finished task + \"failed sla\"","commit_id":"ca03ead9492c3a6af47ef2e125b5f42d61a6ef42"},{"author":{"_account_id":12395,"name":"Roman Vasylets","email":"pomeo92@gmail.com","username":"rvasilets"},"change_message_id":"e4c10c2abc36f33d2f38ea1945bebcdf876806ae","unresolved":false,"context_lines":[{"line_number":521,"context_line":"        if task[\"status\"] not in finished_statuses:"},{"line_number":522,"context_line":"            print(_(\"The task %s marked as %s. Results \""},{"line_number":523,"context_line":"                    \"available when it is one of %s.\") % ("},{"line_number":524,"context_line":"                task_id, task[\"status\"], \", \".join(finished_statuses)))"},{"line_number":525,"context_line":"            return(1)"},{"line_number":526,"context_line":""},{"line_number":527,"context_line":"        results \u003d [{\"key\": x[\"key\"], \"result\": x[\"data\"][\"raw\"],"}],"source_content_type":"text/x-python","patch_set":4,"id":"3afc51ec_4c060487","line":524,"updated":"2016-03-15 12:44:24.000000000","message":"Here we could get kind like race condition in case when task status will change after `if` and before `print`. \nAlso better to take task status with proper function https://github.com/openstack/rally/blob/master/rally/common/objects/task.py#L325","commit_id":"ca03ead9492c3a6af47ef2e125b5f42d61a6ef42"},{"author":{"_account_id":9545,"name":"Andriy Kurilin","email":"andr.kurilin@gmail.com","username":"akurilin"},"change_message_id":"55e79046e6f1eacd09a9abc421350a5b7e5543f0","unresolved":false,"context_lines":[{"line_number":521,"context_line":"        if task[\"status\"] not in finished_statuses:"},{"line_number":522,"context_line":"            print(_(\"The task %s marked as %s. Results \""},{"line_number":523,"context_line":"                    \"available when it is one of %s.\") % ("},{"line_number":524,"context_line":"                task_id, task[\"status\"], \", \".join(finished_statuses)))"},{"line_number":525,"context_line":"            return(1)"},{"line_number":526,"context_line":""},{"line_number":527,"context_line":"        results \u003d [{\"key\": x[\"key\"], \"result\": x[\"data\"][\"raw\"],"}],"source_content_type":"text/x-python","patch_set":4,"id":"1af94dfe_30a0ae90","line":524,"in_reply_to":"3afc51ec_4c060487","updated":"2016-03-15 13:31:06.000000000","message":"Really? Race condition?\n\nWe MUST print task[\"status\"] here and DO NOT obtain new status, because this value lead to this message. It\u0027s actually prevents phrases like \"The task \u003cuuid\u003e marked as \u0027FINISHED\u0027. Results available when it is one of \u0027FINISHED\u0027, \u0027ABORTED\u0027\"(Task is finished, but you should wait until it become finished) with \"1\" exit code.","commit_id":"ca03ead9492c3a6af47ef2e125b5f42d61a6ef42"},{"author":{"_account_id":12395,"name":"Roman Vasylets","email":"pomeo92@gmail.com","username":"rvasilets"},"change_message_id":"e4c10c2abc36f33d2f38ea1945bebcdf876806ae","unresolved":false,"context_lines":[{"line_number":532,"context_line":""},{"line_number":533,"context_line":"        if not results:"},{"line_number":534,"context_line":"            # NOTE(andreykurilin): does it possible?"},{"line_number":535,"context_line":"            print(_(\"Oops... The task %s doesn\u0027t have results.\") % task_id)"},{"line_number":536,"context_line":"            return(1)"},{"line_number":537,"context_line":""},{"line_number":538,"context_line":"        print(json.dumps(results, sort_keys\u003dTrue, indent\u003d4))"}],"source_content_type":"text/x-python","patch_set":4,"id":"1af94dfe_0420dc9a","line":535,"updated":"2016-03-15 12:44:24.000000000","message":"Now I can\u0027t find the case when its possible","commit_id":"ca03ead9492c3a6af47ef2e125b5f42d61a6ef42"},{"author":{"_account_id":9545,"name":"Andriy Kurilin","email":"andr.kurilin@gmail.com","username":"akurilin"},"change_message_id":"71e49ec3f43c9b61da4420dde903220bf0e8b5ff","unresolved":false,"context_lines":[{"line_number":532,"context_line":""},{"line_number":533,"context_line":"        if not results:"},{"line_number":534,"context_line":"            # NOTE(andreykurilin): does it possible?"},{"line_number":535,"context_line":"            print(_(\"Oops... The task %s doesn\u0027t have results.\") % task_id)"},{"line_number":536,"context_line":"            return(1)"},{"line_number":537,"context_line":""},{"line_number":538,"context_line":"        print(json.dumps(results, sort_keys\u003dTrue, indent\u003d4))"}],"source_content_type":"text/x-python","patch_set":4,"id":"5a18252c_42f3cc73","line":535,"in_reply_to":"1af94dfe_0420dc9a","updated":"2016-04-12 14:07:38.000000000","message":"removed","commit_id":"ca03ead9492c3a6af47ef2e125b5f42d61a6ef42"}]}
