aderyabin / sniffer

Log and Analyze Outgoing HTTP Requests

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

HTTP with streaming error

palkan opened this issue · comments

When using http gem the following code fail:

res = get(uri)
body = res.body
while (s = body.readpartial)
  io << s
end
io

When Sniffer is enabled it raises body has already been consumed.

The body is consumed when to_s is called here.