Skip Menu |

This queue is for tickets about the CPAN CPAN distribution.

Report information
The Basics
Id: 80662
Status: new
Priority: 0/
Queue: CPAN

People
Owner: Nobody in particular
Requestors: bohica [...] ntlworld.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 1.9800
Fixed in: (no value)



Subject: "reports" doesn't seem to use HTTP proxy settings
I have http_proxy env var set to http://squid.easysoft.local:8080 (which is my correct proxy server) and also http_proxy in my config: cpan[4]> o conf http_proxy http_proxy [http://squid.easysoft.local:8080] however when I run reports I get: cpan[6]> reports MJEVANS/DBD-ODBC-1.41.tar.gz Distribution: M/MJ/MJEVANS/DBD-ODBC-1.41.tar.gz path M/MJ/MJEVANS/DBD-ODBC-1.41.tar.gz Fetching 'http://www.cpantesters.org/show/DBD-ODBC.yaml'... Could not download 'http://www.cpantesters.org/show/DBD-ODBC.yaml': 500 Can't connect to www.cpantesters.org:80 (Connection refused) NOTE: the last argument in the error is LWP::UserAgent message which I added to CPAN::Distribution since error 500 is meanginless (it would be worth doing this anyway): $CPAN::Frontend->myprint("Fetching '$url'..."); my $resp = $Ua->get($url); unless ($resp->is_success) { $CPAN::Frontend->mydie(sprintf "Could not download '%s': %s %s\n", $url, $resp->code, $resp->message); I also added: my $Ua; eval { $Ua = CPAN::LWP::UserAgent->new;}; if ($@) { $CPAN::Frontend->mydie("CPAN::LWP::UserAgent->new dies with $@\n"); } # added the following 2 lines use Data::Dumper; $CPAN::Frontend->myprint("proxy is " . Dumper($Ua->proxy(['http'])) . "\n"); and they output: proxy is $VAR1 = undef; suggesting a proxy server is not being set on the LWP::UserAgent in the reports sub. I verified this is probably the case since adding $Ua- Show quoted text
>env_proxy to the end of the above eval made it work but it should
probably pull the proxy setting from the CPAN config. Martin -- Martin J. Evans Wetherby, UK