{"action":"created","comment":{"url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments/36858284","id":36858284,"diff_hunk":"@@ -20,6 +20,12 @@\n from authproxy import AuthServiceProxy, JSONRPCException\n from util import *\n \n+def null_file():\n+    if os.name == 'nt':\n+        return open(\"NUL\", \"w+\")\n+    else:\n+\treturn open(\"/dev/null\", \"w+\")\n+","path":"qa/rpc-tests/test_framework/util.py","position":9,"original_position":9,"commit_id":"879ef159333c1e5b6ba49350d5868e38e944764f","original_commit_id":"879ef159333c1e5b6ba49350d5868e38e944764f","user":{"login":"ptschip","id":12862928,"avatar_url":"https://avatars.githubusercontent.com/u/12862928?v=3","gravatar_id":"","url":"https://api.github.com/users/ptschip","html_url":"https://github.com/ptschip","followers_url":"https://api.github.com/users/ptschip/followers","following_url":"https://api.github.com/users/ptschip/following{/other_user}","gists_url":"https://api.github.com/users/ptschip/gists{/gist_id}","starred_url":"https://api.github.com/users/ptschip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ptschip/subscriptions","organizations_url":"https://api.github.com/users/ptschip/orgs","repos_url":"https://api.github.com/users/ptschip/repos","events_url":"https://api.github.com/users/ptschip/events{/privacy}","received_events_url":"https://api.github.com/users/ptschip/received_events","type":"User","site_admin":false},"body":"i'll add that\n\nOn 12/08/2015 6:12 AM, Jonas Schnelli wrote:\n>\n> In qa/rpc-tests/test_framework/util.py \n> <https://github.com/bitcoin/bitcoin/pull/6548#discussion_r36857141>:\n>\n> > @@ -20,6 +20,12 @@\n> >  from authproxy import AuthServiceProxy, JSONRPCException\n> >  from util import *\n> >\n> > +def null_file():\n> > +    if os.name == 'nt':\n> > +        return open(\"NUL\", \"w+\")\n> > +    else:\n> > +\treturn open(\"/dev/null\", \"w+\")\n> > +\n>\n> The devnull switch is not required.\n> I think you can do |devnull = open(os.devnull, 'w')| at L96 and L188.\n>\n> —\n> Reply to this email directly or view it on GitHub \n> <https://github.com/bitcoin/bitcoin/pull/6548/files#r36857141>.\n>\n\n","created_at":"2015-08-12T13:24:24Z","updated_at":"2015-08-12T13:24:24Z","html_url":"https://github.com/bitcoin/bitcoin/pull/6548#discussion_r36858284","pull_request_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/6548","_links":{"self":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments/36858284"},"html":{"href":"https://github.com/bitcoin/bitcoin/pull/6548#discussion_r36858284"},"pull_request":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/6548"}}},"pull_request":{"url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/6548","id":42152999,"html_url":"https://github.com/bitcoin/bitcoin/pull/6548","diff_url":"https://github.com/bitcoin/bitcoin/pull/6548.diff","patch_url":"https://github.com/bitcoin/bitcoin/pull/6548.patch","issue_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/6548","number":6548,"state":"open","locked":false,"title":"Enable python regression test for Windows","user":{"login":"ptschip","id":12862928,"avatar_url":"https://avatars.githubusercontent.com/u/12862928?v=3","gravatar_id":"","url":"https://api.github.com/users/ptschip","html_url":"https://github.com/ptschip","followers_url":"https://api.github.com/users/ptschip/followers","following_url":"https://api.github.com/users/ptschip/following{/other_user}","gists_url":"https://api.github.com/users/ptschip/gists{/gist_id}","starred_url":"https://api.github.com/users/ptschip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ptschip/subscriptions","organizations_url":"https://api.github.com/users/ptschip/orgs","repos_url":"https://api.github.com/users/ptschip/repos","events_url":"https://api.github.com/users/ptschip/events{/privacy}","received_events_url":"https://api.github.com/users/ptschip/received_events","type":"User","site_admin":false},"body":"Two files changed:\r\n\r\n1)  rpc-test.sh - enable windows regression test and set env variable so that run-bitcoin-cli does \r\n     not get invoked as python can not invoke this on a  windows machine\r\n2)  util.py - added handling of  NUL files because /dev/null is not recognized on windows\r\n      Also, although not required added some additional handling of cache files in the event\r\n      that one or more are missing as happened while I was debugging.","created_at":"2015-08-11T17:07:01Z","updated_at":"2015-08-12T13:24:24Z","closed_at":null,"merged_at":null,"merge_commit_sha":"15f6112d3e5072f69827b2f59f0ee0f5ba5af52e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/6548/commits","review_comments_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/6548/comments","review_comment_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/6548/comments","statuses_url":"https://api.github.com/repos/bitcoin/bitcoin/statuses/879ef159333c1e5b6ba49350d5868e38e944764f","head":{"label":"ptschip:enable_win_py","ref":"enable_win_py","sha":"879ef159333c1e5b6ba49350d5868e38e944764f","user":{"login":"ptschip","id":12862928,"avatar_url":"https://avatars.githubusercontent.com/u/12862928?v=3","gravatar_id":"","url":"https://api.github.com/users/ptschip","html_url":"https://github.com/ptschip","followers_url":"https://api.github.com/users/ptschip/followers","following_url":"https://api.github.com/users/ptschip/following{/other_user}","gists_url":"https://api.github.com/users/ptschip/gists{/gist_id}","starred_url":"https://api.github.com/users/ptschip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ptschip/subscriptions","organizations_url":"https://api.github.com/users/ptschip/orgs","repos_url":"https://api.github.com/users/ptschip/repos","events_url":"https://api.github.com/users/ptschip/events{/privacy}","received_events_url":"https://api.github.com/users/ptschip/received_events","type":"User","site_admin":false},"repo":{"id":37345010,"name":"bitcoin","full_name":"ptschip/bitcoin","owner":{"login":"ptschip","id":12862928,"avatar_url":"https://avatars.githubusercontent.com/u/12862928?v=3","gravatar_id":"","url":"https://api.github.com/users/ptschip","html_url":"https://github.com/ptschip","followers_url":"https://api.github.com/users/ptschip/followers","following_url":"https://api.github.com/users/ptschip/following{/other_user}","gists_url":"https://api.github.com/users/ptschip/gists{/gist_id}","starred_url":"https://api.github.com/users/ptschip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ptschip/subscriptions","organizations_url":"https://api.github.com/users/ptschip/orgs","repos_url":"https://api.github.com/users/ptschip/repos","events_url":"https://api.github.com/users/ptschip/events{/privacy}","received_events_url":"https://api.github.com/users/ptschip/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ptschip/bitcoin","description":"Bitcoin Core integration/staging tree","fork":true,"url":"https://api.github.com/repos/ptschip/bitcoin","forks_url":"https://api.github.com/repos/ptschip/bitcoin/forks","keys_url":"https://api.github.com/repos/ptschip/bitcoin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ptschip/bitcoin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ptschip/bitcoin/teams","hooks_url":"https://api.github.com/repos/ptschip/bitcoin/hooks","issue_events_url":"https://api.github.com/repos/ptschip/bitcoin/issues/events{/number}","events_url":"https://api.github.com/repos/ptschip/bitcoin/events","assignees_url":"https://api.github.com/repos/ptschip/bitcoin/assignees{/user}","branches_url":"https://api.github.com/repos/ptschip/bitcoin/branches{/branch}","tags_url":"https://api.github.com/repos/ptschip/bitcoin/tags","blobs_url":"https://api.github.com/repos/ptschip/bitcoin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ptschip/bitcoin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ptschip/bitcoin/git/refs{/sha}","trees_url":"https://api.github.com/repos/ptschip/bitcoin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ptschip/bitcoin/statuses/{sha}","languages_url":"https://api.github.com/repos/ptschip/bitcoin/languages","stargazers_url":"https://api.github.com/repos/ptschip/bitcoin/stargazers","contributors_url":"https://api.github.com/repos/ptschip/bitcoin/contributors","subscribers_url":"https://api.github.com/repos/ptschip/bitcoin/subscribers","subscription_url":"https://api.github.com/repos/ptschip/bitcoin/subscription","commits_url":"https://api.github.com/repos/ptschip/bitcoin/commits{/sha}","git_commits_url":"https://api.github.com/repos/ptschip/bitcoin/git/commits{/sha}","comments_url":"https://api.github.com/repos/ptschip/bitcoin/comments{/number}","issue_comment_url":"https://api.github.com/repos/ptschip/bitcoin/issues/comments{/number}","contents_url":"https://api.github.com/repos/ptschip/bitcoin/contents/{+path}","compare_url":"https://api.github.com/repos/ptschip/bitcoin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ptschip/bitcoin/merges","archive_url":"https://api.github.com/repos/ptschip/bitcoin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ptschip/bitcoin/downloads","issues_url":"https://api.github.com/repos/ptschip/bitcoin/issues{/number}","pulls_url":"https://api.github.com/repos/ptschip/bitcoin/pulls{/number}","milestones_url":"https://api.github.com/repos/ptschip/bitcoin/milestones{/number}","notifications_url":"https://api.github.com/repos/ptschip/bitcoin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ptschip/bitcoin/labels{/name}","releases_url":"https://api.github.com/repos/ptschip/bitcoin/releases{/id}","created_at":"2015-06-12T21:16:10Z","updated_at":"2015-08-03T14:13:16Z","pushed_at":"2015-08-11T17:00:55Z","git_url":"git://github.com/ptschip/bitcoin.git","ssh_url":"git@github.com:ptschip/bitcoin.git","clone_url":"https://github.com/ptschip/bitcoin.git","svn_url":"https://github.com/ptschip/bitcoin","homepage":"https://bitcoin.org/en/download","size":54793,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":false,"has_wiki":false,"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":"bitcoin:master","ref":"master","sha":"87f37e259d6deb52ee464edde7aece687eea97a5","user":{"login":"bitcoin","id":528860,"avatar_url":"https://avatars.githubusercontent.com/u/528860?v=3","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,"name":"bitcoin","full_name":"bitcoin/bitcoin","owner":{"login":"bitcoin","id":528860,"avatar_url":"https://avatars.githubusercontent.com/u/528860?v=3","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},"private":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}","created_at":"2010-12-19T15:16:43Z","updated_at":"2015-08-12T01:47:33Z","pushed_at":"2015-08-12T06:29:52Z","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://bitcoin.org/en/download","size":131714,"stargazers_count":7289,"watchers_count":7289,"language":"C++","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":5078,"mirror_url":null,"open_issues_count":432,"forks":5078,"open_issues":432,"watchers":7289,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/6548"},"html":{"href":"https://github.com/bitcoin/bitcoin/pull/6548"},"issue":{"href":"https://api.github.com/repos/bitcoin/bitcoin/issues/6548"},"comments":{"href":"https://api.github.com/repos/bitcoin/bitcoin/issues/6548/comments"},"review_comments":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/6548/comments"},"review_comment":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/6548/commits"},"statuses":{"href":"https://api.github.com/repos/bitcoin/bitcoin/statuses/879ef159333c1e5b6ba49350d5868e38e944764f"}}}}