in reply to Problem using Perl to access a webpage

At first blush "500" is usually a configuration error on the server OR a badly written (broken) CGI script. What-cha got for code?


Peter L. Berghold -- Unix Professional
Peter at Berghold dot Net
   Dog trainer, dog agility exhibitor, brewer of fine Belgian style ales. Happiness is a warm, tired, contented dog curled up at your side and a good Belgian ale in your chalice.
  • Comment on Re: Problem using Perl to access a webpage

Replies are listed 'Best First'.
Re: Re: Problem using Perl to access a webpage
by iburrell (Chaplain) on Mar 04, 2004 at 21:29 UTC
    LWP will return a 500 status code when it can't connect to the server. From a web server, it indicates a problem on the server, usually a CGI script dying. With LWP, it can indicate a network connection problem. In this case, this is what is happening.

    I would suggest that this is a bug in LWP::UserAgent. It should instead choose another code, or not return a code at all. This behavior can be turned with the use_eval option.

Re: Re: Problem using Perl to access a webpage
by terriblue (Initiate) on Mar 05, 2004 at 01:57 UTC
    More likely the latter. I tried CGI::Carp to get more information. Working on cleaning it up now...