{"action":"created","comment":{"url":"https://api.github.com/repos/joblib/joblib/pulls/comments/92620446","pull_request_review_id":13139519,"id":92620446,"diff_hunk":"@@ -230,27 +200,27 @@ def test_numpy_persistence():\n \n \n @with_numpy\n-def test_numpy_persistence_bufferred_array_compression():\n+def test_numpy_persistence_bufferred_array_compression(tmpdir):\n     big_array = np.ones((_IO_BUFFER_SIZE + 100), dtype=np.uint8)\n-    filename = env['filename'] + str(random.randint(0, 1000))\n+    filename = tmpdir.join('test.pkl').strpath + str(random.randint(0, 1000))","path":"joblib/test/test_numpy_pickle.py","position":83,"original_position":83,"commit_id":"903e7bda0aca2716652356df9448180b06178646","original_commit_id":"903e7bda0aca2716652356df9448180b06178646","user":{"login":"lesteve","id":1680079,"avatar_url":"https://avatars.githubusercontent.com/u/1680079?v=3","gravatar_id":"","url":"https://api.github.com/users/lesteve","html_url":"https://github.com/lesteve","followers_url":"https://api.github.com/users/lesteve/followers","following_url":"https://api.github.com/users/lesteve/following{/other_user}","gists_url":"https://api.github.com/users/lesteve/gists{/gist_id}","starred_url":"https://api.github.com/users/lesteve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lesteve/subscriptions","organizations_url":"https://api.github.com/users/lesteve/orgs","repos_url":"https://api.github.com/users/lesteve/repos","events_url":"https://api.github.com/users/lesteve/events{/privacy}","received_events_url":"https://api.github.com/users/lesteve/received_events","type":"User","site_admin":false},"body":"I think it is better to use `tmpdir`. Because `tmpdir` is a function fixture you know that each test function is independent from each other.","created_at":"2016-12-15T14:38:45Z","updated_at":"2016-12-15T14:38:46Z","html_url":"https://github.com/joblib/joblib/pull/463#discussion_r92620446","pull_request_url":"https://api.github.com/repos/joblib/joblib/pulls/463","_links":{"self":{"href":"https://api.github.com/repos/joblib/joblib/pulls/comments/92620446"},"html":{"href":"https://github.com/joblib/joblib/pull/463#discussion_r92620446"},"pull_request":{"href":"https://api.github.com/repos/joblib/joblib/pulls/463"}}},"pull_request":{"url":"https://api.github.com/repos/joblib/joblib/pulls/463","id":98119476,"html_url":"https://github.com/joblib/joblib/pull/463","diff_url":"https://github.com/joblib/joblib/pull/463.diff","patch_url":"https://github.com/joblib/joblib/pull/463.patch","issue_url":"https://api.github.com/repos/joblib/joblib/issues/463","number":463,"state":"open","locked":false,"title":"[MRG] Replace manual setup / teardown of temp directory with 'tmpdir' fixture.","user":{"login":"karandesai-96","id":10494087,"avatar_url":"https://avatars.githubusercontent.com/u/10494087?v=3","gravatar_id":"","url":"https://api.github.com/users/karandesai-96","html_url":"https://github.com/karandesai-96","followers_url":"https://api.github.com/users/karandesai-96/followers","following_url":"https://api.github.com/users/karandesai-96/following{/other_user}","gists_url":"https://api.github.com/users/karandesai-96/gists{/gist_id}","starred_url":"https://api.github.com/users/karandesai-96/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/karandesai-96/subscriptions","organizations_url":"https://api.github.com/users/karandesai-96/orgs","repos_url":"https://api.github.com/users/karandesai-96/repos","events_url":"https://api.github.com/users/karandesai-96/events{/privacy}","received_events_url":"https://api.github.com/users/karandesai-96/received_events","type":"User","site_admin":false},"body":"#### Fourth Phase PR on #411 (Succeeding PR #461 )\r\n\r\nSeveral modules declare a setup and teardown where a temporary directory was created and its path was set as a global variable. Creation and deletion of this directory was handled manually while setup and teardown. This has been replaced by pytest's `tmpdir` fixture.\r\n\r\nIt is a `py.path.local` object, and has to be specified as a parameter in tests requiring a temporary directory.","created_at":"2016-12-15T10:04:05Z","updated_at":"2016-12-15T14:38:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"924bdfceb27b85aa70fb18c285a7d8ad559afa11","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/joblib/joblib/pulls/463/commits","review_comments_url":"https://api.github.com/repos/joblib/joblib/pulls/463/comments","review_comment_url":"https://api.github.com/repos/joblib/joblib/pulls/comments{/number}","comments_url":"https://api.github.com/repos/joblib/joblib/issues/463/comments","statuses_url":"https://api.github.com/repos/joblib/joblib/statuses/903e7bda0aca2716652356df9448180b06178646","head":{"label":"karandesai-96:use-tmpdir-everywhere","ref":"use-tmpdir-everywhere","sha":"903e7bda0aca2716652356df9448180b06178646","user":{"login":"karandesai-96","id":10494087,"avatar_url":"https://avatars.githubusercontent.com/u/10494087?v=3","gravatar_id":"","url":"https://api.github.com/users/karandesai-96","html_url":"https://github.com/karandesai-96","followers_url":"https://api.github.com/users/karandesai-96/followers","following_url":"https://api.github.com/users/karandesai-96/following{/other_user}","gists_url":"https://api.github.com/users/karandesai-96/gists{/gist_id}","starred_url":"https://api.github.com/users/karandesai-96/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/karandesai-96/subscriptions","organizations_url":"https://api.github.com/users/karandesai-96/orgs","repos_url":"https://api.github.com/users/karandesai-96/repos","events_url":"https://api.github.com/users/karandesai-96/events{/privacy}","received_events_url":"https://api.github.com/users/karandesai-96/received_events","type":"User","site_admin":false},"repo":{"id":72710695,"name":"joblib","full_name":"karandesai-96/joblib","owner":{"login":"karandesai-96","id":10494087,"avatar_url":"https://avatars.githubusercontent.com/u/10494087?v=3","gravatar_id":"","url":"https://api.github.com/users/karandesai-96","html_url":"https://github.com/karandesai-96","followers_url":"https://api.github.com/users/karandesai-96/followers","following_url":"https://api.github.com/users/karandesai-96/following{/other_user}","gists_url":"https://api.github.com/users/karandesai-96/gists{/gist_id}","starred_url":"https://api.github.com/users/karandesai-96/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/karandesai-96/subscriptions","organizations_url":"https://api.github.com/users/karandesai-96/orgs","repos_url":"https://api.github.com/users/karandesai-96/repos","events_url":"https://api.github.com/users/karandesai-96/events{/privacy}","received_events_url":"https://api.github.com/users/karandesai-96/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/karandesai-96/joblib","description":"Python function as pipeline jobs.","fork":true,"url":"https://api.github.com/repos/karandesai-96/joblib","forks_url":"https://api.github.com/repos/karandesai-96/joblib/forks","keys_url":"https://api.github.com/repos/karandesai-96/joblib/keys{/key_id}","collaborators_url":"https://api.github.com/repos/karandesai-96/joblib/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/karandesai-96/joblib/teams","hooks_url":"https://api.github.com/repos/karandesai-96/joblib/hooks","issue_events_url":"https://api.github.com/repos/karandesai-96/joblib/issues/events{/number}","events_url":"https://api.github.com/repos/karandesai-96/joblib/events","assignees_url":"https://api.github.com/repos/karandesai-96/joblib/assignees{/user}","branches_url":"https://api.github.com/repos/karandesai-96/joblib/branches{/branch}","tags_url":"https://api.github.com/repos/karandesai-96/joblib/tags","blobs_url":"https://api.github.com/repos/karandesai-96/joblib/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/karandesai-96/joblib/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/karandesai-96/joblib/git/refs{/sha}","trees_url":"https://api.github.com/repos/karandesai-96/joblib/git/trees{/sha}","statuses_url":"https://api.github.com/repos/karandesai-96/joblib/statuses/{sha}","languages_url":"https://api.github.com/repos/karandesai-96/joblib/languages","stargazers_url":"https://api.github.com/repos/karandesai-96/joblib/stargazers","contributors_url":"https://api.github.com/repos/karandesai-96/joblib/contributors","subscribers_url":"https://api.github.com/repos/karandesai-96/joblib/subscribers","subscription_url":"https://api.github.com/repos/karandesai-96/joblib/subscription","commits_url":"https://api.github.com/repos/karandesai-96/joblib/commits{/sha}","git_commits_url":"https://api.github.com/repos/karandesai-96/joblib/git/commits{/sha}","comments_url":"https://api.github.com/repos/karandesai-96/joblib/comments{/number}","issue_comment_url":"https://api.github.com/repos/karandesai-96/joblib/issues/comments{/number}","contents_url":"https://api.github.com/repos/karandesai-96/joblib/contents/{+path}","compare_url":"https://api.github.com/repos/karandesai-96/joblib/compare/{base}...{head}","merges_url":"https://api.github.com/repos/karandesai-96/joblib/merges","archive_url":"https://api.github.com/repos/karandesai-96/joblib/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/karandesai-96/joblib/downloads","issues_url":"https://api.github.com/repos/karandesai-96/joblib/issues{/number}","pulls_url":"https://api.github.com/repos/karandesai-96/joblib/pulls{/number}","milestones_url":"https://api.github.com/repos/karandesai-96/joblib/milestones{/number}","notifications_url":"https://api.github.com/repos/karandesai-96/joblib/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/karandesai-96/joblib/labels{/name}","releases_url":"https://api.github.com/repos/karandesai-96/joblib/releases{/id}","deployments_url":"https://api.github.com/repos/karandesai-96/joblib/deployments","created_at":"2016-11-03T05:08:11Z","updated_at":"2016-12-15T13:31:06Z","pushed_at":"2016-12-15T10:45:29Z","git_url":"git://github.com/karandesai-96/joblib.git","ssh_url":"git@github.com:karandesai-96/joblib.git","clone_url":"https://github.com/karandesai-96/joblib.git","svn_url":"https://github.com/karandesai-96/joblib","homepage":"http://packages.python.org/joblib/","size":2589,"stargazers_count":0,"watchers_count":0,"language":"Python","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":"joblib:master","ref":"master","sha":"aab21b654e853616b31c6e50255b2dcf47af5818","user":{"login":"joblib","id":332661,"avatar_url":"https://avatars.githubusercontent.com/u/332661?v=3","gravatar_id":"","url":"https://api.github.com/users/joblib","html_url":"https://github.com/joblib","followers_url":"https://api.github.com/users/joblib/followers","following_url":"https://api.github.com/users/joblib/following{/other_user}","gists_url":"https://api.github.com/users/joblib/gists{/gist_id}","starred_url":"https://api.github.com/users/joblib/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joblib/subscriptions","organizations_url":"https://api.github.com/users/joblib/orgs","repos_url":"https://api.github.com/users/joblib/repos","events_url":"https://api.github.com/users/joblib/events{/privacy}","received_events_url":"https://api.github.com/users/joblib/received_events","type":"Organization","site_admin":false},"repo":{"id":654608,"name":"joblib","full_name":"joblib/joblib","owner":{"login":"joblib","id":332661,"avatar_url":"https://avatars.githubusercontent.com/u/332661?v=3","gravatar_id":"","url":"https://api.github.com/users/joblib","html_url":"https://github.com/joblib","followers_url":"https://api.github.com/users/joblib/followers","following_url":"https://api.github.com/users/joblib/following{/other_user}","gists_url":"https://api.github.com/users/joblib/gists{/gist_id}","starred_url":"https://api.github.com/users/joblib/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joblib/subscriptions","organizations_url":"https://api.github.com/users/joblib/orgs","repos_url":"https://api.github.com/users/joblib/repos","events_url":"https://api.github.com/users/joblib/events{/privacy}","received_events_url":"https://api.github.com/users/joblib/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/joblib/joblib","description":"Python function as pipeline jobs.","fork":false,"url":"https://api.github.com/repos/joblib/joblib","forks_url":"https://api.github.com/repos/joblib/joblib/forks","keys_url":"https://api.github.com/repos/joblib/joblib/keys{/key_id}","collaborators_url":"https://api.github.com/repos/joblib/joblib/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/joblib/joblib/teams","hooks_url":"https://api.github.com/repos/joblib/joblib/hooks","issue_events_url":"https://api.github.com/repos/joblib/joblib/issues/events{/number}","events_url":"https://api.github.com/repos/joblib/joblib/events","assignees_url":"https://api.github.com/repos/joblib/joblib/assignees{/user}","branches_url":"https://api.github.com/repos/joblib/joblib/branches{/branch}","tags_url":"https://api.github.com/repos/joblib/joblib/tags","blobs_url":"https://api.github.com/repos/joblib/joblib/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/joblib/joblib/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/joblib/joblib/git/refs{/sha}","trees_url":"https://api.github.com/repos/joblib/joblib/git/trees{/sha}","statuses_url":"https://api.github.com/repos/joblib/joblib/statuses/{sha}","languages_url":"https://api.github.com/repos/joblib/joblib/languages","stargazers_url":"https://api.github.com/repos/joblib/joblib/stargazers","contributors_url":"https://api.github.com/repos/joblib/joblib/contributors","subscribers_url":"https://api.github.com/repos/joblib/joblib/subscribers","subscription_url":"https://api.github.com/repos/joblib/joblib/subscription","commits_url":"https://api.github.com/repos/joblib/joblib/commits{/sha}","git_commits_url":"https://api.github.com/repos/joblib/joblib/git/commits{/sha}","comments_url":"https://api.github.com/repos/joblib/joblib/comments{/number}","issue_comment_url":"https://api.github.com/repos/joblib/joblib/issues/comments{/number}","contents_url":"https://api.github.com/repos/joblib/joblib/contents/{+path}","compare_url":"https://api.github.com/repos/joblib/joblib/compare/{base}...{head}","merges_url":"https://api.github.com/repos/joblib/joblib/merges","archive_url":"https://api.github.com/repos/joblib/joblib/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/joblib/joblib/downloads","issues_url":"https://api.github.com/repos/joblib/joblib/issues{/number}","pulls_url":"https://api.github.com/repos/joblib/joblib/pulls{/number}","milestones_url":"https://api.github.com/repos/joblib/joblib/milestones{/number}","notifications_url":"https://api.github.com/repos/joblib/joblib/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/joblib/joblib/labels{/name}","releases_url":"https://api.github.com/repos/joblib/joblib/releases{/id}","deployments_url":"https://api.github.com/repos/joblib/joblib/deployments","created_at":"2010-05-07T06:48:26Z","updated_at":"2016-12-10T22:37:04Z","pushed_at":"2016-12-15T10:47:23Z","git_url":"git://github.com/joblib/joblib.git","ssh_url":"git@github.com:joblib/joblib.git","clone_url":"https://github.com/joblib/joblib.git","svn_url":"https://github.com/joblib/joblib","homepage":"http://packages.python.org/joblib/","size":2586,"stargazers_count":800,"watchers_count":800,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":124,"mirror_url":null,"open_issues_count":114,"forks":124,"open_issues":114,"watchers":800,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/joblib/joblib/pulls/463"},"html":{"href":"https://github.com/joblib/joblib/pull/463"},"issue":{"href":"https://api.github.com/repos/joblib/joblib/issues/463"},"comments":{"href":"https://api.github.com/repos/joblib/joblib/issues/463/comments"},"review_comments":{"href":"https://api.github.com/repos/joblib/joblib/pulls/463/comments"},"review_comment":{"href":"https://api.github.com/repos/joblib/joblib/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/joblib/joblib/pulls/463/commits"},"statuses":{"href":"https://api.github.com/repos/joblib/joblib/statuses/903e7bda0aca2716652356df9448180b06178646"}}}}
{"actor":{"display_login":"lesteve"}}