launchpad proxy support

Gordon Tyler gordon at
Fri Oct 30 23:28:51 GMT 2009

On 10/30/2009 5:03 PM, Vincent Ladeuil wrote:
>      Gordon>  I was wondering that myself so I went and tested your
>      Gordon>  branch on my debian box at home using tinyproxy and
>      Gordon>  it worked. Color me extremely confused.
> As I understood it, you too had your version working before going
> too much into propagating the port, no ?

It was only once I forced the URL to use port 443 that it started 
working for me at work. I verified that it was a problem with the 
underlying urllib2 code by testing with lp-login which doesn't use 
xmlrpc, just the standard bzrlib http transport (i.e. _urllib2_wrappers).

> May be you didn't test the same *revno* at work and at home ?
> revno 4781 added the port.

I was fairly careful about that. I'm new to bazaar so I'm 
double-checking everything that I do to make sure that I have the 
correct version, etc.

>      Gordon>  When I tested my changes to use the _urllib2_wrappers
>      Gordon>  but without the port correction, it was
>      Gordon>  failing.
> At home or at work ?

I had to go back and reread my email trail, but here's what happened: My 
initial attempt was failing in both environments but not due to the port 
issue, the request was just not being formed correctly or something due 
to the way Bill originally implemented the transport. Once I rewrote 
Bill's code into a simpler form, it started working with tinyproxy at 
home but was failing with the 502 proxy error when using cntlm at work. 
Once I forced the port, it started working at work.

> Well, I can say for sure that httplib and urllib2 are very easy
> to get confused with. _urllib2_wrappers implements a lot of
> additional features *AND* fix many bugs encountered along the
> way, the result is... feature-complete as far as bzr is
> concerned, but I'd really like to rewrite the whole lot as an
> enhanced httplib and get rid of the recursive call chains in the
> Opener objects...

Sounds like a nice idea but that's a lot of effort. Is mere code 
cleanliness worth it? Personally, I would tend to agree, but your or the 
project's priorities may be different.

> But you confirm that the fix works right ?


> The code I pushed *set* the port so it should be displayed like that.


> Thanks for the heads-up !

You're welcome.

Do you think this will get into a 2.0.x release?


More information about the bazaar mailing list