{"action":"created","comment":{"url":"https://api.github.com/repos/guzzle/guzzle/pulls/comments/44173970","id":44173970,"diff_hunk":"@@ -87,6 +87,19 @@ function ($value) use ($request, $options) {\n                 if ($this->onFulfilled) {\n                     call_user_func($this->onFulfilled, $value);\n                 }\n+                if (isset($options['sink'])) {\n+                    $contents = (string) $value->getBody();\n+                    $sink = $options['sink'];\n+\n+                    if (is_resource($sink)) {","path":"src/Handler/MockHandler.php","position":8,"original_position":8,"commit_id":"ae2536bf7208fb876236f8edf950895f0f155ee2","original_commit_id":"ae2536bf7208fb876236f8edf950895f0f155ee2","user":{"login":"mtdowling","id":190930,"avatar_url":"https://avatars.githubusercontent.com/u/190930?v=3","gravatar_id":"","url":"https://api.github.com/users/mtdowling","html_url":"https://github.com/mtdowling","followers_url":"https://api.github.com/users/mtdowling/followers","following_url":"https://api.github.com/users/mtdowling/following{/other_user}","gists_url":"https://api.github.com/users/mtdowling/gists{/gist_id}","starred_url":"https://api.github.com/users/mtdowling/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mtdowling/subscriptions","organizations_url":"https://api.github.com/users/mtdowling/orgs","repos_url":"https://api.github.com/users/mtdowling/repos","events_url":"https://api.github.com/users/mtdowling/events{/privacy}","received_events_url":"https://api.github.com/users/mtdowling/received_events","type":"User","site_admin":false},"body":"PHP tmp stream only create a temp file when the stream exceeds a certain size (2 megs by default I believe). Are you saying that you're seeing a temp file created no matter what or that you had to manually create a temp file to make what I suggested work?","created_at":"2015-11-06T18:58:35Z","updated_at":"2015-11-06T18:58:35Z","html_url":"https://github.com/guzzle/guzzle/pull/1292#discussion_r44173970","pull_request_url":"https://api.github.com/repos/guzzle/guzzle/pulls/1292","_links":{"self":{"href":"https://api.github.com/repos/guzzle/guzzle/pulls/comments/44173970"},"html":{"href":"https://github.com/guzzle/guzzle/pull/1292#discussion_r44173970"},"pull_request":{"href":"https://api.github.com/repos/guzzle/guzzle/pulls/1292"}}},"pull_request":{"url":"https://api.github.com/repos/guzzle/guzzle/pulls/1292","id":49288511,"html_url":"https://github.com/guzzle/guzzle/pull/1292","diff_url":"https://github.com/guzzle/guzzle/pull/1292.diff","patch_url":"https://github.com/guzzle/guzzle/pull/1292.patch","issue_url":"https://api.github.com/repos/guzzle/guzzle/issues/1292","number":1292,"state":"open","locked":false,"title":"Implement \"sink\" for MockHandler","user":{"login":"ivank","id":4976,"avatar_url":"https://avatars.githubusercontent.com/u/4976?v=3","gravatar_id":"","url":"https://api.github.com/users/ivank","html_url":"https://github.com/ivank","followers_url":"https://api.github.com/users/ivank/followers","following_url":"https://api.github.com/users/ivank/following{/other_user}","gists_url":"https://api.github.com/users/ivank/gists{/gist_id}","starred_url":"https://api.github.com/users/ivank/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ivank/subscriptions","organizations_url":"https://api.github.com/users/ivank/orgs","repos_url":"https://api.github.com/users/ivank/repos","events_url":"https://api.github.com/users/ivank/events{/privacy}","received_events_url":"https://api.github.com/users/ivank/received_events","type":"User","site_admin":false},"body":"This is a reimplementation of my previous pull request https://github.com/guzzle/guzzle/pull/1020 which regressed with the 6.0 rewrite\n\nFingers crossed for 7.0, maybe I can make one of those too :)","created_at":"2015-10-30T16:07:39Z","updated_at":"2015-11-06T18:58:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5427d95d31b1eb0f85f9e95c0fba17ae6c293996","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/guzzle/guzzle/pulls/1292/commits","review_comments_url":"https://api.github.com/repos/guzzle/guzzle/pulls/1292/comments","review_comment_url":"https://api.github.com/repos/guzzle/guzzle/pulls/comments{/number}","comments_url":"https://api.github.com/repos/guzzle/guzzle/issues/1292/comments","statuses_url":"https://api.github.com/repos/guzzle/guzzle/statuses/ae2536bf7208fb876236f8edf950895f0f155ee2","head":{"label":"ivank:sink-for-mock-handler","ref":"sink-for-mock-handler","sha":"ae2536bf7208fb876236f8edf950895f0f155ee2","user":{"login":"ivank","id":4976,"avatar_url":"https://avatars.githubusercontent.com/u/4976?v=3","gravatar_id":"","url":"https://api.github.com/users/ivank","html_url":"https://github.com/ivank","followers_url":"https://api.github.com/users/ivank/followers","following_url":"https://api.github.com/users/ivank/following{/other_user}","gists_url":"https://api.github.com/users/ivank/gists{/gist_id}","starred_url":"https://api.github.com/users/ivank/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ivank/subscriptions","organizations_url":"https://api.github.com/users/ivank/orgs","repos_url":"https://api.github.com/users/ivank/repos","events_url":"https://api.github.com/users/ivank/events{/privacy}","received_events_url":"https://api.github.com/users/ivank/received_events","type":"User","site_admin":false},"repo":{"id":45258985,"name":"guzzle","full_name":"ivank/guzzle","owner":{"login":"ivank","id":4976,"avatar_url":"https://avatars.githubusercontent.com/u/4976?v=3","gravatar_id":"","url":"https://api.github.com/users/ivank","html_url":"https://github.com/ivank","followers_url":"https://api.github.com/users/ivank/followers","following_url":"https://api.github.com/users/ivank/following{/other_user}","gists_url":"https://api.github.com/users/ivank/gists{/gist_id}","starred_url":"https://api.github.com/users/ivank/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ivank/subscriptions","organizations_url":"https://api.github.com/users/ivank/orgs","repos_url":"https://api.github.com/users/ivank/repos","events_url":"https://api.github.com/users/ivank/events{/privacy}","received_events_url":"https://api.github.com/users/ivank/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ivank/guzzle","description":"Guzzle, an extensible PHP HTTP client","fork":true,"url":"https://api.github.com/repos/ivank/guzzle","forks_url":"https://api.github.com/repos/ivank/guzzle/forks","keys_url":"https://api.github.com/repos/ivank/guzzle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ivank/guzzle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ivank/guzzle/teams","hooks_url":"https://api.github.com/repos/ivank/guzzle/hooks","issue_events_url":"https://api.github.com/repos/ivank/guzzle/issues/events{/number}","events_url":"https://api.github.com/repos/ivank/guzzle/events","assignees_url":"https://api.github.com/repos/ivank/guzzle/assignees{/user}","branches_url":"https://api.github.com/repos/ivank/guzzle/branches{/branch}","tags_url":"https://api.github.com/repos/ivank/guzzle/tags","blobs_url":"https://api.github.com/repos/ivank/guzzle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ivank/guzzle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ivank/guzzle/git/refs{/sha}","trees_url":"https://api.github.com/repos/ivank/guzzle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ivank/guzzle/statuses/{sha}","languages_url":"https://api.github.com/repos/ivank/guzzle/languages","stargazers_url":"https://api.github.com/repos/ivank/guzzle/stargazers","contributors_url":"https://api.github.com/repos/ivank/guzzle/contributors","subscribers_url":"https://api.github.com/repos/ivank/guzzle/subscribers","subscription_url":"https://api.github.com/repos/ivank/guzzle/subscription","commits_url":"https://api.github.com/repos/ivank/guzzle/commits{/sha}","git_commits_url":"https://api.github.com/repos/ivank/guzzle/git/commits{/sha}","comments_url":"https://api.github.com/repos/ivank/guzzle/comments{/number}","issue_comment_url":"https://api.github.com/repos/ivank/guzzle/issues/comments{/number}","contents_url":"https://api.github.com/repos/ivank/guzzle/contents/{+path}","compare_url":"https://api.github.com/repos/ivank/guzzle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ivank/guzzle/merges","archive_url":"https://api.github.com/repos/ivank/guzzle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ivank/guzzle/downloads","issues_url":"https://api.github.com/repos/ivank/guzzle/issues{/number}","pulls_url":"https://api.github.com/repos/ivank/guzzle/pulls{/number}","milestones_url":"https://api.github.com/repos/ivank/guzzle/milestones{/number}","notifications_url":"https://api.github.com/repos/ivank/guzzle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ivank/guzzle/labels{/name}","releases_url":"https://api.github.com/repos/ivank/guzzle/releases{/id}","created_at":"2015-10-30T15:23:14Z","updated_at":"2015-10-30T15:23:16Z","pushed_at":"2015-10-30T16:05:32Z","git_url":"git://github.com/ivank/guzzle.git","ssh_url":"git@github.com:ivank/guzzle.git","clone_url":"https://github.com/ivank/guzzle.git","svn_url":"https://github.com/ivank/guzzle","homepage":"http://guzzlephp.org/","size":10835,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"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":"guzzle:master","ref":"master","sha":"4f11935f709ef5e279af9da062507e72bd356e1a","user":{"login":"guzzle","id":638632,"avatar_url":"https://avatars.githubusercontent.com/u/638632?v=3","gravatar_id":"","url":"https://api.github.com/users/guzzle","html_url":"https://github.com/guzzle","followers_url":"https://api.github.com/users/guzzle/followers","following_url":"https://api.github.com/users/guzzle/following{/other_user}","gists_url":"https://api.github.com/users/guzzle/gists{/gist_id}","starred_url":"https://api.github.com/users/guzzle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guzzle/subscriptions","organizations_url":"https://api.github.com/users/guzzle/orgs","repos_url":"https://api.github.com/users/guzzle/repos","events_url":"https://api.github.com/users/guzzle/events{/privacy}","received_events_url":"https://api.github.com/users/guzzle/received_events","type":"Organization","site_admin":false},"repo":{"id":1420053,"name":"guzzle","full_name":"guzzle/guzzle","owner":{"login":"guzzle","id":638632,"avatar_url":"https://avatars.githubusercontent.com/u/638632?v=3","gravatar_id":"","url":"https://api.github.com/users/guzzle","html_url":"https://github.com/guzzle","followers_url":"https://api.github.com/users/guzzle/followers","following_url":"https://api.github.com/users/guzzle/following{/other_user}","gists_url":"https://api.github.com/users/guzzle/gists{/gist_id}","starred_url":"https://api.github.com/users/guzzle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guzzle/subscriptions","organizations_url":"https://api.github.com/users/guzzle/orgs","repos_url":"https://api.github.com/users/guzzle/repos","events_url":"https://api.github.com/users/guzzle/events{/privacy}","received_events_url":"https://api.github.com/users/guzzle/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/guzzle/guzzle","description":"Guzzle, an extensible PHP HTTP client","fork":false,"url":"https://api.github.com/repos/guzzle/guzzle","forks_url":"https://api.github.com/repos/guzzle/guzzle/forks","keys_url":"https://api.github.com/repos/guzzle/guzzle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/guzzle/guzzle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/guzzle/guzzle/teams","hooks_url":"https://api.github.com/repos/guzzle/guzzle/hooks","issue_events_url":"https://api.github.com/repos/guzzle/guzzle/issues/events{/number}","events_url":"https://api.github.com/repos/guzzle/guzzle/events","assignees_url":"https://api.github.com/repos/guzzle/guzzle/assignees{/user}","branches_url":"https://api.github.com/repos/guzzle/guzzle/branches{/branch}","tags_url":"https://api.github.com/repos/guzzle/guzzle/tags","blobs_url":"https://api.github.com/repos/guzzle/guzzle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/guzzle/guzzle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/guzzle/guzzle/git/refs{/sha}","trees_url":"https://api.github.com/repos/guzzle/guzzle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/guzzle/guzzle/statuses/{sha}","languages_url":"https://api.github.com/repos/guzzle/guzzle/languages","stargazers_url":"https://api.github.com/repos/guzzle/guzzle/stargazers","contributors_url":"https://api.github.com/repos/guzzle/guzzle/contributors","subscribers_url":"https://api.github.com/repos/guzzle/guzzle/subscribers","subscription_url":"https://api.github.com/repos/guzzle/guzzle/subscription","commits_url":"https://api.github.com/repos/guzzle/guzzle/commits{/sha}","git_commits_url":"https://api.github.com/repos/guzzle/guzzle/git/commits{/sha}","comments_url":"https://api.github.com/repos/guzzle/guzzle/comments{/number}","issue_comment_url":"https://api.github.com/repos/guzzle/guzzle/issues/comments{/number}","contents_url":"https://api.github.com/repos/guzzle/guzzle/contents/{+path}","compare_url":"https://api.github.com/repos/guzzle/guzzle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/guzzle/guzzle/merges","archive_url":"https://api.github.com/repos/guzzle/guzzle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/guzzle/guzzle/downloads","issues_url":"https://api.github.com/repos/guzzle/guzzle/issues{/number}","pulls_url":"https://api.github.com/repos/guzzle/guzzle/pulls{/number}","milestones_url":"https://api.github.com/repos/guzzle/guzzle/milestones{/number}","notifications_url":"https://api.github.com/repos/guzzle/guzzle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/guzzle/guzzle/labels{/name}","releases_url":"https://api.github.com/repos/guzzle/guzzle/releases{/id}","created_at":"2011-02-28T02:44:05Z","updated_at":"2015-11-06T17:46:20Z","pushed_at":"2015-11-06T05:32:32Z","git_url":"git://github.com/guzzle/guzzle.git","ssh_url":"git@github.com:guzzle/guzzle.git","clone_url":"https://github.com/guzzle/guzzle.git","svn_url":"https://github.com/guzzle/guzzle","homepage":"http://guzzlephp.org/","size":18952,"stargazers_count":5863,"watchers_count":5863,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":894,"mirror_url":null,"open_issues_count":26,"forks":894,"open_issues":26,"watchers":5863,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/guzzle/guzzle/pulls/1292"},"html":{"href":"https://github.com/guzzle/guzzle/pull/1292"},"issue":{"href":"https://api.github.com/repos/guzzle/guzzle/issues/1292"},"comments":{"href":"https://api.github.com/repos/guzzle/guzzle/issues/1292/comments"},"review_comments":{"href":"https://api.github.com/repos/guzzle/guzzle/pulls/1292/comments"},"review_comment":{"href":"https://api.github.com/repos/guzzle/guzzle/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/guzzle/guzzle/pulls/1292/commits"},"statuses":{"href":"https://api.github.com/repos/guzzle/guzzle/statuses/ae2536bf7208fb876236f8edf950895f0f155ee2"}}}}