{"action":"created","comment":{"url":"https://api.github.com/repos/dotnet/buildtools/pulls/comments/51522261","id":51522261,"diff_hunk":"@@ -0,0 +1,195 @@\n+import csv\n+import getopt\n+import json\n+import os\n+import os.path\n+import serialobj\n+import sys\n+sys.path.append(os.getenv('HELIX_SCRIPT_ROOT'))\n+import helix.logs\n+\n+log = helix.logs.get_logger()\n+\n+def readCSV(csvFile):\n+    log.info('Reading '+csvFile)\n+    if not os.path.exists(csvFile):\n+        raise Exception(csvFile+' could not be found for conversion')\n+\n+    csvdict = dict()\n+    with open(csvFile, 'rb') as csvfile:\n+        reader = csv.reader(csvfile)","path":"src/Microsoft.DotNet.Build.CloudTestTasks/PackageFiles/xunitrunner-perf/csvjsonconvertor.py","position":20,"original_position":20,"commit_id":"414850618ae45a653bc60d53885b2cc7d77de83b","original_commit_id":"414850618ae45a653bc60d53885b2cc7d77de83b","user":{"login":"dsgouda","id":14796031,"avatar_url":"https://avatars.githubusercontent.com/u/14796031?v=3","gravatar_id":"","url":"https://api.github.com/users/dsgouda","html_url":"https://github.com/dsgouda","followers_url":"https://api.github.com/users/dsgouda/followers","following_url":"https://api.github.com/users/dsgouda/following{/other_user}","gists_url":"https://api.github.com/users/dsgouda/gists{/gist_id}","starred_url":"https://api.github.com/users/dsgouda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dsgouda/subscriptions","organizations_url":"https://api.github.com/users/dsgouda/orgs","repos_url":"https://api.github.com/users/dsgouda/repos","events_url":"https://api.github.com/users/dsgouda/events{/privacy}","received_events_url":"https://api.github.com/users/dsgouda/received_events","type":"User","site_admin":false},"body":"I have tried adding some commenting but the structure is, Each run has suites, each suite has tests and each test has a number of results, (in other words dict->dict->dict->list)","created_at":"2016-02-02T04:21:58Z","updated_at":"2016-02-02T04:21:58Z","html_url":"https://github.com/dotnet/buildtools/pull/426#discussion_r51522261","pull_request_url":"https://api.github.com/repos/dotnet/buildtools/pulls/426","_links":{"self":{"href":"https://api.github.com/repos/dotnet/buildtools/pulls/comments/51522261"},"html":{"href":"https://github.com/dotnet/buildtools/pull/426#discussion_r51522261"},"pull_request":{"href":"https://api.github.com/repos/dotnet/buildtools/pulls/426"}}},"pull_request":{"url":"https://api.github.com/repos/dotnet/buildtools/pulls/426","id":57905804,"html_url":"https://github.com/dotnet/buildtools/pull/426","diff_url":"https://github.com/dotnet/buildtools/pull/426.diff","patch_url":"https://github.com/dotnet/buildtools/pull/426.patch","issue_url":"https://api.github.com/repos/dotnet/buildtools/issues/426","number":426,"state":"open","locked":false,"title":"Python script to convert csv results to BV jsons","user":{"login":"dsgouda","id":14796031,"avatar_url":"https://avatars.githubusercontent.com/u/14796031?v=3","gravatar_id":"","url":"https://api.github.com/users/dsgouda","html_url":"https://github.com/dsgouda","followers_url":"https://api.github.com/users/dsgouda/followers","following_url":"https://api.github.com/users/dsgouda/following{/other_user}","gists_url":"https://api.github.com/users/dsgouda/gists{/gist_id}","starred_url":"https://api.github.com/users/dsgouda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dsgouda/subscriptions","organizations_url":"https://api.github.com/users/dsgouda/orgs","repos_url":"https://api.github.com/users/dsgouda/repos","events_url":"https://api.github.com/users/dsgouda/events{/privacy}","received_events_url":"https://api.github.com/users/dsgouda/received_events","type":"User","site_admin":false},"body":"Utility scripts that will convert the results csv to json consumable by bench view; this is a stop-gap solution that should allow us to run perf on multiple OSes; moving forward, the benchview team should provide a script/exe to do this conversion for us.\r\n\r\n@davmason @ChadNedzlek @MattGal @jhendrixMSFT @mmitche ","created_at":"2016-02-01T21:51:18Z","updated_at":"2016-02-02T04:21:58Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a6a1754e27e101ab07f18e098c3405dbc66ab71b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/dotnet/buildtools/pulls/426/commits","review_comments_url":"https://api.github.com/repos/dotnet/buildtools/pulls/426/comments","review_comment_url":"https://api.github.com/repos/dotnet/buildtools/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dotnet/buildtools/issues/426/comments","statuses_url":"https://api.github.com/repos/dotnet/buildtools/statuses/414850618ae45a653bc60d53885b2cc7d77de83b","head":{"label":"dsgouda:csvtojson","ref":"csvtojson","sha":"414850618ae45a653bc60d53885b2cc7d77de83b","user":{"login":"dsgouda","id":14796031,"avatar_url":"https://avatars.githubusercontent.com/u/14796031?v=3","gravatar_id":"","url":"https://api.github.com/users/dsgouda","html_url":"https://github.com/dsgouda","followers_url":"https://api.github.com/users/dsgouda/followers","following_url":"https://api.github.com/users/dsgouda/following{/other_user}","gists_url":"https://api.github.com/users/dsgouda/gists{/gist_id}","starred_url":"https://api.github.com/users/dsgouda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dsgouda/subscriptions","organizations_url":"https://api.github.com/users/dsgouda/orgs","repos_url":"https://api.github.com/users/dsgouda/repos","events_url":"https://api.github.com/users/dsgouda/events{/privacy}","received_events_url":"https://api.github.com/users/dsgouda/received_events","type":"User","site_admin":false},"repo":{"id":50616195,"name":"buildtools","full_name":"dsgouda/buildtools","owner":{"login":"dsgouda","id":14796031,"avatar_url":"https://avatars.githubusercontent.com/u/14796031?v=3","gravatar_id":"","url":"https://api.github.com/users/dsgouda","html_url":"https://github.com/dsgouda","followers_url":"https://api.github.com/users/dsgouda/followers","following_url":"https://api.github.com/users/dsgouda/following{/other_user}","gists_url":"https://api.github.com/users/dsgouda/gists{/gist_id}","starred_url":"https://api.github.com/users/dsgouda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dsgouda/subscriptions","organizations_url":"https://api.github.com/users/dsgouda/orgs","repos_url":"https://api.github.com/users/dsgouda/repos","events_url":"https://api.github.com/users/dsgouda/events{/privacy}","received_events_url":"https://api.github.com/users/dsgouda/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/dsgouda/buildtools","description":"Build tools that are necessary for building the .NET Core projects","fork":true,"url":"https://api.github.com/repos/dsgouda/buildtools","forks_url":"https://api.github.com/repos/dsgouda/buildtools/forks","keys_url":"https://api.github.com/repos/dsgouda/buildtools/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dsgouda/buildtools/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dsgouda/buildtools/teams","hooks_url":"https://api.github.com/repos/dsgouda/buildtools/hooks","issue_events_url":"https://api.github.com/repos/dsgouda/buildtools/issues/events{/number}","events_url":"https://api.github.com/repos/dsgouda/buildtools/events","assignees_url":"https://api.github.com/repos/dsgouda/buildtools/assignees{/user}","branches_url":"https://api.github.com/repos/dsgouda/buildtools/branches{/branch}","tags_url":"https://api.github.com/repos/dsgouda/buildtools/tags","blobs_url":"https://api.github.com/repos/dsgouda/buildtools/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dsgouda/buildtools/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dsgouda/buildtools/git/refs{/sha}","trees_url":"https://api.github.com/repos/dsgouda/buildtools/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dsgouda/buildtools/statuses/{sha}","languages_url":"https://api.github.com/repos/dsgouda/buildtools/languages","stargazers_url":"https://api.github.com/repos/dsgouda/buildtools/stargazers","contributors_url":"https://api.github.com/repos/dsgouda/buildtools/contributors","subscribers_url":"https://api.github.com/repos/dsgouda/buildtools/subscribers","subscription_url":"https://api.github.com/repos/dsgouda/buildtools/subscription","commits_url":"https://api.github.com/repos/dsgouda/buildtools/commits{/sha}","git_commits_url":"https://api.github.com/repos/dsgouda/buildtools/git/commits{/sha}","comments_url":"https://api.github.com/repos/dsgouda/buildtools/comments{/number}","issue_comment_url":"https://api.github.com/repos/dsgouda/buildtools/issues/comments{/number}","contents_url":"https://api.github.com/repos/dsgouda/buildtools/contents/{+path}","compare_url":"https://api.github.com/repos/dsgouda/buildtools/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dsgouda/buildtools/merges","archive_url":"https://api.github.com/repos/dsgouda/buildtools/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dsgouda/buildtools/downloads","issues_url":"https://api.github.com/repos/dsgouda/buildtools/issues{/number}","pulls_url":"https://api.github.com/repos/dsgouda/buildtools/pulls{/number}","milestones_url":"https://api.github.com/repos/dsgouda/buildtools/milestones{/number}","notifications_url":"https://api.github.com/repos/dsgouda/buildtools/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dsgouda/buildtools/labels{/name}","releases_url":"https://api.github.com/repos/dsgouda/buildtools/releases{/id}","deployments_url":"https://api.github.com/repos/dsgouda/buildtools/deployments","created_at":"2016-01-28T21:47:40Z","updated_at":"2016-01-28T21:47:42Z","pushed_at":"2016-02-01T21:41:05Z","git_url":"git://github.com/dsgouda/buildtools.git","ssh_url":"git@github.com:dsgouda/buildtools.git","clone_url":"https://github.com/dsgouda/buildtools.git","svn_url":"https://github.com/dsgouda/buildtools","homepage":"","size":2160,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":false,"has_downloads":true,"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":"dotnet:master","ref":"master","sha":"38aa28e8b8b527c076b2b9293a102d022ea8d8b9","user":{"login":"dotnet","id":9141961,"avatar_url":"https://avatars.githubusercontent.com/u/9141961?v=3","gravatar_id":"","url":"https://api.github.com/users/dotnet","html_url":"https://github.com/dotnet","followers_url":"https://api.github.com/users/dotnet/followers","following_url":"https://api.github.com/users/dotnet/following{/other_user}","gists_url":"https://api.github.com/users/dotnet/gists{/gist_id}","starred_url":"https://api.github.com/users/dotnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dotnet/subscriptions","organizations_url":"https://api.github.com/users/dotnet/orgs","repos_url":"https://api.github.com/users/dotnet/repos","events_url":"https://api.github.com/users/dotnet/events{/privacy}","received_events_url":"https://api.github.com/users/dotnet/received_events","type":"Organization","site_admin":false},"repo":{"id":26295349,"name":"buildtools","full_name":"dotnet/buildtools","owner":{"login":"dotnet","id":9141961,"avatar_url":"https://avatars.githubusercontent.com/u/9141961?v=3","gravatar_id":"","url":"https://api.github.com/users/dotnet","html_url":"https://github.com/dotnet","followers_url":"https://api.github.com/users/dotnet/followers","following_url":"https://api.github.com/users/dotnet/following{/other_user}","gists_url":"https://api.github.com/users/dotnet/gists{/gist_id}","starred_url":"https://api.github.com/users/dotnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dotnet/subscriptions","organizations_url":"https://api.github.com/users/dotnet/orgs","repos_url":"https://api.github.com/users/dotnet/repos","events_url":"https://api.github.com/users/dotnet/events{/privacy}","received_events_url":"https://api.github.com/users/dotnet/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dotnet/buildtools","description":"Build tools that are necessary for building the .NET Core projects","fork":false,"url":"https://api.github.com/repos/dotnet/buildtools","forks_url":"https://api.github.com/repos/dotnet/buildtools/forks","keys_url":"https://api.github.com/repos/dotnet/buildtools/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dotnet/buildtools/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dotnet/buildtools/teams","hooks_url":"https://api.github.com/repos/dotnet/buildtools/hooks","issue_events_url":"https://api.github.com/repos/dotnet/buildtools/issues/events{/number}","events_url":"https://api.github.com/repos/dotnet/buildtools/events","assignees_url":"https://api.github.com/repos/dotnet/buildtools/assignees{/user}","branches_url":"https://api.github.com/repos/dotnet/buildtools/branches{/branch}","tags_url":"https://api.github.com/repos/dotnet/buildtools/tags","blobs_url":"https://api.github.com/repos/dotnet/buildtools/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dotnet/buildtools/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dotnet/buildtools/git/refs{/sha}","trees_url":"https://api.github.com/repos/dotnet/buildtools/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dotnet/buildtools/statuses/{sha}","languages_url":"https://api.github.com/repos/dotnet/buildtools/languages","stargazers_url":"https://api.github.com/repos/dotnet/buildtools/stargazers","contributors_url":"https://api.github.com/repos/dotnet/buildtools/contributors","subscribers_url":"https://api.github.com/repos/dotnet/buildtools/subscribers","subscription_url":"https://api.github.com/repos/dotnet/buildtools/subscription","commits_url":"https://api.github.com/repos/dotnet/buildtools/commits{/sha}","git_commits_url":"https://api.github.com/repos/dotnet/buildtools/git/commits{/sha}","comments_url":"https://api.github.com/repos/dotnet/buildtools/comments{/number}","issue_comment_url":"https://api.github.com/repos/dotnet/buildtools/issues/comments{/number}","contents_url":"https://api.github.com/repos/dotnet/buildtools/contents/{+path}","compare_url":"https://api.github.com/repos/dotnet/buildtools/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dotnet/buildtools/merges","archive_url":"https://api.github.com/repos/dotnet/buildtools/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dotnet/buildtools/downloads","issues_url":"https://api.github.com/repos/dotnet/buildtools/issues{/number}","pulls_url":"https://api.github.com/repos/dotnet/buildtools/pulls{/number}","milestones_url":"https://api.github.com/repos/dotnet/buildtools/milestones{/number}","notifications_url":"https://api.github.com/repos/dotnet/buildtools/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dotnet/buildtools/labels{/name}","releases_url":"https://api.github.com/repos/dotnet/buildtools/releases{/id}","deployments_url":"https://api.github.com/repos/dotnet/buildtools/deployments","created_at":"2014-11-06T23:43:05Z","updated_at":"2016-01-28T19:29:29Z","pushed_at":"2016-02-02T01:40:17Z","git_url":"git://github.com/dotnet/buildtools.git","ssh_url":"git@github.com:dotnet/buildtools.git","clone_url":"https://github.com/dotnet/buildtools.git","svn_url":"https://github.com/dotnet/buildtools","homepage":"","size":2674,"stargazers_count":392,"watchers_count":392,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":170,"mirror_url":null,"open_issues_count":39,"forks":170,"open_issues":39,"watchers":392,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dotnet/buildtools/pulls/426"},"html":{"href":"https://github.com/dotnet/buildtools/pull/426"},"issue":{"href":"https://api.github.com/repos/dotnet/buildtools/issues/426"},"comments":{"href":"https://api.github.com/repos/dotnet/buildtools/issues/426/comments"},"review_comments":{"href":"https://api.github.com/repos/dotnet/buildtools/pulls/426/comments"},"review_comment":{"href":"https://api.github.com/repos/dotnet/buildtools/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dotnet/buildtools/pulls/426/commits"},"statuses":{"href":"https://api.github.com/repos/dotnet/buildtools/statuses/414850618ae45a653bc60d53885b2cc7d77de83b"}}}}