[Haskell-cafe] Network.HTTP problem

Graham Fawcett graham.fawcett at gmail.com
Sat Nov 17 17:21:10 EST 2007


On Nov 17, 2007 4:52 PM, Radosław Grzanka <radoslawg at gmail.com> wrote:
> > > Also:
> > > $ ./get http://digg.com/rss/indexvideos_animation.xml
>
> However this one still seems to hang and eventually ends with :
> get: recv: resource vanished (Connection reset by peer)


It's not a Haskell problem. It looks like Digg expects a User-Agent
request header. Modify get.hs like this:

request uri = Request{ rqURI = uri,
                       rqMethod = GET,
                       rqHeaders = [Header HdrUserAgent "haskell-get-example"],
                       rqBody = "" }

and see what happens.

G


More information about the Haskell-Cafe mailing list