{"action":"created","comment":{"url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments/279476692","pull_request_review_id":231822959,"id":279476692,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDI3OTQ3NjY5Mg==","diff_hunk":"@@ -55,13 +42,14 @@ def generate_test_data(self, filename):\n         mocktime = time.time()","path":"test/functional/rpc_getblockstats.py","position":30,"original_position":30,"commit_id":"293cb0e2ee8029df2d49d0bdf5c025396116aa77","original_commit_id":"293cb0e2ee8029df2d49d0bdf5c025396116aa77","user":{"login":"MarcoFalke","id":6399679,"node_id":"MDQ6VXNlcjYzOTk2Nzk=","avatar_url":"https://avatars0.githubusercontent.com/u/6399679?v=4","gravatar_id":"","url":"https://api.github.com/users/MarcoFalke","html_url":"https://github.com/MarcoFalke","followers_url":"https://api.github.com/users/MarcoFalke/followers","following_url":"https://api.github.com/users/MarcoFalke/following{/other_user}","gists_url":"https://api.github.com/users/MarcoFalke/gists{/gist_id}","starred_url":"https://api.github.com/users/MarcoFalke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarcoFalke/subscriptions","organizations_url":"https://api.github.com/users/MarcoFalke/orgs","repos_url":"https://api.github.com/users/MarcoFalke/repos","events_url":"https://api.github.com/users/MarcoFalke/events{/privacy}","received_events_url":"https://api.github.com/users/MarcoFalke/received_events","type":"User","site_admin":false},"body":"```suggestion\r\n        mocktime = 1525107225\r\n```\r\n\r\nnit: could set mocktime to the previous value, so that similar data is generated?","created_at":"2019-04-29T18:10:06Z","updated_at":"2019-04-29T18:21:21Z","html_url":"https://github.com/bitcoin/bitcoin/pull/14802#discussion_r279476692","pull_request_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14802","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments/279476692"},"html":{"href":"https://github.com/bitcoin/bitcoin/pull/14802#discussion_r279476692"},"pull_request":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14802"}}},"pull_request":{"url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14802","id":233401181,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMzNDAxMTgx","html_url":"https://github.com/bitcoin/bitcoin/pull/14802","diff_url":"https://github.com/bitcoin/bitcoin/pull/14802.diff","patch_url":"https://github.com/bitcoin/bitcoin/pull/14802.patch","issue_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/14802","number":14802,"state":"open","locked":false,"title":"rpc: faster getblockstats using BlockUndo data","user":{"login":"FelixWeis","id":551068,"node_id":"MDQ6VXNlcjU1MTA2OA==","avatar_url":"https://avatars2.githubusercontent.com/u/551068?v=4","gravatar_id":"","url":"https://api.github.com/users/FelixWeis","html_url":"https://github.com/FelixWeis","followers_url":"https://api.github.com/users/FelixWeis/followers","following_url":"https://api.github.com/users/FelixWeis/following{/other_user}","gists_url":"https://api.github.com/users/FelixWeis/gists{/gist_id}","starred_url":"https://api.github.com/users/FelixWeis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FelixWeis/subscriptions","organizations_url":"https://api.github.com/users/FelixWeis/orgs","repos_url":"https://api.github.com/users/FelixWeis/repos","events_url":"https://api.github.com/users/FelixWeis/events{/privacy}","received_events_url":"https://api.github.com/users/FelixWeis/received_events","type":"User","site_admin":false},"body":"Using undo data for a block (rev?????.dat) we can retrieve value information about prevouts and calculate the final transaction fee (rate). This approach is about 80x faster, drops the requirement for `-txindex`, and works for all non-pruned blocks.\r\n\r\n```\r\n# 2018-11-25T16:36:19Z Bitcoin Core version v0.17.99.0-edc715240-dirty (release build)\r\nseq 550100 550200  0.00s user 0.00s system 62% cpu 0.004 total\r\nxargs -n1 src/bitcoin-cli getblockstats  0.21s user 0.19s system 17% cpu 2.302 total\r\n\r\n\r\n# 2018-11-25T16:39:17Z Bitcoin Core version v0.17.0 (release build)\r\nseq 550100 550200  0.00s user 0.00s system 87% cpu 0.002 total\r\nxargs -n1 src/bitcoin-cli getblockstats  0.24s user 0.22s system 0% cpu 3:19.42 total\r\n```","created_at":"2018-11-25T21:14:03Z","updated_at":"2019-04-29T18:21:21Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1efbb6fafa3646440111cd25ae14e1a3220a6445","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":98279177,"node_id":"MDU6TGFiZWw5ODI3OTE3Nw==","url":"https://api.github.com/repos/bitcoin/bitcoin/labels/RPC/REST/ZMQ","name":"RPC/REST/ZMQ","color":"0052cc","default":false}],"milestone":{"url":"https://api.github.com/repos/bitcoin/bitcoin/milestones/37","html_url":"https://github.com/bitcoin/bitcoin/milestone/37","labels_url":"https://api.github.com/repos/bitcoin/bitcoin/milestones/37/labels","id":3391434,"node_id":"MDk6TWlsZXN0b25lMzM5MTQzNA==","number":37,"title":"0.19.0","description":null,"creator":{"login":"MarcoFalke","id":6399679,"node_id":"MDQ6VXNlcjYzOTk2Nzk=","avatar_url":"https://avatars0.githubusercontent.com/u/6399679?v=4","gravatar_id":"","url":"https://api.github.com/users/MarcoFalke","html_url":"https://github.com/MarcoFalke","followers_url":"https://api.github.com/users/MarcoFalke/followers","following_url":"https://api.github.com/users/MarcoFalke/following{/other_user}","gists_url":"https://api.github.com/users/MarcoFalke/gists{/gist_id}","starred_url":"https://api.github.com/users/MarcoFalke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarcoFalke/subscriptions","organizations_url":"https://api.github.com/users/MarcoFalke/orgs","repos_url":"https://api.github.com/users/MarcoFalke/repos","events_url":"https://api.github.com/users/MarcoFalke/events{/privacy}","received_events_url":"https://api.github.com/users/MarcoFalke/received_events","type":"User","site_admin":false},"open_issues":21,"closed_issues":26,"state":"open","created_at":"2018-05-31T19:40:07Z","updated_at":"2019-04-28T00:14:06Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14802/commits","review_comments_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14802/comments","review_comment_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/14802/comments","statuses_url":"https://api.github.com/repos/bitcoin/bitcoin/statuses/293cb0e2ee8029df2d49d0bdf5c025396116aa77","head":{"label":"FelixWeis:201811_blockstats_undoblock","ref":"201811_blockstats_undoblock","sha":"293cb0e2ee8029df2d49d0bdf5c025396116aa77","user":{"login":"FelixWeis","id":551068,"node_id":"MDQ6VXNlcjU1MTA2OA==","avatar_url":"https://avatars2.githubusercontent.com/u/551068?v=4","gravatar_id":"","url":"https://api.github.com/users/FelixWeis","html_url":"https://github.com/FelixWeis","followers_url":"https://api.github.com/users/FelixWeis/followers","following_url":"https://api.github.com/users/FelixWeis/following{/other_user}","gists_url":"https://api.github.com/users/FelixWeis/gists{/gist_id}","starred_url":"https://api.github.com/users/FelixWeis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FelixWeis/subscriptions","organizations_url":"https://api.github.com/users/FelixWeis/orgs","repos_url":"https://api.github.com/users/FelixWeis/repos","events_url":"https://api.github.com/users/FelixWeis/events{/privacy}","received_events_url":"https://api.github.com/users/FelixWeis/received_events","type":"User","site_admin":false},"repo":{"id":100159184,"node_id":"MDEwOlJlcG9zaXRvcnkxMDAxNTkxODQ=","name":"bitcoin","full_name":"FelixWeis/bitcoin","private":false,"owner":{"login":"FelixWeis","id":551068,"node_id":"MDQ6VXNlcjU1MTA2OA==","avatar_url":"https://avatars2.githubusercontent.com/u/551068?v=4","gravatar_id":"","url":"https://api.github.com/users/FelixWeis","html_url":"https://github.com/FelixWeis","followers_url":"https://api.github.com/users/FelixWeis/followers","following_url":"https://api.github.com/users/FelixWeis/following{/other_user}","gists_url":"https://api.github.com/users/FelixWeis/gists{/gist_id}","starred_url":"https://api.github.com/users/FelixWeis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FelixWeis/subscriptions","organizations_url":"https://api.github.com/users/FelixWeis/orgs","repos_url":"https://api.github.com/users/FelixWeis/repos","events_url":"https://api.github.com/users/FelixWeis/events{/privacy}","received_events_url":"https://api.github.com/users/FelixWeis/received_events","type":"User","site_admin":false},"html_url":"https://github.com/FelixWeis/bitcoin","description":"Bitcoin Core integration/staging tree","fork":true,"url":"https://api.github.com/repos/FelixWeis/bitcoin","forks_url":"https://api.github.com/repos/FelixWeis/bitcoin/forks","keys_url":"https://api.github.com/repos/FelixWeis/bitcoin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/FelixWeis/bitcoin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/FelixWeis/bitcoin/teams","hooks_url":"https://api.github.com/repos/FelixWeis/bitcoin/hooks","issue_events_url":"https://api.github.com/repos/FelixWeis/bitcoin/issues/events{/number}","events_url":"https://api.github.com/repos/FelixWeis/bitcoin/events","assignees_url":"https://api.github.com/repos/FelixWeis/bitcoin/assignees{/user}","branches_url":"https://api.github.com/repos/FelixWeis/bitcoin/branches{/branch}","tags_url":"https://api.github.com/repos/FelixWeis/bitcoin/tags","blobs_url":"https://api.github.com/repos/FelixWeis/bitcoin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/FelixWeis/bitcoin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/FelixWeis/bitcoin/git/refs{/sha}","trees_url":"https://api.github.com/repos/FelixWeis/bitcoin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/FelixWeis/bitcoin/statuses/{sha}","languages_url":"https://api.github.com/repos/FelixWeis/bitcoin/languages","stargazers_url":"https://api.github.com/repos/FelixWeis/bitcoin/stargazers","contributors_url":"https://api.github.com/repos/FelixWeis/bitcoin/contributors","subscribers_url":"https://api.github.com/repos/FelixWeis/bitcoin/subscribers","subscription_url":"https://api.github.com/repos/FelixWeis/bitcoin/subscription","commits_url":"https://api.github.com/repos/FelixWeis/bitcoin/commits{/sha}","git_commits_url":"https://api.github.com/repos/FelixWeis/bitcoin/git/commits{/sha}","comments_url":"https://api.github.com/repos/FelixWeis/bitcoin/comments{/number}","issue_comment_url":"https://api.github.com/repos/FelixWeis/bitcoin/issues/comments{/number}","contents_url":"https://api.github.com/repos/FelixWeis/bitcoin/contents/{+path}","compare_url":"https://api.github.com/repos/FelixWeis/bitcoin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/FelixWeis/bitcoin/merges","archive_url":"https://api.github.com/repos/FelixWeis/bitcoin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/FelixWeis/bitcoin/downloads","issues_url":"https://api.github.com/repos/FelixWeis/bitcoin/issues{/number}","pulls_url":"https://api.github.com/repos/FelixWeis/bitcoin/pulls{/number}","milestones_url":"https://api.github.com/repos/FelixWeis/bitcoin/milestones{/number}","notifications_url":"https://api.github.com/repos/FelixWeis/bitcoin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/FelixWeis/bitcoin/labels{/name}","releases_url":"https://api.github.com/repos/FelixWeis/bitcoin/releases{/id}","deployments_url":"https://api.github.com/repos/FelixWeis/bitcoin/deployments","created_at":"2017-08-13T06:45:57Z","updated_at":"2019-04-23T10:14:56Z","pushed_at":"2019-04-29T12:46:48Z","git_url":"git://github.com/FelixWeis/bitcoin.git","ssh_url":"git@github.com:FelixWeis/bitcoin.git","clone_url":"https://github.com/FelixWeis/bitcoin.git","svn_url":"https://github.com/FelixWeis/bitcoin","homepage":"https://bitcoin.org/en/download","size":120565,"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,"disabled":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"bitcoin:master","ref":"master","sha":"150be1c7b3432df19a7be6f1ce486723887a0fdc","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":"2019-04-29T17:53:30Z","pushed_at":"2019-04-29T17:56:43Z","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":125124,"stargazers_count":38046,"watchers_count":38046,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":22671,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":971,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":22671,"open_issues":971,"watchers":38046,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14802"},"html":{"href":"https://github.com/bitcoin/bitcoin/pull/14802"},"issue":{"href":"https://api.github.com/repos/bitcoin/bitcoin/issues/14802"},"comments":{"href":"https://api.github.com/repos/bitcoin/bitcoin/issues/14802/comments"},"review_comments":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14802/comments"},"review_comment":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/14802/commits"},"statuses":{"href":"https://api.github.com/repos/bitcoin/bitcoin/statuses/293cb0e2ee8029df2d49d0bdf5c025396116aa77"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"MarcoFalke"}}