{"action":"opened","number":3810,"pull_request":{"url":"https://api.github.com/repos/StackStorm/st2/pulls/3810","id":148484026,"html_url":"https://github.com/StackStorm/st2/pull/3810","diff_url":"https://github.com/StackStorm/st2/pull/3810.diff","patch_url":"https://github.com/StackStorm/st2/pull/3810.patch","issue_url":"https://api.github.com/repos/StackStorm/st2/issues/3810","number":3810,"state":"open","locked":false,"title":"st2 CLI Formatted Result Status and Timestamps","user":{"login":"nmaludy","id":3693851,"avatar_url":"https://avatars1.githubusercontent.com/u/3693851?v=4","gravatar_id":"","url":"https://api.github.com/users/nmaludy","html_url":"https://github.com/nmaludy","followers_url":"https://api.github.com/users/nmaludy/followers","following_url":"https://api.github.com/users/nmaludy/following{/other_user}","gists_url":"https://api.github.com/users/nmaludy/gists{/gist_id}","starred_url":"https://api.github.com/users/nmaludy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nmaludy/subscriptions","organizations_url":"https://api.github.com/users/nmaludy/orgs","repos_url":"https://api.github.com/users/nmaludy/repos","events_url":"https://api.github.com/users/nmaludy/events{/privacy}","received_events_url":"https://api.github.com/users/nmaludy/received_events","type":"User","site_admin":false},"body":"# Problem\r\n\r\nPreviously when executing an action i was commonly thinking that my action, or more routinely my workflow, succeeded even though it had not. I realized this was caused by a workflow having a bunch of sub-tasks and each of those succeeding, but not realizing the main workflow had failed. It was hard to tell that the main workflow had failed and the failure definitely didn't \"stand out\". In all fairness the information was right in front of me in `status: failed`. \r\n\r\nTo make this \"pop\" and i decided to colorize the the `status:` field in the result output on the CLI. As a result this also formats the `start_timestamp` and `end_timestamp` consistently with the format in the sub-task table.\r\n\r\n### Action - Before\r\n\r\n![image](https://user-images.githubusercontent.com/3693851/31961869-13d7c4de-b8ca-11e7-9d13-9d973687da56.png)\r\n\r\n### Action - After\r\n\r\n![image](https://user-images.githubusercontent.com/3693851/31961951-41076680-b8ca-11e7-8bdb-3edc194ca814.png)\r\n\r\n## Workflow - Before\r\n\r\n![image](https://user-images.githubusercontent.com/3693851/31962364-54c07080-b8cb-11e7-85a1-6335fe355f1c.png)\r\n\r\n## Workflow - After\r\n\r\n![image](https://user-images.githubusercontent.com/3693851/31962391-69a6997a-b8cb-11e7-9f14-0ce4d56fdd91.png)\r\n\r\n## Workflow with succeeded tasks, but failed workflow - Before\r\n\r\n![image](https://user-images.githubusercontent.com/3693851/31962423-7f92d1d6-b8cb-11e7-892d-9be5ea8cf3c2.png)\r\n\r\n## Workflow with succeeded tasks, but failed workflow - After\r\n\r\n![image](https://user-images.githubusercontent.com/3693851/31962450-95ad6a4e-b8cb-11e7-89b1-194f4a1cdf51.png)\r\n","created_at":"2017-10-24T18:57:07Z","updated_at":"2017-10-24T18:57:07Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/StackStorm/st2/pulls/3810/commits","review_comments_url":"https://api.github.com/repos/StackStorm/st2/pulls/3810/comments","review_comment_url":"https://api.github.com/repos/StackStorm/st2/pulls/comments{/number}","comments_url":"https://api.github.com/repos/StackStorm/st2/issues/3810/comments","statuses_url":"https://api.github.com/repos/StackStorm/st2/statuses/1974492696c55d5360a2e0d8e1dad9c9f86b7d12","head":{"label":"nmaludy:feature/formatted-result-values","ref":"feature/formatted-result-values","sha":"1974492696c55d5360a2e0d8e1dad9c9f86b7d12","user":{"login":"nmaludy","id":3693851,"avatar_url":"https://avatars1.githubusercontent.com/u/3693851?v=4","gravatar_id":"","url":"https://api.github.com/users/nmaludy","html_url":"https://github.com/nmaludy","followers_url":"https://api.github.com/users/nmaludy/followers","following_url":"https://api.github.com/users/nmaludy/following{/other_user}","gists_url":"https://api.github.com/users/nmaludy/gists{/gist_id}","starred_url":"https://api.github.com/users/nmaludy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nmaludy/subscriptions","organizations_url":"https://api.github.com/users/nmaludy/orgs","repos_url":"https://api.github.com/users/nmaludy/repos","events_url":"https://api.github.com/users/nmaludy/events{/privacy}","received_events_url":"https://api.github.com/users/nmaludy/received_events","type":"User","site_admin":false},"repo":{"id":87355177,"name":"st2","full_name":"nmaludy/st2","owner":{"login":"nmaludy","id":3693851,"avatar_url":"https://avatars1.githubusercontent.com/u/3693851?v=4","gravatar_id":"","url":"https://api.github.com/users/nmaludy","html_url":"https://github.com/nmaludy","followers_url":"https://api.github.com/users/nmaludy/followers","following_url":"https://api.github.com/users/nmaludy/following{/other_user}","gists_url":"https://api.github.com/users/nmaludy/gists{/gist_id}","starred_url":"https://api.github.com/users/nmaludy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nmaludy/subscriptions","organizations_url":"https://api.github.com/users/nmaludy/orgs","repos_url":"https://api.github.com/users/nmaludy/repos","events_url":"https://api.github.com/users/nmaludy/events{/privacy}","received_events_url":"https://api.github.com/users/nmaludy/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nmaludy/st2","description":"StackStorm (aka \"IFTTT for Ops\") is event-driven automation commonly used for auto-remediation, security responses, facilitated troubleshooting, complex deployments, and more. Includes rules engine, workflow, 1800+ integrations (see /st2contrib), native ChatOps and so forth. Installer available at http://docs.stackstorm.com/install/index.html. Ping us on slack - https://stackstorm-community.slack.com/.","fork":true,"url":"https://api.github.com/repos/nmaludy/st2","forks_url":"https://api.github.com/repos/nmaludy/st2/forks","keys_url":"https://api.github.com/repos/nmaludy/st2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nmaludy/st2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nmaludy/st2/teams","hooks_url":"https://api.github.com/repos/nmaludy/st2/hooks","issue_events_url":"https://api.github.com/repos/nmaludy/st2/issues/events{/number}","events_url":"https://api.github.com/repos/nmaludy/st2/events","assignees_url":"https://api.github.com/repos/nmaludy/st2/assignees{/user}","branches_url":"https://api.github.com/repos/nmaludy/st2/branches{/branch}","tags_url":"https://api.github.com/repos/nmaludy/st2/tags","blobs_url":"https://api.github.com/repos/nmaludy/st2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nmaludy/st2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nmaludy/st2/git/refs{/sha}","trees_url":"https://api.github.com/repos/nmaludy/st2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nmaludy/st2/statuses/{sha}","languages_url":"https://api.github.com/repos/nmaludy/st2/languages","stargazers_url":"https://api.github.com/repos/nmaludy/st2/stargazers","contributors_url":"https://api.github.com/repos/nmaludy/st2/contributors","subscribers_url":"https://api.github.com/repos/nmaludy/st2/subscribers","subscription_url":"https://api.github.com/repos/nmaludy/st2/subscription","commits_url":"https://api.github.com/repos/nmaludy/st2/commits{/sha}","git_commits_url":"https://api.github.com/repos/nmaludy/st2/git/commits{/sha}","comments_url":"https://api.github.com/repos/nmaludy/st2/comments{/number}","issue_comment_url":"https://api.github.com/repos/nmaludy/st2/issues/comments{/number}","contents_url":"https://api.github.com/repos/nmaludy/st2/contents/{+path}","compare_url":"https://api.github.com/repos/nmaludy/st2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nmaludy/st2/merges","archive_url":"https://api.github.com/repos/nmaludy/st2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nmaludy/st2/downloads","issues_url":"https://api.github.com/repos/nmaludy/st2/issues{/number}","pulls_url":"https://api.github.com/repos/nmaludy/st2/pulls{/number}","milestones_url":"https://api.github.com/repos/nmaludy/st2/milestones{/number}","notifications_url":"https://api.github.com/repos/nmaludy/st2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nmaludy/st2/labels{/name}","releases_url":"https://api.github.com/repos/nmaludy/st2/releases{/id}","deployments_url":"https://api.github.com/repos/nmaludy/st2/deployments","created_at":"2017-04-05T20:48:36Z","updated_at":"2017-04-05T20:48:40Z","pushed_at":"2017-10-24T18:44:30Z","git_url":"git://github.com/nmaludy/st2.git","ssh_url":"git@github.com:nmaludy/st2.git","clone_url":"https://github.com/nmaludy/st2.git","svn_url":"https://github.com/nmaludy/st2","homepage":"http://www.stackstorm.com/","size":21481,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"StackStorm:master","ref":"master","sha":"8283f711a89b21a2fa389e5decf2008272ad1de5","user":{"login":"StackStorm","id":4969009,"avatar_url":"https://avatars3.githubusercontent.com/u/4969009?v=4","gravatar_id":"","url":"https://api.github.com/users/StackStorm","html_url":"https://github.com/StackStorm","followers_url":"https://api.github.com/users/StackStorm/followers","following_url":"https://api.github.com/users/StackStorm/following{/other_user}","gists_url":"https://api.github.com/users/StackStorm/gists{/gist_id}","starred_url":"https://api.github.com/users/StackStorm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/StackStorm/subscriptions","organizations_url":"https://api.github.com/users/StackStorm/orgs","repos_url":"https://api.github.com/users/StackStorm/repos","events_url":"https://api.github.com/users/StackStorm/events{/privacy}","received_events_url":"https://api.github.com/users/StackStorm/received_events","type":"Organization","site_admin":false},"repo":{"id":19051806,"name":"st2","full_name":"StackStorm/st2","owner":{"login":"StackStorm","id":4969009,"avatar_url":"https://avatars3.githubusercontent.com/u/4969009?v=4","gravatar_id":"","url":"https://api.github.com/users/StackStorm","html_url":"https://github.com/StackStorm","followers_url":"https://api.github.com/users/StackStorm/followers","following_url":"https://api.github.com/users/StackStorm/following{/other_user}","gists_url":"https://api.github.com/users/StackStorm/gists{/gist_id}","starred_url":"https://api.github.com/users/StackStorm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/StackStorm/subscriptions","organizations_url":"https://api.github.com/users/StackStorm/orgs","repos_url":"https://api.github.com/users/StackStorm/repos","events_url":"https://api.github.com/users/StackStorm/events{/privacy}","received_events_url":"https://api.github.com/users/StackStorm/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/StackStorm/st2","description":"StackStorm (aka \"IFTTT for Ops\") is event-driven automation commonly used for auto-remediation, security responses, facilitated troubleshooting, complex deployments, and more. Includes rules engine, workflow, 1800+ integrations (see https://exchange.stackstorm.org), native ChatOps and so forth. Installer available at http://docs.stackstorm.com/install/index.html. Ping us on slack - https://stackstorm-community.slack.com/.","fork":false,"url":"https://api.github.com/repos/StackStorm/st2","forks_url":"https://api.github.com/repos/StackStorm/st2/forks","keys_url":"https://api.github.com/repos/StackStorm/st2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/StackStorm/st2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/StackStorm/st2/teams","hooks_url":"https://api.github.com/repos/StackStorm/st2/hooks","issue_events_url":"https://api.github.com/repos/StackStorm/st2/issues/events{/number}","events_url":"https://api.github.com/repos/StackStorm/st2/events","assignees_url":"https://api.github.com/repos/StackStorm/st2/assignees{/user}","branches_url":"https://api.github.com/repos/StackStorm/st2/branches{/branch}","tags_url":"https://api.github.com/repos/StackStorm/st2/tags","blobs_url":"https://api.github.com/repos/StackStorm/st2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/StackStorm/st2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/StackStorm/st2/git/refs{/sha}","trees_url":"https://api.github.com/repos/StackStorm/st2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/StackStorm/st2/statuses/{sha}","languages_url":"https://api.github.com/repos/StackStorm/st2/languages","stargazers_url":"https://api.github.com/repos/StackStorm/st2/stargazers","contributors_url":"https://api.github.com/repos/StackStorm/st2/contributors","subscribers_url":"https://api.github.com/repos/StackStorm/st2/subscribers","subscription_url":"https://api.github.com/repos/StackStorm/st2/subscription","commits_url":"https://api.github.com/repos/StackStorm/st2/commits{/sha}","git_commits_url":"https://api.github.com/repos/StackStorm/st2/git/commits{/sha}","comments_url":"https://api.github.com/repos/StackStorm/st2/comments{/number}","issue_comment_url":"https://api.github.com/repos/StackStorm/st2/issues/comments{/number}","contents_url":"https://api.github.com/repos/StackStorm/st2/contents/{+path}","compare_url":"https://api.github.com/repos/StackStorm/st2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/StackStorm/st2/merges","archive_url":"https://api.github.com/repos/StackStorm/st2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/StackStorm/st2/downloads","issues_url":"https://api.github.com/repos/StackStorm/st2/issues{/number}","pulls_url":"https://api.github.com/repos/StackStorm/st2/pulls{/number}","milestones_url":"https://api.github.com/repos/StackStorm/st2/milestones{/number}","notifications_url":"https://api.github.com/repos/StackStorm/st2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/StackStorm/st2/labels{/name}","releases_url":"https://api.github.com/repos/StackStorm/st2/releases{/id}","deployments_url":"https://api.github.com/repos/StackStorm/st2/deployments","created_at":"2014-04-23T00:51:34Z","updated_at":"2017-10-24T07:25:49Z","pushed_at":"2017-10-24T18:45:17Z","git_url":"git://github.com/StackStorm/st2.git","ssh_url":"git@github.com:StackStorm/st2.git","clone_url":"https://github.com/StackStorm/st2.git","svn_url":"https://github.com/StackStorm/st2","homepage":"http://www.stackstorm.com/","size":21757,"stargazers_count":2278,"watchers_count":2278,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":302,"mirror_url":null,"archived":false,"open_issues_count":302,"forks":302,"open_issues":302,"watchers":2278,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/StackStorm/st2/pulls/3810"},"html":{"href":"https://github.com/StackStorm/st2/pull/3810"},"issue":{"href":"https://api.github.com/repos/StackStorm/st2/issues/3810"},"comments":{"href":"https://api.github.com/repos/StackStorm/st2/issues/3810/comments"},"review_comments":{"href":"https://api.github.com/repos/StackStorm/st2/pulls/3810/comments"},"review_comment":{"href":"https://api.github.com/repos/StackStorm/st2/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/StackStorm/st2/pulls/3810/commits"},"statuses":{"href":"https://api.github.com/repos/StackStorm/st2/statuses/1974492696c55d5360a2e0d8e1dad9c9f86b7d12"}},"author_association":"CONTRIBUTOR","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":2,"additions":9,"deletions":1,"changed_files":2}}
{"actor":{"display_login":"nmaludy"}}