Skip Menu |

This queue is for tickets about the POE-Component-Client-UserAgent CPAN distribution.

Report information
The Basics
Id: 31287
Status: resolved
Priority: 0/
Queue: POE-Component-Client-UserAgent

People
Owner: Nobody in particular
Requestors: gm [...] cruft.de
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.06
Fixed in: (no value)



Subject: Tests fail if using http_proxy ENV variable
All tests hang (which is tantamount to failure) whilst using the http_proxy environment variable. POE::Component::Client::UserAgent doesn't honour the env_proxy argument for LWP::UserAgent->new in sub _pococ_ua_start. Patch attached. best regards, shmem ----------- distribution: POE-Component-Client-UserAgent-0.06 perl version: 5.8.8 i386-linux-thread-multi OS version : Linux 2.6.22.9-91.fc7 i686 (Fedora 7)
Subject: PCCUA.patch
--- UserAgent.pm.orig 2004-09-04 00:28:31.000000000 +0200 +++ UserAgent.pm 2007-12-07 12:11:26.000000000 +0100 @@ -56,7 +56,7 @@ $$heap{alias} = $alias; $object -> $_ ($$args{$_}) for grep exists ($$args{$_}), qw(agent from timeout redirect duplicates in_order remember_failures - proxy cookie_jar parse_head max_size max_hosts max_req delay); + env_proxy proxy cookie_jar parse_head max_size max_hosts max_req delay); $kernel->sig(INT => 'sigint'); $kernel->sig(BREAK => 'sigint'); } --- t/01basic.t.orig 2002-10-21 03:02:50.000000000 +0200 +++ t/01basic.t 2007-12-07 12:09:51.000000000 +0100 @@ -39,7 +39,7 @@ { warn "%%% Start event arrived.\n" if $debuglevel >= 3; warn "%%% Starting POE::Component::Client::UserAgent...\n" if $debuglevel >= 3; - POE::Component::Client::UserAgent -> new; + POE::Component::Client::UserAgent -> new(env_proxy => 1); warn "%%% Sending a test request...\n" if $debuglevel >= 3; $_[KERNEL] -> post (useragent => request => request => HTTP::Request -> new (GET => $url), --- t/02multi.t.orig 2002-10-21 03:02:45.000000000 +0200 +++ t/02multi.t 2007-12-07 12:10:02.000000000 +0100 @@ -69,7 +69,7 @@ { warn "%%% Start event arrived.\n" if $debuglevel >= 3; warn "%%% Starting POE::Component::Client::UserAgent...\n" if $debuglevel >= 3; - POE::Component::Client::UserAgent -> new; + POE::Component::Client::UserAgent -> new(env_proxy => 1); warn "%%% Sending test requests...\n" if $debuglevel >= 3; my $postback = $_[SESSION] -> postback ('response'); $_[KERNEL] -> post (useragent => request => --- t/03chunks.t.orig 2004-05-02 20:56:50.000000000 +0200 +++ t/03chunks.t 2007-12-07 12:10:11.000000000 +0100 @@ -39,7 +39,7 @@ { warn "%%% Start event arrived.\n" if $debuglevel >= 3; warn "%%% Starting POE::Component::Client::UserAgent...\n" if $debuglevel >= 3; - POE::Component::Client::UserAgent -> new; + POE::Component::Client::UserAgent -> new(env_proxy => 1); warn "%%% Sending a test request...\n" if $debuglevel >= 3; $_[KERNEL] -> post (useragent => request => request => HTTP::Request -> new (GET => $url),
Thank you for the patch. I have applied it as revision 14. I am not able to test your patch, however, as LWP::Parallel fails to install. I will just trust it works.