Subject: | Bug in UserAgent |
Date: | Fri, 20 Jun 2008 17:37:59 -0500 |
To: | marclang [...] cpan.org, rcaputo [...] pobox.com |
From: | "Da-Breegster" <dabreegster [...] gmail.com> |
The latest versions of both LWP::Parallel::UserAgent and
POE::Component::Client::UserAgent
share a similar bug regarding HTTP redirects. The behavior is observed
on sites such as
Youtube that return a 303 (see other) status code. Both modules only
test for "moved
permanently" and "moved temporarily." HTTP::Response has the proper
behavior:
$response->is_redirect consults HTTP::Status, which returns true if
it's a 3xx code. Thus,
in both modules, simply grep for RC_MOVED and replace the compound if
statement with if
($response->is_redirect). This appears to fix the buggy Youtube
behavior and doesn't seem to
break anything.
Sorry for not using the traditional perlbug method or CPAN bug
tracker. That what have
involved either setting up a local mail server or finding the password
to my old PAUSE
account. The bug seemed simple enough to describe like this.
Thanks for the great modules,
Da-Breegster