Skip Menu |

This queue is for tickets about the URI-Title CPAN distribution.

Report information
The Basics
Id: 39694
Status: resolved
Priority: 0/
Queue: URI-Title

People
Owner: Nobody in particular
Requestors: ANDK [...] cpan.org
Cc: GAAS [...] cpan.org
AdminCc:

Bug Information
Severity: Important
Broken in: 1.81
Fixed in: 1.82



CC: gaas [...] cpan.org
Subject: libwww 5.815,5.816 break t/failure.t tests
As the subject says. One of my smoker boxes discovered the failing test. I'm not able to investigate the exact cause for the failure. I have seen a similar case with Acme::MetaSyntactic and maybe with mod_perl. Looking forward to getting this cleared up. Thanks,
aaah, that's what it was. Thanks. Fixed in 1.82 On Mon Sep 29 19:48:51 2008, ANDK wrote: Show quoted text
> As the subject says. One of my smoker boxes discovered the failing test. > I'm not able to investigate the exact cause for the failure. I have seen > a similar case with Acme::MetaSyntactic and maybe with mod_perl. > > Looking forward to getting this cleared up. > > Thanks,
On Tue Sep 30 04:19:54 2008, TOMI wrote: Show quoted text
> aaah, that's what it was. Thanks. Fixed in 1.82
What was the problem. Did I break compatibility in a bad way?
On Tue Sep 30 04:38:36 2008, GAAS wrote: Show quoted text
> On Tue Sep 30 04:19:54 2008, TOMI wrote:
> > aaah, that's what it was. Thanks. Fixed in 1.82
> > What was the problem. Did I break compatibility in a bad way? >
$ perl -I/Users/tomi/Downloads/libwww-perl-5.814/lib/ test.pl HTTP::Request is 5.814 LWP::UserAgent is 5.814 Got HTTP::Response=HASH(0x86ad2c): 400 URL must be absolute $ perl -I/Users/tomi/Downloads/libwww-perl-5.816/lib/ test.pl HTTP::Request is 5.815 LWP::UserAgent is 5.816 Bad request: URL must be absolute at test.pl line 13 $ cat test.pl #!/usr/bin/perl use warnings; use strict; use LWP::UserAgent; use HTTP::Request; print "HTTP::Request is $HTTP::Request::VERSION\n"; print "LWP::UserAgent is $LWP::UserAgent::VERSION\n"; my $req = HTTP::Request->new(GET => "foo"); my $ua = LWP::UserAgent->new(); my $response = $ua->request( $req ); print "Got $response: " . $response->content; (hope rt doesn't eat my formatting here..) One of my test cases was testing for failure by passing a nonsense string as an URL. I've fixed it by just wrapping the call in an eval and throwing away errors (I handle most failure cases in URI::Title by returning an empty string, rather than being helpful. I vaguely regret this, but that's history for you).
Sigh. I should be clearer, as opposed to just dumping code. Need coffee. Calling 'request', passing a request that's been initialised with a bad URL, is croaking with the string "Bad request: URL must be absolute". It's not croaking when I create the request object, but only when I pass it to the UA. It used to return a 400 failure response object with the error in the body of the response.
Thanks. I'll consider restoring the old behaviour. It's easier to use the API if it don't fail with an exception in this case.