[patch][merge] sftp/http tweaks

John Arbash Meinel john at arbash-meinel.com
Mon Jan 9 18:56:01 GMT 2006


Robey Pointer wrote:
> Since my bzr.robey branch only had 2 un-integrated patches in it  (when
> compared to bzr.dev), I blew it away, did a fresh branch from  bzr.dev,
> and applied just those 2 patches.
> 
> 1516: change http url parsing to use urlparse, and use the ui_factory 
> to ask for a password if necessary
> 1517: allow forcing the use of paramiko via environ var; use prefetch 
> on paramiko >= 1.5.2"
> 
> So I'd like to resubmit those for merge and/or feedback.
> 
> The branch is at http://www.lag.net/~robey/bzr.robey/
> 
> robey

Have you always had dots over the 'o' in your name?

I just saw that your latest commits were from 'Röbey Pointer'. Grepping
through the revision store, I see about 41 commits, and only the last 2
with ö. And your email name doesn't have them either.

I'm just curious if you were testing something. It might also be some of
the first instances of non-ascii characters in the commit logs.

Anyway, to review your changes:
The urlparse changes seem good to me.

Is there a reason that you check os.environ at the time of reading the
file, rather than doing that as part of _get_ssh_vendor()?

Also, I think it would be nicer to use something like:
BZR_USE_SSH=""
Where you can set it to exactly what you want, rather than only being
able to turn on paramiko.

Also, it turns out better to use 'getattr' than 'hasattr'. So it
probably would be best to do:

_default_do_prefetch = False
_paramiko_version = getattr(paramiko, '__version__info__', None)
if _paramiko_version is not None, and _paramiko_version >= (1,5,2):
  _default_do_prefetch = True


class SFTPTransport ...

  _do_prefetch = _default_do_prefetch

At least, thats my thoughts.

John
=:->

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 256 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060109/faec1d12/attachment.pgp 


More information about the bazaar mailing list