GitHub PullRequestReviewCommentEvent at 2014-08-07 20:46:34
Repository: puppet
Actor: adrienthebo
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/puppetlabs/puppet/pulls/comments/15962883","id":15962883,"diff_hunk":"@@ -2,4 +2,35 @@ class Puppet::FileSystem::File19 < Puppet::FileSystem::FileImpl\n   def binread(path)\n     path.binread\n   end\n+\n+  # Ensure that we have a consistent compare_stream implementation on Ruby 1.9+\n+  #\n+  # In commit 2142287c `FileUtils.compare_stream` was optimized to produce\n+  # fewer objects while comparing streams by predeclaring a pair of strings\n+  # and reusing them for each iteration of the comparison. However, this change\n+  # exposes some inconsistency in how ruby handles IO#read vs StringIO#read.\n+  # When IO#read is passed a length and string, it will copy the read data into\n+  # the string, but will convert the encoding from the expected ASCII-8BIT\n+  # into the encoding of the string regardless of if the file was opened as\n+  # a binary file. However, when StringIO#read is passed a length and string\n+  # it will convert the passed string to the expected ASCII-8BIT. Because\n+  # of this it's impossible to use `FileUtils.compare_stream` to compare a\n+  # binary file and StringIO instance.\n+  #","path":"lib/puppet/file_system/file19.rb","position":18,"original_position":18,"commit_id":"d917f17c46659f0f960642cfe10b070e0372569e","original_commit_id":"d917f17c46659f0f960642cfe10b070e0372569e","user":{"login":"adrienthebo","id":172194,"avatar_url":"https://avatars.githubusercontent.com/u/172194?v=2","gravatar_id":"3bc6d4c30aba3b9e7d15a92d4b894d27","url":"https://api.github.com/users/adrienthebo","html_url":"https://github.com/adrienthebo","followers_url":"https://api.github.com/users/adrienthebo/followers","following_url":"https://api.github.com/users/adrienthebo/following{/other_user}","gists_url":"https://api.github.com/users/adrienthebo/gists{/gist_id}","starred_url":"https://api.github.com/users/adrienthebo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrienthebo/subscriptions","organizations_url":"https://api.github.com/users/adrienthebo/orgs","repos_url":"https://api.github.com/users/adrienthebo/repos","events_url":"https://api.github.com/users/adrienthebo/events{/privacy}","received_events_url":"https://api.github.com/users/adrienthebo/received_events","type":"User","site_admin":false},"body":"There's no Ruby bug as of yet, because it's unclear as to what the correct implementation is - StringIO doesn't respect the encoding of the passed string and File does. I'll amend this commit message.","created_at":"2014-08-07T20:46:34Z","updated_at":"2014-08-07T20:46:34Z","html_url":"https://github.com/puppetlabs/puppet/pull/2947#discussion_r15962883","pull_request_url":"https://api.github.com/repos/puppetlabs/puppet/pulls/2947","_links":{"self":{"href":"https://api.github.com/repos/puppetlabs/puppet/pulls/comments/15962883"},"html":{"href":"https://github.com/puppetlabs/puppet/pull/2947#discussion_r15962883"},"pull_request":{"href":"https://api.github.com/repos/puppetlabs/puppet/pulls/2947"}}},"pull_request":{"url":"https://api.github.com/repos/puppetlabs/puppet/pulls/2947","id":19435696,"html_url":"https://github.com/puppetlabs/puppet/pull/2947","diff_url":"https://github.com/puppetlabs/puppet/pull/2947.diff","patch_url":"https://github.com/puppetlabs/puppet/pull/2947.patch","issue_url":"https://api.github.com/repos/puppetlabs/puppet/issues/2947","number":2947,"state":"open","title":"Issue/master/pup 2946 filebucket encodings","user":{"login":"adrienthebo","id":172194,"avatar_url":"https://avatars.githubusercontent.com/u/172194?v=2","gravatar_id":"3bc6d4c30aba3b9e7d15a92d4b894d27","url":"https://api.github.com/users/adrienthebo","html_url":"https://github.com/adrienthebo","followers_url":"https://api.github.com/users/adrienthebo/followers","following_url":"https://api.github.com/users/adrienthebo/following{/other_user}","gists_url":"https://api.github.com/users/adrienthebo/gists{/gist_id}","starred_url":"https://api.github.com/users/adrienthebo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrienthebo/subscriptions","organizations_url":"https://api.github.com/users/adrienthebo/orgs","repos_url":"https://api.github.com/users/adrienthebo/repos","events_url":"https://api.github.com/users/adrienthebo/events{/privacy}","received_events_url":"https://api.github.com/users/adrienthebo/received_events","type":"User","site_admin":false},"body":"This pull request adds an implementation of `#compare_stream` that will properly compare the binary values of two IO streams.","created_at":"2014-08-06T22:13:04Z","updated_at":"2014-08-07T20:46:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a129ebde4d0e9e306963000424210e65e837c0b8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/puppetlabs/puppet/pulls/2947/commits","review_comments_url":"https://api.github.com/repos/puppetlabs/puppet/pulls/2947/comments","review_comment_url":"https://api.github.com/repos/puppetlabs/puppet/pulls/comments/{number}","comments_url":"https://api.github.com/repos/puppetlabs/puppet/issues/2947/comments","statuses_url":"https://api.github.com/repos/puppetlabs/puppet/statuses/d917f17c46659f0f960642cfe10b070e0372569e","head":{"label":"adrienthebo:issue/master/pup-2946-filebucket-encodings","ref":"issue/master/pup-2946-filebucket-encodings","sha":"d917f17c46659f0f960642cfe10b070e0372569e","user":{"login":"adrienthebo","id":172194,"avatar_url":"https://avatars.githubusercontent.com/u/172194?v=2","gravatar_id":"3bc6d4c30aba3b9e7d15a92d4b894d27","url":"https://api.github.com/users/adrienthebo","html_url":"https://github.com/adrienthebo","followers_url":"https://api.github.com/users/adrienthebo/followers","following_url":"https://api.github.com/users/adrienthebo/following{/other_user}","gists_url":"https://api.github.com/users/adrienthebo/gists{/gist_id}","starred_url":"https://api.github.com/users/adrienthebo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrienthebo/subscriptions","organizations_url":"https://api.github.com/users/adrienthebo/orgs","repos_url":"https://api.github.com/users/adrienthebo/repos","events_url":"https://api.github.com/users/adrienthebo/events{/privacy}","received_events_url":"https://api.github.com/users/adrienthebo/received_events","type":"User","site_admin":false},"repo":{"id":4814986,"name":"puppet","full_name":"adrienthebo/puppet","owner":{"login":"adrienthebo","id":172194,"avatar_url":"https://avatars.githubusercontent.com/u/172194?v=2","gravatar_id":"3bc6d4c30aba3b9e7d15a92d4b894d27","url":"https://api.github.com/users/adrienthebo","html_url":"https://github.com/adrienthebo","followers_url":"https://api.github.com/users/adrienthebo/followers","following_url":"https://api.github.com/users/adrienthebo/following{/other_user}","gists_url":"https://api.github.com/users/adrienthebo/gists{/gist_id}","starred_url":"https://api.github.com/users/adrienthebo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrienthebo/subscriptions","organizations_url":"https://api.github.com/users/adrienthebo/orgs","repos_url":"https://api.github.com/users/adrienthebo/repos","events_url":"https://api.github.com/users/adrienthebo/events{/privacy}","received_events_url":"https://api.github.com/users/adrienthebo/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/adrienthebo/puppet","description":"Server automation framework and application","fork":true,"url":"https://api.github.com/repos/adrienthebo/puppet","forks_url":"https://api.github.com/repos/adrienthebo/puppet/forks","keys_url":"https://api.github.com/repos/adrienthebo/puppet/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adrienthebo/puppet/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adrienthebo/puppet/teams","hooks_url":"https://api.github.com/repos/adrienthebo/puppet/hooks","issue_events_url":"https://api.github.com/repos/adrienthebo/puppet/issues/events{/number}","events_url":"https://api.github.com/repos/adrienthebo/puppet/events","assignees_url":"https://api.github.com/repos/adrienthebo/puppet/assignees{/user}","branches_url":"https://api.github.com/repos/adrienthebo/puppet/branches{/branch}","tags_url":"https://api.github.com/repos/adrienthebo/puppet/tags","blobs_url":"https://api.github.com/repos/adrienthebo/puppet/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adrienthebo/puppet/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adrienthebo/puppet/git/refs{/sha}","trees_url":"https://api.github.com/repos/adrienthebo/puppet/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adrienthebo/puppet/statuses/{sha}","languages_url":"https://api.github.com/repos/adrienthebo/puppet/languages","stargazers_url":"https://api.github.com/repos/adrienthebo/puppet/stargazers","contributors_url":"https://api.github.com/repos/adrienthebo/puppet/contributors","subscribers_url":"https://api.github.com/repos/adrienthebo/puppet/subscribers","subscription_url":"https://api.github.com/repos/adrienthebo/puppet/subscription","commits_url":"https://api.github.com/repos/adrienthebo/puppet/commits{/sha}","git_commits_url":"https://api.github.com/repos/adrienthebo/puppet/git/commits{/sha}","comments_url":"https://api.github.com/repos/adrienthebo/puppet/comments{/number}","issue_comment_url":"https://api.github.com/repos/adrienthebo/puppet/issues/comments/{number}","contents_url":"https://api.github.com/repos/adrienthebo/puppet/contents/{+path}","compare_url":"https://api.github.com/repos/adrienthebo/puppet/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adrienthebo/puppet/merges","archive_url":"https://api.github.com/repos/adrienthebo/puppet/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adrienthebo/puppet/downloads","issues_url":"https://api.github.com/repos/adrienthebo/puppet/issues{/number}","pulls_url":"https://api.github.com/repos/adrienthebo/puppet/pulls{/number}","milestones_url":"https://api.github.com/repos/adrienthebo/puppet/milestones{/number}","notifications_url":"https://api.github.com/repos/adrienthebo/puppet/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adrienthebo/puppet/labels{/name}","releases_url":"https://api.github.com/repos/adrienthebo/puppet/releases{/id}","created_at":"2012-06-28T00:10:44Z","updated_at":"2014-06-17T23:02:57Z","pushed_at":"2014-08-07T19:08:47Z","git_url":"git://github.com/adrienthebo/puppet.git","ssh_url":"git@github.com:adrienthebo/puppet.git","clone_url":"https://github.com/adrienthebo/puppet.git","svn_url":"https://github.com/adrienthebo/puppet","homepage":"http://www.puppetlabs.com/puppet/introduction/","size":41905,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":true,"has_wiki":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"puppetlabs:master","ref":"master","sha":"c6ba27e2c419f0354e5c1e100c831577ec97ab65","user":{"login":"puppetlabs","id":234268,"avatar_url":"https://avatars.githubusercontent.com/u/234268?v=2","gravatar_id":"eb454c2139c156db7c8266a875519a1f","url":"https://api.github.com/users/puppetlabs","html_url":"https://github.com/puppetlabs","followers_url":"https://api.github.com/users/puppetlabs/followers","following_url":"https://api.github.com/users/puppetlabs/following{/other_user}","gists_url":"https://api.github.com/users/puppetlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/puppetlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/puppetlabs/subscriptions","organizations_url":"https://api.github.com/users/puppetlabs/orgs","repos_url":"https://api.github.com/users/puppetlabs/repos","events_url":"https://api.github.com/users/puppetlabs/events{/privacy}","received_events_url":"https://api.github.com/users/puppetlabs/received_events","type":"Organization","site_admin":false},"repo":{"id":910744,"name":"puppet","full_name":"puppetlabs/puppet","owner":{"login":"puppetlabs","id":234268,"avatar_url":"https://avatars.githubusercontent.com/u/234268?v=2","gravatar_id":"eb454c2139c156db7c8266a875519a1f","url":"https://api.github.com/users/puppetlabs","html_url":"https://github.com/puppetlabs","followers_url":"https://api.github.com/users/puppetlabs/followers","following_url":"https://api.github.com/users/puppetlabs/following{/other_user}","gists_url":"https://api.github.com/users/puppetlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/puppetlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/puppetlabs/subscriptions","organizations_url":"https://api.github.com/users/puppetlabs/orgs","repos_url":"https://api.github.com/users/puppetlabs/repos","events_url":"https://api.github.com/users/puppetlabs/events{/privacy}","received_events_url":"https://api.github.com/users/puppetlabs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/puppetlabs/puppet","description":"Server automation framework and application","fork":false,"url":"https://api.github.com/repos/puppetlabs/puppet","forks_url":"https://api.github.com/repos/puppetlabs/puppet/forks","keys_url":"https://api.github.com/repos/puppetlabs/puppet/keys{/key_id}","collaborators_url":"https://api.github.com/repos/puppetlabs/puppet/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/puppetlabs/puppet/teams","hooks_url":"https://api.github.com/repos/puppetlabs/puppet/hooks","issue_events_url":"https://api.github.com/repos/puppetlabs/puppet/issues/events{/number}","events_url":"https://api.github.com/repos/puppetlabs/puppet/events","assignees_url":"https://api.github.com/repos/puppetlabs/puppet/assignees{/user}","branches_url":"https://api.github.com/repos/puppetlabs/puppet/branches{/branch}","tags_url":"https://api.github.com/repos/puppetlabs/puppet/tags","blobs_url":"https://api.github.com/repos/puppetlabs/puppet/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/puppetlabs/puppet/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/puppetlabs/puppet/git/refs{/sha}","trees_url":"https://api.github.com/repos/puppetlabs/puppet/git/trees{/sha}","statuses_url":"https://api.github.com/repos/puppetlabs/puppet/statuses/{sha}","languages_url":"https://api.github.com/repos/puppetlabs/puppet/languages","stargazers_url":"https://api.github.com/repos/puppetlabs/puppet/stargazers","contributors_url":"https://api.github.com/repos/puppetlabs/puppet/contributors","subscribers_url":"https://api.github.com/repos/puppetlabs/puppet/subscribers","subscription_url":"https://api.github.com/repos/puppetlabs/puppet/subscription","commits_url":"https://api.github.com/repos/puppetlabs/puppet/commits{/sha}","git_commits_url":"https://api.github.com/repos/puppetlabs/puppet/git/commits{/sha}","comments_url":"https://api.github.com/repos/puppetlabs/puppet/comments{/number}","issue_comment_url":"https://api.github.com/repos/puppetlabs/puppet/issues/comments/{number}","contents_url":"https://api.github.com/repos/puppetlabs/puppet/contents/{+path}","compare_url":"https://api.github.com/repos/puppetlabs/puppet/compare/{base}...{head}","merges_url":"https://api.github.com/repos/puppetlabs/puppet/merges","archive_url":"https://api.github.com/repos/puppetlabs/puppet/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/puppetlabs/puppet/downloads","issues_url":"https://api.github.com/repos/puppetlabs/puppet/issues{/number}","pulls_url":"https://api.github.com/repos/puppetlabs/puppet/pulls{/number}","milestones_url":"https://api.github.com/repos/puppetlabs/puppet/milestones{/number}","notifications_url":"https://api.github.com/repos/puppetlabs/puppet/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/puppetlabs/puppet/labels{/name}","releases_url":"https://api.github.com/repos/puppetlabs/puppet/releases{/id}","created_at":"2010-09-14T19:26:44Z","updated_at":"2014-08-07T20:38:23Z","pushed_at":"2014-08-07T20:34:48Z","git_url":"git://github.com/puppetlabs/puppet.git","ssh_url":"git@github.com:puppetlabs/puppet.git","clone_url":"https://github.com/puppetlabs/puppet.git","svn_url":"https://github.com/puppetlabs/puppet","homepage":"http://www.puppetlabs.com/puppet/introduction/","size":106413,"stargazers_count":2510,"watchers_count":2510,"language":"Ruby","has_issues":false,"has_downloads":true,"has_wiki":false,"forks_count":1085,"mirror_url":null,"open_issues_count":27,"forks":1085,"open_issues":27,"watchers":2510,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/puppetlabs/puppet/pulls/2947"},"html":{"href":"https://github.com/puppetlabs/puppet/pull/2947"},"issue":{"href":"https://api.github.com/repos/puppetlabs/puppet/issues/2947"},"comments":{"href":"https://api.github.com/repos/puppetlabs/puppet/issues/2947/comments"},"review_comments":{"href":"https://api.github.com/repos/puppetlabs/puppet/pulls/2947/comments"},"review_comment":{"href":"https://api.github.com/repos/puppetlabs/puppet/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/puppetlabs/puppet/pulls/2947/commits"},"statuses":{"href":"https://api.github.com/repos/puppetlabs/puppet/statuses/d917f17c46659f0f960642cfe10b070e0372569e"}}}}