in reply to LWP::UserAgent not finishing get requests?
I'd start by eliminating variables. Specifically, comment out $ua->timeout(10); and $ua->env_proxy;.
even as_string() all return blank.
That's impossible! HTTP::Response objects are guaranteed to return "000 Unknown code" at the very least.
sub status_line { my $self = shift; my $code = $self->{'_rc'} || "000"; my $mess = $self->{'_msg'} || HTTP::Status::status_message($code) +|| "Unknown code"; return "$code $mess"; } sub as_string { require HTTP::Status; my $self = shift; my($eol) = @_; $eol = "\n" unless defined $eol; my $status_line = $self->status_line; my $proto = $self->protocol; $status_line = "$proto $status_line" if $proto; return join($eol, $status_line, $self->SUPER::as_string(@_)); }
And besides, we know that _rc is ≥200 and <300 because is_success returned true.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: LWP::UserAgent not finishing get requests?
by ttlgreen (Sexton) on Jan 17, 2009 at 02:01 UTC | |
by ikegami (Patriarch) on Jan 17, 2009 at 02:47 UTC | |
by ttlgreen (Sexton) on Jan 17, 2009 at 03:01 UTC |