{"action":"created","comment":{"url":"https://api.github.com/repos/avocado-framework/avocado/pulls/comments/175135126","pull_request_review_id":104621147,"id":175135126,"diff_hunk":"@@ -39,7 +39,33 @@ def _find_simple_test_candidates(candidates=None):\n     def test_job_empty_suite(self):\n         args = argparse.Namespace(base_logdir=self.tmpdir)\n         self.job = job.Job(args)\n-        self.assertIsNone(self.job.test_suite)\n+        # Job without setup called\n+        none_attrs = (\"logdir\", \"replay_sourcejob\", \"result\", \"sysinfo\",\n+                      \"test_runner\", \"test_suite\", \"tmpdir\")\n+        for attr in none_attrs:\n+            self.assertIsNone(getattr(self.job, attr), \"job.%s is not None \"\n+                              \"(%s)\" % (attr, getattr(self.job, attr)))\n+        self.assertEquals(self.job.args, args)\n+        self.assertEquals(self.job.exitcode, exit_codes.AVOCADO_ALL_OK)\n+        self.assertEquals(self.job.references, [])\n+        self.assertEquals(self.job.status, \"RUNNING\")\n+        uid = self.job.unique_id\n+\n+        # Job with setup called\n+        self.job.setup()\n+        self.assertTrue(self.job.logdir)","path":"selftests/unit/test_job.py","position":29,"original_position":19,"commit_id":"2617aa2e7e592333d02b9ed15c0156e1a311d911","original_commit_id":"f174fe1990bd59e694c5298e9d1194914f080c5f","user":{"login":"ldoktor","id":1074021,"avatar_url":"https://avatars3.githubusercontent.com/u/1074021?v=4","gravatar_id":"","url":"https://api.github.com/users/ldoktor","html_url":"https://github.com/ldoktor","followers_url":"https://api.github.com/users/ldoktor/followers","following_url":"https://api.github.com/users/ldoktor/following{/other_user}","gists_url":"https://api.github.com/users/ldoktor/gists{/gist_id}","starred_url":"https://api.github.com/users/ldoktor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ldoktor/subscriptions","organizations_url":"https://api.github.com/users/ldoktor/orgs","repos_url":"https://api.github.com/users/ldoktor/repos","events_url":"https://api.github.com/users/ldoktor/events{/privacy}","received_events_url":"https://api.github.com/users/ldoktor/received_events","type":"User","site_admin":false},"body":"I'm not sure which `None` you have in mind :-/","created_at":"2018-03-16T15:55:22Z","updated_at":"2018-03-16T15:55:22Z","html_url":"https://github.com/avocado-framework/avocado/pull/2465#discussion_r175135126","pull_request_url":"https://api.github.com/repos/avocado-framework/avocado/pulls/2465","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/avocado-framework/avocado/pulls/comments/175135126"},"html":{"href":"https://github.com/avocado-framework/avocado/pull/2465#discussion_r175135126"},"pull_request":{"href":"https://api.github.com/repos/avocado-framework/avocado/pulls/2465"}},"in_reply_to_id":175107447},"pull_request":{"url":"https://api.github.com/repos/avocado-framework/avocado/pulls/2465","id":170139841,"html_url":"https://github.com/avocado-framework/avocado/pull/2465","diff_url":"https://github.com/avocado-framework/avocado/pull/2465.diff","patch_url":"https://github.com/avocado-framework/avocado/pull/2465.patch","issue_url":"https://api.github.com/repos/avocado-framework/avocado/issues/2465","number":2465,"state":"open","locked":false,"title":"avocado.core.job: Provide per-job tmpdir [v2]","user":{"login":"ldoktor","id":1074021,"avatar_url":"https://avatars3.githubusercontent.com/u/1074021?v=4","gravatar_id":"","url":"https://api.github.com/users/ldoktor","html_url":"https://github.com/ldoktor","followers_url":"https://api.github.com/users/ldoktor/followers","following_url":"https://api.github.com/users/ldoktor/following{/other_user}","gists_url":"https://api.github.com/users/ldoktor/gists{/gist_id}","starred_url":"https://api.github.com/users/ldoktor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ldoktor/subscriptions","organizations_url":"https://api.github.com/users/ldoktor/orgs","repos_url":"https://api.github.com/users/ldoktor/repos","events_url":"https://api.github.com/users/ldoktor/events{/privacy}","received_events_url":"https://api.github.com/users/ldoktor/received_events","type":"User","site_admin":false},"body":"Historically the `avocado.core.job.Job` uses `datadir.get_tmp_dir` to get the job tmpdir, which (together with tmpdir cleanup and check) disallows the use of multiple jobs within one python interpreter. Let's create a job tmpdir there instead to allow that.\r\n\r\nThis unveiled how much handlers and temporary settings Job produces so there is an extra commit to require `Job.setup` and `Job.cleanup` calls manually to explicitly define where those handlers are in use.\r\n\r\nv1: https://github.com/avocado-framework/avocado/pull/2436\r\n\r\nChanges:\r\n\r\n```yaml\r\nv2: Use `datadir.get_tmp_dir` directly in Job instead of optional argument\r\nv2: Added commit to require to call setup/cleanup manually\r\nv2: Added extra commit to remove unnecessary srcdir hack\r\n```","created_at":"2018-02-20T09:35:05Z","updated_at":"2018-03-16T15:55:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a0ea565c1aa2051b07a6dec1f458c594453405b2","assignee":{"login":"clebergnu","id":447178,"avatar_url":"https://avatars1.githubusercontent.com/u/447178?v=4","gravatar_id":"","url":"https://api.github.com/users/clebergnu","html_url":"https://github.com/clebergnu","followers_url":"https://api.github.com/users/clebergnu/followers","following_url":"https://api.github.com/users/clebergnu/following{/other_user}","gists_url":"https://api.github.com/users/clebergnu/gists{/gist_id}","starred_url":"https://api.github.com/users/clebergnu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/clebergnu/subscriptions","organizations_url":"https://api.github.com/users/clebergnu/orgs","repos_url":"https://api.github.com/users/clebergnu/repos","events_url":"https://api.github.com/users/clebergnu/events{/privacy}","received_events_url":"https://api.github.com/users/clebergnu/received_events","type":"User","site_admin":false},"assignees":[{"login":"clebergnu","id":447178,"avatar_url":"https://avatars1.githubusercontent.com/u/447178?v=4","gravatar_id":"","url":"https://api.github.com/users/clebergnu","html_url":"https://github.com/clebergnu","followers_url":"https://api.github.com/users/clebergnu/followers","following_url":"https://api.github.com/users/clebergnu/following{/other_user}","gists_url":"https://api.github.com/users/clebergnu/gists{/gist_id}","starred_url":"https://api.github.com/users/clebergnu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/clebergnu/subscriptions","organizations_url":"https://api.github.com/users/clebergnu/orgs","repos_url":"https://api.github.com/users/clebergnu/repos","events_url":"https://api.github.com/users/clebergnu/events{/privacy}","received_events_url":"https://api.github.com/users/clebergnu/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/avocado-framework/avocado/pulls/2465/commits","review_comments_url":"https://api.github.com/repos/avocado-framework/avocado/pulls/2465/comments","review_comment_url":"https://api.github.com/repos/avocado-framework/avocado/pulls/comments{/number}","comments_url":"https://api.github.com/repos/avocado-framework/avocado/issues/2465/comments","statuses_url":"https://api.github.com/repos/avocado-framework/avocado/statuses/2617aa2e7e592333d02b9ed15c0156e1a311d911","head":{"label":"ldoktor:multiple-tmpdirs2","ref":"multiple-tmpdirs2","sha":"2617aa2e7e592333d02b9ed15c0156e1a311d911","user":{"login":"ldoktor","id":1074021,"avatar_url":"https://avatars3.githubusercontent.com/u/1074021?v=4","gravatar_id":"","url":"https://api.github.com/users/ldoktor","html_url":"https://github.com/ldoktor","followers_url":"https://api.github.com/users/ldoktor/followers","following_url":"https://api.github.com/users/ldoktor/following{/other_user}","gists_url":"https://api.github.com/users/ldoktor/gists{/gist_id}","starred_url":"https://api.github.com/users/ldoktor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ldoktor/subscriptions","organizations_url":"https://api.github.com/users/ldoktor/orgs","repos_url":"https://api.github.com/users/ldoktor/repos","events_url":"https://api.github.com/users/ldoktor/events{/privacy}","received_events_url":"https://api.github.com/users/ldoktor/received_events","type":"User","site_admin":false},"repo":{"id":26808700,"name":"avocado","full_name":"ldoktor/avocado","owner":{"login":"ldoktor","id":1074021,"avatar_url":"https://avatars3.githubusercontent.com/u/1074021?v=4","gravatar_id":"","url":"https://api.github.com/users/ldoktor","html_url":"https://github.com/ldoktor","followers_url":"https://api.github.com/users/ldoktor/followers","following_url":"https://api.github.com/users/ldoktor/following{/other_user}","gists_url":"https://api.github.com/users/ldoktor/gists{/gist_id}","starred_url":"https://api.github.com/users/ldoktor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ldoktor/subscriptions","organizations_url":"https://api.github.com/users/ldoktor/orgs","repos_url":"https://api.github.com/users/ldoktor/repos","events_url":"https://api.github.com/users/ldoktor/events{/privacy}","received_events_url":"https://api.github.com/users/ldoktor/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ldoktor/avocado","description":"Avocado Test Framework","fork":true,"url":"https://api.github.com/repos/ldoktor/avocado","forks_url":"https://api.github.com/repos/ldoktor/avocado/forks","keys_url":"https://api.github.com/repos/ldoktor/avocado/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ldoktor/avocado/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ldoktor/avocado/teams","hooks_url":"https://api.github.com/repos/ldoktor/avocado/hooks","issue_events_url":"https://api.github.com/repos/ldoktor/avocado/issues/events{/number}","events_url":"https://api.github.com/repos/ldoktor/avocado/events","assignees_url":"https://api.github.com/repos/ldoktor/avocado/assignees{/user}","branches_url":"https://api.github.com/repos/ldoktor/avocado/branches{/branch}","tags_url":"https://api.github.com/repos/ldoktor/avocado/tags","blobs_url":"https://api.github.com/repos/ldoktor/avocado/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ldoktor/avocado/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ldoktor/avocado/git/refs{/sha}","trees_url":"https://api.github.com/repos/ldoktor/avocado/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ldoktor/avocado/statuses/{sha}","languages_url":"https://api.github.com/repos/ldoktor/avocado/languages","stargazers_url":"https://api.github.com/repos/ldoktor/avocado/stargazers","contributors_url":"https://api.github.com/repos/ldoktor/avocado/contributors","subscribers_url":"https://api.github.com/repos/ldoktor/avocado/subscribers","subscription_url":"https://api.github.com/repos/ldoktor/avocado/subscription","commits_url":"https://api.github.com/repos/ldoktor/avocado/commits{/sha}","git_commits_url":"https://api.github.com/repos/ldoktor/avocado/git/commits{/sha}","comments_url":"https://api.github.com/repos/ldoktor/avocado/comments{/number}","issue_comment_url":"https://api.github.com/repos/ldoktor/avocado/issues/comments{/number}","contents_url":"https://api.github.com/repos/ldoktor/avocado/contents/{+path}","compare_url":"https://api.github.com/repos/ldoktor/avocado/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ldoktor/avocado/merges","archive_url":"https://api.github.com/repos/ldoktor/avocado/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ldoktor/avocado/downloads","issues_url":"https://api.github.com/repos/ldoktor/avocado/issues{/number}","pulls_url":"https://api.github.com/repos/ldoktor/avocado/pulls{/number}","milestones_url":"https://api.github.com/repos/ldoktor/avocado/milestones{/number}","notifications_url":"https://api.github.com/repos/ldoktor/avocado/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ldoktor/avocado/labels{/name}","releases_url":"https://api.github.com/repos/ldoktor/avocado/releases{/id}","deployments_url":"https://api.github.com/repos/ldoktor/avocado/deployments","created_at":"2014-11-18T12:42:43Z","updated_at":"2017-04-24T13:33:47Z","pushed_at":"2018-03-16T09:18:34Z","git_url":"git://github.com/ldoktor/avocado.git","ssh_url":"git@github.com:ldoktor/avocado.git","clone_url":"https://github.com/ldoktor/avocado.git","svn_url":"https://github.com/ldoktor/avocado","homepage":"http://avocado-framework.readthedocs.org/en/latest/","size":12687,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"avocado-framework:master","ref":"master","sha":"bba095904a02b20c6626cf23f814e9dfaf066999","user":{"login":"avocado-framework","id":7245719,"avatar_url":"https://avatars3.githubusercontent.com/u/7245719?v=4","gravatar_id":"","url":"https://api.github.com/users/avocado-framework","html_url":"https://github.com/avocado-framework","followers_url":"https://api.github.com/users/avocado-framework/followers","following_url":"https://api.github.com/users/avocado-framework/following{/other_user}","gists_url":"https://api.github.com/users/avocado-framework/gists{/gist_id}","starred_url":"https://api.github.com/users/avocado-framework/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/avocado-framework/subscriptions","organizations_url":"https://api.github.com/users/avocado-framework/orgs","repos_url":"https://api.github.com/users/avocado-framework/repos","events_url":"https://api.github.com/users/avocado-framework/events{/privacy}","received_events_url":"https://api.github.com/users/avocado-framework/received_events","type":"Organization","site_admin":false},"repo":{"id":17449498,"name":"avocado","full_name":"avocado-framework/avocado","owner":{"login":"avocado-framework","id":7245719,"avatar_url":"https://avatars3.githubusercontent.com/u/7245719?v=4","gravatar_id":"","url":"https://api.github.com/users/avocado-framework","html_url":"https://github.com/avocado-framework","followers_url":"https://api.github.com/users/avocado-framework/followers","following_url":"https://api.github.com/users/avocado-framework/following{/other_user}","gists_url":"https://api.github.com/users/avocado-framework/gists{/gist_id}","starred_url":"https://api.github.com/users/avocado-framework/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/avocado-framework/subscriptions","organizations_url":"https://api.github.com/users/avocado-framework/orgs","repos_url":"https://api.github.com/users/avocado-framework/repos","events_url":"https://api.github.com/users/avocado-framework/events{/privacy}","received_events_url":"https://api.github.com/users/avocado-framework/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/avocado-framework/avocado","description":"Avocado Test Framework","fork":false,"url":"https://api.github.com/repos/avocado-framework/avocado","forks_url":"https://api.github.com/repos/avocado-framework/avocado/forks","keys_url":"https://api.github.com/repos/avocado-framework/avocado/keys{/key_id}","collaborators_url":"https://api.github.com/repos/avocado-framework/avocado/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/avocado-framework/avocado/teams","hooks_url":"https://api.github.com/repos/avocado-framework/avocado/hooks","issue_events_url":"https://api.github.com/repos/avocado-framework/avocado/issues/events{/number}","events_url":"https://api.github.com/repos/avocado-framework/avocado/events","assignees_url":"https://api.github.com/repos/avocado-framework/avocado/assignees{/user}","branches_url":"https://api.github.com/repos/avocado-framework/avocado/branches{/branch}","tags_url":"https://api.github.com/repos/avocado-framework/avocado/tags","blobs_url":"https://api.github.com/repos/avocado-framework/avocado/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/avocado-framework/avocado/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/avocado-framework/avocado/git/refs{/sha}","trees_url":"https://api.github.com/repos/avocado-framework/avocado/git/trees{/sha}","statuses_url":"https://api.github.com/repos/avocado-framework/avocado/statuses/{sha}","languages_url":"https://api.github.com/repos/avocado-framework/avocado/languages","stargazers_url":"https://api.github.com/repos/avocado-framework/avocado/stargazers","contributors_url":"https://api.github.com/repos/avocado-framework/avocado/contributors","subscribers_url":"https://api.github.com/repos/avocado-framework/avocado/subscribers","subscription_url":"https://api.github.com/repos/avocado-framework/avocado/subscription","commits_url":"https://api.github.com/repos/avocado-framework/avocado/commits{/sha}","git_commits_url":"https://api.github.com/repos/avocado-framework/avocado/git/commits{/sha}","comments_url":"https://api.github.com/repos/avocado-framework/avocado/comments{/number}","issue_comment_url":"https://api.github.com/repos/avocado-framework/avocado/issues/comments{/number}","contents_url":"https://api.github.com/repos/avocado-framework/avocado/contents/{+path}","compare_url":"https://api.github.com/repos/avocado-framework/avocado/compare/{base}...{head}","merges_url":"https://api.github.com/repos/avocado-framework/avocado/merges","archive_url":"https://api.github.com/repos/avocado-framework/avocado/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/avocado-framework/avocado/downloads","issues_url":"https://api.github.com/repos/avocado-framework/avocado/issues{/number}","pulls_url":"https://api.github.com/repos/avocado-framework/avocado/pulls{/number}","milestones_url":"https://api.github.com/repos/avocado-framework/avocado/milestones{/number}","notifications_url":"https://api.github.com/repos/avocado-framework/avocado/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/avocado-framework/avocado/labels{/name}","releases_url":"https://api.github.com/repos/avocado-framework/avocado/releases{/id}","deployments_url":"https://api.github.com/repos/avocado-framework/avocado/deployments","created_at":"2014-03-05T17:52:27Z","updated_at":"2018-03-16T02:47:43Z","pushed_at":"2018-03-16T12:54:46Z","git_url":"git://github.com/avocado-framework/avocado.git","ssh_url":"git@github.com:avocado-framework/avocado.git","clone_url":"https://github.com/avocado-framework/avocado.git","svn_url":"https://github.com/avocado-framework/avocado","homepage":"http://avocado-framework.github.io/","size":11983,"stargazers_count":144,"watchers_count":144,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":157,"mirror_url":null,"archived":false,"open_issues_count":30,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":157,"open_issues":30,"watchers":144,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/avocado-framework/avocado/pulls/2465"},"html":{"href":"https://github.com/avocado-framework/avocado/pull/2465"},"issue":{"href":"https://api.github.com/repos/avocado-framework/avocado/issues/2465"},"comments":{"href":"https://api.github.com/repos/avocado-framework/avocado/issues/2465/comments"},"review_comments":{"href":"https://api.github.com/repos/avocado-framework/avocado/pulls/2465/comments"},"review_comment":{"href":"https://api.github.com/repos/avocado-framework/avocado/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/avocado-framework/avocado/pulls/2465/commits"},"statuses":{"href":"https://api.github.com/repos/avocado-framework/avocado/statuses/2617aa2e7e592333d02b9ed15c0156e1a311d911"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"ldoktor"}}