Skip to content

show(HTTP.Response) blocks forever #85

Closed
@samoconnor

Description

@samoconnor

I have a server that streams forever.

If I try to get with stream=true form the REPL, the REPL tries to do show(HTTP.Response) and that blocks forever...

julia> r = HTTP.get("http://127.0.0.1:8000"; stream = true)
HTTP.Response:
"""
HTTP/1.1 200 OK
Connection: keep-alive
Transfer-Encoding: chunked
Cache-Control: no-cache
Content-Type: text/event-stream
Date: Wed, 30 Aug 2017 00:17:46 GMT
<waits forever!!>

The same thing happens when I use @show from a source file:

r = HTTP.get("http://127.0.0.1:8000"; stream = true)
@show typeof(r)
@show r

for l in eachline(HTTP.body(r))
    println(l)
end
typeof(r) = HTTP.Response
<waits forever!!>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions