{"action":"created","comment":{"url":"https://api.github.com/repos/google/openhtf/pulls/comments/56113257","id":56113257,"diff_hunk":"@@ -93,16 +95,23 @@ class MultipleValidatorsException(Exception):\n   \"\"\"Multiple validators were used when defining a measurement.\"\"\"\n \n \n+class Outcome(Enum):\n+  \"\"\"Enum values for measurement 'outcome' fields.\"\"\"\n+  PASS = 'PASS'","path":"openhtf/util/measurements.py","position":19,"original_position":19,"commit_id":"0b8b3308c9caf5501a0b60bd1a135b56fff693fd","original_commit_id":"0b8b3308c9caf5501a0b60bd1a135b56fff693fd","user":{"login":"fahhem","id":306100,"avatar_url":"https://avatars.githubusercontent.com/u/306100?v=3","gravatar_id":"","url":"https://api.github.com/users/fahhem","html_url":"https://github.com/fahhem","followers_url":"https://api.github.com/users/fahhem/followers","following_url":"https://api.github.com/users/fahhem/following{/other_user}","gists_url":"https://api.github.com/users/fahhem/gists{/gist_id}","starred_url":"https://api.github.com/users/fahhem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fahhem/subscriptions","organizations_url":"https://api.github.com/users/fahhem/orgs","repos_url":"https://api.github.com/users/fahhem/repos","events_url":"https://api.github.com/users/fahhem/events{/privacy}","received_events_url":"https://api.github.com/users/fahhem/received_events","type":"User","site_admin":false},"body":"Why do you set the value to its string version? `value.name` returns the string version when you need it.\r\n\r\n```py\r\nOutcome = enum.Enum('Outcome', ['PASS', 'FAIL', 'UNSET'])\r\n","created_at":"2016-03-15T04:13:10Z","updated_at":"2016-03-15T04:13:10Z","html_url":"https://github.com/google/openhtf/pull/168#discussion_r56113257","pull_request_url":"https://api.github.com/repos/google/openhtf/pulls/168","_links":{"self":{"href":"https://api.github.com/repos/google/openhtf/pulls/comments/56113257"},"html":{"href":"https://github.com/google/openhtf/pull/168#discussion_r56113257"},"pull_request":{"href":"https://api.github.com/repos/google/openhtf/pulls/168"}}},"pull_request":{"url":"https://api.github.com/repos/google/openhtf/pulls/168","id":62642387,"html_url":"https://github.com/google/openhtf/pull/168","diff_url":"https://github.com/google/openhtf/pull/168.diff","patch_url":"https://github.com/google/openhtf/pull/168.patch","issue_url":"https://api.github.com/repos/google/openhtf/issues/168","number":168,"state":"open","locked":false,"title":"Test state updates","user":{"login":"grybmadsci","id":14081283,"avatar_url":"https://avatars.githubusercontent.com/u/14081283?v=3","gravatar_id":"","url":"https://api.github.com/users/grybmadsci","html_url":"https://github.com/grybmadsci","followers_url":"https://api.github.com/users/grybmadsci/followers","following_url":"https://api.github.com/users/grybmadsci/following{/other_user}","gists_url":"https://api.github.com/users/grybmadsci/gists{/gist_id}","starred_url":"https://api.github.com/users/grybmadsci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grybmadsci/subscriptions","organizations_url":"https://api.github.com/users/grybmadsci/orgs","repos_url":"https://api.github.com/users/grybmadsci/repos","events_url":"https://api.github.com/users/grybmadsci/events{/privacy}","received_events_url":"https://api.github.com/users/grybmadsci/received_events","type":"User","site_admin":false},"body":"Update TestState to decouple running/completed from pass/fail.  This cascaded into lots of cleanup/refactoring.  Settled on this naming convention:\r\n-  PhaseResult, any reference to a 'result': User-facing return values from test phases.\r\n-  PhaseOutcome, any reference to an 'outcome': Framework internal state based on what happened in a phase, including return values, exceptions raised, or timeout.\r\n\r\nMade a few other name changes, usually to be more explicit.  There's the one change from 'running_phase' to 'running_phase_record', because I was annoyed at having no idea what kind of object 'running_phase' was, and 'running_phase_record' at least gives a clue as to what to look for to find out (PhaseRecord).  That one required a change in the frontend, though, so @jettisonjoe a heads up for the new frontend.\r\n\r\nAlso, I moved things around a bit for examples, updated some docs for example_plug, made a real hello_world.py example (because our last one was really anything but).\r\n\r\nI tried to keep any real logic changes inside test_state.py, as that's the focus of the PR, most other stuff should be primarily refactoring only.\r\n\r\nTested via all_the_things.py to produce a pass, fail, error (by raising), and timeout.  We should add an integration test that does those 4 things automatically, but i'm concerned this PR is already huge and noisy, so I'd like to do that in a followup (or have someone else do it ;))","created_at":"2016-03-12T14:16:18Z","updated_at":"2016-03-15T04:13:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c60c297a615b7f24f294acd4f2a32567a3acb143","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/google/openhtf/pulls/168/commits","review_comments_url":"https://api.github.com/repos/google/openhtf/pulls/168/comments","review_comment_url":"https://api.github.com/repos/google/openhtf/pulls/comments{/number}","comments_url":"https://api.github.com/repos/google/openhtf/issues/168/comments","statuses_url":"https://api.github.com/repos/google/openhtf/statuses/0b8b3308c9caf5501a0b60bd1a135b56fff693fd","head":{"label":"grybmadsci:test_state","ref":"test_state","sha":"0b8b3308c9caf5501a0b60bd1a135b56fff693fd","user":{"login":"grybmadsci","id":14081283,"avatar_url":"https://avatars.githubusercontent.com/u/14081283?v=3","gravatar_id":"","url":"https://api.github.com/users/grybmadsci","html_url":"https://github.com/grybmadsci","followers_url":"https://api.github.com/users/grybmadsci/followers","following_url":"https://api.github.com/users/grybmadsci/following{/other_user}","gists_url":"https://api.github.com/users/grybmadsci/gists{/gist_id}","starred_url":"https://api.github.com/users/grybmadsci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grybmadsci/subscriptions","organizations_url":"https://api.github.com/users/grybmadsci/orgs","repos_url":"https://api.github.com/users/grybmadsci/repos","events_url":"https://api.github.com/users/grybmadsci/events{/privacy}","received_events_url":"https://api.github.com/users/grybmadsci/received_events","type":"User","site_admin":false},"repo":{"id":42607023,"name":"openhtf","full_name":"grybmadsci/openhtf","owner":{"login":"grybmadsci","id":14081283,"avatar_url":"https://avatars.githubusercontent.com/u/14081283?v=3","gravatar_id":"","url":"https://api.github.com/users/grybmadsci","html_url":"https://github.com/grybmadsci","followers_url":"https://api.github.com/users/grybmadsci/followers","following_url":"https://api.github.com/users/grybmadsci/following{/other_user}","gists_url":"https://api.github.com/users/grybmadsci/gists{/gist_id}","starred_url":"https://api.github.com/users/grybmadsci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grybmadsci/subscriptions","organizations_url":"https://api.github.com/users/grybmadsci/orgs","repos_url":"https://api.github.com/users/grybmadsci/repos","events_url":"https://api.github.com/users/grybmadsci/events{/privacy}","received_events_url":"https://api.github.com/users/grybmadsci/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/grybmadsci/openhtf","description":null,"fork":true,"url":"https://api.github.com/repos/grybmadsci/openhtf","forks_url":"https://api.github.com/repos/grybmadsci/openhtf/forks","keys_url":"https://api.github.com/repos/grybmadsci/openhtf/keys{/key_id}","collaborators_url":"https://api.github.com/repos/grybmadsci/openhtf/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/grybmadsci/openhtf/teams","hooks_url":"https://api.github.com/repos/grybmadsci/openhtf/hooks","issue_events_url":"https://api.github.com/repos/grybmadsci/openhtf/issues/events{/number}","events_url":"https://api.github.com/repos/grybmadsci/openhtf/events","assignees_url":"https://api.github.com/repos/grybmadsci/openhtf/assignees{/user}","branches_url":"https://api.github.com/repos/grybmadsci/openhtf/branches{/branch}","tags_url":"https://api.github.com/repos/grybmadsci/openhtf/tags","blobs_url":"https://api.github.com/repos/grybmadsci/openhtf/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/grybmadsci/openhtf/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/grybmadsci/openhtf/git/refs{/sha}","trees_url":"https://api.github.com/repos/grybmadsci/openhtf/git/trees{/sha}","statuses_url":"https://api.github.com/repos/grybmadsci/openhtf/statuses/{sha}","languages_url":"https://api.github.com/repos/grybmadsci/openhtf/languages","stargazers_url":"https://api.github.com/repos/grybmadsci/openhtf/stargazers","contributors_url":"https://api.github.com/repos/grybmadsci/openhtf/contributors","subscribers_url":"https://api.github.com/repos/grybmadsci/openhtf/subscribers","subscription_url":"https://api.github.com/repos/grybmadsci/openhtf/subscription","commits_url":"https://api.github.com/repos/grybmadsci/openhtf/commits{/sha}","git_commits_url":"https://api.github.com/repos/grybmadsci/openhtf/git/commits{/sha}","comments_url":"https://api.github.com/repos/grybmadsci/openhtf/comments{/number}","issue_comment_url":"https://api.github.com/repos/grybmadsci/openhtf/issues/comments{/number}","contents_url":"https://api.github.com/repos/grybmadsci/openhtf/contents/{+path}","compare_url":"https://api.github.com/repos/grybmadsci/openhtf/compare/{base}...{head}","merges_url":"https://api.github.com/repos/grybmadsci/openhtf/merges","archive_url":"https://api.github.com/repos/grybmadsci/openhtf/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/grybmadsci/openhtf/downloads","issues_url":"https://api.github.com/repos/grybmadsci/openhtf/issues{/number}","pulls_url":"https://api.github.com/repos/grybmadsci/openhtf/pulls{/number}","milestones_url":"https://api.github.com/repos/grybmadsci/openhtf/milestones{/number}","notifications_url":"https://api.github.com/repos/grybmadsci/openhtf/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/grybmadsci/openhtf/labels{/name}","releases_url":"https://api.github.com/repos/grybmadsci/openhtf/releases{/id}","deployments_url":"https://api.github.com/repos/grybmadsci/openhtf/deployments","created_at":"2015-09-16T18:54:24Z","updated_at":"2016-02-04T20:55:11Z","pushed_at":"2016-03-14T23:52:50Z","git_url":"git://github.com/grybmadsci/openhtf.git","ssh_url":"git@github.com:grybmadsci/openhtf.git","clone_url":"https://github.com/grybmadsci/openhtf.git","svn_url":"https://github.com/grybmadsci/openhtf","homepage":null,"size":18517,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"google:master","ref":"master","sha":"b8f2930b12e5e57b730542875b065e47ad65d3ac","user":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":41519483,"name":"openhtf","full_name":"google/openhtf","owner":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/google/openhtf","description":null,"fork":false,"url":"https://api.github.com/repos/google/openhtf","forks_url":"https://api.github.com/repos/google/openhtf/forks","keys_url":"https://api.github.com/repos/google/openhtf/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/openhtf/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/openhtf/teams","hooks_url":"https://api.github.com/repos/google/openhtf/hooks","issue_events_url":"https://api.github.com/repos/google/openhtf/issues/events{/number}","events_url":"https://api.github.com/repos/google/openhtf/events","assignees_url":"https://api.github.com/repos/google/openhtf/assignees{/user}","branches_url":"https://api.github.com/repos/google/openhtf/branches{/branch}","tags_url":"https://api.github.com/repos/google/openhtf/tags","blobs_url":"https://api.github.com/repos/google/openhtf/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/openhtf/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/openhtf/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/openhtf/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/openhtf/statuses/{sha}","languages_url":"https://api.github.com/repos/google/openhtf/languages","stargazers_url":"https://api.github.com/repos/google/openhtf/stargazers","contributors_url":"https://api.github.com/repos/google/openhtf/contributors","subscribers_url":"https://api.github.com/repos/google/openhtf/subscribers","subscription_url":"https://api.github.com/repos/google/openhtf/subscription","commits_url":"https://api.github.com/repos/google/openhtf/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/openhtf/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/openhtf/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/openhtf/issues/comments{/number}","contents_url":"https://api.github.com/repos/google/openhtf/contents/{+path}","compare_url":"https://api.github.com/repos/google/openhtf/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/openhtf/merges","archive_url":"https://api.github.com/repos/google/openhtf/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/openhtf/downloads","issues_url":"https://api.github.com/repos/google/openhtf/issues{/number}","pulls_url":"https://api.github.com/repos/google/openhtf/pulls{/number}","milestones_url":"https://api.github.com/repos/google/openhtf/milestones{/number}","notifications_url":"https://api.github.com/repos/google/openhtf/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/openhtf/labels{/name}","releases_url":"https://api.github.com/repos/google/openhtf/releases{/id}","deployments_url":"https://api.github.com/repos/google/openhtf/deployments","created_at":"2015-08-28T01:14:17Z","updated_at":"2016-03-08T21:09:52Z","pushed_at":"2016-03-15T02:57:35Z","git_url":"git://github.com/google/openhtf.git","ssh_url":"git@github.com:google/openhtf.git","clone_url":"https://github.com/google/openhtf.git","svn_url":"https://github.com/google/openhtf","homepage":null,"size":18551,"stargazers_count":17,"watchers_count":17,"language":"Python","has_issues":true,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":18,"mirror_url":null,"open_issues_count":58,"forks":18,"open_issues":58,"watchers":17,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/openhtf/pulls/168"},"html":{"href":"https://github.com/google/openhtf/pull/168"},"issue":{"href":"https://api.github.com/repos/google/openhtf/issues/168"},"comments":{"href":"https://api.github.com/repos/google/openhtf/issues/168/comments"},"review_comments":{"href":"https://api.github.com/repos/google/openhtf/pulls/168/comments"},"review_comment":{"href":"https://api.github.com/repos/google/openhtf/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/google/openhtf/pulls/168/commits"},"statuses":{"href":"https://api.github.com/repos/google/openhtf/statuses/0b8b3308c9caf5501a0b60bd1a135b56fff693fd"}}}}