{"action":"created","comment":{"url":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/comments/26761520","id":26761520,"diff_hunk":"@@ -274,3 +309,19 @@ type RawRef struct {\n \tEnd       uint32\n \tToBuiltin bool\n }\n+\n+func installPipRequirements(pipBin string, requirementFiles []string) {\n+\tfor _, requirementFile := range requirementFiles {\n+\t\terr := runCmdStderr(exec.Command(pipBin, \"install\", \"-r\", requirementFile))\n+\t\tif err != nil {\n+\t\t\tlog.Printf(\"Error installing dependencies in %s. Trying piecemeal install\", requirementFile)\n+\t\t\tif b, err := ioutil.ReadFile(requirementFile); err == nil {\n+\t\t\t\tfor _, req := range strings.Split(string(b), \"\\n\") {\n+\t\t\t\t\trunCmdLogError(exec.Command(pipBin, \"install\", req))","path":"python/grapher.go","position":129,"original_position":129,"commit_id":"f160e7eaf2ea636e0fd755ba7adcdebd89d21f4d","original_commit_id":"f160e7eaf2ea636e0fd755ba7adcdebd89d21f4d","user":{"login":"MaikuMori","id":28470,"avatar_url":"https://avatars.githubusercontent.com/u/28470?v=3","gravatar_id":"","url":"https://api.github.com/users/MaikuMori","html_url":"https://github.com/MaikuMori","followers_url":"https://api.github.com/users/MaikuMori/followers","following_url":"https://api.github.com/users/MaikuMori/following{/other_user}","gists_url":"https://api.github.com/users/MaikuMori/gists{/gist_id}","starred_url":"https://api.github.com/users/MaikuMori/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MaikuMori/subscriptions","organizations_url":"https://api.github.com/users/MaikuMori/orgs","repos_url":"https://api.github.com/users/MaikuMori/repos","events_url":"https://api.github.com/users/MaikuMori/events{/privacy}","received_events_url":"https://api.github.com/users/MaikuMori/received_events","type":"User","site_admin":false},"body":"As I wrote in the next comment, I didn't want to change the logic too much and this function is extracted from a code path which was ran in docker mode (preciously I had multiple calls for this function, but not in this version).\r\n\r\nWhich one do you think is best? Fail fast vs analyze 90%? It would be nice that we could analyze as much as possible but still communicate the warnings/errors back to the end user.","created_at":"2015-03-19T14:57:55Z","updated_at":"2015-03-19T14:57:55Z","html_url":"https://github.com/sourcegraph/srclib-python/pull/20#discussion_r26761520","pull_request_url":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/20","_links":{"self":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/comments/26761520"},"html":{"href":"https://github.com/sourcegraph/srclib-python/pull/20#discussion_r26761520"},"pull_request":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/20"}}},"pull_request":{"url":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/20","id":31388803,"html_url":"https://github.com/sourcegraph/srclib-python/pull/20","diff_url":"https://github.com/sourcegraph/srclib-python/pull/20.diff","patch_url":"https://github.com/sourcegraph/srclib-python/pull/20.patch","issue_url":"https://api.github.com/repos/sourcegraph/srclib-python/issues/20","number":20,"state":"open","locked":false,"title":"Use venv per SourceUnit","user":{"login":"MaikuMori","id":28470,"avatar_url":"https://avatars.githubusercontent.com/u/28470?v=3","gravatar_id":"","url":"https://api.github.com/users/MaikuMori","html_url":"https://github.com/MaikuMori","followers_url":"https://api.github.com/users/MaikuMori/followers","following_url":"https://api.github.com/users/MaikuMori/following{/other_user}","gists_url":"https://api.github.com/users/MaikuMori/gists{/gist_id}","starred_url":"https://api.github.com/users/MaikuMori/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MaikuMori/subscriptions","organizations_url":"https://api.github.com/users/MaikuMori/orgs","repos_url":"https://api.github.com/users/MaikuMori/repos","events_url":"https://api.github.com/users/MaikuMori/events{/privacy}","received_events_url":"https://api.github.com/users/MaikuMori/received_events","type":"User","site_admin":false},"body":"WIP.\r\n\r\nThe tests will probably fail because I'm depending on https://github.com/sourcegraph/srclib/pull/127","created_at":"2015-03-17T23:38:23Z","updated_at":"2015-03-19T14:57:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"93eb77655d27f8e2fcf2f516a7f1157332c1da3a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/20/commits","review_comments_url":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/20/comments","review_comment_url":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/comments{/number}","comments_url":"https://api.github.com/repos/sourcegraph/srclib-python/issues/20/comments","statuses_url":"https://api.github.com/repos/sourcegraph/srclib-python/statuses/f160e7eaf2ea636e0fd755ba7adcdebd89d21f4d","head":{"label":"sourcegraph:use-venv-per-source-unit","ref":"use-venv-per-source-unit","sha":"f160e7eaf2ea636e0fd755ba7adcdebd89d21f4d","user":{"login":"sourcegraph","id":3979584,"avatar_url":"https://avatars.githubusercontent.com/u/3979584?v=3","gravatar_id":"","url":"https://api.github.com/users/sourcegraph","html_url":"https://github.com/sourcegraph","followers_url":"https://api.github.com/users/sourcegraph/followers","following_url":"https://api.github.com/users/sourcegraph/following{/other_user}","gists_url":"https://api.github.com/users/sourcegraph/gists{/gist_id}","starred_url":"https://api.github.com/users/sourcegraph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sourcegraph/subscriptions","organizations_url":"https://api.github.com/users/sourcegraph/orgs","repos_url":"https://api.github.com/users/sourcegraph/repos","events_url":"https://api.github.com/users/sourcegraph/events{/privacy}","received_events_url":"https://api.github.com/users/sourcegraph/received_events","type":"Organization","site_admin":false},"repo":{"id":22005119,"name":"srclib-python","full_name":"sourcegraph/srclib-python","owner":{"login":"sourcegraph","id":3979584,"avatar_url":"https://avatars.githubusercontent.com/u/3979584?v=3","gravatar_id":"","url":"https://api.github.com/users/sourcegraph","html_url":"https://github.com/sourcegraph","followers_url":"https://api.github.com/users/sourcegraph/followers","following_url":"https://api.github.com/users/sourcegraph/following{/other_user}","gists_url":"https://api.github.com/users/sourcegraph/gists{/gist_id}","starred_url":"https://api.github.com/users/sourcegraph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sourcegraph/subscriptions","organizations_url":"https://api.github.com/users/sourcegraph/orgs","repos_url":"https://api.github.com/users/sourcegraph/repos","events_url":"https://api.github.com/users/sourcegraph/events{/privacy}","received_events_url":"https://api.github.com/users/sourcegraph/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/sourcegraph/srclib-python","description":"","fork":false,"url":"https://api.github.com/repos/sourcegraph/srclib-python","forks_url":"https://api.github.com/repos/sourcegraph/srclib-python/forks","keys_url":"https://api.github.com/repos/sourcegraph/srclib-python/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sourcegraph/srclib-python/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sourcegraph/srclib-python/teams","hooks_url":"https://api.github.com/repos/sourcegraph/srclib-python/hooks","issue_events_url":"https://api.github.com/repos/sourcegraph/srclib-python/issues/events{/number}","events_url":"https://api.github.com/repos/sourcegraph/srclib-python/events","assignees_url":"https://api.github.com/repos/sourcegraph/srclib-python/assignees{/user}","branches_url":"https://api.github.com/repos/sourcegraph/srclib-python/branches{/branch}","tags_url":"https://api.github.com/repos/sourcegraph/srclib-python/tags","blobs_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/refs{/sha}","trees_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sourcegraph/srclib-python/statuses/{sha}","languages_url":"https://api.github.com/repos/sourcegraph/srclib-python/languages","stargazers_url":"https://api.github.com/repos/sourcegraph/srclib-python/stargazers","contributors_url":"https://api.github.com/repos/sourcegraph/srclib-python/contributors","subscribers_url":"https://api.github.com/repos/sourcegraph/srclib-python/subscribers","subscription_url":"https://api.github.com/repos/sourcegraph/srclib-python/subscription","commits_url":"https://api.github.com/repos/sourcegraph/srclib-python/commits{/sha}","git_commits_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/commits{/sha}","comments_url":"https://api.github.com/repos/sourcegraph/srclib-python/comments{/number}","issue_comment_url":"https://api.github.com/repos/sourcegraph/srclib-python/issues/comments{/number}","contents_url":"https://api.github.com/repos/sourcegraph/srclib-python/contents/{+path}","compare_url":"https://api.github.com/repos/sourcegraph/srclib-python/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sourcegraph/srclib-python/merges","archive_url":"https://api.github.com/repos/sourcegraph/srclib-python/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sourcegraph/srclib-python/downloads","issues_url":"https://api.github.com/repos/sourcegraph/srclib-python/issues{/number}","pulls_url":"https://api.github.com/repos/sourcegraph/srclib-python/pulls{/number}","milestones_url":"https://api.github.com/repos/sourcegraph/srclib-python/milestones{/number}","notifications_url":"https://api.github.com/repos/sourcegraph/srclib-python/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sourcegraph/srclib-python/labels{/name}","releases_url":"https://api.github.com/repos/sourcegraph/srclib-python/releases{/id}","created_at":"2014-07-19T08:12:33Z","updated_at":"2015-03-17T10:23:57Z","pushed_at":"2015-03-17T23:30:07Z","git_url":"git://github.com/sourcegraph/srclib-python.git","ssh_url":"git@github.com:sourcegraph/srclib-python.git","clone_url":"https://github.com/sourcegraph/srclib-python.git","svn_url":"https://github.com/sourcegraph/srclib-python","homepage":"https://sourcegraph.com/sourcegraph/srclib-python","size":694,"stargazers_count":12,"watchers_count":12,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":6,"mirror_url":null,"open_issues_count":10,"forks":6,"open_issues":10,"watchers":12,"default_branch":"master"}},"base":{"label":"sourcegraph:master","ref":"master","sha":"4d777587e06c9533286ff253aeaf8e153d1ee61d","user":{"login":"sourcegraph","id":3979584,"avatar_url":"https://avatars.githubusercontent.com/u/3979584?v=3","gravatar_id":"","url":"https://api.github.com/users/sourcegraph","html_url":"https://github.com/sourcegraph","followers_url":"https://api.github.com/users/sourcegraph/followers","following_url":"https://api.github.com/users/sourcegraph/following{/other_user}","gists_url":"https://api.github.com/users/sourcegraph/gists{/gist_id}","starred_url":"https://api.github.com/users/sourcegraph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sourcegraph/subscriptions","organizations_url":"https://api.github.com/users/sourcegraph/orgs","repos_url":"https://api.github.com/users/sourcegraph/repos","events_url":"https://api.github.com/users/sourcegraph/events{/privacy}","received_events_url":"https://api.github.com/users/sourcegraph/received_events","type":"Organization","site_admin":false},"repo":{"id":22005119,"name":"srclib-python","full_name":"sourcegraph/srclib-python","owner":{"login":"sourcegraph","id":3979584,"avatar_url":"https://avatars.githubusercontent.com/u/3979584?v=3","gravatar_id":"","url":"https://api.github.com/users/sourcegraph","html_url":"https://github.com/sourcegraph","followers_url":"https://api.github.com/users/sourcegraph/followers","following_url":"https://api.github.com/users/sourcegraph/following{/other_user}","gists_url":"https://api.github.com/users/sourcegraph/gists{/gist_id}","starred_url":"https://api.github.com/users/sourcegraph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sourcegraph/subscriptions","organizations_url":"https://api.github.com/users/sourcegraph/orgs","repos_url":"https://api.github.com/users/sourcegraph/repos","events_url":"https://api.github.com/users/sourcegraph/events{/privacy}","received_events_url":"https://api.github.com/users/sourcegraph/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/sourcegraph/srclib-python","description":"","fork":false,"url":"https://api.github.com/repos/sourcegraph/srclib-python","forks_url":"https://api.github.com/repos/sourcegraph/srclib-python/forks","keys_url":"https://api.github.com/repos/sourcegraph/srclib-python/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sourcegraph/srclib-python/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sourcegraph/srclib-python/teams","hooks_url":"https://api.github.com/repos/sourcegraph/srclib-python/hooks","issue_events_url":"https://api.github.com/repos/sourcegraph/srclib-python/issues/events{/number}","events_url":"https://api.github.com/repos/sourcegraph/srclib-python/events","assignees_url":"https://api.github.com/repos/sourcegraph/srclib-python/assignees{/user}","branches_url":"https://api.github.com/repos/sourcegraph/srclib-python/branches{/branch}","tags_url":"https://api.github.com/repos/sourcegraph/srclib-python/tags","blobs_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/refs{/sha}","trees_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sourcegraph/srclib-python/statuses/{sha}","languages_url":"https://api.github.com/repos/sourcegraph/srclib-python/languages","stargazers_url":"https://api.github.com/repos/sourcegraph/srclib-python/stargazers","contributors_url":"https://api.github.com/repos/sourcegraph/srclib-python/contributors","subscribers_url":"https://api.github.com/repos/sourcegraph/srclib-python/subscribers","subscription_url":"https://api.github.com/repos/sourcegraph/srclib-python/subscription","commits_url":"https://api.github.com/repos/sourcegraph/srclib-python/commits{/sha}","git_commits_url":"https://api.github.com/repos/sourcegraph/srclib-python/git/commits{/sha}","comments_url":"https://api.github.com/repos/sourcegraph/srclib-python/comments{/number}","issue_comment_url":"https://api.github.com/repos/sourcegraph/srclib-python/issues/comments{/number}","contents_url":"https://api.github.com/repos/sourcegraph/srclib-python/contents/{+path}","compare_url":"https://api.github.com/repos/sourcegraph/srclib-python/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sourcegraph/srclib-python/merges","archive_url":"https://api.github.com/repos/sourcegraph/srclib-python/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sourcegraph/srclib-python/downloads","issues_url":"https://api.github.com/repos/sourcegraph/srclib-python/issues{/number}","pulls_url":"https://api.github.com/repos/sourcegraph/srclib-python/pulls{/number}","milestones_url":"https://api.github.com/repos/sourcegraph/srclib-python/milestones{/number}","notifications_url":"https://api.github.com/repos/sourcegraph/srclib-python/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sourcegraph/srclib-python/labels{/name}","releases_url":"https://api.github.com/repos/sourcegraph/srclib-python/releases{/id}","created_at":"2014-07-19T08:12:33Z","updated_at":"2015-03-17T10:23:57Z","pushed_at":"2015-03-17T23:30:07Z","git_url":"git://github.com/sourcegraph/srclib-python.git","ssh_url":"git@github.com:sourcegraph/srclib-python.git","clone_url":"https://github.com/sourcegraph/srclib-python.git","svn_url":"https://github.com/sourcegraph/srclib-python","homepage":"https://sourcegraph.com/sourcegraph/srclib-python","size":694,"stargazers_count":12,"watchers_count":12,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":6,"mirror_url":null,"open_issues_count":10,"forks":6,"open_issues":10,"watchers":12,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/20"},"html":{"href":"https://github.com/sourcegraph/srclib-python/pull/20"},"issue":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/issues/20"},"comments":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/issues/20/comments"},"review_comments":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/20/comments"},"review_comment":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/pulls/20/commits"},"statuses":{"href":"https://api.github.com/repos/sourcegraph/srclib-python/statuses/f160e7eaf2ea636e0fd755ba7adcdebd89d21f4d"}}}}