{"action":"created","issue":{"url":"https://api.github.com/repos/jnunemaker/httparty/issues/435","labels_url":"https://api.github.com/repos/jnunemaker/httparty/issues/435/labels{/name}","comments_url":"https://api.github.com/repos/jnunemaker/httparty/issues/435/comments","events_url":"https://api.github.com/repos/jnunemaker/httparty/issues/435/events","html_url":"https://github.com/jnunemaker/httparty/pull/435","id":107621218,"number":435,"title":"Stop trying to deflate responses that redirect.","user":{"login":"pvande","id":2350,"avatar_url":"https://avatars.githubusercontent.com/u/2350?v=3","gravatar_id":"","url":"https://api.github.com/users/pvande","html_url":"https://github.com/pvande","followers_url":"https://api.github.com/users/pvande/followers","following_url":"https://api.github.com/users/pvande/following{/other_user}","gists_url":"https://api.github.com/users/pvande/gists{/gist_id}","starred_url":"https://api.github.com/users/pvande/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvande/subscriptions","organizations_url":"https://api.github.com/users/pvande/orgs","repos_url":"https://api.github.com/users/pvande/repos","events_url":"https://api.github.com/users/pvande/events{/privacy}","received_events_url":"https://api.github.com/users/pvande/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-09-21T23:56:54Z","updated_at":"2015-09-23T16:05:25Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/jnunemaker/httparty/pulls/435","html_url":"https://github.com/jnunemaker/httparty/pull/435","diff_url":"https://github.com/jnunemaker/httparty/pull/435.diff","patch_url":"https://github.com/jnunemaker/httparty/pull/435.patch"},"body":"Some servers (including YouTube) will send a redirect response with a\r\nContent-Encoding header, but no body.  Since inflating an empty body\r\nraises an exception, we should minimally work around this problem for\r\nnon-terminal redirect responses.\r\n\r\nNote that this will still attempt to inflate a redirected response body\r\nif HTTParty is not configured to follow redirects (which will raise\r\nexceptions if the body is empty), and this does nothing to protect\r\nagainst otherwise empty responses with a compressed Content-Encoding\r\n(which may indicate a mis-configured server)."},"comment":{"url":"https://api.github.com/repos/jnunemaker/httparty/issues/comments/142649226","html_url":"https://github.com/jnunemaker/httparty/pull/435#issuecomment-142649226","issue_url":"https://api.github.com/repos/jnunemaker/httparty/issues/435","id":142649226,"user":{"login":"pvande","id":2350,"avatar_url":"https://avatars.githubusercontent.com/u/2350?v=3","gravatar_id":"","url":"https://api.github.com/users/pvande","html_url":"https://github.com/pvande","followers_url":"https://api.github.com/users/pvande/followers","following_url":"https://api.github.com/users/pvande/following{/other_user}","gists_url":"https://api.github.com/users/pvande/gists{/gist_id}","starred_url":"https://api.github.com/users/pvande/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvande/subscriptions","organizations_url":"https://api.github.com/users/pvande/orgs","repos_url":"https://api.github.com/users/pvande/repos","events_url":"https://api.github.com/users/pvande/events{/privacy}","received_events_url":"https://api.github.com/users/pvande/received_events","type":"User","site_admin":false},"created_at":"2015-09-23T16:05:25Z","updated_at":"2015-09-23T16:05:25Z","body":"This is closely related to [this bug](https://bugs.ruby-lang.org/issues/11058) in Ruby core, particularly the \"second problem\" (`Zlib::BufError`).\r\n\r\nSkipping all empty bodies is probably more correct, but I'm still new enough to the project that I wasn't 100% comfortable making that change without being aware of all the potential edge-cases (e.g. streaming bodies)."}}