{"action":"created","comment":{"url":"https://api.github.com/repos/ideascube/ideascube/pulls/comments/76419978","id":76419978,"diff_hunk":"@@ -762,21 +763,26 @@ def update_cache(self):\n \n         for remote in self._remotes.values():\n             # TODO: Get resumable.urlretrieve to accept a file-like object?\n-            fd, tmppath = tempfile.mkstemp()\n-            os.close(fd)\n+            with tempfile.NamedTemporaryFile() as fd:\n+                tmppath = fd.name\n \n-            def _progress(*args):\n-                self._progress(' {}'.format(remote.name), *args)\n+                def _progress(*args):\n+                    self._progress(' {}'.format(remote.name), *args)","path":"ideascube/serveradmin/catalog.py","position":20,"original_position":20,"commit_id":"e47f25f0927fcac9fb52df3666ca0b0a4f633e89","original_commit_id":"e47f25f0927fcac9fb52df3666ca0b0a4f633e89","user":{"login":"bochecha","id":272170,"avatar_url":"https://avatars.githubusercontent.com/u/272170?v=3","gravatar_id":"","url":"https://api.github.com/users/bochecha","html_url":"https://github.com/bochecha","followers_url":"https://api.github.com/users/bochecha/followers","following_url":"https://api.github.com/users/bochecha/following{/other_user}","gists_url":"https://api.github.com/users/bochecha/gists{/gist_id}","starred_url":"https://api.github.com/users/bochecha/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bochecha/subscriptions","organizations_url":"https://api.github.com/users/bochecha/orgs","repos_url":"https://api.github.com/users/bochecha/repos","events_url":"https://api.github.com/users/bochecha/events{/privacy}","received_events_url":"https://api.github.com/users/bochecha/received_events","type":"User","site_admin":false},"body":"Maybe keep the definition outside of the `with` block?\r\n\r\nLess lines changed, less stuff to review. :stuck_out_tongue: ","created_at":"2016-08-26T13:42:27Z","updated_at":"2016-08-26T13:42:27Z","html_url":"https://github.com/ideascube/ideascube/pull/451#discussion_r76419978","pull_request_url":"https://api.github.com/repos/ideascube/ideascube/pulls/451","_links":{"self":{"href":"https://api.github.com/repos/ideascube/ideascube/pulls/comments/76419978"},"html":{"href":"https://github.com/ideascube/ideascube/pull/451#discussion_r76419978"},"pull_request":{"href":"https://api.github.com/repos/ideascube/ideascube/pulls/451"}}},"pull_request":{"url":"https://api.github.com/repos/ideascube/ideascube/pulls/451","id":82885441,"html_url":"https://github.com/ideascube/ideascube/pull/451","diff_url":"https://github.com/ideascube/ideascube/pull/451.diff","patch_url":"https://github.com/ideascube/ideascube/pull/451.patch","issue_url":"https://api.github.com/repos/ideascube/ideascube/issues/451","number":451,"state":"open","locked":false,"title":"Fix few catalog errors","user":{"login":"mgautierfr","id":86161,"avatar_url":"https://avatars.githubusercontent.com/u/86161?v=3","gravatar_id":"","url":"https://api.github.com/users/mgautierfr","html_url":"https://github.com/mgautierfr","followers_url":"https://api.github.com/users/mgautierfr/followers","following_url":"https://api.github.com/users/mgautierfr/following{/other_user}","gists_url":"https://api.github.com/users/mgautierfr/gists{/gist_id}","starred_url":"https://api.github.com/users/mgautierfr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mgautierfr/subscriptions","organizations_url":"https://api.github.com/users/mgautierfr/orgs","repos_url":"https://api.github.com/users/mgautierfr/repos","events_url":"https://api.github.com/users/mgautierfr/events{/privacy}","received_events_url":"https://api.github.com/users/mgautierfr/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-08-26T13:12:26Z","updated_at":"2016-08-26T13:42:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"783ff73d255a4439e05dfb1b58926ef857da59fa","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/ideascube/ideascube/pulls/451/commits","review_comments_url":"https://api.github.com/repos/ideascube/ideascube/pulls/451/comments","review_comment_url":"https://api.github.com/repos/ideascube/ideascube/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ideascube/ideascube/issues/451/comments","statuses_url":"https://api.github.com/repos/ideascube/ideascube/statuses/e47f25f0927fcac9fb52df3666ca0b0a4f633e89","head":{"label":"ideascube:fix_few_catalog","ref":"fix_few_catalog","sha":"e47f25f0927fcac9fb52df3666ca0b0a4f633e89","user":{"login":"ideascube","id":9719862,"avatar_url":"https://avatars.githubusercontent.com/u/9719862?v=3","gravatar_id":"","url":"https://api.github.com/users/ideascube","html_url":"https://github.com/ideascube","followers_url":"https://api.github.com/users/ideascube/followers","following_url":"https://api.github.com/users/ideascube/following{/other_user}","gists_url":"https://api.github.com/users/ideascube/gists{/gist_id}","starred_url":"https://api.github.com/users/ideascube/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ideascube/subscriptions","organizations_url":"https://api.github.com/users/ideascube/orgs","repos_url":"https://api.github.com/users/ideascube/repos","events_url":"https://api.github.com/users/ideascube/events{/privacy}","received_events_url":"https://api.github.com/users/ideascube/received_events","type":"Organization","site_admin":false},"repo":{"id":26708471,"name":"ideascube","full_name":"ideascube/ideascube","owner":{"login":"ideascube","id":9719862,"avatar_url":"https://avatars.githubusercontent.com/u/9719862?v=3","gravatar_id":"","url":"https://api.github.com/users/ideascube","html_url":"https://github.com/ideascube","followers_url":"https://api.github.com/users/ideascube/followers","following_url":"https://api.github.com/users/ideascube/following{/other_user}","gists_url":"https://api.github.com/users/ideascube/gists{/gist_id}","starred_url":"https://api.github.com/users/ideascube/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ideascube/subscriptions","organizations_url":"https://api.github.com/users/ideascube/orgs","repos_url":"https://api.github.com/users/ideascube/repos","events_url":"https://api.github.com/users/ideascube/events{/privacy}","received_events_url":"https://api.github.com/users/ideascube/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ideascube/ideascube","description":"Ideas Box server core application","fork":false,"url":"https://api.github.com/repos/ideascube/ideascube","forks_url":"https://api.github.com/repos/ideascube/ideascube/forks","keys_url":"https://api.github.com/repos/ideascube/ideascube/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ideascube/ideascube/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ideascube/ideascube/teams","hooks_url":"https://api.github.com/repos/ideascube/ideascube/hooks","issue_events_url":"https://api.github.com/repos/ideascube/ideascube/issues/events{/number}","events_url":"https://api.github.com/repos/ideascube/ideascube/events","assignees_url":"https://api.github.com/repos/ideascube/ideascube/assignees{/user}","branches_url":"https://api.github.com/repos/ideascube/ideascube/branches{/branch}","tags_url":"https://api.github.com/repos/ideascube/ideascube/tags","blobs_url":"https://api.github.com/repos/ideascube/ideascube/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ideascube/ideascube/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ideascube/ideascube/git/refs{/sha}","trees_url":"https://api.github.com/repos/ideascube/ideascube/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ideascube/ideascube/statuses/{sha}","languages_url":"https://api.github.com/repos/ideascube/ideascube/languages","stargazers_url":"https://api.github.com/repos/ideascube/ideascube/stargazers","contributors_url":"https://api.github.com/repos/ideascube/ideascube/contributors","subscribers_url":"https://api.github.com/repos/ideascube/ideascube/subscribers","subscription_url":"https://api.github.com/repos/ideascube/ideascube/subscription","commits_url":"https://api.github.com/repos/ideascube/ideascube/commits{/sha}","git_commits_url":"https://api.github.com/repos/ideascube/ideascube/git/commits{/sha}","comments_url":"https://api.github.com/repos/ideascube/ideascube/comments{/number}","issue_comment_url":"https://api.github.com/repos/ideascube/ideascube/issues/comments{/number}","contents_url":"https://api.github.com/repos/ideascube/ideascube/contents/{+path}","compare_url":"https://api.github.com/repos/ideascube/ideascube/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ideascube/ideascube/merges","archive_url":"https://api.github.com/repos/ideascube/ideascube/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ideascube/ideascube/downloads","issues_url":"https://api.github.com/repos/ideascube/ideascube/issues{/number}","pulls_url":"https://api.github.com/repos/ideascube/ideascube/pulls{/number}","milestones_url":"https://api.github.com/repos/ideascube/ideascube/milestones{/number}","notifications_url":"https://api.github.com/repos/ideascube/ideascube/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ideascube/ideascube/labels{/name}","releases_url":"https://api.github.com/repos/ideascube/ideascube/releases{/id}","deployments_url":"https://api.github.com/repos/ideascube/ideascube/deployments","created_at":"2014-11-16T08:39:32Z","updated_at":"2016-08-01T09:12:34Z","pushed_at":"2016-08-26T13:36:56Z","git_url":"git://github.com/ideascube/ideascube.git","ssh_url":"git@github.com:ideascube/ideascube.git","clone_url":"https://github.com/ideascube/ideascube.git","svn_url":"https://github.com/ideascube/ideascube","homepage":"http://ideascube.readthedocs.org/","size":10565,"stargazers_count":21,"watchers_count":21,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":24,"mirror_url":null,"open_issues_count":137,"forks":24,"open_issues":137,"watchers":21,"default_branch":"master"}},"base":{"label":"ideascube:master","ref":"master","sha":"ca05685e3c97f06af343d72c898429f26a94deab","user":{"login":"ideascube","id":9719862,"avatar_url":"https://avatars.githubusercontent.com/u/9719862?v=3","gravatar_id":"","url":"https://api.github.com/users/ideascube","html_url":"https://github.com/ideascube","followers_url":"https://api.github.com/users/ideascube/followers","following_url":"https://api.github.com/users/ideascube/following{/other_user}","gists_url":"https://api.github.com/users/ideascube/gists{/gist_id}","starred_url":"https://api.github.com/users/ideascube/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ideascube/subscriptions","organizations_url":"https://api.github.com/users/ideascube/orgs","repos_url":"https://api.github.com/users/ideascube/repos","events_url":"https://api.github.com/users/ideascube/events{/privacy}","received_events_url":"https://api.github.com/users/ideascube/received_events","type":"Organization","site_admin":false},"repo":{"id":26708471,"name":"ideascube","full_name":"ideascube/ideascube","owner":{"login":"ideascube","id":9719862,"avatar_url":"https://avatars.githubusercontent.com/u/9719862?v=3","gravatar_id":"","url":"https://api.github.com/users/ideascube","html_url":"https://github.com/ideascube","followers_url":"https://api.github.com/users/ideascube/followers","following_url":"https://api.github.com/users/ideascube/following{/other_user}","gists_url":"https://api.github.com/users/ideascube/gists{/gist_id}","starred_url":"https://api.github.com/users/ideascube/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ideascube/subscriptions","organizations_url":"https://api.github.com/users/ideascube/orgs","repos_url":"https://api.github.com/users/ideascube/repos","events_url":"https://api.github.com/users/ideascube/events{/privacy}","received_events_url":"https://api.github.com/users/ideascube/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ideascube/ideascube","description":"Ideas Box server core application","fork":false,"url":"https://api.github.com/repos/ideascube/ideascube","forks_url":"https://api.github.com/repos/ideascube/ideascube/forks","keys_url":"https://api.github.com/repos/ideascube/ideascube/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ideascube/ideascube/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ideascube/ideascube/teams","hooks_url":"https://api.github.com/repos/ideascube/ideascube/hooks","issue_events_url":"https://api.github.com/repos/ideascube/ideascube/issues/events{/number}","events_url":"https://api.github.com/repos/ideascube/ideascube/events","assignees_url":"https://api.github.com/repos/ideascube/ideascube/assignees{/user}","branches_url":"https://api.github.com/repos/ideascube/ideascube/branches{/branch}","tags_url":"https://api.github.com/repos/ideascube/ideascube/tags","blobs_url":"https://api.github.com/repos/ideascube/ideascube/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ideascube/ideascube/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ideascube/ideascube/git/refs{/sha}","trees_url":"https://api.github.com/repos/ideascube/ideascube/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ideascube/ideascube/statuses/{sha}","languages_url":"https://api.github.com/repos/ideascube/ideascube/languages","stargazers_url":"https://api.github.com/repos/ideascube/ideascube/stargazers","contributors_url":"https://api.github.com/repos/ideascube/ideascube/contributors","subscribers_url":"https://api.github.com/repos/ideascube/ideascube/subscribers","subscription_url":"https://api.github.com/repos/ideascube/ideascube/subscription","commits_url":"https://api.github.com/repos/ideascube/ideascube/commits{/sha}","git_commits_url":"https://api.github.com/repos/ideascube/ideascube/git/commits{/sha}","comments_url":"https://api.github.com/repos/ideascube/ideascube/comments{/number}","issue_comment_url":"https://api.github.com/repos/ideascube/ideascube/issues/comments{/number}","contents_url":"https://api.github.com/repos/ideascube/ideascube/contents/{+path}","compare_url":"https://api.github.com/repos/ideascube/ideascube/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ideascube/ideascube/merges","archive_url":"https://api.github.com/repos/ideascube/ideascube/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ideascube/ideascube/downloads","issues_url":"https://api.github.com/repos/ideascube/ideascube/issues{/number}","pulls_url":"https://api.github.com/repos/ideascube/ideascube/pulls{/number}","milestones_url":"https://api.github.com/repos/ideascube/ideascube/milestones{/number}","notifications_url":"https://api.github.com/repos/ideascube/ideascube/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ideascube/ideascube/labels{/name}","releases_url":"https://api.github.com/repos/ideascube/ideascube/releases{/id}","deployments_url":"https://api.github.com/repos/ideascube/ideascube/deployments","created_at":"2014-11-16T08:39:32Z","updated_at":"2016-08-01T09:12:34Z","pushed_at":"2016-08-26T13:36:56Z","git_url":"git://github.com/ideascube/ideascube.git","ssh_url":"git@github.com:ideascube/ideascube.git","clone_url":"https://github.com/ideascube/ideascube.git","svn_url":"https://github.com/ideascube/ideascube","homepage":"http://ideascube.readthedocs.org/","size":10565,"stargazers_count":21,"watchers_count":21,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":24,"mirror_url":null,"open_issues_count":137,"forks":24,"open_issues":137,"watchers":21,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ideascube/ideascube/pulls/451"},"html":{"href":"https://github.com/ideascube/ideascube/pull/451"},"issue":{"href":"https://api.github.com/repos/ideascube/ideascube/issues/451"},"comments":{"href":"https://api.github.com/repos/ideascube/ideascube/issues/451/comments"},"review_comments":{"href":"https://api.github.com/repos/ideascube/ideascube/pulls/451/comments"},"review_comment":{"href":"https://api.github.com/repos/ideascube/ideascube/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ideascube/ideascube/pulls/451/commits"},"statuses":{"href":"https://api.github.com/repos/ideascube/ideascube/statuses/e47f25f0927fcac9fb52df3666ca0b0a4f633e89"}}}}
{"actor":{"display_login":"bochecha"}}