{"action":"created","comment":{"url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments/232167860","pull_request_review_id":173305413,"id":232167860,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMjE2Nzg2MA==","diff_hunk":"@@ -53,6 +63,29 @@ def read_logs(tmp_dir):\n \n     return heapq.merge(*[get_log_events(source, f) for source, f in files])\n \n+\n+def find_latest_test_dir():\n+    \"\"\"Returns the latest tmpfile test directory prefix.\"\"\"\n+    tmpdir = tempfile.gettempdir()\n+\n+    def join_tmp(basename):\n+        return os.path.join(tmpdir, basename)\n+\n+    testdir_paths = [\n+        join_tmp(name) for name in os.listdir(tmpdir) if\n+        os.path.isdir(join_tmp(name)) and is_test_dir_name(name)\n+    ]\n+\n+    testdir_paths.sort(key=lambda x: os.path.getmtime(x), reverse=True)","path":"test/functional/combine_logs.py","position":73,"original_position":73,"commit_id":"e2d9b2fec809971de4cfc67048995e33e7e4749c","original_commit_id":"e2d9b2fec809971de4cfc67048995e33e7e4749c","user":{"login":"practicalswift","id":7826565,"node_id":"MDQ6VXNlcjc4MjY1NjU=","avatar_url":"https://avatars3.githubusercontent.com/u/7826565?v=4","gravatar_id":"","url":"https://api.github.com/users/practicalswift","html_url":"https://github.com/practicalswift","followers_url":"https://api.github.com/users/practicalswift/followers","following_url":"https://api.github.com/users/practicalswift/following{/other_user}","gists_url":"https://api.github.com/users/practicalswift/gists{/gist_id}","starred_url":"https://api.github.com/users/practicalswift/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/practicalswift/subscriptions","organizations_url":"https://api.github.com/users/practicalswift/orgs","repos_url":"https://api.github.com/users/practicalswift/repos","events_url":"https://api.github.com/users/practicalswift/events{/privacy}","received_events_url":"https://api.github.com/users/practicalswift/received_events","type":"User","site_admin":false},"body":"Isn't the lambda redundant here? Could use `os.path.getmtime` directly?","created_at":"2018-11-09T08:05:50Z","updated_at":"2018-11-09T08:05:51Z","html_url":"https://github.com/bitcoin/bitcoin/pull/14683#discussion_r232167860","pull_request_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14683","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments/232167860"},"html":{"href":"https://github.com/bitcoin/bitcoin/pull/14683#discussion_r232167860"},"pull_request":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14683"}}},"pull_request":{"url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14683","id":229103500,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI5MTAzNTAw","html_url":"https://github.com/bitcoin/bitcoin/pull/14683","diff_url":"https://github.com/bitcoin/bitcoin/pull/14683.diff","patch_url":"https://github.com/bitcoin/bitcoin/pull/14683.patch","issue_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/14683","number":14683,"state":"open","locked":false,"title":"tests: better combine_logs.py behavior","user":{"login":"jamesob","id":73197,"node_id":"MDQ6VXNlcjczMTk3","avatar_url":"https://avatars0.githubusercontent.com/u/73197?v=4","gravatar_id":"","url":"https://api.github.com/users/jamesob","html_url":"https://github.com/jamesob","followers_url":"https://api.github.com/users/jamesob/followers","following_url":"https://api.github.com/users/jamesob/following{/other_user}","gists_url":"https://api.github.com/users/jamesob/gists{/gist_id}","starred_url":"https://api.github.com/users/jamesob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jamesob/subscriptions","organizations_url":"https://api.github.com/users/jamesob/orgs","repos_url":"https://api.github.com/users/jamesob/repos","events_url":"https://api.github.com/users/jamesob/events{/privacy}","received_events_url":"https://api.github.com/users/jamesob/received_events","type":"User","site_admin":false},"body":"Have `combine_logs.py` default to the most recent test directory if no argument is provided. This allows you to avoid an annoying copy-paste when iterating on a failing test, since you can do something like\r\n```sh\r\nalias testlogs='./test/functional/combine_logs.py -c | less'\r\n\r\n./test/functional/some_test.py  # fails\r\ntestlogs\r\n```","created_at":"2018-11-07T17:11:44Z","updated_at":"2018-11-09T08:05:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1cdf56204dea0d1eeabc0be17fc81e7ab0b3bf32","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":62963516,"node_id":"MDU6TGFiZWw2Mjk2MzUxNg==","url":"https://api.github.com/repos/bitcoin/bitcoin/labels/Tests","name":"Tests","color":"d4c5f9","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14683/commits","review_comments_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14683/comments","review_comment_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/14683/comments","statuses_url":"https://api.github.com/repos/bitcoin/bitcoin/statuses/e2d9b2fec809971de4cfc67048995e33e7e4749c","head":{"label":"jamesob:2018-11-better-cons-log","ref":"2018-11-better-cons-log","sha":"e2d9b2fec809971de4cfc67048995e33e7e4749c","user":{"login":"jamesob","id":73197,"node_id":"MDQ6VXNlcjczMTk3","avatar_url":"https://avatars0.githubusercontent.com/u/73197?v=4","gravatar_id":"","url":"https://api.github.com/users/jamesob","html_url":"https://github.com/jamesob","followers_url":"https://api.github.com/users/jamesob/followers","following_url":"https://api.github.com/users/jamesob/following{/other_user}","gists_url":"https://api.github.com/users/jamesob/gists{/gist_id}","starred_url":"https://api.github.com/users/jamesob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jamesob/subscriptions","organizations_url":"https://api.github.com/users/jamesob/orgs","repos_url":"https://api.github.com/users/jamesob/repos","events_url":"https://api.github.com/users/jamesob/events{/privacy}","received_events_url":"https://api.github.com/users/jamesob/received_events","type":"User","site_admin":false},"repo":{"id":42077031,"node_id":"MDEwOlJlcG9zaXRvcnk0MjA3NzAzMQ==","name":"bitcoin","full_name":"jamesob/bitcoin","private":false,"owner":{"login":"jamesob","id":73197,"node_id":"MDQ6VXNlcjczMTk3","avatar_url":"https://avatars0.githubusercontent.com/u/73197?v=4","gravatar_id":"","url":"https://api.github.com/users/jamesob","html_url":"https://github.com/jamesob","followers_url":"https://api.github.com/users/jamesob/followers","following_url":"https://api.github.com/users/jamesob/following{/other_user}","gists_url":"https://api.github.com/users/jamesob/gists{/gist_id}","starred_url":"https://api.github.com/users/jamesob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jamesob/subscriptions","organizations_url":"https://api.github.com/users/jamesob/orgs","repos_url":"https://api.github.com/users/jamesob/repos","events_url":"https://api.github.com/users/jamesob/events{/privacy}","received_events_url":"https://api.github.com/users/jamesob/received_events","type":"User","site_admin":false},"html_url":"https://github.com/jamesob/bitcoin","description":"Bitcoin Core integration/staging tree","fork":true,"url":"https://api.github.com/repos/jamesob/bitcoin","forks_url":"https://api.github.com/repos/jamesob/bitcoin/forks","keys_url":"https://api.github.com/repos/jamesob/bitcoin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jamesob/bitcoin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jamesob/bitcoin/teams","hooks_url":"https://api.github.com/repos/jamesob/bitcoin/hooks","issue_events_url":"https://api.github.com/repos/jamesob/bitcoin/issues/events{/number}","events_url":"https://api.github.com/repos/jamesob/bitcoin/events","assignees_url":"https://api.github.com/repos/jamesob/bitcoin/assignees{/user}","branches_url":"https://api.github.com/repos/jamesob/bitcoin/branches{/branch}","tags_url":"https://api.github.com/repos/jamesob/bitcoin/tags","blobs_url":"https://api.github.com/repos/jamesob/bitcoin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jamesob/bitcoin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jamesob/bitcoin/git/refs{/sha}","trees_url":"https://api.github.com/repos/jamesob/bitcoin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jamesob/bitcoin/statuses/{sha}","languages_url":"https://api.github.com/repos/jamesob/bitcoin/languages","stargazers_url":"https://api.github.com/repos/jamesob/bitcoin/stargazers","contributors_url":"https://api.github.com/repos/jamesob/bitcoin/contributors","subscribers_url":"https://api.github.com/repos/jamesob/bitcoin/subscribers","subscription_url":"https://api.github.com/repos/jamesob/bitcoin/subscription","commits_url":"https://api.github.com/repos/jamesob/bitcoin/commits{/sha}","git_commits_url":"https://api.github.com/repos/jamesob/bitcoin/git/commits{/sha}","comments_url":"https://api.github.com/repos/jamesob/bitcoin/comments{/number}","issue_comment_url":"https://api.github.com/repos/jamesob/bitcoin/issues/comments{/number}","contents_url":"https://api.github.com/repos/jamesob/bitcoin/contents/{+path}","compare_url":"https://api.github.com/repos/jamesob/bitcoin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jamesob/bitcoin/merges","archive_url":"https://api.github.com/repos/jamesob/bitcoin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jamesob/bitcoin/downloads","issues_url":"https://api.github.com/repos/jamesob/bitcoin/issues{/number}","pulls_url":"https://api.github.com/repos/jamesob/bitcoin/pulls{/number}","milestones_url":"https://api.github.com/repos/jamesob/bitcoin/milestones{/number}","notifications_url":"https://api.github.com/repos/jamesob/bitcoin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jamesob/bitcoin/labels{/name}","releases_url":"https://api.github.com/repos/jamesob/bitcoin/releases{/id}","deployments_url":"https://api.github.com/repos/jamesob/bitcoin/deployments","created_at":"2015-09-07T22:18:03Z","updated_at":"2018-11-07T16:12:39Z","pushed_at":"2018-11-07T21:38:46Z","git_url":"git://github.com/jamesob/bitcoin.git","ssh_url":"git@github.com:jamesob/bitcoin.git","clone_url":"https://github.com/jamesob/bitcoin.git","svn_url":"https://github.com/jamesob/bitcoin","homepage":"https://bitcoin.org/en/download","size":117076,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"bitcoin:master","ref":"master","sha":"e8d490f27e691d8e5f6910f878c4f1c3c6ad788d","user":{"login":"bitcoin","id":528860,"node_id":"MDEyOk9yZ2FuaXphdGlvbjUyODg2MA==","avatar_url":"https://avatars2.githubusercontent.com/u/528860?v=4","gravatar_id":"","url":"https://api.github.com/users/bitcoin","html_url":"https://github.com/bitcoin","followers_url":"https://api.github.com/users/bitcoin/followers","following_url":"https://api.github.com/users/bitcoin/following{/other_user}","gists_url":"https://api.github.com/users/bitcoin/gists{/gist_id}","starred_url":"https://api.github.com/users/bitcoin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bitcoin/subscriptions","organizations_url":"https://api.github.com/users/bitcoin/orgs","repos_url":"https://api.github.com/users/bitcoin/repos","events_url":"https://api.github.com/users/bitcoin/events{/privacy}","received_events_url":"https://api.github.com/users/bitcoin/received_events","type":"Organization","site_admin":false},"repo":{"id":1181927,"node_id":"MDEwOlJlcG9zaXRvcnkxMTgxOTI3","name":"bitcoin","full_name":"bitcoin/bitcoin","private":false,"owner":{"login":"bitcoin","id":528860,"node_id":"MDEyOk9yZ2FuaXphdGlvbjUyODg2MA==","avatar_url":"https://avatars2.githubusercontent.com/u/528860?v=4","gravatar_id":"","url":"https://api.github.com/users/bitcoin","html_url":"https://github.com/bitcoin","followers_url":"https://api.github.com/users/bitcoin/followers","following_url":"https://api.github.com/users/bitcoin/following{/other_user}","gists_url":"https://api.github.com/users/bitcoin/gists{/gist_id}","starred_url":"https://api.github.com/users/bitcoin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bitcoin/subscriptions","organizations_url":"https://api.github.com/users/bitcoin/orgs","repos_url":"https://api.github.com/users/bitcoin/repos","events_url":"https://api.github.com/users/bitcoin/events{/privacy}","received_events_url":"https://api.github.com/users/bitcoin/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/bitcoin/bitcoin","description":"Bitcoin Core integration/staging tree","fork":false,"url":"https://api.github.com/repos/bitcoin/bitcoin","forks_url":"https://api.github.com/repos/bitcoin/bitcoin/forks","keys_url":"https://api.github.com/repos/bitcoin/bitcoin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bitcoin/bitcoin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bitcoin/bitcoin/teams","hooks_url":"https://api.github.com/repos/bitcoin/bitcoin/hooks","issue_events_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/events{/number}","events_url":"https://api.github.com/repos/bitcoin/bitcoin/events","assignees_url":"https://api.github.com/repos/bitcoin/bitcoin/assignees{/user}","branches_url":"https://api.github.com/repos/bitcoin/bitcoin/branches{/branch}","tags_url":"https://api.github.com/repos/bitcoin/bitcoin/tags","blobs_url":"https://api.github.com/repos/bitcoin/bitcoin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bitcoin/bitcoin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bitcoin/bitcoin/git/refs{/sha}","trees_url":"https://api.github.com/repos/bitcoin/bitcoin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bitcoin/bitcoin/statuses/{sha}","languages_url":"https://api.github.com/repos/bitcoin/bitcoin/languages","stargazers_url":"https://api.github.com/repos/bitcoin/bitcoin/stargazers","contributors_url":"https://api.github.com/repos/bitcoin/bitcoin/contributors","subscribers_url":"https://api.github.com/repos/bitcoin/bitcoin/subscribers","subscription_url":"https://api.github.com/repos/bitcoin/bitcoin/subscription","commits_url":"https://api.github.com/repos/bitcoin/bitcoin/commits{/sha}","git_commits_url":"https://api.github.com/repos/bitcoin/bitcoin/git/commits{/sha}","comments_url":"https://api.github.com/repos/bitcoin/bitcoin/comments{/number}","issue_comment_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/comments{/number}","contents_url":"https://api.github.com/repos/bitcoin/bitcoin/contents/{+path}","compare_url":"https://api.github.com/repos/bitcoin/bitcoin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bitcoin/bitcoin/merges","archive_url":"https://api.github.com/repos/bitcoin/bitcoin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bitcoin/bitcoin/downloads","issues_url":"https://api.github.com/repos/bitcoin/bitcoin/issues{/number}","pulls_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls{/number}","milestones_url":"https://api.github.com/repos/bitcoin/bitcoin/milestones{/number}","notifications_url":"https://api.github.com/repos/bitcoin/bitcoin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bitcoin/bitcoin/labels{/name}","releases_url":"https://api.github.com/repos/bitcoin/bitcoin/releases{/id}","deployments_url":"https://api.github.com/repos/bitcoin/bitcoin/deployments","created_at":"2010-12-19T15:16:43Z","updated_at":"2018-11-09T07:35:48Z","pushed_at":"2018-11-09T05:55:08Z","git_url":"git://github.com/bitcoin/bitcoin.git","ssh_url":"git@github.com:bitcoin/bitcoin.git","clone_url":"https://github.com/bitcoin/bitcoin.git","svn_url":"https://github.com/bitcoin/bitcoin","homepage":"https://bitcoincore.org/en/download","size":116755,"stargazers_count":35797,"watchers_count":35797,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":21317,"mirror_url":null,"archived":false,"open_issues_count":871,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":21317,"open_issues":871,"watchers":35797,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14683"},"html":{"href":"https://github.com/bitcoin/bitcoin/pull/14683"},"issue":{"href":"https://api.github.com/repos/bitcoin/bitcoin/issues/14683"},"comments":{"href":"https://api.github.com/repos/bitcoin/bitcoin/issues/14683/comments"},"review_comments":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14683/comments"},"review_comment":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14683/commits"},"statuses":{"href":"https://api.github.com/repos/bitcoin/bitcoin/statuses/e2d9b2fec809971de4cfc67048995e33e7e4749c"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"practicalswift"}}