From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040808 Firefox/0.9.3 Description of problem: python urllib (via yum 2.1.3-1) does not look for or honor the no_proxy environment variable. Please reference this bug in python bugtracker: http://sourceforge.net/tracker/index.php?func=detail&aid=856047&group_id=5470&atid=105470 (note: the attached patch appears to be gzipped twice, strange...) I didn't know what the protocol was for merging patches not yet applied upstream, but I wanted to report the issue... Version-Release number of selected component (if applicable): python-2.3.4-10 How reproducible: Always Steps to Reproduce: From behind a firewall with a non-transparent proxy: 1. set http_proxy to whatever 2. set no_proxy to mydomain.com 3. have yum.conf point to a repo in mydomain.com 4. yum update Actual Results: we're hitting the proxy Expected Results: we shouldn't hit the proxy Additional info:
in the newer yum's the proxy stuff _should_ work per-repository. if you set the proxy info in the yum.conf or *.repo files and then don't set it for the location where you don't want it, does it work?
configuring it on a per-repository case is not a good solution. Proxies are a system-wide but not application-specific setting (except some special cases like anonymizing proxy in your browser, but this does not matter here). Most (mature) software understands and honors the $http_proxy + $no_proxy environment variables for proxy setup (firefox/mozilla is the only exception I know), and so, urllib should do it also.
I'm not arguging that urllib should not do it. I'm just explaining in the case of yum the proxy stuff CAN be done per-repo.
The patch didn't make it into 2.4.1 either. I am hesitant to adding patches that we would have to support ourselves, therefore I am closing the bug as WONTFIX. But please do feel free to reopen it if you feel strongly about having this in, even though I would recommend getting the patch merged upstream.
ok, reopening the bug as suggested ;) no_proxy support is elementarily for every HTTP aware application. The broken urllib makes e.g. the nightly yum updates impossible because the *_proxy env is set globally.
Really needs to be applied upstream; we're already carrying way too many non-upstreamed patches to python and I'm trying to get that number down. Added myself to the upstream bug to watch for it. (Note that their concern afaict is that it only fixes urllib and not urllib2 as well)